libmpeg2/libmpeg2.spec

changeset 1
4667f24fe848
parent 0
4f133201e207
     1.1 --- a/libmpeg2/libmpeg2.spec	Fri Mar 11 21:30:26 2011 +0100
     1.2 +++ b/libmpeg2/libmpeg2.spec	Fri Mar 11 21:36:51 2011 +0100
     1.3 @@ -1,97 +1,90 @@
     1.4  Name:           libmpeg2
     1.5 +Summary:        MPEG-2 decoder libraries
     1.6 +Vendor:         Europalab Software
     1.7 +Packager:       Michael Schloh von Bennewitz
     1.8 +Distribution:   MeeGo Thirdparty
     1.9  Version:        0.5.1
    1.10 -Release:        9%{?dist}
    1.11 -Summary:        MPEG-2 decoder libraries
    1.12 -
    1.13 +Release:        20101201
    1.14  Group:          System Environment/Libraries
    1.15  License:        GPLv2+
    1.16  URL:            http://libmpeg2.sourceforge.net/
    1.17  Source0:        http://libmpeg2.sourceforge.net/files/libmpeg2-%{version}.tar.gz
    1.18 -BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
    1.19 -
    1.20 +BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
    1.21  BuildRequires:  SDL-devel
    1.22  BuildRequires:  libXt-devel
    1.23  BuildRequires:  libXv-devel
    1.24 -
    1.25 +BuildRequires:  chrpath
    1.26  
    1.27  %description
    1.28 -libmpeg2 is a free library for decoding mpeg-2 and mpeg-1 video
    1.29 -streams. It is released under the terms of the GPL license.
    1.30 +The libmpeg2 library is a free decoder of mpeg-2 and mpeg-1 video streams.
    1.31  
    1.32 -%package -n     mpeg2dec
    1.33 +%package -n mpeg2dec
    1.34  Summary:        MPEG-2 decoder program
    1.35  Group:          Applications/Multimedia
    1.36  Requires:       %{name} = %{version}-%{release}
    1.37  
    1.38  %description -n mpeg2dec
    1.39 -The %{name}-devel package contains libraries and header files for
    1.40 +The libmpeg2 library is a free decoder of mpeg-2 and mpeg-1 video
    1.41 +streams. This package contains the small mpeg2dec(1) test program
    1.42 +used together with %{name}.
    1.43 +
    1.44 +%package devel
    1.45 +Summary:        Development files for %{name}
    1.46 +Vendor:         Europalab Software
    1.47 +Packager:       Michael Schloh von Bennewitz
    1.48 +Distribution:   MeeGo Thirdparty
    1.49 +Group:          Development/Libraries
    1.50 +Requires:       pkgconfig
    1.51 +Requires:       %{name} = %{version}-%{release}
    1.52 +Provides:       %{name}-devel = %{version}-%{release}
    1.53 +
    1.54 +%description devel
    1.55 +The libmpeg2 library is a free decoder of mpeg-2 and mpeg-1 video
    1.56 +streams. This package contains libraries and header files for
    1.57  developing applications that use %{name}.
    1.58  
    1.59 -%package        devel
    1.60 -Summary:        Development files for %{name}
    1.61 -Group:          Development/Libraries
    1.62 -Requires:       %{name} = %{version}-%{release}
    1.63 -Requires:       pkgconfig
    1.64 -# Introducted in F-10 Can be dropped in F-12
    1.65 -Provides:       mpeg2dec-devel = %{version}-%{release}
    1.66 -Obsoletes:      mpeg2dec-devel < %{version}
    1.67 -
    1.68 -%description    devel
    1.69 -The %{name}-devel package contains libraries and header files for
    1.70 -developing applications that use %{name}.
    1.71 -
    1.72 -
    1.73  %prep
    1.74  %setup -q
    1.75 -iconv -f ISO-8859-1 -t UTF-8 AUTHORS > AUTHORS.tmp
    1.76 -touch -r AUTHORS AUTHORS.tmp 
    1.77 -cp -p -f AUTHORS.tmp AUTHORS
    1.78 -rm AUTHORS.tmp
    1.79  
    1.80 -#Disable ppc altivec case
    1.81 -sed -i -e 's/ppc-/noppc64-/' configure.ac configure
    1.82 -sed -i -e 's/powerpc-/nopowerpc64-/' configure.ac configure
    1.83 +# disable ppc altivec case
    1.84 +sed -i -e 's;ppc-;noppc64-;' configure.ac configure
    1.85 +sed -i -e 's;powerpc-;nopowerpc64-;' configure.ac configure
    1.86  
    1.87  %build
    1.88 -%configure --disable-static \
    1.89 +%configure \
    1.90 +    --enable-shared \
    1.91  %ifarch %{ix86} ppc
    1.92 -  --disable-accel-detect \
    1.93 +    --disable-accel-detect \
    1.94  %endif
    1.95 -
    1.96 -# mpeg2dec have rpath
    1.97 -# remove rpath from libtool
    1.98 -sed -i.rpath 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
    1.99 -sed -i.rpath 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
   1.100 +    --disable-rpath
   1.101  
   1.102  make %{?_smp_mflags} \
   1.103  %ifarch %{ix86}
   1.104 -  OPT_CFLAGS="-fPIC -DPIC" \
   1.105 +    OPT_CFLAGS="-fPIC -DPIC" \
   1.106  %else
   1.107 -  OPT_CFLAGS="" \
   1.108 +    OPT_CFLAGS=""
   1.109  %endif
   1.110  
   1.111 -
   1.112  %install
   1.113  rm -rf $RPM_BUILD_ROOT
   1.114 -make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
   1.115 +make install DESTDIR=$RPM_BUILD_ROOT
   1.116  find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
   1.117  
   1.118 +# fix datatype internal definitions
   1.119 +install -pm 0644 libmpeg2/mpeg2_internal.h \
   1.120 +    $RPM_BUILD_ROOT%{_includedir}/mpeg2dec/
   1.121  
   1.122 -#Fix datatype internal definitions
   1.123 -install -pm 0644 libmpeg2/mpeg2_internal.h \
   1.124 -  $RPM_BUILD_ROOT%{_includedir}/mpeg2dec/
   1.125 -
   1.126 -
   1.127 +# remove rpath
   1.128 +chrpath --delete $RPM_BUILD_ROOT%{_bindir}/*
   1.129 +chrpath --delete $RPM_BUILD_ROOT%{_libdir}/*.so.*
   1.130  
   1.131  %clean
   1.132  rm -rf $RPM_BUILD_ROOT
   1.133  
   1.134 -
   1.135  %post -p /sbin/ldconfig
   1.136  
   1.137  %postun -p /sbin/ldconfig
   1.138  
   1.139 -
   1.140  %files
   1.141  %defattr(-,root,root,-)
   1.142  %doc AUTHORS ChangeLog COPYING NEWS README TODO
   1.143 @@ -102,18 +95,21 @@
   1.144  %{_bindir}/corrupt_mpeg2
   1.145  %{_bindir}/extract_mpeg2
   1.146  %{_bindir}/mpeg2dec
   1.147 -%{_mandir}/man1/*.1*
   1.148 +%{_mandir}/man1/extract_mpeg2.1.gz
   1.149 +%{_mandir}/man1/mpeg2dec.1.gz
   1.150  
   1.151  %files devel
   1.152  %defattr(-,root,root,-)
   1.153  %doc CodingStyle doc/libmpeg2.txt doc/sample*.c
   1.154 -%{_includedir}/mpeg2dec/
   1.155 +%{_includedir}/mpeg2dec
   1.156 +%{_libdir}/*.a
   1.157  %{_libdir}/*.so
   1.158 -%{_libdir}/pkgconfig/libmpeg2.pc
   1.159 -%{_libdir}/pkgconfig/libmpeg2convert.pc
   1.160 -
   1.161 +%{_libdir}/pkgconfig/*.pc
   1.162  
   1.163  %changelog
   1.164 +* Wed Dec 1 2010 Michael Schloh von Bennewitz <michael@schloh.com> - 0.5.1-20101201
   1.165 +- Adjust packaging and patch logic
   1.166 +
   1.167  * Mon Nov 1 2010 Kozinov Ivan <kozinov@gmail.com> - 0.5.1-9
   1.168  - Build for MeeGo 1.1
   1.169  

mercurial