]> git.pld-linux.org Git - packages/libdv.git/blobdiff - libdv.spec
- disable asm on x86_64 because of relocation problems
[packages/libdv.git] / libdv.spec
index 0f938d4a41cd7e513db72186902a4534ebb0f2e1..49d1508f8e417775d3df269a9c039b0611146319 100644 (file)
@@ -1,23 +1,35 @@
 #
-# _with_mmx - uses MMX asm (won't run on non-MMX CPU!)
+# Conditional build:
+%bcond_without gui     # don't build gui stuff
+%bcond_with    mmx     # use MMX asm (won't run on non-MMX CPU!)
+%bcond_without static_libs     # don't build static library
+#
+%ifarch athlon pentium3 pentium4
+# %{x8664} skipped - gas generates PIC-incompatible relocation entries
+%define                with_mmx        1
+%endif
 Summary:       DV video software codec
 Summary(pl):   Biblioteka do obs³ugi formatu wideo DV
 Name:          libdv
-Version:       0.98
-Release:       1
-License:       GPL
-Group:         X11/Libraries
-Source0:       http://download.sourceforge.net/libdv/%{name}-%{version}.tar.gz
+Version:       0.104
+Release:       2
+License:       LGPL
+Group:         Libraries
+Source0:       http://dl.sourceforge.net/libdv/%{name}-%{version}.tar.gz
+# Source0-md5: f6b08efce7472daa20685e6e8431f542
+Patch0:                %{name}-include_fix.patch
 URL:           http://libdv.sourceforge.net/
+%if %{with gui}
+BuildRequires: SDL-devel >= 1.1.6
 BuildRequires: XFree86-devel
 BuildRequires: gtk+-devel >= 1.2.10-3
-BuildRequires: pkgconfig >= 0.7
+%endif
+BuildRequires: automake
+BuildRequires: pkgconfig >= 1:0.7
 BuildRequires: popt-devel
+BuildRequires: rpmbuild(macros) >= 1.213
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _prefix         /usr/X11R6
-%define                _mandir         %{_prefix}/man
-
 %description
 The Quasar DV codec (libdv) is a software codec for DV video. DV is
 the encoding format used by most digital camcorders, typically those
@@ -35,7 +47,7 @@ pisany zgodnie z oficjalnymi standardami DV, IEC 61834, SMPTE 314M.
 Summary:       Programs to encode and play DV files
 Summary(pl):   Programy do kodowania i odtwarzania plików DV
 Group:         X11/Applications/Multimedia
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{version}-%{release}
 
 %description -n dv
 Programs to encode and play DV files.
@@ -47,7 +59,7 @@ Programy do kodowania i odtwarzania plik
 Summary:       DV library headers
 Summary(pl):   Pliki nag³ówkowe biblioteki DV
 Group:         Development/Libraries
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{version}-%{release}
 
 %description devel
 This is the libraries, include files and other resources you can use
@@ -61,7 +73,7 @@ libdv.
 Summary:       DV static libraries
 Summary(pl):   Statyczne biblioteki do obs³ugi formatu DV
 Group:         Development/Libraries
-Requires:      %{name}-devel = %{version}
+Requires:      %{name}-devel = %{version}-%{release}
 
 %description static
 This is package with static libdv libraries.
@@ -70,13 +82,23 @@ This is package with static libdv libraries.
 Statyczna wersja biblioteki libdv.
 
 %prep
-%setup  -q
+%setup -q
+%patch0 -p1
 
 %build
+cp /usr/share/automake/config.sub .
 %configure \
        --enable-shared \
+%if %{with gui}
+       --enable-sdl \
+       --enable-gtk \
+%else
+       --disable-sdl \
+       --disable-gtk \
+%endif
        --without-debug \
-       %{!?_with_mmx:--disable-asm}
+       %{!?with_mmx:--disable-asm} \
+       %{!?with_static_libs:--disable-static}
 
 %{__make}
 
@@ -87,8 +109,6 @@ rm -rf $RPM_BUILD_ROOT
        DESTDIR=$RPM_BUILD_ROOT \
        pkgconfigdir=%{_pkgconfigdir}
 
-gzip -9nf AUTHORS ChangeLog NEWS README.* TODO
-
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -97,21 +117,25 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so.*
+%doc AUTHORS ChangeLog NEWS README.* TODO
+%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
 
+%if %{with gui}
 %files -n dv
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/*
 %{_mandir}/man1/*
+%endif
 
 %files devel
 %defattr(644,root,root,755)
-%doc *.gz
 %attr(755,root,root) %{_libdir}/lib*.so
-%{_includedir}/libdv
 %{_libdir}/*.la
+%{_includedir}/libdv
 %{_pkgconfigdir}/*
 
+%if %{with static_libs}
 %files static
 %defattr(644,root,root,755)
 %{_libdir}/lib*.a
+%endif
This page took 0.037002 seconds and 4 git commands to generate.