SPECS: flixengine.spec - amd64 linked bindings - bconds for python...

glen glen at pld-linux.org
Thu Dec 28 18:38:37 CET 2006


Author: glen                         Date: Thu Dec 28 17:38:37 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- amd64 linked bindings
- bconds for python and java

---- Files affected:
SPECS:
   flixengine.spec (1.16 -> 1.17) 

---- Diffs:

================================================================
Index: SPECS/flixengine.spec
diff -u SPECS/flixengine.spec:1.16 SPECS/flixengine.spec:1.17
--- SPECS/flixengine.spec:1.16	Thu Dec 28 18:27:50 2006
+++ SPECS/flixengine.spec	Thu Dec 28 18:38:32 2006
@@ -2,14 +2,21 @@
 #
 # Conditional build:
 %bcond_without	autodeps	# don't BR packages needed only for resolving deps
+%bcond_with		python	# do not build Python bindings
+%bcond_with		java	# do not build Java bindings
 %bcond_with	tests		# perform "make test". needs running flixd on localhost
 #
+%ifarch %{x8664}
+%undefine	with_python
+%undefine	with_java
+%endif
+#
 %include	/usr/lib/rpm/macros.perl
 Summary:	On2 Flix Engine
 Summary(pl):	Silnik On2 Flix
 Name:		flixengine
 Version:	8.0.7.1
-Release:	0.3
+Release:	0.4
 License:	not distributable
 Group:		Applications
 # download demo from http://flix.on2.com/demos/
@@ -17,12 +24,13 @@
 # NoSource0-md5:	fb7cc89ce2689d3c43434291620cfd0f
 NoSource:	0
 Source1:	%{name}.init
+Patch0:		%{name}-libdir.patch
 URL:		http://www.on2.com/developer/flix-engine-sdk
 BuildRequires:	bash
-BuildRequires:	jre
+%{?with_java:BuildRequires:	jre}
 BuildRequires:	perl-base
 BuildRequires:	php-devel
-BuildRequires:	python
+%{?with_python:BuildRequires:	python}
 BuildRequires:	rpm-perlprov >= 4.1-13
 BuildRequires:	rpmbuild(macros) >= 1.344
 %if %{with autodeps}
@@ -33,7 +41,7 @@
 Requires:	%{name}-libs = %{version}-%{release}
 Requires:	portmap
 Requires:	rc-scripts
-ExclusiveArch:	%{ix86}
+ExclusiveArch:	%{ix86} %{x8664}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 # FIXME: FHS 2.x violation
@@ -153,6 +161,8 @@
 dd bs=8 if=$bin of=$tar skip=$OFFSET
 %{__tar} zxf $tar
 
+%patch0 -p1
+
 %{__sed} -ne '/## FUNCTIONS common/,/## END - common function/p' $bin > functions.sh
 cat <<'EOF' > install.sh
 #!/bin/bash
@@ -195,12 +205,17 @@
 ln -snf flixhdrs flixengine2
 export C_INCLUDE_PATH=$(pwd)
 
-ldconfig -n flixlibs
+%ifarch %{x8664}
+export LD_LIBRARY_PATH=$(pwd)/testing/lib64
+ldconfig -n testing/lib64
+%else
 export LD_LIBRARY_PATH=$(pwd)/flixlibs
-export LIBRARY_PATH=$(pwd)/flixlibs
+ldconfig -n flixlibs
+%endif
 
 # PHP
 %{__make} -C flixphp \
+	LIBDIR=$LD_LIBRARY_PATH \
 	CC="%{__cc}" \
 	-f target.mk
 
@@ -214,15 +229,17 @@
 %{?with_tests:%{__make} test}
 cd ..
 
-# Python
+%if %{with python}
 cd flixpython
 %{__python} setup.py build
 cd ..
+%endif
 
-# Java
+%if %{with java}
 %{__make} -C flixjava \
 	CC="%{__cc}" \
 	-f target.mk
+%endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -243,8 +260,9 @@
 
 install -D %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/flixengine
 
-# install bindings
 cd .flix-engine-installation-files
+
+# install bindings
 # PHP
 %{__make} -C flixphp \
 	install \
@@ -263,15 +281,16 @@
 rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/On2/flixengine2/.packlist
 cd ..
 
-# Python
+%if %{with python}
 cd flixpython
 %{__python} setup.py install \
 	--optimize=2 \
 	--root=$RPM_BUILD_ROOT
 %py_postclean
 cd ..
+%endif
 
-# Java
+%if %{with java}
 %{__make} -C flixjava \
 	SOINST=$RPM_BUILD_ROOT%{_libdir} \
 	JARINST=$RPM_BUILD_ROOT%{_javadir} \
@@ -280,6 +299,11 @@
 
 # symlink without buildroot
 ln -snf %{_prefix}/src/flixmodules/flixjava/doc $RPM_BUILD_ROOT%{_docdir}/on2/flixengine/javadoc
+%endif
+
+%ifarch %{x8664}
+cp -a testing/lib64/libflixengine2.so* $RPM_BUILD_ROOT%{_libdir}
+%endif
 
 # do not put hardware fingerprint to rpm package
 > $RPM_BUILD_ROOT/var/lib/on2/hostinfo
@@ -320,7 +344,8 @@
 
 %files
 %defattr(644,root,root,755)
-%doc %{_docdir}/on2 doc/*
+%doc %{_docdir}/on2
+%doc doc/*
 %exclude %{_docdir}/on2/flixengine/javadoc
 %attr(755,root,root) %{_sbindir}/flixd
 %attr(755,root,root) %{_sbindir}/lget
@@ -337,23 +362,31 @@
 
 %files libs
 %defattr(644,root,root,755)
+%attr(755,root,root) %{_prefix}/lib/libflixengine2.so.*.*
+%attr(755,root,root) %{_prefix}/lib/libflixengine2_core.so.*.*
+%ifarch %{x8664}
 %attr(755,root,root) %{_libdir}/libflixengine2.so.*.*
-%attr(755,root,root) %{_libdir}/libflixengine2_core.so.*.*
+%endif
 %dir %{_examplesdir}/%{name}-%{version}
 
 %files devel
 %defattr(644,root,root,755)
+%attr(755,root,root) %{_prefix}/lib/libflixengine2.so
+%attr(755,root,root) %{_prefix}/lib/libflixengine2_core.so
+%ifarch %{x8664}
 %attr(755,root,root) %{_libdir}/libflixengine2.so
-%attr(755,root,root) %{_libdir}/libflixengine2_core.so
+%endif
 %{_includedir}/flixengine2
 %{_examplesdir}/%{name}-%{version}/c
 
+%if %{with java}
 %files -n java-flixengine
 %defattr(644,root,root,755)
 %doc %{_docdir}/on2/flixengine/javadoc
 %attr(755,root,root) %{_libdir}/libflixengine2_jni.so
 %{_javadir}/flixengine2.jar
 %{_examplesdir}/%{name}-%{version}/java
+%endif
 
 %files -n perl-flixengine
 %defattr(644,root,root,755)
@@ -372,12 +405,14 @@
 %{_libdir}/flixengine2.php
 %{_examplesdir}/%{name}-%{version}/php
 
+%if %{with python}
 %files -n python-flixengine
 %defattr(644,root,root,755)
 %attr(755,root,root) %{py_sitedir}/_flixengine2.so
 %{py_sitedir}/flixengine2.pyc
 %{py_sitedir}/flixengine2.pyo
 %{_examplesdir}/%{name}-%{version}/python
+%endif
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -385,6 +420,10 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.17  2006/12/28 17:38:32  glen
+- amd64 linked bindings
+- bconds for python and java
+
 Revision 1.16  2006/12/28 17:27:50  glen
 - install more docs
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/flixengine.spec?r1=1.16&r2=1.17&f=u



More information about the pld-cvs-commit mailing list