]> git.pld-linux.org Git - packages/shfs.git/blob - shfs.spec
- patch against kernels >=2.6.19
[packages/shfs.git] / shfs.spec
1 #
2 # Conditional build:
3 %bcond_without  dist_kernel     # without distribution kernel
4 %bcond_without  kernel          # don't build kernel modules
5 %bcond_with     verbose         # verbose build (V=1)
6 %bcond_without  userspace       # don't build userspace tools
7 %bcond_with     grsec_kernel    # build for kernel-grsecurity
8 #
9 %if %{with kernel} && %{with dist_kernel} && %{with grsec_kernel}
10 %define alt_kernel      grsecurity
11 %endif
12 #
13 %ifarch sparc
14 %undefine       with_smp
15 %endif
16 #
17 %define         _rel    20
18 Summary:        (Secure) SHell FileSystem utilities
19 Summary(pl.UTF-8):      Narzędzia obsługujące system plików przez ssh
20 Name:           shfs
21 Version:        0.35
22 Release:        %{_rel}
23 License:        GPL v2
24 Group:          Applications/System
25 Source0:        http://dl.sourceforge.net/shfs/%{name}-%{version}.tar.gz
26 # Source0-md5:  016f49d71bc32eee2b5d11fc1600cfbe
27 Patch0:         %{name}-opt.patch
28 Patch1:         %{name}-df.patch
29 Patch2:         %{name}-space_chars.patch
30 Patch3:         %{name}-uidgid32.patch
31 Patch4:         %{name}-gcc4.patch
32 Patch5:         %{name}-inode_oops.patch
33 Patch6:         %{name}-d_entry.patch
34 Patch7:         %{name}-shfs_get_sb.patch
35 Patch8:         %{name}-2.6.19.patch
36 URL:            http://shfs.sourceforge.net/
37 %if %{with kernel}
38 %{?with_dist_kernel:BuildRequires:      kernel%{_alt_kernel}-module-build >= 3:2.6.7}
39 BuildRequires:  rpmbuild(macros) >= 1.379
40 %endif
41 %{?with_dist_kernel:Requires:   kernel(shfs)}
42 Obsoletes:      shfsmount
43 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44
45 %description
46 SHFS is a simple and easy to use Linux kernel 2.4.10+ and 2.6 module
47 which allows you to mount remote filesystems using plain shell
48 (ssh/rsh) connection. It supports some nice features like number of
49 different caches for access speedup, target system optimisations, etc.
50
51 This package contains utilities for SHFS.
52
53 %description -l pl.UTF-8
54 SHFS to prosty i łatwy w użyciu moduł jądra Linuksa 2.4.10+ i 2.6
55 pozwalający montować zdalne systemy plików przy użyciu zwykłego
56 połączenia ze zdalną powłoką (ssh lub rsh). Obsługuje pewne miłe
57 cechy, takie jak różne sposoby buforowania dla przyspieszenia dostępu,
58 optymalizacje pod kątem zdalnego systemu itp.
59
60 Ten pakiet zawiera programy narzędziowe dla SHFS.
61
62 %package -n kernel%{_alt_kernel}-fs-shfs
63 Summary:        SHell File System Linux kernel module
64 Summary(pl.UTF-8):      Moduł jądra Linuksa obsługujący powłokowy system plików
65 Release:        %{_rel}@%{_kernel_ver_str}
66 Group:          Base/Kernel
67 Requires(post,postun):  /sbin/depmod
68 %if %{with dist_kernel}
69 %requires_releq_kernel
70 Requires(postun):       %releq_kernel
71 %endif
72 Provides:       kernel(shfs)
73 %if "%{_alt_kernel}" == "%{nil}"
74 Obsoletes:      kernel-misc-shfs
75 %endif
76
77 %description -n kernel%{_alt_kernel}-fs-shfs
78 SHell File System Linux kernel module.
79
80 %description -n kernel%{_alt_kernel}-fs-shfs -l pl.UTF-8
81 Moduł jądra Linuksa obsługujący powłokowy system plików.
82
83 %prep
84 %setup -q
85 %patch0 -p1
86 %patch1 -p0
87 %patch2 -p1
88 %patch3 -p1
89 %patch4 -p1
90 %patch5 -p1
91 %patch6 -p1
92 %patch7 -p1
93 %patch8 -p1
94
95 cat > shfs/Linux-2.6/Makefile <<'EOF'
96 obj-m := shfs.o
97 shfs-objs := dcache.o dir.o fcache.o file.o inode.o \
98                 ioctl.o proc.o shell.o symlink.o
99 EOF
100
101 %build
102 %if %{with kernel}
103 %build_kernel_modules -C shfs/Linux-2.6 -m shfs
104 %endif
105
106 %if %{with userspace}
107 %{__make} -C shfsmount \
108         SHFS_VERSION="\"%{version}\"" \
109         CC="%{__cc} %{rpmcflags}" \
110         LINKER="%{__cc}"        \
111         LDFLAGS="%{rpmldflags}"
112 %{__make} docs
113 %endif
114
115 %install
116 rm -rf $RPM_BUILD_ROOT
117
118 %if %{with kernel}
119 %install_kernel_modules -m shfs/Linux-2.6/shfs -d kernel/fs/shfs
120 %endif
121
122 %if %{with userspace}
123 %{__make} utils-install docs-install \
124         ROOT=$RPM_BUILD_ROOT \
125         MAN_PAGE_DIR=%{_mandir}
126 %endif
127
128 %clean
129 rm -rf $RPM_BUILD_ROOT
130
131 %post   -n kernel%{_alt_kernel}-fs-shfs
132 %depmod %{_kernel_ver}
133
134 %postun -n kernel%{_alt_kernel}-fs-shfs
135 %depmod %{_kernel_ver}
136
137 %if %{with userspace}
138 %files
139 %defattr(644,root,root,755)
140 %doc COPYRIGHT Changelog TODO docs/html
141 %attr(4754,root,wheel) %{_bindir}/shfsmount
142 %attr(4754,root,wheel) %{_bindir}/shfsumount
143 %attr(755,root,root) /sbin/*
144 %{_mandir}/man8/*
145 %endif
146
147 %if %{with kernel}
148 %files -n kernel%{_alt_kernel}-fs-shfs
149 %defattr(644,root,root,755)
150 %dir /lib/modules/%{_kernel_ver}/kernel/fs/shfs
151 /lib/modules/%{_kernel_ver}/kernel/fs/shfs/shfs.ko*
152 %endif
This page took 0.080218 seconds and 3 git commands to generate.