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