[SCM] libav/experimental: More changes to make things compile on more platforms

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 15:34:26 UTC 2013


The following commit has been merged in the experimental branch:
commit 4baca0690f827be32cb17ac57c44c89e63a6b516
Author: Philip Gladstone <philipjsg at users.sourceforge.net>
Date:   Wed Nov 27 02:45:14 2002 +0000

    More changes to make things compile on more platforms
    
    Originally committed as revision 1287 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/Makefile b/Makefile
index db78217..afa613c 100644
--- a/Makefile
+++ b/Makefile
@@ -7,13 +7,7 @@ include config.mak
 VPATH=$(SRC_PATH)
 
 CFLAGS= $(OPTFLAGS) -Wall -g -I. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -I$(SRC_PATH)/libavformat -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE
-ifeq ($(CONFIG_DARWIN),yes)
-LDFLAGS+= -g -d
-FFSLDFLAGS= -Wl,-bind_at_load
-else
-LDFLAGS+= -g -Wl,--warn-common
-FFSLDFLAGS= -Wl,-E
-endif
+LDFLAGS+= -g 
 
 ifeq ($(TARGET_GPROF),yes)
 CFLAGS+=-p
@@ -90,7 +84,7 @@ install-vhook: $(prefix)/lib/vhook
 	$(MAKE) -C vhook install INSTDIR=$(prefix)/lib/vhook
 
 $(prefix)/lib/vhook:
-	mkdir $@
+	install -d $@
 
 installlib:
 	$(MAKE) -C libavcodec installlib
diff --git a/configure b/configure
index cf38fb7..e5a95a2 100755
--- a/configure
+++ b/configure
@@ -68,6 +68,9 @@ vhook="no"
 mpegaudio_hp="yes"
 SHFLAGS=-shared
 netserver="no"
+need_inet_aton="no"
+LDFLAGS=-Wl,--warn-common
+FFSLDFLAGS=-Wl,-E
 
 # OS specific
 targetos=`uname -s`
@@ -98,13 +101,23 @@ if (echo $BEINCLUDES|grep 'headers/be/bone' >/dev/null); then
 extralibs="-lbind -lsocket"
 else
 netserver="yes"
+need_inet_aton="yes"
 extralibs="-lnet"
 fi ;;
+SunOS)
+v4l="no"
+audio_oss="no"
+make="gmake"
+LDFLAGS=""
+FFSLDFLAGS=""
+need_inet_aton="yes"
+extralibs="$extralibs -lsocket -lnsl"
+;;
 FreeBSD)
 v4l="no"
 audio_oss="yes"
 make="gmake"
-LDFLAGS="-export-dynamic"
+LDFLAGS="$LDFLAGS -export-dynamic"
 ;;
 BSD/OS)
 v4l="no"
@@ -116,11 +129,21 @@ Darwin)
 cc="cc"
 v4l="no"
 audio_oss="no"
-CFLAGS="-no-cpp-precomp -pipe -O3 -fomit-frame-pointer -mdynamic-no-pic"
 SHFLAGS="-dynamiclib"
 extralibs=""
 darwin="yes"
 strip="strip -x"
+LDFLAGS="$LDFLAGS -d"
+FFSLDFLAGS=-Wl,-bind_at_load
+gcc_version="$($cc -v 2>&1 | grep version | cut -d ' ' -f4-)"
+case "$gcc_version" in
+*2.95*) 
+CFLAGS="-no-cpp-precomp -pipe -O3 -fomit-frame-pointer"
+;;
+*) 
+CFLAGS="-no-cpp-precomp -pipe -O3 -fomit-frame-pointer -mdynamic-no-pic"
+;;
+esac
 ;;
 CYGWIN*)
 v4l="no"
@@ -133,7 +156,7 @@ echo "Missing inttypes.h, please copy cygwin_inttypes.h to" \
      "/usr/include/inttypes.h !!!"
 ;;
 Linux)
-LDFLAGS=-rdynamic
+LDFLAGS="$LDFLAGS -rdynamic"
 ;;
 *) ;;
 esac
@@ -487,6 +510,7 @@ echo "RANLIB=$ranlib" >> config.mak
 echo "STRIP=$strip" >> config.mak
 echo "OPTFLAGS=$CFLAGS" >> config.mak
 echo "LDFLAGS=$LDFLAGS" >> config.mak
+echo "FFSLDFLAGS=$FFSLDFLAGS" >> config.mak
 echo "SHFLAGS=$SHFLAGS" >> config.mak
 if test "$cpu" = "x86" ; then
   echo "TARGET_ARCH_X86=yes" >> config.mak
@@ -642,6 +666,10 @@ if test "$netserver" = "yes" ; then
   echo "CONFIG_BEOS_NETSERVER=yes" >> config.mak
 fi
 
+if test "$need_inet_aton" = "yes" ; then
+  echo "NEED_INET_ATON=yes" >> config.mak
+fi
+
 if test "$simpleidct" = "yes" ; then
   echo "#define SIMPLE_IDCT 1" >> $TMPH
 fi
diff --git a/libavformat/Makefile b/libavformat/Makefile
index 1051aa6..0ee4f09 100644
--- a/libavformat/Makefile
+++ b/libavformat/Makefile
@@ -35,7 +35,7 @@ endif
 ifeq ($(CONFIG_NETWORK),yes)
 OBJS+= udp.o tcp.o http.o rtsp.o rtp.o rtpproto.o
 # BeOS network stuff
-ifeq ($(CONFIG_BEOS_NETSERVER),yes)
+ifeq ($(NEED_INET_ATON),yes)
 OBJS+= barpainet.o
 endif
 endif

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list