From fdfb46a2d447bbedbd1e2fd42bb2d500aadf86f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zoran=20Peri=C4=8Di=C4=87?= Date: Tue, 9 Jun 2026 09:50:48 +0200 Subject: [PATCH] nodejs-napi-ldap: initial package 1.0.4 --- nodejs-napi-ldap.spec | 64 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 nodejs-napi-ldap.spec diff --git a/nodejs-napi-ldap.spec b/nodejs-napi-ldap.spec new file mode 100644 index 0000000..ba12220 --- /dev/null +++ b/nodejs-napi-ldap.spec @@ -0,0 +1,64 @@ +%global npm_name napi-ldap + +%{?nodejs_default_filter} + +Name: nodejs-%{npm_name} +Version: 1.0.4 +Release: 1%{?dist} +Summary: Native OpenLDAP bindings for Node.js via N-API +License: MIT +URL: https://github.com/jjhoughton/napi-ldap + +Source0: %{npm_name}-%{version}.tgz +Source1: %{npm_name}-%{version}-nm-prod.tgz +Source2: %{npm_name}-%{version}-bundled-licenses.txt + +BuildRequires: nodejs-devel +BuildRequires: nodejs-npm +BuildRequires: gcc-c++ +BuildRequires: make +BuildRequires: openldap-devel +BuildRequires: cyrus-sasl-devel +BuildRequires: libuuid-devel +BuildRequires: openssl-devel + +Requires: nodejs +Requires: openldap +Requires: cyrus-sasl-lib + +Provides: bundled(npm(bindings)) = 1.5.0 + +%description +Native OpenLDAP bindings for Node.js using N-API. Provides LDAP search, +bind, add, modify, delete, and SyncRepl (RFC 4533) support by linking +against the system libldap. + +%prep +%setup -q -n package +cp -p %{S:2} . + +tar -xzf %{S:1} +mkdir -p node_modules/.bin/ +ln -srt node_modules/ node_modules_prod/* +ln -srt node_modules/.bin/ node_modules_prod/.bin + +%build +USE_SYSTEM_LDAP=1 npm rebuild + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{npm_name} +cp -pr main.js LDAPError.js package.json build node_modules_prod node_modules \ + %{buildroot}%{nodejs_sitelib}/%{npm_name}/ + +%check +%{__nodejs} -e 'require("./")' + +%files +%license LICENSE %{npm_name}-%{version}-bundled-licenses.txt +%doc README.md +%dir %{nodejs_sitelib}/%{npm_name} +%{nodejs_sitelib}/%{npm_name} + +%changelog +* Tue Jun 09 2026 Zoran Pericic - 1.0.4-1 +- Initial package