Sophie

Sophie

distrib > Mandriva > 8.0 > i586 > by-pkgid > ec6cbc71453eee6005c7b9a87aa6426f > files > 4

ncpfs-2.2.0.18.a-3mdk.src.rpm

%define pversion 2.2.0.18

Summary:		Utilities for the ncpfs filesystem, a NetWare client for Linux
Name:			ncpfs
Version:		%{pversion}.a
Release:		3mdk
Copyright:		GPL

Source:			ftp://ftp.platan.vc.cvut.cz/pub/linux/ncpfs/ncpfs-%{version}/ncpfs-%{pversion}.tar.bz2
Source1:		mount.ncp
Patch0:			ncpfs-largekeys.patch.bz2

Group:			Networking/Other
Requires:		ipxutils
Buildroot:		%{_tmppath}/%name-%version-root
BuildRequires:	pam-devel
Prereq:			/bin/sed, /bin/grep

%description
Ncpfs is a filesystem which understands the Novell NetWare(TM)
NCP protocol.  Functionally, NCP is used for NetWare the way NFS
is used in the TCP/IP world.  For a Linux system to mount a NetWare
filesystem, it needs a special mount program.  The ncpfs package
contains such a mount program plus other tools for configuring and
using the ncpfs filesystem.

Install the ncpfs package if you need to use the ncpfs filesystem
to use Novell NetWare files or services.

%package -n ipxutils
Summary:	Tools for configuring and debugging IPX interfaces and networks
Group:		System/Configuration/Networking

%description -n ipxutils
The ipxutils package includes utilities (ipx_configure, ipx_internal_net,
ipx_interface, ipx_route) necessary for configuring and debugging IPX
interfaces and networks under Linux. IPX is the low-level protocol used
by Novell's NetWare file server system to transfer data.

Install ipxutils if you need to configure IPX networking on your network.

%prep
%setup -q -n ncpfs-%{pversion}

%build
CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{_tmppath}/ncpfs-root/%{_prefix} \
								  	--exec-prefix=%{_tmppath}/ncpfs-root/%{_prefix} \
								  	--libexecdir=%{_tmppath}/ncpfs-root%{_libdir} \
								  	--enable-pam \
								  	--with-included-gettext

%make clean
%make
%make -C ipxdump
mv ipxdump/README ipxdump/README.ipxdump

%install
# Install "a la main" because of fucking makefile
rm -rf $RPM_BUILD_ROOT

#install po
cd po
mkdir -p $RPM_BUILD_ROOT%{_datadir}/locale/cs/LC_MESSAGES
cp cs.gmo $RPM_BUILD_ROOT%{_datadir}/locale/cs/LC_MESSAGES/cs.gmo
mkdir -p $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES
cp de.gmo $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES/de.gmo
cd ..

#lib
cd lib
mkdir -p $RPM_BUILD_ROOT%{_libdir}
%{_bindir}/install -c -m 755 libncp.so.2.3.0 $RPM_BUILD_ROOT%{_libdir}
cd ..

#sutil
cd sutil
mkdir -p $RPM_BUILD_ROOT%{_bindir}
/usr/bin/install -c -m 4755 nwsfind ncpmount ncpumount $RPM_BUILD_ROOT/usr/bin
cd ..

#util
cd util
mkdir -p $RPM_BUILD_ROOT/usr/bin
cp slist pqlist nwfsinfo pserver nprint nsend nwpasswd nwbols nwbocreate nwborm nwboprops pqstat pqrm nwbpcreate nwbprm nwbpvalues nwbpadd nwbpset nwgrant nwrevoke nwuserlist nwauth nwfstime nwvolinfo nwtrustee nwdir nwfsctrl nwdpvalues ncopy nwtrustee2 nwpurge nwrights $RPM_BUILD_ROOT/usr/bin
/usr/bin/install -c -m 755 nwmsg $RPM_BUILD_ROOT/usr/sbin;
cd ..

#man
cd man
mkdir -p $RPM_BUILD_ROOT%{_mandir}/man{1,3,5,8}
cp *.1.gz $RPM_BUILD_ROOT%{_mandir}/man1
cp *.3ncp.gz $RPM_BUILD_ROOT%{_mandir}/man3
cp *.5.gz $RPM_BUILD_ROOT%{_mandir}/man5
cp *.8.gz $RPM_BUILD_ROOT%{_mandir}/man8
ln -sf ncpmount.8.gz $RPM_BUILD_ROOT%{_mandir}/man8/mount.ncp.8.gz
cd ..

#IPX
cd ipx-1.0
mkdir -p $RPM_BUILD_ROOT/sbin
cp ipx_configure ipx_interface ipx_internal_net $RPM_BUILD_ROOT/sbin
cp ipx_cmd ipx_route $RPM_BUILD_ROOT%{_bindir}
cp ipx_configure.8 ipx_cmd.8 ipx_interface.8 ipx_internal_net.8 ipx_route.8 $RPM_BUILD_ROOT%{_mandir}/man8/
cd ..

#contrib pam
mkdir -p $RPM_BUILD_ROOT/lib/security
cd contrib/pam
cp pam_ncp_auth.so $RPM_BUILD_ROOT/lib/security/
chmod 755 $RPM_BUILD_ROOT/lib/security/pam_ncp_auth.so 
cd ../..

#ipxdump
install -m755 ipxdump/ipxdump ipxdump/ipxparse $RPM_BUILD_ROOT/usr/bin/

#mdk don't look at me it wasn't my make file
ln -sf ncpmount.8 $RPM_BUILD_ROOT%{_mandir}/man8/mount.ncp.8
rm -f $RPM_BUILD_ROOT%{_mandir}/man8/mount.ncp.8

#link
cd $RPM_BUILD_ROOT%{_libdir}
ln -s libncp.so.2.3.0 libncp.so.2.3
 
%post -n ipxutils
if [ -f %{_sysconfdir}/modules.conf ];then
		if ! grep -q -E "^alias.*net-pf-4.*ipx" %{_sysconfdir}/modules.conf;then
			echo "alias net-pf-4 ipx" >> %{_sysconfdir}/modules.conf
		fi
else
		echo "alias net-pf-4 ipx" >> %{_sysconfdir}/modules.conf
fi

%postun  -n ipxutils
if [ "$1" = "0" ];then
	if [ -f %{_sysconfdir}/modules.conf ];then
		if grep -q -E "^alias.*net-pf-4.*ipx" %{_sysconfdir}/modules.conf;then
			sed 's/^alias net-pf-4 ipx//' %{_sysconfdir}/modules.conf > /tmp/.modules.conf \
		&& mv -f /tmp/.modules.conf %{_sysconfdir}/modules.conf
		fi
	fi	
fi

%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig

%clean
rm -rf $RPM_BUILD_ROOT
rm -f rpm.files

%files
%defattr(-,root,root)
%doc BUGS COPYING Changes FAQ README 
%{_datadir}/locale/*/LC_MESSAGES/*
%attr (755,root,root) %{_bindir}/n*
%attr (755,root,root) %{_bindir}/p*
%attr (755,root,root) %{_bindir}/slist
%attr (755,root,root) /lib/security/*
%attr (755,root,root) %{_mandir}/man1/*
%attr (755,root,root) %{_mandir}/man3/*
%attr (755,root,root) %{_mandir}/man8/n*
%attr (755,root,root) %{_libdir}/libncp.so.2.3.0
%attr (755,root,root) %{_libdir}/libncp.so.2.3


%files -n ipxutils
%defattr(-,root,root)
%doc ipxdump/README.ipxdump
%doc ipx-1.0/COPYING ipx-1.0/README
/sbin/ipx*
%{_bindir}/ipx*
%{_mandir}/*/ipx*

%changelog
* Sun Nov 05 2000 David BAUDENS <baudens@mandrakesoft.com> 2.2.0.18.a-3mdk
- Use optimizations

* Tue Aug 30 2000 Florin Grad <florin@mandrakesoft.com> 2.2.0.18.a-2mdk
- changing some macros

* Tue Aug 29 2000 Florin Grad <florin@mandrakesoft.com> 2.2.0.18.a-1mdk
- new version
- adding some macros

* Tue May 23 2000 Vincent Saugey <vince@mandrakesoft.com> 2.2.0.17.a-4mdk
- new version
- adding new macros

* Tue May 23 2000 Vincent Saugey <vince@mandrakesoft.com> 2.2.0.17.a-4mdk
- Add ldconfig to ncp package

* Mon May 22 2000 Vicnent Saugey <chmouel@mandrakesoft.com> 2.2.0.17.a-3mdk
- Fix file list


* Thu May 18 2000 Vincent Saugey <vince@mandrakesoft.com> 2.2.0.17.a-2mdk
- Many fix in build process
- Add build pam-devel require
- Change all %install process don't use the buggy Makefile of source for install

* Wed May 10 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.0.17.a-1mdk
- 2.2.0.17
- Add large key patch
- Add net-pf-4 to /etc/conf.modules in %post.

* Fri Apr 14 2000 Yoann Vandoorselaere <yoann@mandrakesoft.com> 2.2.0.16.a-3mdk
- Fix groups.
- s/.gz/.bz2/ in rpm.files
- do not issue 2 sed call , just use the sed -e option.

* Tue Jul 20 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- 2.2.0.16.a
- left ipx_interface out of %files.
- fix mount.ncp USER arg.
- move ipxdump docs to the package that it's in...
- fix bug in slist/nwsfind

* Mon May 17 1999 Axalon Bloodstone <axalon@relic.net>
- More Mandake adaptions, bzip2 manpages
- broken manpage symlinks

* Sat May 15 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Add patch from Axalon Bloodstone <axalon@Jumpstart.netpirate.org>

* Wed May 05 1999 Bernhard Rosenkränzer <bero@mandrakesoft.com>
- Mandrake adaptions
- fix compilation

* Tue Apr  6 1999 Bill Nottingham <notting@redhat.com>
- turn off setuid on nwsfind
- move ipxutils to using ncpfs versioning for sanity reasons

* Fri Mar 26 1999 Bill Nottingham <notting@redhat.com>
- doesn't work on alpha, apparently
- add a mount.ncp mount helper

* Mon Mar 22 1999 Bill Nottingham <notting@redhat.com>
- remove dangling symlink

* Tue Feb 23 1999 Bill Nottingham <notting@redhat.com>
- update to 2.2.0.12

* Fri Jan 22 1999 Bill Nottingham <notting@redhat.com>
- build for arm. Yuk.

* Wed Dec  9 1998 Bill Nottingham <notting@redhat.com>
- update to 2.2.0.11

* Fri Sep 11 1998 Jeff Johnson <jbj@redhat.com>
- update to 2.2.0.

* Fri Jul 10 1998 Jeff Johnson <jbj@redhat.com>
- exclusively i386 for now.

* Tue Jul  7 1998 Jeff Johnson <jbj@redhat.com>
- move ipx_configure/ipx_internal_net to /sbin to permit /usr from NFS.

* Thu May 07 1998 Prospector System <bugs@redhat.com>
- translations modified for de, fr, tr

* Mon Apr 13 1998 Cristian Gafton <gafton@redhat.com>
- manhattan rebuild
- there is a new version out, 2.0.12, but it contains RSA crypto code, so
  it's of no use for us. :-(
- buildroot and spec file cleanup

* Thu Dec 18 1997 Erik Troan <ewt@redhat.com>
- uid_t, gid_t, mode_t fixes for glibc 2.0.5 and linux 2.0.x

* Wed Oct 23 1997 Michael Fulbright <msf@redhat.com>
- added a few file which were missing from the file list

* Sun Oct 19 1997 Erik Troan <ewt@redhat.com>
- updated to 2.0.11
- massive hacking for glibc

* Thu Mar 06 1997 Michael K. Johnson <johnsonm@redhat.com>
- nwrights program now included in package.