65 lines
1.6 KiB
RPMSpec
65 lines
1.6 KiB
RPMSpec
%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 --nodedir=/usr
|
|
|
|
%install
|
|
rm -rf build/Release/obj.target
|
|
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
|
|
%{nodejs_sitelib}/%{npm_name}
|
|
|
|
%changelog
|
|
* Tue Jun 09 2026 Zoran Pericic <zpericic@netst.org> - 1.0.4-1
|
|
- Initial package
|