2011-07-25 12:58:45 +02:00
#
# spec file for package ntfs-3g_ntfsprogs
#
2013-02-01 00:49:35 +01:00
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
2011-07-25 12:58:45 +02:00
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
2012-02-17 09:53:46 +01:00
2011-07-25 12:58:45 +02:00
Name : ntfs-3g_ntfsprogs
Summary : NTFS Support in Userspace
2011-12-06 18:32:40 +01:00
License : GPL-2.0+
2011-07-25 12:58:45 +02:00
Group : System/Filesystems
2012-02-08 16:52:01 +01:00
Version : 2012.1.15
Release : 0
2013-04-15 16:10:18 +02:00
Source : http://tuxera.com/opensource/%{name} -%{version} .tgz
2011-07-25 12:58:45 +02:00
Source1 : buildall.sh
Source2 : 21-storage-ntfs-3g.fdi
2013-02-01 00:49:35 +01:00
# PATCH-FIX-UPSTREAM ntfs-3g_ntfsprogs-use-caution-with-fastboot.patch rh#859373 badshah400@gmail.com -- Prevent partitions with metadata cached in Windows from being mounted; patch taken from upstream git
Patch0 : ntfs-3g_ntfsprogs-use-caution-with-fastboot.patch
2013-04-15 16:10:18 +02:00
Url : http://www.tuxera.com/community/ntfs-3g-download/
2012-11-27 18:56:57 +01:00
%if 0%{?sles_version}
BuildRequires : fuse-devel >= 2.6.0
%else
BuildRequires : pkgconfig(fuse) >= 2.6.0
%endif
BuildRequires : pkgconfig
2011-07-25 12:58:45 +02:00
BuildRoot : %{_tmppath} /%{name} -%{version} -build
%description
NTFS-3G allows for read/write access to NTFS partitions which can be
shared with Windows XP, Windows Server 2003, Windows 2000, Windows
Vista and Windows Seven.
%package -n ntfs-3g
Summary : NTFS Support in Userspace
2012-02-08 16:52:01 +01:00
License : GPL-2.0+
2011-07-25 12:58:45 +02:00
Group : System/Filesystems
Provides : ntfsprogs-fuse = 1.13.1
Obsoletes : ntfsprogs-fuse < 1.13.1
2012-11-27 18:56:57 +01:00
%if 0%{?suse_version}
2011-07-25 12:58:45 +02:00
Requires(post) : update-alternatives
Requires(postun) : update-alternatives
# The build service fails to build the package because it doesn't really
# understand Requires(post), so use PreReq too (see bnc#439232).
PreReq : update-alternatives
%endif
%if 0%{?suse_version} > 1010
Supplements: filesystem(ntfs-3g)
%endif
%description -n ntfs-3g
NTFS-3G allows for read/write access to NTFS partitions which can be
shared with Windows XP, Windows Server 2003, Windows 2000, Windows
Vista and Windows Seven.
2012-02-08 16:48:22 +01:00
%package -n libntfs-3g83
2011-07-25 12:58:45 +02:00
Summary : NTFS Support in Userspace -- Library
2012-02-08 16:52:01 +01:00
License : LGPL-2.1+
2011-07-25 12:58:45 +02:00
Group : System/Filesystems
2012-02-08 16:48:22 +01:00
%description -n libntfs-3g83
2011-07-25 12:58:45 +02:00
NTFS-3G allows for read/write access to NTFS partitions which can be
shared with Windows XP, Windows Server 2003, Windows 2000, Windows
Vista and Windows Seven.
%package -n libntfs-3g-devel
Summary : NTFS Support in Userspace -- Development Files
2012-02-08 16:52:01 +01:00
License : LGPL-2.1+
2011-07-25 12:58:45 +02:00
Group : System/Filesystems
Requires : glibc-devel
2012-02-08 16:48:22 +01:00
Requires : libntfs-3g83 = %{version}
2011-07-25 12:58:45 +02:00
Provides : ntfs-3g-devel = %{version}
Obsoletes : ntfs-3g-devel < %{version}
%description -n libntfs-3g-devel
NTFS-3G allows for read/write access to NTFS partitions which can be
shared with Windows XP, Windows Server 2003, Windows 2000, Windows
Vista and Windows Seven.
%package -n ntfsprogs
Summary : NTFS Utilities
2012-02-08 16:52:01 +01:00
License : GPL-2.0+
2011-07-25 12:58:45 +02:00
Group : System/Filesystems
%description -n ntfsprogs
The ntfsprogs includes utilities for doing all required tasks to NTFS
partitions. In general, just run a utility without any command line
options to display the version number and usage syntax.
%prep
%setup -q
2013-02-01 00:49:35 +01:00
%patch0 -p1
2011-07-25 12:58:45 +02:00
%build
#
# regarding -Wno-sign-compare - checked with the Szaka: There is one variable
# which is signed and would possibly ok to be unsigned. Any solution to this
# needs to be carefully reviewed and tested, so we do not change the code now:
#
2012-05-26 18:37:56 +02:00
export CFLAGS=" $RPM_OPT_FLAGS - W f o r m a t - W f o r m a t - s e c u r i t y - W - W n o - s i g n - c o m p a r e "
2012-11-27 18:56:57 +01:00
%configure --exec-prefix=/ --disable-static --with-pic --disable-ldconfig \
--with-fuse=external
2012-05-26 18:37:56 +02:00
make %{?_smp_mflags}
2011-07-25 12:58:45 +02:00
%install
2012-11-27 18:56:57 +01:00
make install DESTDIR=" % b u i l d r o o t "
2012-02-17 09:53:46 +01:00
%{__rm} -v %{buildroot} %{_libdir} /libntfs-3g.la
2011-07-25 12:58:45 +02:00
# Hal stuff for mounting on hotplug.
%{__mkdir_p} %{buildroot} %{_datadir} /hal/fdi/policy/10osvendor/
%{__install} -m 644 %{SOURCE2} %{buildroot} %{_datadir} /hal/fdi/policy/10osvendor/21-storage-ntfs-3g.fdi
# Touch ghost files
touch %{buildroot} /sbin/mount.ntfs %{buildroot} %{_mandir} /man8/mount.ntfs.8
%check
TESTFS=$(mktemp) || exit 1
ntfsprogs/mkntfs -q -F $TESTFS 3000
src/ntfs-3g.probe --readonly $TESTFS
src/ntfs-3g.probe --readwrite $TESTFS
rm -v $TESTFS
%post -n ntfs-3g
# If the mount.ntfs group is in automatic mode, then this will also switch all
# symlinks automatically
update-alternatives --install /sbin/mount.ntfs mount.ntfs /sbin/mount.ntfs-3g 10 --slave /usr/share/man/man8/mount.ntfs.8.gz mount.ntfs.8.gz /usr/share/man/man8/mount.ntfs-3g.8.gz
%postun -n ntfs-3g
# Note: we don't use "$1 -eq 0", to avoid issues if the package gets renamed
if [ ! -f /sbin/mount.ntfs-3g ]; then
update-alternatives --remove mount.ntfs /sbin/mount.ntfs-3g
fi
%posttrans -n ntfs-3g
# Workaround old bug in 11.1/11.2 packages that always removed the symlinks in
# %postun. Can be removed during 12.2 development.
if [ ! -f /sbin/mount.ntfs -a -f /sbin/mount.ntfs-3g ]; then
update-alternatives --install /sbin/mount.ntfs mount.ntfs /sbin/mount.ntfs-3g 10 --slave /usr/share/man/man8/mount.ntfs.8.gz mount.ntfs.8.gz /usr/share/man/man8/mount.ntfs-3g.8.gz
fi
2012-02-08 16:48:22 +01:00
%post -n libntfs-3g83 -p /sbin/ldconfig
2011-07-25 12:58:45 +02:00
2012-02-08 16:48:22 +01:00
%postun -n libntfs-3g83 -p /sbin/ldconfig
2011-07-25 12:58:45 +02:00
%files -n ntfs-3g
%defattr (-,root,root,-)
%doc AUTHORS ChangeLog COPYING CREDITS NEWS README
%dir %{_datadir} /hal
%dir %{_datadir} /hal/fdi
%dir %{_datadir} /hal/fdi/policy
%dir %{_datadir} /hal/fdi/policy/10osvendor
%{_datadir} /hal/fdi/policy/10osvendor/21-storage-ntfs-3g.fdi
%{_bindir} /ntfs-3g
%{_bindir} /ntfs-3g.probe
%{_bindir} /ntfs-3g.secaudit
%{_bindir} /ntfs-3g.usermap
%{_bindir} /lowntfs-3g
%ghost /sbin/mount.ntfs
/sbin/mount.ntfs-3g
/sbin/mount.lowntfs-3g
%{_mandir} /man8/mount.lowntfs-3g.8%{?ext_man}
%ghost %{_mandir} /man8/mount.ntfs.8%{?ext_man}
%{_mandir} /man8/mount.ntfs-3g.8%{?ext_man}
%{_mandir} /man8/ntfs-3g.8%{?ext_man}
%{_mandir} /man8/ntfs-3g.probe.8%{?ext_man}
%{_mandir} /man8/ntfs-3g.secaudit.8%{?ext_man}
%{_mandir} /man8/ntfs-3g.usermap.8%{?ext_man}
# We already have this, so no need to package it again.
%exclude /usr/share/doc/ntfs-3g/README
2012-02-08 16:48:22 +01:00
%files -n libntfs-3g83
2011-07-25 12:58:45 +02:00
%defattr (-,root,root,-)
%doc COPYING.LIB
2012-02-17 09:53:46 +01:00
%{_libdir} /libntfs-3g.so.*
2011-07-25 12:58:45 +02:00
%files -n libntfs-3g-devel
%defattr (-,root,root,-)
%{_includedir} /ntfs-3g/
%{_libdir} /libntfs-3g.so
%{_libdir} /pkgconfig/libntfs-3g.pc
%files -n ntfsprogs
%defattr (-, root, root)
%doc AUTHORS ChangeLog COPYING CREDITS NEWS README
/sbin/mkfs.ntfs
%{_sbindir} /mkntfs
%{_sbindir} /ntfsclone
%{_sbindir} /ntfscp
%{_sbindir} /ntfslabel
%{_sbindir} /ntfsresize
%{_sbindir} /ntfsundelete
%{_bindir} /ntfscat
%{_bindir} /ntfscluster
%{_bindir} /ntfscmp
%{_bindir} /ntfsfix
%{_bindir} /ntfsinfo
%{_bindir} /ntfsls
%{_mandir} /man8/mkfs.ntfs.8%{?ext_man}
%{_mandir} /man8/mkntfs.8%{?ext_man}
%{_mandir} /man8/ntfscat.8%{?ext_man}
%{_mandir} /man8/ntfsclone.8%{?ext_man}
%{_mandir} /man8/ntfscluster.8%{?ext_man}
%{_mandir} /man8/ntfscmp.8%{?ext_man}
%{_mandir} /man8/ntfscp.8%{?ext_man}
%{_mandir} /man8/ntfsfix.8%{?ext_man}
%{_mandir} /man8/ntfsinfo.8%{?ext_man}
%{_mandir} /man8/ntfslabel.8%{?ext_man}
%{_mandir} /man8/ntfsls.8%{?ext_man}
%{_mandir} /man8/ntfsprogs.8%{?ext_man}
%{_mandir} /man8/ntfsresize.8%{?ext_man}
%{_mandir} /man8/ntfsundelete.8%{?ext_man}
%changelog