File libcdio.spec of Package libcdio.7811

#
# spec file for package libcdio
#
# Copyright (c) 2018 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/
#


%define cdioutils 0
%define cdio_soname 16
Name:           libcdio
Version:        0.94
Release:        0
Summary:        CD-ROM Access Library
License:        GPL-3.0+
Group:          Productivity/Multimedia/Other
Url:            https://savannah.gnu.org/projects/libcdio
Source0:        https://ftp.gnu.org/gnu/libcdio/%{name}-%{version}.tar.gz
Source1:        https://ftp.gnu.org/gnu/libcdio/%{name}-%{version}.tar.gz.sig
Source2:        %{name}.keyring
Source3:        baselibs.conf
# PATCH-FIX-UPSTREAM 0001-Savannah-Bug-49907.patch https://savannah.gnu.org/bugs/index.php?49907
Patch0:         0001-Savannah-Bug-49907.patch
# PATCH-FIX-SECURITY CVE-2017-18201.patch bsc1082877 CVE-2017-18201 sbrabec@suse.com -- Fix double free vulnerability.
Patch1:         CVE-2017-18201.patch
# PATCH-FIX-SECURITY CVE-2017-18199.patch bsc1082821 CVE-2017-18199 sbrabec@suse.com -- Fix NULL Pointer Dereference.
Patch2:         CVE-2017-18199.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-01.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch101:       libcdio-0.94-leak-01.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-02.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch102:       libcdio-0.94-leak-02.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-03.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch103:       libcdio-0.94-leak-03.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-04.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch104:       libcdio-0.94-leak-04.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-05.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch105:       libcdio-0.94-leak-05.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-06.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch106:       libcdio-0.94-leak-06.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-07patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch107:       libcdio-0.94-leak-07.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-08.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch108:       libcdio-0.94-leak-08.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-09.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch109:       libcdio-0.94-leak-09.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-10.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch110:       libcdio-0.94-leak-10.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-11.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch111:       libcdio-0.94-leak-11.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-12.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch112:       libcdio-0.94-leak-12.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-13.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch113:       libcdio-0.94-leak-13.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-14.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch114:       libcdio-0.94-leak-14.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-15.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch115:       libcdio-0.94-leak-15.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-16.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch116:       libcdio-0.94-leak-16.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-17.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch117:       libcdio-0.94-leak-17.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-18.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch118:       libcdio-0.94-leak-18.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-19.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch119:       libcdio-0.94-leak-19.patch
# PATCH-FIX-UPSTREAM libcdio-0.94-leak-20.patch bsc1082821 sbrabec@suse.com -- Memory leak fix.
Patch120:       libcdio-0.94-leak-20.patch
BuildRequires:  fdupes
BuildRequires:  gcc-c++
BuildRequires:  help2man
BuildRequires:  libtool
BuildRequires:  ncurses-devel
BuildRequires:  pkgconfig
BuildRequires:  popt-devel
BuildRequires:  pkgconfig(libcddb)
Requires(post): %{install_info_prereq}
Requires(preun): %{install_info_prereq}
%if 0%{?suse_version} > 1220
BuildRequires:  makeinfo
%endif

%description
The libcdio package contains libraries for CD-ROM and CD image
access. Applications can use them as an abstraction to OS- and
device-dependent properties of a CD-ROM or of the specific details of
various CD image formats.

%package -n libcdio%{cdio_soname}
Summary:        CD-ROM Access Library
Group:          System/Libraries

%description -n libcdio%{cdio_soname}
The libcdio package contains libraries for CD-ROM and CD image
access. Applications can use them as an abstraction to OS- and
device-dependent properties of a CD-ROM or of the specific details of
various CD image formats.

This subpackage contains the C API library from cdio.

%package -n libcdio++0
Summary:        C++ API for the libcdio CD-ROM access library
Group:          System/Libraries

%description -n libcdio++0
The libcdio package contains libraries for CD-ROM and CD image
access.

This subpackage contains the C++ API library for cdio.

%package -n libiso9660-10
Summary:        Library for working with ISO 9660 filesystems
Group:          System/Libraries

%description -n libiso9660-10
A library for working with ISO 9660 filesystems.

%package -n libudf0
Summary:        Library for working with Universal Disk Format filesystems
Group:          System/Libraries

%description -n libudf0
A library for working with UDF filesystems.

%package devel
Summary:        CD-ROM access library
Group:          Development/Languages/C and C++
Requires:       glibc-devel
Requires:       libcdio%{cdio_soname} = %{version}
Requires:       libcdio++0 = %{version}
Requires:       libiso9660-10 = %{version}
Requires:       libudf0 = %{version}
Requires(post): %{install_info_prereq}
Requires(preun): %{install_info_prereq}

%description devel
The libcdio package contains libraries for CD-ROM and CD image
access. Applications can use them as an abstraction to OS- and
device-dependent properties of a CD-ROM or of the specific details of
various CD image formats.

This subpackage contains libraries and header files for developing
applications that want to make use of the cdio libraries.

%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch101 -p1
%patch102 -p1
%patch103 -p1
%patch104 -p1
%patch105 -p1
%patch106 -p1
%patch107 -p1
%patch108 -p1
%patch109 -p1
%patch110 -p1
%patch111 -p1
%patch112 -p1
%patch113 -p1
%patch114 -p1
%patch115 -p1
%patch116 -p1
%patch117 -p1
%patch118 -p1
%patch119 -p1
%patch120 -p1
%define buildir ${PWD}

%build
%configure \
	--disable-rpath \
	--disable-static \
	--enable-rock \
	--without-cd-drive \
	--without-cd-info \
	--without-cdda-player \
	--without-cd-read \
	--without-iso-info \
	--without-iso-read
 VERBOSE=1 make -e %{?_smp_mflags}
#-lcdioutils

%install
%make_install
%if 1 == 0
mv %{buildroot}%{_mandir}/jp %{buildroot}%{_mandir}/ja
%endif
#empty depdendency libs
rm -rf %{buildroot}%{_bindir} %{buildroot}%{_mandir}
find %{buildroot} -type f -name "*.la" -delete -print

%post -n libcdio%{cdio_soname} -p /sbin/ldconfig
%post -n libcdio++0 -p /sbin/ldconfig
%post -n libiso9660-10 -p /sbin/ldconfig
%post -n libudf0 -p /sbin/ldconfig
%postun -n libcdio%{cdio_soname} -p /sbin/ldconfig
%postun -n libcdio++0 -p /sbin/ldconfig
%postun -n libiso9660-10 -p /sbin/ldconfig
%postun -n libudf0 -p /sbin/ldconfig
%post devel
%install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz

%preun devel
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz

%files -n libcdio%{cdio_soname}
%{_libdir}/libcdio.so.*

%files -n libcdio++0
%{_libdir}/libcdio++.so.*
%{_libdir}/libiso9660++.so.*

%files -n libiso9660-10
%{_libdir}/libiso9660.so.*

%files -n libudf0
%{_libdir}/libudf.so.*

%files devel
%{_infodir}/*.info*
%{_includedir}/cdio
%{_includedir}/cdio++
%{_libdir}/libcdio*.so
%{_libdir}/libiso9660*.so
%{_libdir}/libudf*.so
%{_libdir}/pkgconfig/*.pc

%changelog
openSUSE Build Service is sponsored by