]> git.pld-linux.org Git - packages/libfuse.git/blob - libfuse.spec
- alt kernel fixes from AC-branch
[packages/libfuse.git] / libfuse.spec
1 #
2 # Condtional build:
3 %bcond_without  dist_kernel     # without distribution kernel
4 %bcond_with     kernel          # build kernel modules
5 %bcond_without  userspace       # don't build userspace tools
6 %bcond_with     verbose         # verbose build (V=1)
7 %bcond_without  selinux         # build without SELinux support
8
9 %ifarch sparc
10 %undefine       with_smp
11 %endif
12
13 %if %{without kernel}
14 %undefine with_dist_kernel
15 %endif
16 %if "%{_alt_kernel}" != "%{nil}"
17 %undefine       with_userspace
18 %endif
19
20 %define         pname   libfuse
21 %define         _rel    1
22 Summary:        Filesystem in Userspace
23 Summary(pl.UTF-8):      System plików w przestrzeni użytkownika
24 Name:           %{pname}%{_alt_kernel}
25 Version:        2.7.3
26 Release:        %{_rel}
27 Epoch:          0
28 License:        GPL v2
29 Group:          Applications/System
30 Source0:        http://dl.sourceforge.net/fuse/fuse-%{version}.tar.gz
31 # Source0-md5:  98563fc7b265b7479a3178181cbcf59a
32 Source1:        fuse.conf
33 Patch0:         kernel-misc-fuse-Makefile.am.patch
34 Patch1:         %{pname}-link.patch
35 URL:            http://fuse.sourceforge.net/
36 BuildRequires:  autoconf
37 BuildRequires:  automake
38 BuildRequires:  libtool
39 BuildRequires:  cpp
40 BuildRequires:  sed >= 4.0
41 %if %{with kernel}
42 %{?with_dist_kernel:BuildRequires:      kernel%{_alt_kernel}-module-build >= 3:2.6.20.2}
43 BuildRequires:  rpmbuild(macros) >= 1.379
44 %endif
45 %if %{with userspace}
46 %{?with_selinux:BuildRequires:  libselinux-devel}
47 %endif
48 Requires(postun):       /sbin/ldconfig
49 Requires(postun):       /usr/sbin/groupdel
50 Requires(pre):  /usr/bin/getgid
51 Requires(pre):  /usr/sbin/groupadd
52 Provides:       group(fuse)
53 Buildroot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
54
55 %description
56 FUSE (Filesystem in Userspace) is a simple interface for userspace
57 programs to export a virtual filesystem to the Linux kernel. FUSE also
58 aims to provide a secure method for non privileged users to create and
59 mount their own filesystem implementations.
60
61 This package contains a shared library.
62
63 %description -l pl.UTF-8
64 FUSE stanowi prosty interfejs dla programów działających w przestrzeni
65 użytkownika eksportujący wirtualny system plików do jądra Linuksa.
66 FUSE ma również na celu udostępnienie bezpiecznej metody tworzenia i
67 montowania własnych implementacji systemów plików przez zwykłych
68 (nieuprzywilejowanych) użytkowników.
69
70 Ten pakiet zawiera bibliotekę współdzieloną.
71
72 %package devel
73 Summary:        Filesytem in Userspace - Development header files
74 Summary(pl.UTF-8):      System plików w przestrzeni użytkownika - pliki nagłówkowe
75 Group:          Development/Libraries
76 Requires:       %{pname} = %{epoch}:%{version}-%{_rel}
77
78 %description devel
79 Libfuse library header files.
80
81 %description devel -l pl.UTF-8
82 Pliki nagłówkowe biblioteki libfuse.
83
84 %package static
85 Summary:        Filesytem in Userspace - static library
86 Summary(pl.UTF-8):      System plików w przestrzeni użytkownika - biblioteka statyczna
87 Group:          Development/Libraries
88 Requires:       libfuse-devel = %{epoch}:%{version}-%{_rel}
89
90 %description static
91 Static libfuse libraries.
92
93 %description static -l pl.UTF-8
94 Statyczna biblioteka libfuse.
95
96 %package -n kernel%{_alt_kernel}-misc-fuse
97 Summary:        Filesystem in Userspace
98 Summary(pl.UTF-8):      System plików w przestrzeni użytkownika
99 Release:        %{_rel}@%{_kernel_ver_str}
100 License:        GPL v2
101 Group:          Base/Kernel
102 Requires(post,postun):  /sbin/depmod
103 %if %{with dist_kernel}
104 %requires_releq_kernel
105 Requires(postun):       %releq_kernel
106 %endif
107 %if "%{_alt_kernel}" != "%{nil}"
108 Provides:       kernel-misc-fuse
109 %endif
110
111 %description -n kernel%{_alt_kernel}-misc-fuse
112 FUSE (Filesystem in Userspace) is a simple interface for userspace
113 programs to export a virtual filesystem to the Linux kernel. FUSE also
114 aims to provide a secure method for non privileged users to create and
115 mount their own filesystem implementations.
116
117 %description -n kernel%{_alt_kernel}-misc-fuse -l pl.UTF-8
118 FUSE stanowi prosty interfejs dla programów działających w przestrzeni
119 użytkownika eksportujący wirtualny system plików do jądra Linuksa.
120 FUSE ma również na celu udostępnienie bezpiecznej metody tworzenia i
121 montowania własnych implementacji systemów plików przez zwykłych
122 (nieuprzywilejowanych) użytkowników.
123
124 %prep
125 %setup -q -n fuse-%{version}
126 %patch0 -p1
127 %patch1 -p1
128
129 sed -i '/FUSERMOUNT_PROG/s,fusermount,%{_bindir}/fusermount,' lib/mount.c
130
131 %build
132 %{__libtoolize}
133 %{__aclocal}
134 %{__autoheader}
135 %{__autoconf}
136 %{__automake}
137 %configure \
138         %{!?with_selinux:ac_cv_header_selinux_selinux_h=no} \
139         --%{?with_kernel:en}%{!?with_kernel:dis}able-kernel-module \
140         --enable-lib \
141         --enable-util \
142         %{?with_kernel:--with-kernel=%{_kernelsrcdir}}
143
144 %if %{with userspace}
145 cp kernel/fuse_kernel.h include/
146 for DIR in include lib util; do
147 %{__make} -C $DIR
148 done
149 %endif
150
151 %if %{with kernel}
152 %build_kernel_modules -m fuse -C kernel
153 %endif
154
155 %install
156 rm -rf $RPM_BUILD_ROOT
157 install -d $RPM_BUILD_ROOT{%{_pkgconfigdir},%{_sysconfdir}}
158
159 %if %{with userspace}
160 for DIR in include lib util; do
161 %{__make} -C $DIR install \
162         DESTDIR=$RPM_BUILD_ROOT
163 done
164
165 install fuse.pc $RPM_BUILD_ROOT%{_pkgconfigdir}
166 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
167 %endif
168
169 %if %{with kernel}
170 %install_kernel_modules -m kernel/fuse -d kernel/fs
171 %endif
172
173 %clean
174 rm -rf $RPM_BUILD_ROOT
175
176 %pre
177 %groupadd -g 84 fuse
178
179 %post   -p /sbin/ldconfig
180 %postun
181 /sbin/ldconfig
182 if [ "$1" = "0" ] ; then
183         %groupremove fuse
184 fi
185
186 %post -n kernel%{_alt_kernel}-misc-fuse
187 %depmod %{_kernel_ver}
188
189 %postun -n kernel%{_alt_kernel}-misc-fuse
190 %depmod %{_kernel_ver}
191
192 %if %{with userspace}
193 %files
194 %defattr(644,root,root,755)
195 %doc README NEWS ChangeLog AUTHORS doc/*
196 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/fuse.conf
197 %attr(4754,root,fuse) %{_bindir}/fusermount
198 %attr(755,root,root) %{_bindir}/ulockmgr_server
199 %attr(755,root,root) /sbin/mount.fuse
200 %attr(755,root,root) %{_libdir}/libfuse.so.*.*.*
201 %attr(755,root,root) %ghost %{_libdir}/libfuse.so.2
202 %attr(755,root,root) %{_libdir}/libulockmgr.so.*.*.*
203 %attr(755,root,root) %ghost %{_libdir}/libulockmgr.so.1
204
205 %files devel
206 %defattr(644,root,root,755)
207 %attr(755,root,root) %{_libdir}/libfuse.so
208 %attr(755,root,root) %{_libdir}/libulockmgr.so
209 %{_libdir}/libfuse.la
210 %{_libdir}/libulockmgr.la
211 %{_includedir}/fuse
212 %{_includedir}/fuse.h
213 %{_includedir}/ulockmgr.h
214 %{_pkgconfigdir}/fuse.pc
215
216 %files static
217 %defattr(644,root,root,755)
218 %{_libdir}/libfuse.a
219 %{_libdir}/libulockmgr.a
220 %endif
221
222 %if %{with kernel}
223 %files -n kernel%{_alt_kernel}-misc-fuse
224 %defattr(644,root,root,755)
225 /lib/modules/%{_kernel_ver}/kernel/fs/fuse.ko*
226 %endif
This page took 0.037505 seconds and 4 git commands to generate.