File udftools.spec of Package udftools
#
# spec file for package udftools
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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/
#
Name: udftools
Version: 1.0.0b3
Release: 0
Summary: UDF filesystem tools
License: GPL-2.0+
Group: System/Filesystems
Url: http://linux-udf.sourceforge.net/
Source: http://downloads.sourceforge.net/project/linux-udf/%{name}/%{version}/%{name}-%{version}.tar.gz
Source1: http://www.kernel.org/pub/linux/kernel/people/axboe/tools/cdmrw.c
Source3: http://www.gnu.org/licenses/gpl-3.0.txt
Patch0: %{name}-%{version}.dif
Patch1: udftools-1.0.0b3-pktsetup-chardev.patch
Patch2: udftools-gcc4.patch
Patch3: udftools-include.patch
Patch4: cdmrw-include.patch
Patch5: udftools-HZ.patch
Patch6: udftools-open.patch
Patch7: udftools-wrong-memset.patch
BuildRequires: libtool
BuildRequires: readline-devel
Provides: udf = %{version}
Obsoletes: udf < %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
These are tools for UDF file systems as used, e.g., on DVD-ROMs.
%prep
%setup -q
cp -a %{SOURCE1} .
cp %{SOURCE3} LICENSE.GPL-3.0
%patch0
%patch1 -p1
%patch2
%patch3
%patch4
%patch5
%patch6
%patch7 -p1
%build
cc %{optflags} cdmrw.c -o cdmrw
autoreconf -fvi
CFLAGS="%{optflags} -fgnu89-inline"
%configure
make %{?_smp_mflags}
%install
%make_install %{?_smp_mflags}
install cdmrw %{buildroot}%{_bindir}/
rm %{buildroot}%{_libdir}/libudffs.a
rm %{buildroot}%{_libdir}/libudffs.la
%files
%defattr(-,root,root)
%doc ChangeLog AUTHORS README LICENSE.GPL-3.0
%{_bindir}/*
%{_mandir}/man1/*.1.gz
%{_mandir}/man8/*.8.gz
%changelog