RPM packaging: fix smartcardauth r14.0.x build

pull/3/head
François Andriot 8 years ago
parent dff38fdb79
commit 1a3660cb3f

@ -56,7 +56,6 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source0: %{name}-%{tde_version}%{?preversion:~%{preversion}}.tar.gz
Source1: trinity-%{tde_pkg}-rpmlintrc
#Patch0: %{tde_pkg}-14.0.0.patch
BuildRequires: trinity-tdelibs-devel >= %{tde_version}
BuildRequires: trinity-tdebase-devel >= %{tde_version}
@ -126,6 +125,22 @@ BuildRequires: pam-devel
# TLS support
BuildRequires: gnutls-devel
# PRETTYPRINT utility
%if "%{?tde_version}" != "14.1.0"
%if 0%{?rhel} || 0%{?fedora}
BuildRequires: nss-tools
%define pp %{_libdir}/nss/unsupported-tools/pp
%endif
%if 0%{?mgaversion} || 0%{?mdkversion}
BuildRequires: nss
%define pp /usr/bin/pp
%endif
%if 0%{?suse_version}
BuildRequires: mozilla-nss-tools
%define pp /usr/lib/nss/pp
%endif
%endif
%description
This utility will allow you to set up your computer to accept a SmartCard as an authentication source for:
@ -152,17 +167,17 @@ in addition to the PKCS certificate functionality
%prep
%setup -q -n %{name}-%{tde_version}%{?preversion:~%{preversion}}
#patch0 -p1
%__sed -i "Makefile" \
-e "s|/usr/lib/perl5/Chipcard|%{_libdir}/perl5/vendor_perl/Chipcard|g"
-e "s|/usr/lib/perl5/Chipcard|%{_libdir}/perl5/vendor_perl/Chipcard|g" \
-e "s|/usr/bin/pp|%{pp}|"
%build
export PATH="%{tde_bindir}:${PATH}"
cd src
make CFLAGS="${RPM_OPT_FLAGS}" CXXFLAGS="${RPM_OPT_FLAGS}"
make CFLAGS="${RPM_OPT_FLAGS}" CXXFLAGS="${RPM_OPT_FLAGS}"
%install
@ -178,9 +193,27 @@ export PATH="%{tde_bindir}:${PATH}"
%files
%defattr(-,root,root,-)
%doc gpl.txt
%if "%{tde_version}" == "14.1.0"
%{_bindir}/cardpincheck
%{_bindir}/cryptosmartcard.sh
%{_datadir}/initramfs-tools/
%else
%dir %{_sysconfdir}/init
%{_sysconfdir}/init/smartauthlogin.conf
%{_sysconfdir}/smartauth/
%{tde_bindir}/cryptosmartcard.sh
%{tde_bindir}/scriptor.pl
%{tde_bindir}/setupcard.sh
%{tde_bindir}/setupslavecard.sh
%{tde_bindir}/smartauth.sh
%{tde_bindir}/smartauthckpasswd
%{tde_bindir}/smartauthmon
%{tde_datadir}/applications/smartcardauth.desktop
%{tde_datadir}/applications/smartcardrestrict.desktop
%{tde_datadir}/icons/hicolor/16x16/apps/smartcardauth.png
%{tde_datadir}/icons/hicolor/32x32/apps/smartcardauth.png
%{tde_datadir}/initramfs-tools/
%endif
%changelog

Loading…
Cancel
Save