- cleaned .spec file

This commit is contained in:
Peter Schiffer 2013-04-10 20:13:57 +02:00
parent bf48e81cd6
commit e683e5ff76
1 changed files with 48 additions and 66 deletions

View File

@ -1,5 +1,6 @@
%define perl_version %(eval "`%{__perl} -V:version`"; echo $version)
%global perl_version %(eval "`%{__perl} -V:version`"; echo $version)
Summary: File transfer utilities between Linux and PalmPilots
Name: pilot-link
Version: 0.12.5
Release: 16%{?dist}
@ -10,36 +11,27 @@ Epoch: 2
# kittykiller.c GPLv2+
License: GPLv2 and GPLv2+ and LGPLv2+ and Public Domain
Group: Applications/Communications
Summary: File transfer utilities between Linux and PalmPilots
URL: http://www.pilot-link.org/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source0: http://downloads.pilot-link.org/%{name}-%{version}.tar.bz2
Source3: blacklist-visor
Source4: README.fedora
Source5: 60-pilot.perms
Source6: 69-pilot-link.rules
Source1: blacklist-visor
Source2: README.fedora
Source3: 60-pilot.perms
Source4: 69-pilot-link.rules
Patch0: pilot-link-0.12.1-var.patch
Patch1: pilot-link-0.12.2-open.patch
Patch2: pilot-link-0.12.3-clio.patch
Patch3: pilot-link-0.12.5-mp.patch
Patch4: pilot-link-0.12.5-redefinePerlsymbols.patch
Patch5: pilot-link-0.12.5-compiler_warnings.patch
Patch6: pilot-link-0.12.5-ftbfs-f19.patch
Patch7: pilot-link-0.12.5-aarch64.patch
ExcludeArch: s390 s390x
Patch4: pilot-link-0.12.1-var.patch
Patch6: pilot-link-0.12.2-open.patch
Patch10: pilot-link-0.12.3-clio.patch
Patch11: pilot-link-0.12.5-mp.patch
Patch12: pilot-link-0.12.5-redefinePerlsymbols.patch
Patch13: pilot-link-0.12.5-compiler_warnings.patch
Patch14: pilot-link-0.12.5-ftbfs-f19.patch
Patch15: pilot-link-0.12.5-aarch64.patch
BuildRequires: perl(ExtUtils::MakeMaker), libpng-devel, readline-devel
BuildRequires: libusb-devel, bluez-libs-devel
Requires: pilot-link-libs = %{epoch}:%{version}-%{release}
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: libpng-devel
BuildRequires: readline-devel
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: libusb-devel
BuildRequires: bluez-libs-devel
%description
This suite of tools allows you to upload and download programs and
data files between a Linux/UNIX machine and the PalmPilot. It has a
@ -55,8 +47,7 @@ Hat Linux system.
Summary: PalmPilot development header files
Group: Development/Libraries
Requires: pilot-link-libs = %{epoch}:%{version}-%{release}
Requires: libpng-devel
Requires: readline-devel
Requires: libpng-devel, readline-devel
%description devel
This package contains the development headers that are used to build
@ -88,14 +79,14 @@ Libraries for applications communicating with PalmPilot
%prep
%setup -q
%patch4 -p1 -b .var
%patch6 -p1 -b .open
%patch10 -p1 -b .clio
%patch11 -p1 -b .mp
%patch12 -p1 -b .symbol
%patch13 -p1 -b .compiler
%patch14 -p1 -b .ftbfs-f19
%patch15 -p1 -b .aarch64
%patch0 -p1 -b .var
%patch1 -p1 -b .open
%patch2 -p1 -b .clio
%patch3 -p1 -b .mp
%patch4 -p1 -b .symbol
%patch5 -p1 -b .compiler
%patch6 -p1 -b .ftbfs-f19
%patch7 -p1 -b .aarch64
iconv -f windows-1252 -t UTF8 doc/README.usb > doc/README.usb.aux
mv doc/README.usb.aux doc/README.usb
iconv -f windows-1252 -t UTF8 ChangeLog > ChangeLog.aux
@ -105,34 +96,31 @@ mv NEWS.aux NEWS
%build
%configure \
--with-python=no \
--with-itcl=no \
--with-tk=no \
--with-tcl=no \
--with-java=no \
--with-cpp=yes \
--with-perl=yes \
--enable-conduits \
--enable-libusb
--with-python=no \
--with-itcl=no \
--with-tk=no \
--with-tcl=no \
--with-java=no \
--with-cpp=yes \
--with-perl=yes \
--enable-conduits \
--enable-libusb
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
make
make %{?_smp_mflags}
%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot} libdir=%{_libdir}
make install DESTDIR=%{buildroot} libdir=%{_libdir}
make install -C doc/man DESTDIR=%{buildroot} libdir=%{_libdir}
if test -f bindings/Perl/Makefile.PL ; then
cd bindings/Perl
perl -pi -e 's|^\$libdir =.*|\$libdir = "%{buildroot}%{_libdir}";|g' Makefile.PL
CFLAGS="%{optflags}" %{__perl} Makefile.PL INSTALLDIRS=vendor
make -B || :
make
cd ../..
cd bindings/Perl
perl -pi -e 's|^\$libdir =.*|\$libdir = "%{buildroot}%{_libdir}";|g' Makefile.PL
CFLAGS="%{optflags}" %{__perl} Makefile.PL INSTALLDIRS=vendor
make -B || :
make
cd ../..
fi
cd bindings/Perl
@ -157,27 +145,23 @@ rm -f %{buildroot}%{_bindir}/pilot-prc
# Put visor to blacklist
mkdir -p %{buildroot}%{_sysconfdir}/modprobe.d/
install -p -m644 %{SOURCE3} %{buildroot}%{_sysconfdir}/modprobe.d/blacklist-visor.conf
install -p -m644 %{SOURCE1} %{buildroot}%{_sysconfdir}/modprobe.d/blacklist-visor.conf
# put README.fedora into tree
cp %{SOURCE4} README.fedora
cp %{SOURCE2} README.fedora
# install visor configs to share/udev
install -p -m644 %{SOURCE5} %{buildroot}%{_datadir}/pilot-link/udev
install -p -m644 %{SOURCE3} %{buildroot}%{_datadir}/pilot-link/udev
# now that rules are moved out HAL, install to /lib/udev/
install -d %{buildroot}/lib/udev/rules.d/
install -p -m644 %{SOURCE6} %{buildroot}/lib/udev/rules.d/
install -p -m644 %{SOURCE4} %{buildroot}/lib/udev/rules.d/
%post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
%doc COPYING ChangeLog README NEWS doc/README.usb doc/README.debugging doc/README.libusb README.fedora
%{_bindir}/*
%exclude %{_bindir}/pilot-ietf2datebook
@ -188,14 +172,12 @@ rm -rf %{buildroot}
%exclude %{_mandir}/man1/ietf2datebook*
%files devel
%defattr(-,root,root,-)
%{_libdir}/*.so
%{_libdir}/pkgconfig/*
%{_includedir}/*
%{_datadir}/aclocal/*.m4
%files perl
%defattr(-,root,root,-)
%{_bindir}/pilot-ietf2datebook
%{_bindir}/pilot-sync-plan
%{_bindir}/pilot-undelete
@ -204,7 +186,6 @@ rm -rf %{buildroot}
%{perl_vendorarch}/PDA*
%files libs
%defattr(-,root,root,-)
%doc COPYING
%{_libdir}/*.so.*
%config(noreplace) %{_sysconfdir}/modprobe.d/blacklist-visor.conf
@ -214,6 +195,7 @@ rm -rf %{buildroot}
* Wed Apr 10 2013 Peter Schiffer <pschiffe@redhat.com> - 2:0.12.5-16
- resolves: #926340
added support for aarch64
- cleaned .spec file
* Mon Feb 25 2013 Peter Schiffer <pschiffe@redhat.com> - 2:0.12.5-15
- resolves: #914386