Include 'ext2fsd.sys-v0.10a CheckedBuild' to standard distribution.
[captive.git] / captive.spec.in
1 # $Id$
2 # rpm package description file for building
3 # Copyright (C) 2002-2003 Jan Kratochvil <project-captive@jankratochvil.net>
4
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; exactly version 2 of June 1991 is required
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17
18
19 # Temporary cludge before full 'devel' package gets deployed
20 %define _unpackaged_files_terminate_build 0
21
22 Summary: Microsoft Windows platform filesystem access.
23 Name: @PACKAGE@
24 %define release 0
25 Version: @VERSION@
26 Release: %{release}
27 Group: System Environment/Base
28 Packager: Jan Kratochvil <project-captive@jankratochvil.net>
29 Source: http://www.jankratochvil.net/project/captive/@PACKAGE@-@VERSION@.tar.gz
30 Copyright: GPL
31 BuildRoot: /var/tmp/@PACKAGE@-@VERSION@-%{release}-root
32 BuildRequires: ORBit2-devel
33 Requires: ORBit2
34 BuildRequires: openssl-devel
35 Requires: openssl
36 BuildRequires: gnome-vfs2-devel
37 Requires: gnome-vfs2
38 BuildRequires: libxml2-devel
39 Requires: libxml2
40 BuildRequires: popt
41 Requires: popt
42 BuildRequires: glib2-devel
43 Requires: glib2
44 BuildRequires: readline-devel
45 Requires: readline
46 BuildRequires: gcc >= 3.0
47
48 %description
49 Existing binary Microsoft Windows file system drivers were exploited
50 for accessing drives with possibly proprietary file system data structures.
51 Open file system API is provided to access these file system drivers.
52 Microsoft Windows system components required by these drivers
53 were analyzed and successfuly emulated in the GNU/Linux operating system.
54
55 The implementation allows applications running under the GNU/Linux operating
56 system to access NTFS drives. File system driver compatibility with VFAT,
57 ISO9660 and EXT2 is also provided.
58
59 %package lufs
60 Summary: LUFS module for Microsoft Windows platform filesystem access.
61 Group: System Environment/Base
62 Requires: captive = %{PACKAGE_VERSION}
63 Requires: lufs >= 0.9.6-1captive
64
65 %description lufs
66 LUFS is a hybrid userspace filesystem framework.
67
68 Package provides LUFS filesystem module to access Microsoft Windows platform
69 filesystems such as NTFS.
70
71 %package install
72 Summary: Instant installer for Microsoft Windows platform filesystem access.
73 Group: System Environment/Base
74 Requires: captive-lufs = %{PACKAGE_VERSION}
75 BuildRequires: ntfsprogs-devel
76 Requires: ntfsprogs
77 Requires: ntfsprogs-gnomevfs
78 Requires: gnome-vfs-httpcaptive
79 BuildRequires: gnome-vfs2-devel
80 Requires: gnome-vfs2
81 BuildRequires: libgnomeui-devel
82 Requires: libgnomeui
83 BuildRequires: readline-devel
84 Requires: readline
85
86 %description install
87 Package provides easy enough unattended installation of Microsoft Windows
88 platform filesystem access. Installer finds available NTFS partitions and
89 tries to acquire needed Microsoft Windows filesystem driver files.
90
91 You may need to run 'captive-install-acquire' to answer several questions.
92 NTFS disks will become mount(8)able at directories: /mnt/captive-VOLUME_NAME
93
94 #% %package devel
95 #% Summary: Microsoft Windows platform filesystem access development support.
96 #% Group: Development/System
97 #% Requires: surprise = %{PACKAGE_VERSION}
98 #% 
99 #% %description devel
100 #% Development package containing libraries for static linking together with
101 #% header files needed for any linking.
102 #% 
103 #% Microsoft Windows platform filesystem access.
104 #% TODO
105
106 %prep
107 %setup
108
109 %build
110 # Never disable debug for captive, see FAQ
111 #       "How to check valid input arguments? Invalid processing state assumptions?"
112 # FIXME: Use our own CFLAGS to prevent '-mcpu=i686' which up to gcc-20030214 gcc
113 # will ignore stack freeing of attribute((stdcall)) callees in caller functions code.
114 # Check at the final call of src/libcaptive/reactos/ntoskrnl/io/irp.c/IofCallDriver().
115 CFLAGS="-O2"
116 %configure \
117                 --enable-shared --disable-static \
118                 --with-readline \
119                 --with-sandbox-setuid=@PACKAGE@ \
120                 --with-sandbox-setgid=@PACKAGE@ \
121                 --with-sandbox-chroot=%{_var}/lib/@PACKAGE@ \
122                 --with-sbin-mountdir=/sbin \
123                 --with-sbin-mount-fs=ntfs:fastfat:cdfs:ext2fsd \
124                 --disable-gtk-doc
125 make
126
127 %install
128 make DESTDIR=$RPM_BUILD_ROOT install-strip
129
130 %clean
131 rm -rf $RPM_BUILD_ROOT
132
133 %post
134 /sbin/ldconfig
135 /usr/sbin/useradd -c "Captive Sandbox" -s /sbin/nologin -r -d %{_var}/lib/@PACKAGE@ captive 2>/dev/null || true
136
137 %postun
138 /sbin/ldconfig
139
140 %files
141 %defattr(-,root,root)
142 %doc README NEWS AUTHORS TODO
143 %{_libdir}/lib@PACKAGE@-@VERSION@.so
144 %{_libdir}/gnome-vfs-2.0/modules/lib@PACKAGE@-gnomevfs-@VERSION@.so
145 %{_libdir}/gnome-vfs-2.0/modules/lib@PACKAGE@-gnomevfs.so
146 %{_bindir}/@PACKAGE@-cmdline
147 %attr(4755,root,root) %{_sbindir}/@PACKAGE@-sandbox-server
148 %config %{_sysconfdir}/gnome-vfs-2.0/modules/@PACKAGE@.conf
149 %{_datadir}/locale/*/LC_MESSAGES/@PACKAGE@.mo
150 %attr(755,root,root) %{_var}/lib/@PACKAGE@
151 %attr(644,root,root) %{_var}/lib/@PACKAGE@/*.sys
152
153 %files lufs
154 %defattr(-,root,root)
155 %{_libdir}/liblufs-@PACKAGE@fs-@VERSION@.so
156 %{_libdir}/liblufs-@PACKAGE@fs.so
157 /sbin/mount.@PACKAGE@
158 /sbin/mount.@PACKAGE@-*
159
160 %post install
161 %{_sbindir}/captive-install-fstab --add
162 %{_sbindir}/captive-install-acquire --scan-disks-quick
163
164 %preun install
165 %{_sbindir}/captive-install-fstab --remove
166
167 %files install
168 %defattr(-,root,root)
169 %config %{_sysconfdir}/w32-mod-id.captivemodid.xml
170 %{_sbindir}/captive-install-fstab
171 %{_sbindir}/captive-install-acquire
172
173 # %files devel
174 # %defattr(-,root,root)
175 # %doc ChangeLog
176 # /usr/include/@PACKAGE@
177 # /usr/share/aclocal/*
178 # %{_libdir}/gnome-vfs-2.0/modules/libcaptive-gnomevfs.la
179 # /usr/lib/*.a
180 # /usr/lib/*.la
181 # ###for --disable-shared/(--enable-static-link disable):
182 # /usr/lib/*[a-z].so