Changeset View
Changeset View
Standalone View
Standalone View
multimedia/mplayer/files/patch-configure
--- configure.orig 2015-12-18 14:53:21 UTC | --- configure.orig 2016-11-14 23:29:59 UTC | ||||
+++ configure | +++ configure | ||||
@@ -646,7 +646,7 @@ armthumb=auto | @@ -649,7 +649,7 @@ armthumb=auto | ||||
_iwmmxt=auto | _iwmmxt=auto | ||||
_mtrr=auto | _mtrr=auto | ||||
_altivec=auto | _altivec=auto | ||||
-_install=install | -_install=install | ||||
+_install=@${BSD_INSTALL_PROGRAM} | +_install=@${BSD_INSTALL_PROGRAM} | ||||
_ranlib=ranlib | _ranlib=ranlib | ||||
_windres=windres | _windres=windres | ||||
_cc=cc | _cc=cc | ||||
@@ -988,7 +988,7 @@ for ac_option do | @@ -992,7 +992,7 @@ for ac_option do | ||||
ld_static='' | ld_static='' | ||||
;; | ;; | ||||
--enable-profile) | --enable-profile) | ||||
- _profile='-p' | - _profile='-p' | ||||
+ _profile='-pg' | + _profile='-pg' | ||||
;; | ;; | ||||
--disable-profile) | --disable-profile) | ||||
_profile= | _profile= | ||||
@@ -1459,7 +1459,6 @@ for ac_option do | @@ -1464,7 +1464,6 @@ for ac_option do | ||||
*) | *) | ||||
echo "Unknown parameter: $ac_option" | echo "Unknown parameter: $ac_option" | ||||
- exit 1 | - exit 1 | ||||
;; | ;; | ||||
esac | esac | ||||
@@ -1712,7 +1711,7 @@ if test -z "$_target" ; then | @@ -1502,40 +1501,6 @@ rm -f "$TMPLOG" | ||||
echo configuration: $configuration > "$TMPLOG" | |||||
echo >> "$TMPLOG" | |||||
- | |||||
-# local FFmpeg checkout handling | |||||
-if test -e ffmpeg/.svn ; then | |||||
- echo "You have an outdated FFmpeg SVN checkout in ffmpeg/, please (re)move or replace it" | |||||
- exit 1 | |||||
-fi | |||||
- | |||||
-FFBRANCH=master | |||||
-test -e FFBRANCH && FFBRANCH=$(cat FFMPEG_BRANCH) | |||||
- | |||||
-if test -e ffmpeg/mp_auto_pull ; then | |||||
- echo "Updating FFmpeg, (re)move ffmpeg/mp_auto_pull to disable" | |||||
- (cd ffmpeg && git checkout $FFBRANCH) | |||||
- if ! (cd ffmpeg && git pull --rebase --ff-only) ; then | |||||
- echo "git pull failed, (re)move ffmpeg/mp_auto_pull to disable pulling" | |||||
- exit 1 | |||||
- fi | |||||
-fi | |||||
- | |||||
-if test "$ffmpeg_a" != "no" && ! test -e ffmpeg ; then | |||||
- echo "No FFmpeg checkout, press enter to download one with git or CTRL+C to abort" | |||||
- read tmp | |||||
- if ! git clone -b $FFBRANCH --depth 1 git://source.ffmpeg.org/ffmpeg.git ffmpeg ; then | |||||
- rm -rf ffmpeg | |||||
- echo "Failed to get a FFmpeg checkout" | |||||
- echo "Please try again or put FFmpeg source code copy into ffmpeg/ manually." | |||||
- echo "Nightly snapshot: http://ffmpeg.org/releases/ffmpeg-snapshot.tar.bz2" | |||||
- echo "To use a github mirror via http (e.g. because a firewall blocks git):" | |||||
- echo "git clone --depth 1 https://github.com/FFmpeg/FFmpeg ffmpeg; touch ffmpeg/mp_auto_pull" | |||||
- exit 1 | |||||
- fi | |||||
- touch ffmpeg/mp_auto_pull | |||||
-fi | |||||
- | |||||
list_subparts() { | |||||
test ! -e ffmpeg/libav${3} && return 1 | |||||
pattern="s/^[^#]*${1}.*([^ ,]*, *\([^ ,)]*\).*/\1_${2}/p" | |||||
@@ -1732,7 +1697,7 @@ if test -z "$_target" ; then | |||||
case "$1" in | case "$1" in | ||||
x86_64|amd64|i[3-9]86*|i86pc|x86|x86pc|k5|k6|k6_2|k6_3|k6-2|k6-3|pentium*|athlon*|i586_i686|i586-i686) host_arch=i386 ;; | x86_64|amd64|i[3-9]86*|i86pc|x86|x86pc|k5|k6|k6_2|k6_3|k6-2|k6-3|pentium*|athlon*|i586_i686|i586-i686) host_arch=i386 ;; | ||||
ia64) host_arch=ia64 ;; | ia64) host_arch=ia64 ;; | ||||
- macppc|ppc*|Power*) host_arch=ppc ;; | - macppc|ppc*|Power*) host_arch=ppc ;; | ||||
+ macppc|powerpc|ppc*|Power*) host_arch=ppc ;; | + macppc|powerpc|ppc*|Power*) host_arch=ppc ;; | ||||
alpha) host_arch=alpha ;; | alpha) host_arch=alpha ;; | ||||
sun4*|sparc*) host_arch=sparc ;; | sun4*|sparc*) host_arch=sparc ;; | ||||
parisc*|hppa*|9000*) host_arch=hppa ;; | parisc*|hppa*|9000*) host_arch=hppa ;; | ||||
@@ -1835,7 +1834,11 @@ echocheck "working compiler" | @@ -1855,7 +1820,11 @@ echocheck "working compiler" | ||||
cflag_check "" || die "Compiler is not functioning correctly. Check your installation and custom CFLAGS $CFLAGS ." | cflag_check "" || die "Compiler is not functioning correctly. Check your installation and custom CFLAGS $CFLAGS ." | ||||
echo "yes" | echo "yes" | ||||
-cflag_check "-lm" && libm="-lm" | -cflag_check "-lm" && libm="-lm" | ||||
+if test -z "$_profile" ; then | +if test -z "$_profile" ; then | ||||
+ cflag_check "-lm" && libm="-lm" | + cflag_check "-lm" && libm="-lm" | ||||
+else | +else | ||||
+ cflag_check "-lm_p" && libm="-lm_p" | + cflag_check "-lm_p" && libm="-lm_p" | ||||
+fi | +fi | ||||
if test -z "$_target" ; then | if test -z "$_target" ; then | ||||
cat > $TMPC << EOF | cat > $TMPC << EOF | ||||
@@ -3194,6 +3197,13 @@ if arm ; then | @@ -3224,6 +3193,13 @@ if arm ; then | ||||
fi | fi | ||||
echores "$setend" | echores "$setend" | ||||
+ echocheck "ARM setend" | + echocheck "ARM setend" | ||||
+ if test $setend = "auto" ; then | + if test $setend = "auto" ; then | ||||
+ setend=no | + setend=no | ||||
+ inline_asm_check '"setend be"' && setend=yes | + inline_asm_check '"setend be"' && setend=yes | ||||
+ fi | + fi | ||||
+ echores "$setend" | + echores "$setend" | ||||
+ | + | ||||
echocheck "softfloat ABI" | echocheck "softfloat ABI" | ||||
softfloat=yes | softfloat=yes | ||||
cpp_condition_check '' 'defined(__ARM_PCS_VFP) || (!defined(__ARM_PCS) && !defined(__SOFTFP__))' && softfloat=no | cpp_condition_check '' 'defined(__ARM_PCS_VFP) || (!defined(__ARM_PCS) && !defined(__SOFTFP__))' && softfloat=no | ||||
@@ -3944,7 +3954,7 @@ echocheck "pthread" | @@ -3993,7 +3969,7 @@ echocheck "pthread" | ||||
if linux ; then | if linux ; then | ||||
THREAD_CFLAGS=-D_REENTRANT | THREAD_CFLAGS=-D_REENTRANT | ||||
elif freebsd || netbsd || openbsd || bsdos ; then | elif freebsd || netbsd || openbsd || bsdos ; then | ||||
- THREAD_CFLAGS=-D_THREAD_SAFE | - THREAD_CFLAGS=-D_THREAD_SAFE | ||||
+ THREAD_CFLAGS= | + THREAD_CFLAGS= | ||||
fi | fi | ||||
if test "$_pthreads" = auto ; then | if test "$_pthreads" = auto ; then | ||||
cat > $TMPC << EOF | cat > $TMPC << EOF | ||||
@@ -3954,7 +3964,7 @@ int main(void) { pthread_t tid; return p | @@ -4003,7 +3979,7 @@ int main(void) { pthread_t tid; return p | ||||
EOF | EOF | ||||
_pthreads=no | _pthreads=no | ||||
if ! hpux ; then | if ! hpux ; then | ||||
- for ld_tmp in "-lpthreadGC2" "" "-lpthread" "-pthread" ; do | - for ld_tmp in "-lpthreadGC2" "" "-lpthread" "-pthread" ; do | ||||
+ for ld_tmp in "-lpthread" "-pthread" ; do | + for ld_tmp in "-lpthread" "-pthread" ; do | ||||
# for crosscompilation, we cannot execute the program, be happy if we can link statically | # for crosscompilation, we cannot execute the program, be happy if we can link statically | ||||
cc_check $THREAD_CFLAGS $ld_tmp && (tmp_run || test "$ld_static") && ld_pthread="$ld_tmp" && _pthreads=yes && break | cc_check $THREAD_CFLAGS $ld_tmp && (tmp_run || test "$ld_static") && ld_pthread="$ld_tmp" && _pthreads=yes && break | ||||
done | done | ||||
@@ -4103,7 +4113,7 @@ int main(void) { | @@ -4152,7 +4128,7 @@ int main(void) { | ||||
} | } | ||||
EOF | EOF | ||||
_iconv=no | _iconv=no | ||||
- for ld_tmp in "" "-liconv" "-liconv $ld_dl" ; do | - for ld_tmp in "" "-liconv" "-liconv $ld_dl" ; do | ||||
+ for ld_tmp in "" "-L$_prefix/lib -liconv" "-L%%LOCALBASE%%/lib -liconv" "-liconv" "-liconv $ld_dl" ; do | + for ld_tmp in "" "-L$_prefix/lib -liconv" "-L%%LOCALBASE%%/lib -liconv" "-liconv" "-liconv $ld_dl" ; do | ||||
cc_check $ld_tmp && extra_ldflags="$extra_ldflags $ld_tmp" && | cc_check $ld_tmp && extra_ldflags="$extra_ldflags $ld_tmp" && | ||||
ld_iconv="$ld_tmp" && _iconv=yes && break | ld_iconv="$ld_tmp" && _iconv=yes && break | ||||
done | done | ||||
@@ -5505,15 +5515,6 @@ EOF | @@ -5565,15 +5541,6 @@ EOF | ||||
break | break | ||||
fi | fi | ||||
done | done | ||||
- if test "$_x11" = yes && cc_check -DGL_EGL_X11 -lEGL ; then | - if test "$_x11" = yes && cc_check -DGL_EGL_X11 -lEGL ; then | ||||
- _gl=yes | - _gl=yes | ||||
- _gl_egl_x11=yes | - _gl_egl_x11=yes | ||||
- libs_mplayer="$libs_mplayer -lEGL $ld_dl" | - libs_mplayer="$libs_mplayer -lEGL $ld_dl" | ||||
- elif cc_check -DGL_EGL_ANDROID -lEGL ; then | - elif cc_check -DGL_EGL_ANDROID -lEGL ; then | ||||
- _gl=yes | - _gl=yes | ||||
- _gl_egl_android=yes | - _gl_egl_android=yes | ||||
- libs_mplayer="$libs_mplayer -lEGL $ld_dl" | - libs_mplayer="$libs_mplayer -lEGL $ld_dl" | ||||
- fi | - fi | ||||
if win32 && cc_check -DGL_WIN32 -lopengl32 ; then | if win32 && cc_check -DGL_WIN32 -lopengl32 ; then | ||||
_gl=yes | _gl=yes | ||||
_gl_win32=yes | _gl_win32=yes | ||||
@@ -6077,7 +6078,7 @@ elif darwin ; then | @@ -6137,7 +6104,7 @@ elif darwin ; then | ||||
elif dragonfly ; then | elif dragonfly ; then | ||||
default_cdrom_device="/dev/cd0" | default_cdrom_device="/dev/cd0" | ||||
elif freebsd ; then | elif freebsd ; then | ||||
- default_cdrom_device="/dev/acd0" | - default_cdrom_device="/dev/acd0" | ||||
+ default_cdrom_device="/dev/cdrom" | + default_cdrom_device="/dev/cdrom" | ||||
elif openbsd ; then | elif openbsd ; then | ||||
default_cdrom_device="/dev/rcd0c" | default_cdrom_device="/dev/rcd0c" | ||||
elif sunos ; then | elif sunos ; then | ||||
@@ -6090,7 +6091,7 @@ else | @@ -6150,7 +6117,7 @@ else | ||||
default_cdrom_device="/dev/cdrom" | default_cdrom_device="/dev/cdrom" | ||||
fi | fi | ||||
-if win32 || os2 || dragonfly || freebsd || openbsd || sunos || amigaos ; then | -if win32 || os2 || dragonfly || freebsd || openbsd || sunos || amigaos ; then | ||||
+if win32 || os2 || dragonfly || openbsd || sunos || amigaos ; then | +if win32 || os2 || dragonfly || openbsd || sunos || amigaos ; then | ||||
default_dvd_device=$default_cdrom_device | default_dvd_device=$default_cdrom_device | ||||
elif darwin ; then | elif darwin ; then | ||||
default_dvd_device="/dev/rdiskN" | default_dvd_device="/dev/rdiskN" | ||||
@@ -6607,7 +6608,7 @@ echores "$_speex" | @@ -6667,7 +6634,7 @@ echores "$_speex" | ||||
echocheck "libgsm" | echocheck "libgsm" | ||||
if test "$_libgsm" = auto ; then | if test "$_libgsm" = auto ; then | ||||
_libgsm=no | _libgsm=no | ||||
- statement_check gsm/gsm.h 'gsm_create()' -lgsm && _libgsm=yes | - statement_check gsm/gsm.h 'gsm_create()' -lgsm && _libgsm=yes | ||||
+ statement_check gsm.h 'gsm_create()' -lgsm && _libgsm=yes | + statement_check gsm.h 'gsm_create()' -lgsm && _libgsm=yes | ||||
fi | fi | ||||
if test "$_libgsm" = yes ; then | if test "$_libgsm" = yes ; then | ||||
def_libgsm='#define CONFIG_LIBGSM 1' | def_libgsm='#define CONFIG_LIBGSM 1' | ||||
@@ -7092,6 +7093,16 @@ if test "$_librtmp" = yes && test "$netw | @@ -7152,6 +7119,16 @@ if test "$_librtmp" = yes && test "$netw | ||||
nolibrtmp=no | nolibrtmp=no | ||||
def_librtmp='#define CONFIG_LIBRTMP 1' | def_librtmp='#define CONFIG_LIBRTMP 1' | ||||
inputmodules="librtmp $inputmodules" | inputmodules="librtmp $inputmodules" | ||||
+ | + | ||||
+ if $_pkg_config --exists librtmp; then | + if $_pkg_config --exists librtmp; then | ||||
+ _inc_tmp=$($_pkg_config --cflags librtmp) | + _inc_tmp=$($_pkg_config --cflags librtmp) | ||||
+ _ld_tmp=$($_pkg_config --libs librtmp) | + _ld_tmp=$($_pkg_config --libs librtmp) | ||||
+ else | + else | ||||
+ _inc_tmp="-I${LOCALBASE}/include" | + _inc_tmp="-I${LOCALBASE}/include" | ||||
+ _ld_tmp="-L${LOCALBASE}/lib -lrtmp -lz -lssl -lcrypto" | + _ld_tmp="-L${LOCALBASE}/lib -lrtmp -lz -lssl -lcrypto" | ||||
+ fi | + fi | ||||
+ extra_ldflags="$extra_ldflags $_ld_tmp" | + extra_ldflags="$extra_ldflags $_ld_tmp" | ||||
+ extra_cflags="$extra_cflags $_inc_tmp" | + extra_cflags="$extra_cflags $_inc_tmp" | ||||
else | else | ||||
nolibrtmp=yes | nolibrtmp=yes | ||||
_librtmp=no | _librtmp=no | ||||
@@ -7493,7 +7504,7 @@ echores "$_mp3lame" | @@ -7553,7 +7530,7 @@ echores "$_mp3lame" | ||||
echocheck "mencoder" | echocheck "mencoder" | ||||
if test "$_mencoder" = no ; then | if test "$_mencoder" = no ; then | ||||
# mpeg1video for vf_lavc, snow for vf_uspp / vf_mcdeint, | # mpeg1video for vf_lavc, snow for vf_uspp / vf_mcdeint, | ||||
- libavencoders="$mplayer_encoders MPEG1VIDEO_ENCODER SNOW_ENCODER" | - libavencoders="$mplayer_encoders MPEG1VIDEO_ENCODER SNOW_ENCODER" | ||||
+ libavencoders="$mplayer_encoders MPEG1VIDEO_ENCODER H263_ENCODER SNOW_ENCODER" | + libavencoders="$mplayer_encoders MPEG1VIDEO_ENCODER H263_ENCODER SNOW_ENCODER" | ||||
fi | fi | ||||
echores "$_mencoder" | echores "$_mencoder" | ||||
@@ -8094,7 +8105,7 @@ libs_mplayer=$ld_tmp | @@ -8159,7 +8136,7 @@ libs_mplayer=$ld_tmp | ||||
############################################################################# | ############################################################################# | ||||
-CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE" | -CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE" | ||||
+CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" | +CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" | ||||
CXXFLAGS=" $CFLAGS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS" | CXXFLAGS=" $CFLAGS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS" | ||||