585f0d8
# No FUSE on RHEL5
585f0d8
%if %{?el5:1}0
585f0d8
%define _without_fuse 1
585f0d8
%endif
585f0d8
585f0d8
Name:           afpfs-ng
585f0d8
Version:        0.8.1
f3a61f9
Release:        2%{?dist}.1
585f0d8
Summary:        Apple Filing Protocol client
585f0d8
585f0d8
Group:          System Environment/Base
585f0d8
License:        GPLv2
585f0d8
URL:            http://alexthepuffin.googlepages.com/home
585f0d8
Source0:        http://downloads.sourceforge.net/afpfs-ng/%{name}-%{version}.tar.bz2
585f0d8
Patch0:         afpfs-ng-0.8.1-overflows.patch
585f0d8
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
585f0d8
585f0d8
%{?!_without_fuse:BuildRequires: fuse-devel}
585f0d8
BuildRequires: libgcrypt-devel gmp-devel readline-devel
f3a61f9
BuildRequires: ncurses-devel
585f0d8
585f0d8
%description
585f0d8
A command line client to access files exported from Mac OS system via
585f0d8
AppleTalk or TCP using Apple Filing Protocol.
585f0d8
%{?!_without_fuse:The FUSE filesystem module for AFP is in fuse-afp package}
585f0d8
585f0d8
585f0d8
%if %{?!_without_fuse:1}0
585f0d8
%package -n fuse-afp
585f0d8
Summary:        FUSE driver for AFP filesystem
585f0d8
Group:          System Environment/Base
585f0d8
585f0d8
%description -n fuse-afp
585f0d8
A FUSE file system server to access files exported from Mac OS system
585f0d8
via AppleTalk or TCP using Apple Filing Protocol.
585f0d8
The command line client for AFP is in fuse-afp package
585f0d8
%endif
585f0d8
585f0d8
585f0d8
%package devel
585f0d8
Summary:        Development files for afpfs-ng
585f0d8
Group:          Development/Libraries
585f0d8
Requires:       %{name} = %{version}
585f0d8
585f0d8
%description devel
585f0d8
Library for dynamic linking and header files of afpfs-ng.
585f0d8
585f0d8
585f0d8
%prep
585f0d8
%setup -q
585f0d8
%patch0 -p1 -b .overflows
585f0d8
585f0d8
585f0d8
%build
585f0d8
# make would rebuild the autoconf infrastructure due to the following:
585f0d8
# Prerequisite `configure.ac' is newer than target `Makefile.in'.
585f0d8
# Prerequisite `aclocal.m4' is newer than target `Makefile.in'.
585f0d8
# Prerequisite `configure.ac' is newer than target `aclocal.m4'.
585f0d8
touch --reference aclocal.m4 configure.ac Makefile.in
585f0d8
585f0d8
%configure %{?_without_fuse:--disable-fuse} --disable-static
585f0d8
make %{?_smp_mflags}
585f0d8
585f0d8
585f0d8
%install
585f0d8
rm -rf $RPM_BUILD_ROOT
585f0d8
make install DESTDIR=$RPM_BUILD_ROOT
585f0d8
install -d $RPM_BUILD_ROOT%{_includedir}/afpfs-ng
585f0d8
cp -p include/* $RPM_BUILD_ROOT%{_includedir}/afpfs-ng
585f0d8
585f0d8
585f0d8
%clean
585f0d8
rm -rf $RPM_BUILD_ROOT
585f0d8
585f0d8
585f0d8
%files
585f0d8
%defattr(-,root,root,-)
585f0d8
%{_bindir}/afpcmd
585f0d8
%{_bindir}/afpgetstatus
585f0d8
%{_mandir}/man1/afpcmd.1*
585f0d8
%{_mandir}/man1/afpgetstatus.1*
585f0d8
%{_libdir}/*.so.*
585f0d8
%exclude %{_libdir}/*.la
585f0d8
%doc COPYING AUTHORS ChangeLog docs/README docs/performance docs/FEATURES.txt docs/REPORTING-BUGS.txt
585f0d8
585f0d8
585f0d8
%if %{?!_without_fuse:1}0
585f0d8
%files -n fuse-afp
585f0d8
%defattr(-,root,root,-)
585f0d8
%{_bindir}/afp_client
585f0d8
%{_bindir}/afpfs
585f0d8
%{_bindir}/afpfsd
585f0d8
%{_bindir}/mount_afp
585f0d8
%{_mandir}/man1/afp_client.1*
585f0d8
%{_mandir}/man1/afpfsd.1*
585f0d8
%{_mandir}/man1/mount_afp.1*
585f0d8
%doc COPYING AUTHORS ChangeLog
585f0d8
%endif
585f0d8
585f0d8
585f0d8
%files devel
585f0d8
%defattr(-,root,root,-)
585f0d8
%{_includedir}/afpfs-ng
585f0d8
%{_libdir}/*.so
585f0d8
585f0d8
585f0d8
%post -p /sbin/ldconfig
585f0d8
585f0d8
585f0d8
%postun -p /sbin/ldconfig
585f0d8
585f0d8
585f0d8
%changelog
f3a61f9
* Tue Mar 24 2009 Lubomir Rintel <lkundrak@v3.sk> - 0.8.1-2.1
f3a61f9
- BuildRequire ncurses-devel
f3a61f9
585f0d8
* Thu Mar 19 2009 Lubomir Rintel <lkundrak@v3.sk> - 0.8.1-2
585f0d8
- Add more include files (Jan F. Chadima)
585f0d8
- Don't needlessly build static library (Stefan Kasal)
585f0d8
- Fix fuse-afp summary (Stefan Kasal)
585f0d8
- Remove redundant license file from -devel (Stefan Kasal)
585f0d8
585f0d8
* Mon Oct 6 2008 Lubomir Rintel <lkundrak@v3.sk> - 0.8.1-1
585f0d8
- Initial packaging attempt