Sophie

Sophie

distrib > Mandriva > 2009.0 > i586 > by-pkgid > 39f376582600e43ca97c0b59a97de052 > files > 3

libchipcard-4.2.0-1mdv2009.0.src.rpm

%define name libchipcard
%define version 4.2.0
%define fversion %{version}
%define release %mkrel 1
%define major 0
%define libname %mklibname chipcard %major
%define libnamedev %mklibname -d chipcard
%define clientmajor 2
%define clientlibname %mklibname chipcardc %clientmajor

Summary: A library for easy access to smart cards (chipcards)
Name: %{name}
Version: %{version}
Release: %{release}
Source: http://prdownloads.sourceforge.net/libchipcard/%{name}-%{fversion}.tar.gz
# (fc)  3.0.2-3mdv fix initscript
Patch0: libchipcard-4.0.0-fixinitscript.patch

Group: System/Libraries
License: LGPLv2
URL: http://www.libchipcard.de
BuildRoot: %{_tmppath}/%{name}-%{version}-root
BuildRequires: libgwenhywfar-devel >= 3.0.0
BuildRequires: libpcsclite-devel
BuildRequires: libusb-devel
BuildRequires: libsysfs-devel
Requires(post): rpm-helper
Requires(preun): rpm-helper
Conflicts: libchipcard2

%description
Libchipcard allows easy access to smart cards. It provides basic access
to memory and processor cards and has special support for German medical
cards, German "Geldkarten" and HBCI (homebanking) cards (both type 0 and 
type 1).

It accesses the readers via CTAPI or PC/SC interfaces and has successfully
been tested with Towitoko, Kobil and Reiner-SCT readers.

This package contains the chipcard3-daemon needed to access card readers.

%package -n %libname
Group: System/Libraries
Summary: A library for easy access to smart cards (chipcards)
Requires: %name >= %version

%description -n %libname
Libchipcard allows easy access to smart cards. It provides basic access
to memory and processor cards and has special support for German medical
cards, German "Geldkarten" and HBCI (homebanking) cards (both type 0 and 
type 1).

It accesses the readers via CTAPI or PC/SC interfaces and has successfully
been tested with Towitoko, Kobil and Reiner-SCT readers.

This package contains the chipcard3-daemon needed to access card readers.


%package -n %libnamedev
Summary: LibChipCard server development kit
Group: Development/C
Requires: %libname = %version
Requires: %clientlibname = %version
Provides: %name-devel = %version-%release
Obsoletes: %mklibname -d chipcard 3 0
Obsoletes: %mklibname -d chipcard 3

%description  -n %libnamedev
This package contains chipcard3-server-config and header files for writing 
drivers, services or even your own chipcard daemon for LibChipCard.

%package -n %clientlibname
Group: System/Libraries
Summary: A library for easy access to smart cards (chipcards)
Requires: %name >= %version

%description -n %clientlibname
Libchipcard allows easy access to smart cards. It provides basic access
to memory and processor cards and has special support for German medical
cards, German "Geldkarten" and HBCI (homebanking) cards (both type 0 and 
type 1).

It accesses the readers via CTAPI or PC/SC interfaces and has successfully
been tested with Towitoko, Kobil and Reiner-SCT readers.

This package contains the chipcard3-daemon needed to access card readers.


%prep
%setup -q -n %name-%fversion
%patch0 -p1 -b .fixinitscript

%build
%configure2_5x
%make

%install
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
LIBRARY_PATH=$RPM_BUILD_ROOT%{_libdir} %makeinstall_std
perl -pi -e "s^-L$RPM_BUILD_DIR/%name-%fversion/src/lib/chipcard3-client^^" %buildroot%_libdir/*.la %buildroot%_libdir/gwenhywfar/plugins/*/*/*.la
chmod 644 %buildroot%_libdir/*.la %buildroot%_libdir/gwenhywfar/plugins/*/*/*.la

%clean
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT

%if %mdkversion < 200900
%post -n %libname -p /sbin/ldconfig
%endif
%if %mdkversion < 200900
%postun -n %libname -p /sbin/ldconfig
%endif
%if %mdkversion < 200900
%post -n %clientlibname -p /sbin/ldconfig
%endif
%if %mdkversion < 200900
%postun -n %clientlibname -p /sbin/ldconfig
%endif

%post
%_post_service chipcardd
%preun
%_preun_service chipcardd

%files -n %libname
%defattr(-,root,root,0755)
%{_libdir}/libchipcard_ctapi.so.%{major}*
%{_libdir}/libchipcardd.so.%{major}*

%files -n %clientlibname
%defattr(-,root,root,0755)
%{_libdir}/libchipcardc.so.%{clientmajor}*

%files -n %libnamedev
%defattr(-,root,root,0755)
%doc README COPYING ChangeLog
%{_libdir}/*.so
%{_bindir}/chipcard-config
%{_includedir}/*
%attr(644,root,root) %{_libdir}/*.*a
%{_datadir}/aclocal/chipcard.m4

%files
%defattr(-,root,root,0755)
%doc README COPYING ChangeLog
%{_libdir}/gwenhywfar/plugins
%dir %{_sysconfdir}/chipcard/
%dir %{_sysconfdir}/chipcard/client/
%dir %{_sysconfdir}/chipcard/server/
%config(noreplace) %{_sysconfdir}/chipcard/client/chipcardc.conf*
%config(noreplace) %{_sysconfdir}/chipcard/server/chipcardd.conf*
%attr(755,root,root) %{_sysconfdir}/init.d/chipcardd
%{_bindir}/cardcommander
%{_bindir}/chipcard-tool
%{_bindir}/geldkarte
%{_bindir}/kvkcard
%{_bindir}/memcard
%{_sbindir}/chipcardd4
%_datadir/chipcard/
%_libdir/chipcard


%changelog
* Tue Aug 19 2008 Funda Wang <fundawang@mandriva.org> 4.2.0-1mdv2009.0
+ Revision: 273941
- New version 4.2.0

* Wed Jul 09 2008 Götz Waschk <waschk@mandriva.org> 4.1.3-1mdv2009.0
+ Revision: 233015
- new version

* Sun Jul 06 2008 Götz Waschk <waschk@mandriva.org> 4.1.2-1mdv2009.0
+ Revision: 232285
- new version
- fix license

* Sat Jun 14 2008 Funda Wang <fundawang@mandriva.org> 4.1.1-1mdv2009.0
+ Revision: 219135
- bring back the init file
- New version 4.1.1

  + Pixel <pixel@mandriva.com>
    - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers

  + Thierry Vignaud <tvignaud@mandriva.com>
    - improved description

* Wed May 28 2008 Funda Wang <fundawang@mandriva.org> 4.1.0-1mdv2009.0
+ Revision: 212176
- New version 4.1.0

* Wed Apr 16 2008 Götz Waschk <waschk@mandriva.org> 4.0.0-1mdv2009.0
+ Revision: 194594
- new version
- update the patch
- update file list
- rename the package

  + Olivier Blin <oblin@mandriva.com>
    - restore BuildRoot

  + Thierry Vignaud <tvignaud@mandriva.com>
    - kill re-definition of %%buildroot on Pixel's request

* Fri Nov 23 2007 Götz Waschk <waschk@mandriva.org> 3.0.4-1mdv2008.1
+ Revision: 111452
- new version

* Mon Aug 27 2007 Götz Waschk <waschk@mandriva.org> 3.0.3-1mdv2008.0
+ Revision: 71765
- new version
- new devel name