Revision: 5370 https://sourceforge.net/p/pkgbuild/code/5370 Author: tom68 Date: 2013-07-21 17:56:25 +0000 (Sun, 21 Jul 2013) Log Message: ----------- experimental/SFEvlc-2.0.7.spec: svn copy 2.0.5 -> 2.0.7, bump version to 2.0.7, enable aac, liveMedia, force gcc 4.6.x to avoid errors with 4.7.x, for more see %changelog. Works in S11, needs so much love for S12 Added Paths: ----------- spec-files-extra/trunk/experimental/SFEvlc-2.0.7.spec Copied: spec-files-extra/trunk/experimental/SFEvlc-2.0.7.spec (from rev 5338, spec-files-extra/trunk/experimental/SFEvlc-2.0.5.spec) =================================================================== --- spec-files-extra/trunk/experimental/SFEvlc-2.0.5.spec 2013-04-22 17:57:05 UTC (rev 5338) +++ spec-files-extra/trunk/experimental/SFEvlc-2.0.7.spec 2013-07-21 17:56:25 UTC (rev 5370) @@ -74,7 +74,6 @@ %include packagenamemacros.inc %define cc_is_gcc 1 -%define _gpp /usr/gnu/bin/g++ %if %arch_sse2 #######%define arch_opt --cpu=i686 --enable-mmx --enable-mmx2 %include x86_sse2.inc @@ -87,6 +86,7 @@ #new with 2.x.x source comes compressed in xz BuildRequires: %{pnm_buildrequires_SFExz_gnu} +BuildRequires: %{pnm_buildrequires_SUNWgsed} #we have new X-org with x11-xcb CR 6667057 ##TODO## check if other solarish OS do have same x11-xcb integrated with build 153 @@ -119,7 +119,7 @@ Name: SFEvlc Summary: vlc - multimedia player and streaming server -Version: 2.0.5 +Version: 2.0.7 Source: %{src_url}/%{version}/%{src_name}-%{version}.tar.xz Patch3: vlc-03-1141-oss.diff @@ -153,6 +153,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build %include default-depend.inc +BuildRequires: %{pnm_buildrequires_SUNWautomake_111} ##TODO## check for a pnm_macro to fetch SFEsdl (depends on the addon SFEsdl-image below) %if %SFEsdl BuildRequires: SFEsdl-devel @@ -208,14 +209,15 @@ Requires: SFElibx264 BuildRequires: SFElibtar-devel Requires: SFElibtar -BuildRequires: SUNWlua -Requires: SUNWlua +BuildRequires: %{pnm_buildrequires_SUNWlua} +Requires: %{pnm_buildrequires_SUNWlua} BuildRequires: SUNWlibgcrypt BuildRequires: SUNWlibproxy BuildRequires: SUNWgnome-vfs BuildRequires: SUNWlibrsvg BuildRequires: SFEtwolame -BuildRequires: SFEgcc +#BuildRequires: SFEgcc +BuildRequires: SFEgcc-46 BuildRequires: SUNWavahi-bridge-dsd BuildRequires: SUNWlibgpg-error Requires: SUNWlibgcrypt @@ -223,7 +225,8 @@ Requires: SUNWgnome-vfs Requires: SUNWlibrsvg Requires: SFEtwolame -Requires: SFEgccruntime +#Requires: SFEgccruntime +Requires: SFEgccruntime-46 Requires: SUNWavahi-bridge-dsd Requires: SUNWlibgpg-error BuildRequires: SFEtwolame-devel @@ -236,6 +239,8 @@ Requires: SFElibid3tag BuildRequires: SFEfaad2-devel Requires: SFEfaad2 +BuildRequires: SFEfaac-devel +Requires: SFEfaac BuildRequires: SFElame-devel Requires: SFElame BuildRequires: SFElibdvdcss-devel @@ -310,32 +315,34 @@ GNULIB="-L/usr/gnu/lib -R/usr/gnu/lib" export ACLOCAL_FLAGS="-I %{_datadir}/aclocal -I ./m4" -export CC=/usr/gnu/bin/gcc -export CXX=/usr/gnu/bin/g++ +export CC=/usr/gcc/4.6/bin/gcc +export CXX=/usr/gcc/4.6/bin/g++ +export LD=/opt/dtbld/bin/ld-wrapper +#need to use this "ar" +export AR=`pwd`/localbin/ar +export RANLIB=`pwd`/localbin/ranlib #place selected gnu tools into a local bin directory (e.g. gnu grep -q) -#export PATH=`pwd`/bin:/usr/bin:$PATH -export PATH=`pwd`/bin:$PATH -[ -d bin ] || mkdir bin -[ -s bin/grep ] || ln -s /usr/gnu/bin/grep bin/grep -[ -s bin/ar ] || ln -s /usr/bin/ar bin/ar +export PATH=`pwd`/localbin:$PATH +[ -d localbin ] || mkdir localbin +[ -s localbin/tail ] || ln -s /usr/gnu/bin/tail localbin/tail +[ -s localbin/grep ] || ln -s /usr/gnu/bin/grep localbin/grep +[ -s localbin/ar ] || ln -s /usr/bin/ar localbin/ar +[ -s localbin/ranlib ] || ln -s /usr/bin/ranlib localbin/ranlib -# -#notes to flags: -# Ticket #3040 (closed defect: fixed) https://trac.videolan.org/vlc/ticket/3040 -# need to define _XPG4_2 on Solaris - ##TODO## why make an extra "-L/lib -R/lib" ... can't see why we should do this -#export CXXFLAGS="%cxx_optflags -fpermissive -D_XPG4_2 -D__EXTENSIONS__ -L/lib -R/lib" -export CXXFLAGS="%cxx_optflags -L/lib -R/lib -fpermissive -D_XPG4_2 -D__EXTENSIONS__" -export CFLAGS="%optflags -L/lib -R/lib -D_XPG4_2 -D__EXTENSIONS__ -L/usr/gcc/lib -R/usr/gcc/lib $GNULIB" +#note: only as container, configure doesn't listen to this variable! +export CPPFLAGS_live555="-I/usr/lib/live/liveMedia/include -I/usr/lib/live/groupsock/include -I/usr/lib/live/BasicUsageEnvironment/include -I/usr/lib/live/UsageEnvironment/include" +export CXXFLAGS="%cxx_optflags -fpermissive -D_XPG4_2 -D__EXTENSIONS__ $CPPFLAGS_live555" +export CFLAGS="%optflags $GNULIB -D_XPG4_2 -D__EXTENSIONS__" +#http://www.velocityreviews.com/forums/t737908-gcc-std-c99-fail-to-compile-clock_gettime.html +#export CXXFLAGS="${CXXFLAGS} -D_XOPEN_SOURCE=500" +#export CFLAGS="${CFLAGS} -D_XOPEN_SOURCE=500" + #give these flags only to the C-Pre-Processor -export CPPFLAGS="-I/usr/X11/include -I/usr/gnu/include -I/usr/include/libavcodec -I/usr/include/libavutil -I./include -D_XPG4_2 -D__EXTENSIONS__" +#export CPPFLAGS="-I/usr/X11/include -I/usr/gnu/include -I/usr/include/libavcodec -I/usr/include/libavutil -I./include -D__EXTENSIONS__" -#extend CFLAGS and CPPFLAGS with more Include locations for special libraries -#live555 aka liveMedia -export EXTRA_CFLAGS="${EXTRA_CFLAGS} -I/usr/lib/live/liveMedia/include -I/usr/lib/live/groupsock/include -I/usr/lib/live/UsageEnvironment/include" %if %{enable_matroska} #to find matroska as g++ variant we use -I/usr/g++/include @@ -348,10 +355,17 @@ #as external define export EXTRA_CFLAGS="${EXTRA_CFLAGS} -DO_DIRECTORY=0x1000000" +%if %{solaris12} +#solaris 12 has tdestroy in libs.so and in /usr/include/search.h +#export EXTRA_CFLAGS="${EXTRA_CFLAGS} -DHAVE_TDESTROY=0" +# doesn't find luaL_register +export EXTRA_CFLAGS="${EXTRA_CFLAGS} -DLUA_COMPAT_ALL=1" +%endif + export CFLAGS="${CFLAGS} ${EXTRA_CFLAGS}" -export CPPFLAGS="${CPPFLAGS} ${EXTRA_CFLAGS}" -export CFLAGS="${CPPFLAGS} -mmmx -sse" +export CFLAGS="${CFLAGS} -mmmx" +export CPPFLAGS="${CPPFLAGS} -mmmx" %if %{debug_build} @@ -363,13 +377,14 @@ export LD=/opt/dtbld/bin/ld-wrapper #need to use this "ar" -export AR=/usr/bin/ar +export AR=`pwd`/localbin/ar +export RANLIB=`pwd`/localbin/ranlib #place selected gnu tools into a local bin directory (e.g. gnu grep -q) -#export PATH=`pwd`/bin:/usr/bin:$PATH -export PATH=`pwd`/bin:$PATH -[ -d bin ] || mkdir bin -[ -s bin/grep ] || ln -s /usr/gnu/bin/grep bin/grep -[ -s bin/ar ] || ln -s /usr/bin/ar bin/ar +export PATH=`pwd`/localbin:$PATH +[ -d localbin ] || mkdir localbin +[ -s localbin/tail ] || ln -s /usr/gnu/bin/tail localbin/tail +[ -s localbin/grep ] || ln -s /usr/gnu/bin/grep localbin/grep +[ -s localbin/ar ] || ln -s /usr/bin/ar localbin/ar export LDFLAGS="%_ldflags" @@ -399,18 +414,37 @@ export CONFIG_SHELL=/usr/bin/bash [ -L include/ffmpeg ] || ln -s /usr/include/libavcodec include/ffmpeg -perl -w -pi.bak3 -e "s,#\!\s*/bin/sh,#\!/usr/bin/bash," configure* +perl -w -pi.bak3 -e "s,#\!\s*/bin/sh,#\!/usr/bin/bash," configure configure.ac #let Qt modules in vlc have a good runtime search patch for libraries [ -d pkgconfig ] || mkdir pkgconfig #-L/usr/g++/lib -->> -L/usr/g++/lib -R/usr/g++/lib -sed -e '/^Libs:/s/-L\([^ ]*\)/-L\1 -R\1/' < /usr/g++/lib/pkgconfig/QtGui.pc > pkgconfig/QtGui.pc -sed -e '/^Libs:/s/-L\([^ ]*\)/-L\1 -R\1/' < /usr/g++/lib/pkgconfig/QtCore.pc > pkgconfig/QtCore.pc +gsed -e '/^Libs:/s/-L\([^ ]*\)/-L\1 -R\1/' < /usr/g++/lib/pkgconfig/QtGui.pc > pkgconfig/QtGui.pc +gsed -e '/^Libs:/s/-L\([^ ]*\)/-L\1 -R\1/' < /usr/g++/lib/pkgconfig/QtCore.pc > pkgconfig/QtCore.pc export PKG_CONFIG_PATH=`pwd`/pkgconfig:/usr/g++/lib/pkgconfig:/usr/lib/pkgconfig +#rework liveMedia location for Solaris/SFE +#/usr/include/liveMedia -> /usr/lib/live/liveMedia/include +perl -w -pi.bak_live555 -e 's?(/include)(/\w*)?/lib/live\2\1?g if /CPPFLAGS_live555=/;' configure configure.ac + # invalid options: --enable-ffmpeg \ #./configure --help | gegrep -i3 ffm prints only --enable-merge-ffmpeg merge FFmpeg-based plugins (default disabled) +%if %{solaris12} +echo "don't remove tdestroy test in configure.ac" +#at the very end, add -L/lib -R/lib to find new libc with tdestroy in it +# (avoid searching those dir first and find wrong gcc runtime lib) +export LDFLAGS="${LDFLAGS} -L/lib -R/lib -lc" +%else +#gsed -ibak_tdestroy -e 's?^#define HAVE_TDESTROY 1?/* #undef HAVE_TDESTROY */?' config.h +gsed -ibak_tdestroy_c_ac -e '/^AC_REPLACE_FUNCS.*tdestroy/ s? *tdestroy??' configure.ac +%endif +#ENDIF solaris12 + +echo "CFLAGS $CFLAGS" +echo "CXXLAGS $CXXFLAGS" +echo "CPPFLAGS $CPPFLAGS" +echo "LDFLAGS $LDFLAGS" ./configure --prefix=%{_prefix} \ --bindir=%{_bindir} \ --mandir=%{_mandir} \ @@ -465,6 +499,11 @@ --disable-libva \ $nlsopt +##TODO## re-enable lua! /usr/bin/luac: lua/playlist/appletrailers.lua:70: invalid escape sequence near '\.' +# --disable-dvb \ +# --enable-id3tag \ +# --enable-asademux \ +# --enable-snapshot \ # --with-gnu-ld \ #test with this off --disable-rpath \ @@ -477,20 +516,14 @@ ##TODO## investigate. Test if this goes away with new vlc version #sometimes it fails with a core dump at vlc-cache-gen, just try again. #does vlc-cache-gen work at all? -gmake -j$CPUS || echo "gmake 1. run failed, start over without vlc-cache-gen..." -mv bin/vlc-cache-gen bin/vlc-cache-gen.orig -touch bin/vlc-cache-gen -chmod a+rx bin/vlc-cache-gen -gmake +gmake am__v_CC_0= --debug=j AM_DEFAULT_VERBOSITY=1 -j$CPUS || echo "gmake 1. run failed, start over without vlc-cache-gen..." +gmake am__v_CC_0= --debug=j AM_DEFAULT_VERBOSITY=1 -j1 ##NOTE## If you run into compile problems and "vlc-cache-gen" core dumps, # then you *first* uninstall the old copy of vlc and re-try. %install rm -rf $RPM_BUILD_ROOT gmake install DESTDIR=$RPM_BUILD_ROOT -#Fix for disabled because core dumping vlc-cache-gen -cp -p bin/vlc-cache-gen.orig $RPM_BUILD_ROOT/%{_libdir}/vlc/vlc-cache-gen -#rm -f $RPM_BUILD_ROOT%{_libdir}/lib*a find $RPM_BUILD_ROOT%{_libdir}/ -name '*.la' -exec rm {} \; rm -f $RPM_BUILD_ROOT%{_libdir}/charset.alias @@ -585,6 +618,25 @@ %{_libdir}/pkgconfig/* %changelog +* Sun Jul 21 2013 - Thomas Wagner +- add (Build)Requires to %{pnm_buildrequires_SUNWgsed} +- force to SFEgcc-46 and SFEgccruntime-46 for the moment. With 4.7 running into errors. + set CC and CXX to use exactly gcc 4.6 +- place symlinks of tools ar, grep now in localbin/ inside builddir, set PATH +- fix include/lib-paths to liveMedia in *FLAGS and configure +- remove "-sse" from CFLAGS +- on non-S12 remove configure test for tdestroy as it detects it be present but is not +- make gmake display the full commandlines used for compile. I'm so sorry for the bigger log files. +- re-add -L/lib -R/lib to LDFLAGS to have libtool find "libc" with tdestroy (S12), + but add it at the very end of *FLAGS to not find unwanted gcc runtime libgcc_s.so libstdc++.so.6 in /usr/lib or /lib +- remove workaround for failed compile of vlc-cache-gen +- bump version to 2.0.7, new spec file copy including history +- add (Build)Requires SFEfaac(-devel) +* Thu Jul 11 2013 - Thomas Wagner +- change (Build)Requires to %{pnm_buildrequires_SUNWlua} +- set -DLUA_COMPAT_ALL=1 to fix configure/build detection of LUA +* Wed Jan 30 2013 - Thomas Wagner +- re-insert /usr/bin early in PATH * Mon Jan 28 2013 - Thomas Wagner - place selected gnu tools into local bin directory (e.g. gnu grep -q), replace hardcoded PATH=/usr/bin:$PATH with symlinking ar to local bin/ |