OBS User unknown 2008-11-06 21:23:05 +00:00 committed by Git OBS Bridge
parent ee5cc2e86f
commit 96cc5a8614
3 changed files with 105 additions and 155 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Nov 6 06:25:48 CET 2008 - jjolly@suse.de
- Overhaul of the specfile. All platforms build the base package
and each architecture builds the appropriate 32 or 64 bit package
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Sep 12 06:55:17 CEST 2008 - jjolly@suse.de Fri Sep 12 06:55:17 CEST 2008 - jjolly@suse.de

View File

@ -11,7 +11,7 @@
# #
### BEGIN INIT INFO ### BEGIN INIT INFO
# Provides: pkcsslotd # Provides: pkcsslotd
# Required-Start: $null # Required-Start: $remote_fs
# Required-Stop: $null # Required-Stop: $null
# Should-Start: z90crypt # Should-Start: z90crypt
# Should-Stop: z90crypt # Should-Stop: z90crypt

View File

@ -17,49 +17,6 @@
# norootforbuild # norootforbuild
%define oc_cvs_tag opencryptoki-%{version}
Name: openCryptoki
BuildRequires: gcc-c++ libica openssl-devel pwdutils
Summary: An Implementation of PKCS#11 (Cryptoki) v2.11 for IBM Cryptographic Hardware
Version: 2.2.6
Release: 1
License: IBM Public License
Group: Productivity/Security
# :pserver:anonymous@cvs.sourceforge.net:/cvsroot/opencryptoki
# cvs co -r openCryptoki-2-1-5 -d openCryptoki-2-1-5 .
Source: %{oc_cvs_tag}.tar.bz2
Source1: openCryptoki.pkcsslotd
Source2: openCryptoki-TFAQ.html
# Patch0: openCryptoki-autoconf.patch
# Patch1: openCryptoki-config.patch
# Patch3: openCryptoki-compile-fixes.patch
# Patch4: openCryptoki-no_mmap.patch
# Patch5: openCryptoki-per_user.patch
# Patch6: openCryptoki-prototypes.patch
# Patch7: ock_add_free_mech_list_20060131.diff
# Patch8: ock_head_ptr_to_null_20060308.diff
# Patch9: ock_222_proc_struct_cmd_20060309.diff
# Patch10: ock_222_cmd_fix_ptr_to_arr.diff
# Patch11: ock_64_bit_fixes.diff
# Patch12: openCryptoki-pkcsslotd-removepidfile.patch
# Patch13: openCryptoki-retval.patch
Url: http://oss.software.ibm.com/developerworks/opensource/opencryptoki
BuildRoot: %{_tmppath}/%{name}-%{version}-build
PreReq: /usr/sbin/groupadd /usr/bin/id /usr/sbin/usermod /bin/sed
Requires: libica
# the userland tools are only maintained in 32bit, when a 32bit
# userland compatibility is available for the corresponding 64bit
# architecture.
#
# Thus, the user is supposed to install the 32bit package and the
# additional 64bit package together.
#
#
# openCryptoki contains the common files. is always installed natively
# openCryptoki-32bit contains the 32bit binaries for native use and
# for the 'other' distribution
# openCryptoki-64bit contains the 64bit binaries for use on the 'other' distribution
%define openCryptoki_32bit_arch %ix86 s390 ppc %arm %define openCryptoki_32bit_arch %ix86 s390 ppc %arm
# support in the workings for: ppc64 # support in the workings for: ppc64
# no support in sight for: ia64 x86_64 # no support in sight for: ia64 x86_64
@ -67,6 +24,23 @@ Requires: libica
# autobuild:/work/cd/lib/misc/group # autobuild:/work/cd/lib/misc/group
# openCryptoki pkcs11:x:64: # openCryptoki pkcs11:x:64:
%define pkcs11_group_id 64 %define pkcs11_group_id 64
%define oc_cvs_tag opencryptoki-%{version}
Name: openCryptoki
BuildRequires: gcc-c++ libica openssl-devel pwdutils
Summary: An Implementation of PKCS#11 (Cryptoki) v2.11 for IBM Cryptographic Hardware
Version: 2.2.6
Release: 2
License: IBM Public License
Group: Productivity/Security
# :pserver:anonymous@cvs.sourceforge.net:/cvsroot/opencryptoki
# cvs co -r openCryptoki-2-1-5 -d openCryptoki-2-1-5 .
Source: %{oc_cvs_tag}.tar.bz2
Source1: openCryptoki.pkcsslotd
Source2: openCryptoki-TFAQ.html
Url: http://oss.software.ibm.com/developerworks/opensource/opencryptoki
BuildRoot: %{_tmppath}/%{name}-%{version}-build
PreReq: /usr/sbin/groupadd /usr/bin/id /usr/sbin/usermod /bin/sed
# IBM maintains openCryptoki on these architectures: # IBM maintains openCryptoki on these architectures:
ExclusiveArch: %openCryptoki_32bit_arch %openCryptoki_64bit_arch ExclusiveArch: %openCryptoki_32bit_arch %openCryptoki_64bit_arch
# #
@ -79,48 +53,6 @@ Cryptographic Accelerator (FC 4960 on pSeries).
%ifarch %openCryptoki_32bit_arch
%package 32bit
License: IBM Public License
%else
%package 64bit
License: IBM Public License
%endif
Summary: Implementation of PKCS#11 (Cryptoki) v2.01 for IBM Crypto Hardware
Group: Productivity/Security
# this is needed to make sure the pkcs11 group exists before
# installation:
PreReq: openCryptoki
%ifarch %openCryptoki_32bit_arch
%description 32bit
This is a re-packaged binary rpm. For the package source, please look
for the source of the package without the "32bit" ending
The PKCS#11 version 2.01 API implemented for the IBM cryptographic
cards. This package includes support for the IBM 4758 cryptographic
co-processor (with the PKCS#11 firmware loaded) and the IBM eServer
Cryptographic Accelerator (FC 4960 on pSeries).
%else
%description 64bit
This is a re-packaged binary rpm. For the package source, please look
for the source of the package without the "64bit" ending
The PKCS#11 Version 2.01 api implemented for the IBM Crypto cards. This
package includes support for the IBM 4758 Cryptographic CoProcessor
(with the PKCS#11 firmware loaded) and the IBM eServer Cryptographic
Accelerator (FC 4960 on pSeries)
%endif
%package devel %package devel
License: IBM Public License License: IBM Public License
Summary: An Implementation of PKCS#11 (Cryptoki) v2.01 for IBM Cryptographic Hardware Summary: An Implementation of PKCS#11 (Cryptoki) v2.01 for IBM Cryptographic Hardware
@ -135,22 +67,56 @@ Cryptographic Accelerator (FC 4960 on pSeries).
%ifarch %openCryptoki_32bit_arch
%package 32bit
License: IBM Public License
Summary: An Implementation of PKCS#11 (Cryptoki) v2.01 for IBM Cryptographic Hardware
Group: Productivity/Security
# this is needed to make sure the pkcs11 group exists before
# installation:
PreReq: openCryptoki
ExclusiveArch: %openCryptoki_32bit_arch
%description 32bit
This is a re-packaged binary rpm. For the package source, please look
for the source of the package without the "32bit" ending
The PKCS#11 version 2.01 API implemented for the IBM cryptographic
cards. This package includes support for the IBM 4758 cryptographic
co-processor (with the PKCS#11 firmware loaded) and the IBM eServer
Cryptographic Accelerator (FC 4960 on pSeries).
%endif
%ifarch %openCryptoki_64bit_arch
%package 64bit
License: IBM Public License
Summary: Implementation of PKCS#11 (Cryptoki) v2.01 for IBM Crypto Hardware
Group: Productivity/Security
# this is needed to make sure the pkcs11 group exists before
# installation:
PreReq: openCryptoki
ExclusiveArch: %openCryptoki_64bit_arch
%description 64bit
This is a re-packaged binary rpm. For the package source, please look
for the source of the package without the "64bit" ending
The PKCS#11 Version 2.01 api implemented for the IBM Crypto cards. This
package includes support for the IBM 4758 Cryptographic CoProcessor
(with the PKCS#11 firmware loaded) and the IBM eServer Cryptographic
Accelerator (FC 4960 on pSeries)
%endif
%prep %prep
%setup -q -n %{oc_cvs_tag} %setup -q -n %{oc_cvs_tag}
# %patch1
# %patch3
# %patch4
# %patch5
# %patch6
# %patch7
# %patch8 -p1
# %patch9
# %patch10 -p1
# %patch11 -p2
# %patch12
# %patch13
cp %{SOURCE2} . cp %{SOURCE2} .
#find -name CVS -type d -print0 | xargs -0 rm -rfv
%build %build
autoreconf --force --install autoreconf --force --install
@ -159,38 +125,15 @@ make
%install %install
make install DESTDIR=$RPM_BUILD_ROOT INSROOT=$RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT INSROOT=$RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/usr/include install -d $RPM_BUILD_ROOT/usr/include
mkdir -p $RPM_BUILD_ROOT/var/lib/opencryptoki install -d $RPM_BUILD_ROOT/var/lib/opencryptoki
mkdir -p $RPM_BUILD_ROOT/etc/init.d install -d $RPM_BUILD_ROOT/etc/init.d
mkdir -p $RPM_BUILD_ROOT/usr/sbin install -d $RPM_BUILD_ROOT/usr/sbin
cp -av %{S:1} $RPM_BUILD_ROOT/etc/init.d/pkcsslotd install -m 544 %{S:1} $RPM_BUILD_ROOT/etc/init.d/pkcsslotd
ln -sfv ../../etc/init.d/pkcsslotd $RPM_BUILD_ROOT/usr/sbin/rcpkcsslotd ln -sfv ../../etc/init.d/pkcsslotd $RPM_BUILD_ROOT/usr/sbin/rcpkcsslotd
rm -rf $RPM_BUILD_ROOT/tmp rm -rf $RPM_BUILD_ROOT/tmp
# Remove all development files # Remove all development files
rm -f $RPM_BUILD_ROOT${_libdir}/opencryptoki/libopencryptoki.la rm -f $RPM_BUILD_ROOT${_libdir}/opencryptoki/libopencryptoki.la
#
# FIX to build it on ppc64
#
# %ifarch ppc64
# rm -f $RPM_BUILD_ROOT/usr/lib/pkcs11/methods/pkcs11_startup
# rm -f $RPM_BUILD_ROOT/usr/lib/pkcs11/methods/pkcs_slot
# rm -f $RPM_BUILD_ROOT/usr/lib/pkcs11/stdll/PKCS11_SW.so
# rm -f $RPM_BUILD_ROOT/usr/sbin/pkcsslotd
# %endif
%ifnarch %openCryptoki_32bit_arch
rm -f $RPM_BUILD_ROOT/etc/init.d/pkcsslotd
rm -f $RPM_BUILD_ROOT/usr/include/opencryptoki/apiclient.h
rm -f $RPM_BUILD_ROOT/usr/include/opencryptoki/pkcs11.h
rm -f $RPM_BUILD_ROOT/usr/include/opencryptoki/pkcs11types.h
rm -f $RPM_BUILD_ROOT/usr/lib64/opencryptoki/libopencryptoki.la
rm -f $RPM_BUILD_ROOT/usr/lib64/opencryptoki/stdll/libpkcs11_ica.la
rm -f $RPM_BUILD_ROOT/usr/lib64/opencryptoki/stdll/libpkcs11_sw.la
rm -f $RPM_BUILD_ROOT/usr/sbin/pkcs11_startup
rm -f $RPM_BUILD_ROOT/usr/sbin/pkcs_slot
rm -f $RPM_BUILD_ROOT/usr/sbin/pkcsconf
rm -f $RPM_BUILD_ROOT/usr/sbin/pkcsslotd
rm -f $RPM_BUILD_ROOT/usr/sbin/rcpkcsslotd
%endif
rm -f $RPM_BUILD_ROOT/%_libdir/opencryptoki/methods rm -f $RPM_BUILD_ROOT/%_libdir/opencryptoki/methods
%pre %pre
@ -205,18 +148,26 @@ rm -f $RPM_BUILD_ROOT/%_libdir/opencryptoki/methods
# replace spaces by commas # replace spaces by commas
y/ /,/ y/ /,/
'),pkcs11 root '),pkcs11 root
%ifarch %openCryptoki_32bit_arch
%post
# Symlink from /var/lib/opencryptoki to /etc/pkcs11
if [ ! -L %{_sysconfdir}/pkcs11 ] ; then
if [ -e %{_sysconfdir}/pkcs11/pk_config_data ] ; then
mv %{_sysconfdir}/pkcs11/* %{_localstatedir}/lib/opencryptoki
cd %{_sysconfdir} && rm -rf pkcs11 && \
ln -sf %{_localstatedir}/lib/opencryptoki pkcs11
fi
fi
%postun %postun
if [ -L %{_sysconfdir}/pkcs11 ] ; then if [ -L %{_sysconfdir}/pkcs11 ] ; then
rm %{_sysconfdir}/pkcs11 rm %{_sysconfdir}/pkcs11
fi fi
%ifarch %openCryptoki_32bit_arch
%postun 32bit %postun 32bit
# remove the openCryptoki start script # remove the openCryptoki start script
%{insserv_cleanup} %{insserv_cleanup}
%endif
%ifarch %openCryptoki_32bit_arch
%post 32bit %post 32bit
# Old library name links # Old library name links
@ -230,7 +181,8 @@ if [ -d %{_libdir}/pkcs11 ] ; then
[ -f libpkcs11_ica.so ] && ln -sf ./libpkcs11_ica.so PKCS11_ICA.so || true [ -f libpkcs11_ica.so ] && ln -sf ./libpkcs11_ica.so PKCS11_ICA.so || true
[ -f libpkcs11_sw.so ] && ln -sf ./libpkcs11_sw.so PKCS11_SW.so || true [ -f libpkcs11_sw.so ] && ln -sf ./libpkcs11_sw.so PKCS11_SW.so || true
fi fi
%else %endif
%ifarch %openCryptoki_64bit_arch
%post 64bit %post 64bit
# Old library name for 64bit libs were under /usr/lib/pkcs11. For migration purposes only. # Old library name for 64bit libs were under /usr/lib/pkcs11. For migration purposes only.
@ -238,18 +190,6 @@ test -d /usr/lib/pkcs11 || mkdir -p /usr/lib/pkcs11
ln -sf %{_libdir}/opencryptoki/libopencryptoki.so /usr/lib/pkcs11/PKCS11_API.so64 ln -sf %{_libdir}/opencryptoki/libopencryptoki.so /usr/lib/pkcs11/PKCS11_API.so64
%endif %endif
%post
# Symlink from /var/lib/opencryptoki to /etc/pkcs11
if [ ! -L %{_sysconfdir}/pkcs11 ] ; then
if [ -e %{_sysconfdir}/pkcs11/pk_config_data ] ; then
mv %{_sysconfdir}/pkcs11/* %{_localstatedir}/lib/opencryptoki
cd %{_sysconfdir} && rm -rf pkcs11 && \
ln -sf %{_localstatedir}/lib/opencryptoki pkcs11
fi
fi
###################################################################
%ifarch %openCryptoki_32bit_arch
%files %files
%defattr(-,root,root) %defattr(-,root,root)
%doc openCryptoki-TFAQ.html %doc openCryptoki-TFAQ.html
@ -266,6 +206,15 @@ fi
%dir %{_libdir}/opencryptoki/stdll %dir %{_libdir}/opencryptoki/stdll
%{_mandir}/man*/* %{_mandir}/man*/*
%files devel
%defattr(-,root,root)
%dir %{_libdir}/opencryptoki
%dir %{_libdir}/opencryptoki/stdll
%{_libdir}/opencryptoki/*.la
%{_libdir}/opencryptoki/stdll/*.la
%{_includedir}/opencryptoki
%ifarch %openCryptoki_32bit_arch
%files 32bit %files 32bit
%defattr(-,root,root) %defattr(-,root,root)
# these don't conflict because they only exist as 64bit binaries if # these don't conflict because they only exist as 64bit binaries if
@ -288,16 +237,8 @@ fi
# %{_libdir}/libopencryptoki.so # %{_libdir}/libopencryptoki.so
# %{_libdir}/libopencryptoki.so.0 # %{_libdir}/libopencryptoki.so.0
%{_sysconfdir}/ld.so.conf.d/* %{_sysconfdir}/ld.so.conf.d/*
%endif
%files devel %ifarch %openCryptoki_64bit_arch
%defattr(-,root,root)
%dir %{_libdir}/opencryptoki
%dir %{_libdir}/opencryptoki/stdll
%{_libdir}/opencryptoki/*.la
%{_libdir}/opencryptoki/stdll/*.la
%{_includedir}/opencryptoki
###################################################################
%else # not openCryptoki_32bit_arch but 64bit arch
%files 64bit %files 64bit
%defattr(-,root,root) %defattr(-,root,root)
@ -315,6 +256,9 @@ fi
%endif %endif
%changelog %changelog
* Thu Nov 06 2008 jjolly@suse.de
- Overhaul of the specfile. All platforms build the base package
and each architecture builds the appropriate 32 or 64 bit package
* Fri Sep 12 2008 jjolly@suse.de * Fri Sep 12 2008 jjolly@suse.de
- Updated to openCryptoki v2.2.6 - Updated to openCryptoki v2.2.6
* Thu Aug 28 2008 ro@suse.de * Thu Aug 28 2008 ro@suse.de
@ -385,7 +329,7 @@ fi
- Fixed configure errors. - Fixed configure errors.
* Mon Jun 23 2003 ro@suse.de * Mon Jun 23 2003 ro@suse.de
- added directories to filelist - added directories to filelist
* Wed Jun 04 2003 ro@suse.de * Tue Jun 03 2003 ro@suse.de
- remove CVS subdirs - remove CVS subdirs
- remove unpackaged files from buildroot - remove unpackaged files from buildroot
* Thu Nov 21 2002 ro@suse.de * Thu Nov 21 2002 ro@suse.de
@ -437,7 +381,7 @@ fi
* Mon Jul 29 2002 froh@suse.de * Mon Jul 29 2002 froh@suse.de
- updated to current version - updated to current version
- removed old START_ variable - removed old START_ variable
* Fri Jun 14 2002 ro@suse.de * Thu Jun 13 2002 ro@suse.de
- always use macros when calling insserv - always use macros when calling insserv
* Tue Apr 09 2002 bk@suse.de * Tue Apr 09 2002 bk@suse.de
- add lib64 support - add lib64 support