]>
Commit | Line | Data |
---|---|---|
a8697a92 JR |
1 | Summary: Automount utilities including an updated version of Amd. |
2 | Name: am-utils | |
3 | Version: 6.0 | |
4 | Serial: 1 | |
10038889 | 5 | Release: 4 |
a8697a92 JR |
6 | Copyright: BSD |
7 | Group: System Environment/Daemons | |
8 | Source: ftp://shekel.mcl.cs.columbia.edu/pub/am-utils/am-utils-%{version}.tar.gz | |
9 | Source1: am-utils.init | |
10 | Source2: am-utils.conf | |
11 | Source3: am-utils.sysconf | |
12 | Patch0: am-utils-6.0a16-linux.patch | |
13 | Patch1: am-utils-6.0a16-alpha.patch | |
14 | Patch2: am-utils-6.0a16-glibc21.patch | |
a8697a92 JR |
15 | Requires: portmap |
16 | BuildRoot: /var/tmp/am-utils-root | |
17 | Prereq: /sbin/chkconfig | |
8fb9654d | 18 | Prereq: /usr/sbin/fix-info-dir |
a8697a92 JR |
19 | Obsoletes: amd |
20 | ||
21 | %description | |
22 | Am-utils includes an updated version of Amd, the popular BSD | |
23 | automounter. An automounter is a program which maintains a cache of | |
24 | mounted filesystems. Filesystems are mounted when they are first | |
25 | referenced by the user and unmounted after a certain period of inactivity. | |
26 | Amd supports a variety of filesystems, including NFS, UFS, CD-ROMS and | |
27 | local drives. | |
28 | ||
29 | You should install am-utils if you need a program for automatically | |
30 | mounting and unmounting filesystems. | |
31 | ||
32 | %prep | |
33 | %setup -q | |
34 | %patch2 -p1 -b .glibc21 | |
35 | %patch0 -p1 -b .lnx | |
36 | %ifnarch i386 | |
37 | %patch1 -p1 -b .noauto | |
38 | %endif | |
39 | ||
40 | %build | |
41 | cd aux ; autoconf ; mv -f configure .. ; cd .. | |
42 | CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=/usr \ | |
43 | --enable-shared --sysconfdir=/etc --enable-libs=-lnsl | |
44 | # fun with autoconf | |
45 | touch `find -name Makefile.in` | |
46 | make | |
47 | ||
48 | %install | |
49 | rm -rf $RPM_BUILD_ROOT | |
50 | make install prefix=$RPM_BUILD_ROOT/usr sysconfdir=`pwd`/etc | |
51 | mkdir -p $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d} | |
52 | install -m 600 $RPM_SOURCE_DIR/am-utils.conf $RPM_BUILD_ROOT/etc/amd.conf | |
53 | install -m 755 $RPM_SOURCE_DIR/am-utils.sysconf $RPM_BUILD_ROOT/etc/sysconfig/amd | |
54 | install -m 755 $RPM_SOURCE_DIR/am-utils.init $RPM_BUILD_ROOT/etc/rc.d/init.d/amd | |
55 | strip $RPM_BUILD_ROOT/usr/sbin/* $RPM_BUILD_ROOT/usr/bin/* || : | |
56 | gzip -q9f $RPM_BUILD_ROOT/usr/info/*info* | |
57 | mkdir -p $RPM_BUILD_ROOT/.automount | |
58 | # get rid of some lame scripts | |
59 | file $RPM_BUILD_ROOT/usr/sbin/* | \ | |
60 | grep -v ELF | grep -v am-eject | \ | |
61 | cut -f 1 -d':' | xargs rm -f | |
62 | ||
63 | %clean | |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %post | |
67 | /sbin/ldconfig | |
68 | /sbin/chkconfig --add amd | |
8fb9654d | 69 | /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1 |
a8697a92 | 70 | |
a8697a92 | 71 | %postun |
10038889 | 72 | /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1 |
a8697a92 JR |
73 | /sbin/ldconfig |
74 | if [ $1 = 0 ]; then | |
75 | /sbin/chkconfig --del amd | |
76 | fi | |
77 | ||
78 | %files | |
79 | %defattr(-,root,root) | |
80 | %doc doc/*.ps AUTHORS BUGS ChangeLog NEWS README* TODO | |
81 | %dir /.automount | |
82 | /usr/bin/pawd | |
83 | /usr/sbin/* | |
84 | /usr/man/man[58]/* | |
85 | /usr/man/man1/pawd.1 | |
86 | %config /etc/amd.conf | |
87 | %config /etc/sysconfig/amd | |
88 | %config /etc/rc.d/init.d/amd | |
89 | /usr/info/*info*.gz | |
90 | /usr/lib/libamu.so | |
91 | /usr/lib/libamu.so.* |