/[fuse_dbi]/fuse/trunk/fuse.spec
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /fuse/trunk/fuse.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 5 - (show annotations)
Wed Aug 4 11:40:49 2004 UTC (19 years, 8 months ago) by dpavlin
File size: 3185 byte(s)
copy CVS to trunk

1 %define kernelversion %(uname -r)
2 %define fusemoduledir /lib/modules/%{kernelversion}/kernel/fs/fuse
3
4 %define kernelrel %(uname -r | sed -e s/-/_/g)
5 %define real_release 6
6
7 Name: fuse
8 Version: 1.0
9 Release: kernel_%{kernelrel}_%{real_release}
10 Summary: Filesystem in Userspace
11 Source: %{name}-%{version}.tar.gz
12 Copyright: GPL
13 Group: Utilities/System
14 URL: http://sourceforge.net/projects/avf
15 Buildroot: %{_tmppath}/%{name}-root
16 Prefix: /usr
17 Packager: Achim Settelmeier <fuse-rpm@sirlab.de>
18 # some parts of this specfile are taken from Ian Pilcher's specfile
19
20 # don't restrict to RedHat kernels but also allow compilation with
21 # vanilla kernels, too.
22 #Requires: kernel = %{kernelrel}, redhat-release >= 7
23 #BuildRequires: kernel-source = %{kernelrel}
24
25
26 %description
27 FUSE (Filesystem in Userspace) is a simple interface for userspace
28 programs to export a virtual filesystem to the linux kernel. FUSE
29 also aims to provide a secure method for non privileged users to
30 create and mount their own filesystem implementations.
31
32
33 %clean
34 case "$RPM_BUILD_ROOT" in *-root) rm -rf $RPM_BUILD_ROOT ;; esac
35
36 %prep
37 %setup
38
39 %build
40 # invoke configure with the --with-kernel option in case we attempt to
41 # compile for a different kernel and hope the path is right :-)
42 if [ "%{kernelversion}" != $(uname -r) ]; then
43 for dir in /lib/modules/%{kernelversion}/build \
44 /usr/src/linux-%{kernelversion} \
45 /usr/local/src/linux-%{kernelversion} ; do
46 if [ -d "$dir" ]; then
47 WITH_KERNEL="--with-kernel=$dir"
48 break
49 fi
50 done
51 fi
52
53 ./configure \
54 --prefix=%{prefix} \
55 $WITH_KERNEL
56 make
57 make check
58
59 ## Now build the library as a shared object
60 #cd lib
61 #gcc -fPIC -DHAVE_CONFIG_H -I../include -Wall -W -g -O2 -c *.c
62 #gcc -shared -Wl,-soname,libfuse.so.%{major_ver} -o libfuse.so.%{version} *.o
63 #cd ..
64
65
66 %install
67 case "$RPM_BUILD_ROOT" in *-root) rm -rf $RPM_BUILD_ROOT ;; esac
68 make install \
69 prefix=$RPM_BUILD_ROOT%{prefix} \
70 fusemoduledir=$RPM_BUILD_ROOT%{fusemoduledir}
71
72 install -d $RPM_BUILD_ROOT%{prefix}/lib/fuse/example
73 install -s -m 755 example/{fusexmp,hello,null} $RPM_BUILD_ROOT%{prefix}/lib/fuse/example/
74
75 # remove binaries form example folder so we can include it
76 # as a form of documentation into the package
77 make -C example clean
78 rm -rf example/.deps/
79
80 %post
81 /sbin/depmod -aq
82
83 %preun
84 /sbin/modprobe -r fuse
85
86 %postun
87 /sbin/depmod -aq
88
89
90
91 %files
92 %defattr(-,root,root)
93 %doc README TODO NEWS INSTALL ChangeLog AUTHORS COPYING COPYING.LIB
94 %doc example/
95 %doc patch/
96
97 %{fusemoduledir}
98 %{prefix}/lib/libfuse.a
99 %{prefix}/include/fuse.h
100 %{prefix}/lib/fuse/
101
102 # you want to install fusermount SUID root?
103 # Then uncomment the "%attr()"-line in favour of the line after it.
104 #%attr(4500,root,root) %{prefix}/bin/fusermount
105 %{prefix}/bin/fusermount
106
107
108
109 %changelog
110
111 * Sun May 25 2003 Achim Settelmeier <fuse-rpm@sirlab.de>
112 - don't add --with-kernel in case we compile for the standard kernel
113
114 * Tue Mar 04 2003 Achim Settelmeier <fuse-rpm@sirlab.de>
115 - "Merged" the specfile by Ian Pilcher (Ian Pilcher <pilchman@attbi.com>)
116 and this specfile into one. Both are provided by fuse-1.0.tar.gz.
117
118 * Mon Mar 03 2003 Achim Settelmeier <fuse-rpm@sirlab.de>
119 - Updated specfile for RedHat 8.0 systems
120

  ViewVC Help
Powered by ViewVC 1.1.26