]>
Commit | Line | Data |
---|---|---|
4fee4f0f JB |
1 | # |
2 | # Conditional build: | |
da51438a PS |
3 | %bcond_without dist_kernel # without distribution kernel |
4 | %bcond_without kernel # don't build kernel modules | |
da51438a | 5 | %bcond_with verbose # verbose build (V=1) |
33f2f3f5 | 6 | %bcond_without userspace # don't build userspace tools |
aada9b2a | 7 | |
468160b1 AM |
8 | %ifarch sparc |
9 | %undefine with_smp | |
10 | %endif | |
aada9b2a ER |
11 | |
12 | %if %{without kernel} | |
13 | %undefine with_dist_kernel | |
14 | %endif | |
15 | %if "%{_alt_kernel}" != "%{nil}" | |
16 | %undefine with_userspace | |
17 | %endif | |
18 | ||
19 | %define rel 20 | |
4fee4f0f | 20 | Summary: (Secure) SHell FileSystem utilities |
4102ccc0 | 21 | Summary(pl.UTF-8): Narzędzia obsługujące system plików przez ssh |
0b844bd7 | 22 | Name: shfs |
1ce0728a | 23 | Version: 0.35 |
aada9b2a | 24 | Release: %{rel} |
1ce0728a | 25 | License: GPL v2 |
4fee4f0f | 26 | Group: Applications/System |
11be4c33 | 27 | Source0: http://dl.sourceforge.net/shfs/%{name}-%{version}.tar.gz |
1ce0728a | 28 | # Source0-md5: 016f49d71bc32eee2b5d11fc1600cfbe |
4fee4f0f | 29 | Patch0: %{name}-opt.patch |
66049765 | 30 | Patch1: %{name}-df.patch |
7b31c0f4 PS |
31 | Patch2: %{name}-space_chars.patch |
32 | Patch3: %{name}-uidgid32.patch | |
33 | Patch4: %{name}-gcc4.patch | |
74a7f398 | 34 | Patch5: %{name}-inode_oops.patch |
92f07308 | 35 | Patch6: %{name}-d_entry.patch |
cc626707 | 36 | Patch7: %{name}-shfs_get_sb.patch |
1576cd96 | 37 | Patch8: %{name}-2.6.19.patch |
f29b9650 | 38 | Patch9: %{name}-kmem_cache.patch |
4fee4f0f | 39 | URL: http://shfs.sourceforge.net/ |
33f2f3f5 | 40 | %if %{with kernel} |
4e4245df | 41 | %{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20.2} |
1576cd96 | 42 | BuildRequires: rpmbuild(macros) >= 1.379 |
33f2f3f5 | 43 | %endif |
9ffb98ef | 44 | %{?with_dist_kernel:Requires: kernel(shfs)} |
d8d6d8be | 45 | Obsoletes: shfsmount |
0b844bd7 | 46 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
47 | ||
48 | %description | |
b5eba777 | 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. | |
0b844bd7 | 53 | |
4fee4f0f JB |
54 | This package contains utilities for SHFS. |
55 | ||
06bdd1f1 JR |
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. | |
4fee4f0f | 62 | |
06bdd1f1 | 63 | Ten pakiet zawiera programy narzędziowe dla SHFS. |
4fee4f0f | 64 | |
9ffb98ef | 65 | %package -n kernel%{_alt_kernel}-fs-shfs |
4fee4f0f | 66 | Summary: SHell File System Linux kernel module |
4102ccc0 | 67 | Summary(pl.UTF-8): Moduł jądra Linuksa obsługujący powłokowy system plików |
aada9b2a | 68 | Release: %{rel}@%{_kernel_ver_str} |
4fee4f0f | 69 | Group: Base/Kernel |
4fee4f0f | 70 | Requires(post,postun): /sbin/depmod |
7b31c0f4 | 71 | %if %{with dist_kernel} |
1576cd96 | 72 | %requires_releq_kernel |
73 | Requires(postun): %releq_kernel | |
7b31c0f4 | 74 | %endif |
9ffb98ef | 75 | Provides: kernel(shfs) |
76 | %if "%{_alt_kernel}" == "%{nil}" | |
4fee4f0f | 77 | Obsoletes: kernel-misc-shfs |
9ffb98ef | 78 | %endif |
4fee4f0f | 79 | |
9ffb98ef | 80 | %description -n kernel%{_alt_kernel}-fs-shfs |
4fee4f0f JB |
81 | SHell File System Linux kernel module. |
82 | ||
06bdd1f1 JR |
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. | |
4fee4f0f | 85 | |
0b844bd7 | 86 | %prep |
87 | %setup -q | |
66049765 PS |
88 | %patch0 -p1 |
89 | %patch1 -p0 | |
7b31c0f4 PS |
90 | %patch2 -p1 |
91 | %patch3 -p1 | |
92 | %patch4 -p1 | |
74a7f398 | 93 | %patch5 -p1 |
318902a2 | 94 | %patch6 -p1 |
cc626707 | 95 | %patch7 -p1 |
1576cd96 | 96 | %patch8 -p1 |
f29b9650 | 97 | %patch9 -p1 |
cc626707 | 98 | |
a028120c | 99 | cat > shfs/Linux-2.6/Makefile <<'EOF' |
9ffb98ef | 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 | |
a028120c | 104 | |
105 | %build | |
106 | %if %{with kernel} | |
107 | %build_kernel_modules -C shfs/Linux-2.6 -m shfs | |
da51438a | 108 | %endif |
4fee4f0f | 109 | |
33f2f3f5 | 110 | %if %{with userspace} |
4fee4f0f | 111 | %{__make} -C shfsmount \ |
9ffb98ef | 112 | SHFS_VERSION="\"%{version}\"" \ |
98073c4d | 113 | CC="%{__cc} %{rpmcflags}" \ |
114 | LINKER="%{__cc}" \ | |
da51438a | 115 | LDFLAGS="%{rpmldflags}" |
da51438a | 116 | %{__make} docs |
33f2f3f5 | 117 | %endif |
0b844bd7 | 118 | |
119 | %install | |
120 | rm -rf $RPM_BUILD_ROOT | |
4fee4f0f | 121 | |
da51438a | 122 | %if %{with kernel} |
a028120c | 123 | %install_kernel_modules -m shfs/Linux-2.6/shfs -d kernel/fs/shfs |
da51438a | 124 | %endif |
33f2f3f5 JB |
125 | |
126 | %if %{with userspace} | |
da51438a | 127 | %{__make} utils-install docs-install \ |
4fee4f0f | 128 | ROOT=$RPM_BUILD_ROOT \ |
4fee4f0f | 129 | MAN_PAGE_DIR=%{_mandir} |
33f2f3f5 | 130 | %endif |
4fee4f0f | 131 | |
0b844bd7 | 132 | %clean |
133 | rm -rf $RPM_BUILD_ROOT | |
134 | ||
9ffb98ef | 135 | %post -n kernel%{_alt_kernel}-fs-shfs |
b1c3860d | 136 | %depmod %{_kernel_ver} |
137 | ||
9ffb98ef | 138 | %postun -n kernel%{_alt_kernel}-fs-shfs |
b1c3860d | 139 | %depmod %{_kernel_ver} |
140 | ||
33f2f3f5 | 141 | %if %{with userspace} |
0b844bd7 | 142 | %files |
143 | %defattr(644,root,root,755) | |
4fee4f0f | 144 | %doc COPYRIGHT Changelog TODO docs/html |
e749730a PS |
145 | %attr(4754,root,wheel) %{_bindir}/shfsmount |
146 | %attr(4754,root,wheel) %{_bindir}/shfsumount | |
33f2f3f5 | 147 | %attr(755,root,root) /sbin/* |
706f7e93 | 148 | %{_mandir}/man8/* |
33f2f3f5 | 149 | %endif |
b1c3860d | 150 | |
da51438a | 151 | %if %{with kernel} |
9ffb98ef | 152 | %files -n kernel%{_alt_kernel}-fs-shfs |
4fee4f0f | 153 | %defattr(644,root,root,755) |
9ffb98ef | 154 | %dir /lib/modules/%{_kernel_ver}/kernel/fs/shfs |
155 | /lib/modules/%{_kernel_ver}/kernel/fs/shfs/shfs.ko* | |
5640466f | 156 | %endif |