rpms/x264/devel x264.spec,1.38,1.39

Nicolas Chauvet kwizart at rpmfusion.org
Sat Jun 23 17:13:36 CEST 2012


Author: kwizart

Update of /cvs/free/rpms/x264/devel
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv19329/devel

Modified Files:
	x264.spec 
Log Message:
- Rework alternatives build
- Fix SONAME for x26410b



Index: x264.spec
===================================================================
RCS file: /cvs/free/rpms/x264/devel/x264.spec,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- x264.spec	17 Jun 2012 03:11:09 -0000	1.38
+++ x264.spec	23 Jun 2012 15:13:35 -0000	1.39
@@ -6,6 +6,7 @@
 %{?_with_bootstrap:
 %global _without_gpac 1
 %global _without_libavformat 1
+%global _without_libswscale  1
 }
 #Whitelist of arches with dedicated ASM code
 %ifnarch x86_64 i686 %{arm} ppc ppc64 %{sparc}
@@ -19,7 +20,7 @@
 Summary: H264/AVC video streams encoder
 Name: x264
 Version: 0.124
-Release: 2.%{snapshot}%{?dist}
+Release: 3.%{snapshot}%{?dist}
 License: GPLv2+
 Group: System Environment/Libraries
 URL: http://developers.videolan.org/x264.html
@@ -69,6 +70,7 @@
 	--extra-cflags="$RPM_OPT_FLAGS" \\\
 	%{?_with_visualize:--enable-visualize} \\\
 	%{?_without_libavformat:--disable-lavf} \\\
+	%{?_without_libswscale:--disable-swscale} \\\
 	%{!?_with_ffmpegsource:--disable-ffms} \\\
 	%{?_without_asm:--disable-asm} \\\
 	--enable-debug \\\
@@ -78,16 +80,22 @@
 
 
 %prep
-%setup -q -n %{name}-%{branch}-%{snapshot}
+%setup -q -c -n %{name}-%{branch}-%{snapshot}
+pushd %{name}-%{branch}-%{snapshot}
 %patch0 -p1 -b .nover
+popd
+variants="generic generic10"
 %ifarch i686
-mkdir simd
-cp -a `ls -1|grep -v simd` simd/
+variants="$variants simd"
 %endif
-cd ..
-cp -a %{name}-%{branch}-%{snapshot} %{name}-%{branch}-%{snapshot}10b
+for variant in $variants ; do
+  rm -rf ${variant}
+  cp -pr %{name}-%{branch}-%{snapshot} ${variant}
+done
+
 
 %build
+pushd generic
 %{x_configure}\
 	--host=%{_target_platform} \
 	--libdir=%{_libdir} \
@@ -96,6 +104,8 @@
 %endif
 
 %{__make} %{?_smp_mflags}
+popd
+
 %ifarch i686
 pushd simd
 %{x_configure}\
@@ -105,32 +115,39 @@
 %{__make} %{?_smp_mflags}
 popd
 %endif
-cd ../%{name}-%{branch}-%{snapshot}10b
+
+pushd generic10
 %{x_configure}\
 	--host=%{_target_platform} \
 	--libdir=%{_libdir} \
-    --bit-depth=10 \
+	--bit-depth=10
 %ifarch i686 armv5tel armv6l
 	--disable-asm \
 %endif
+sed -i -e "s/SONAME=libx264.so./SONAME=libx26410b.so./" config.mak
 
 %{__make} %{?_smp_mflags}
+popd
 
 %install
+pushd generic
 %{__make} DESTDIR=%{buildroot} install
+popd
 %ifarch i686
 pushd simd
 %{__make} DESTDIR=%{buildroot} install
 rm %{buildroot}%{_libdir}/*/pkgconfig/x264.pc
 popd
 %endif
-cd ../%{name}-%{branch}-%{snapshot}10b
-#{__make} DESTDIR=%{buildroot} install
-ln -f -s libx264.so.124 %{buildroot}%{_libdir}/libx26410b.so
-install -m 755 libx264.so.124 %{buildroot}%{_libdir}/libx26410b.so.124
+pushd generic10
+SONAME=`grep "^SONAME=" config.mak`
+export $SONAME
+install -m 755 ${SONAME} %{buildroot}%{_libdir}
+ln -fs ${SONAME} %{buildroot}%{_libdir}/libx26410b.so
+popd
 
 #Fix timestamp on x264 generated headers
-touch -r version.h %{buildroot}%{_includedir}/x264.h %{buildroot}%{_includedir}/x264_config.h
+touch -r generic/version.h %{buildroot}%{_includedir}/x264.h %{buildroot}%{_includedir}/x264_config.h
 
 
 %post libs -p /sbin/ldconfig
@@ -139,7 +156,7 @@
 
 %files
 %defattr(644, root, root, 0755)
-%doc AUTHORS COPYING
+%doc generic/AUTHORS generic/COPYING
 %attr(755,root,root) %{_bindir}/x264
 
 %files libs
@@ -152,7 +169,7 @@
 
 %files devel
 %defattr(644, root, root, 0755)
-%doc doc/*
+%doc generic/doc/*
 %{_includedir}/x264.h
 %{_includedir}/x264_config.h
 %{_libdir}/libx264.so
@@ -163,6 +180,10 @@
 %{_libdir}/libx26410b.so
 
 %changelog
+* Sat Jun 23 2012 Nicolas Chauvet <kwizart at gmail.com> - 0.124-3.20120616
+- Rework alternatives build
+- Fix SONAME for x26410b
+
 * Sun Jun 17 2012 Sérgio Basto <sergio at serjux.com> - 0.124-2.20120616
 - use _libdir to fix build on x86_64.
 


More information about the rpmfusion-commits mailing list