Skip to content

Instantly share code, notes, and snippets.

@jorritfolmer
Created December 12, 2015 18:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jorritfolmer/e7c66cce9b968b1019da to your computer and use it in GitHub Desktop.
Save jorritfolmer/e7c66cce9b968b1019da to your computer and use it in GitHub Desktop.

Spec file to generate libnss-ato RPMS for RHEL systems

Name:		libnss-ato
Version:	1.0
Release:	1%{?dist}
Summary:	NSS catchall module

Group:		System Environment/Libraries
License:	GPL 2.0
Vendor:		Pietro Donatini
URL:		https://github.com/donapieppo/libnss-ato
Source0:	%{name}-%{version}.zip
BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

BuildRequires:	gcc
BuildRequires:	make
Requires:	python


%description
The libnss_ato module is a set of C library extensions which allows to map
every nss request for unknown user to a single predefined user. 

%prep
%setup -q -n libnss-ato-master


%build
make  %{?_smp_mflags}

%install
rm -rf %{buildroot}
install -D libnss_ato.so.2 %{buildroot}/%{_lib}/libnss_ato.so.2
install -D libnss-ato.conf %{buildroot}/etc/libnss-ato.conf

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
/%{_lib}/libnss_ato.so.2
%config /etc/libnss-ato.conf

%changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment