summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorLuca Barbato <lu_zero@gentoo.org>2005-12-10 17:14:24 +0000
committerDiego Biurrun <diego@biurrun.de>2005-12-10 17:14:24 +0000
commit5a872801d5e5e287525adfd33bcefa94b185988e (patch)
tree3c1a3cbceae2984ad989ed86c2dfb2deb35f09ed /configure
parent64428d02d1005e911a95476d25d514ffcf41f4d3 (diff)
SONAME support for shared libs
patch by Luca Barbato < .. lu_zero .. @@ .. gentoo .. . .. org .. > Originally committed as revision 4730 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure23
1 files changed, 16 insertions, 7 deletions
diff --git a/configure b/configure
index 0fd14d9de6..a0acc8de3c 100755
--- a/configure
+++ b/configure
@@ -215,7 +215,7 @@ vhook="default"
dlfcn="no"
dlopen="no"
mpegaudio_hp="yes"
-SHFLAGS=-shared
+SHFLAGS='-shared -Wl,-soname,$@.$(LIBVERSION)'
netserver="no"
need_inet_aton="no"
ffserver="yes"
@@ -1447,11 +1447,24 @@ if test "$vhook" = "yes" ; then
echo "BUILD_VHOOK=yes" >> config.mak
echo "#define HAVE_VHOOK 1" >> $TMPH
fi
+
+lavc_version=`grep '#define LIBAVCODEC_VERSION ' "$source_path/libavcodec/avcodec.h" | sed 's/[^0-9\.]//g'`
+lavf_version=`grep '#define LIBAVFORMAT_VERSION ' "$source_path/libavformat/avformat.h" | sed 's/[^0-9\.]//g'`
+lavu_version=`grep '#define LIBAVUTIL_VERSION ' "$source_path/libavutil/avutil.h" | sed 's/[^0-9\.]//g'`
+
+
+
if test "$lshared" = "yes" ; then
echo "BUILD_SHARED=yes" >> config.mak
echo "PIC=-fPIC -DPIC" >> config.mak
- echo "SPPMAJOR=0" >> config.mak
- echo "SPPVERSION=0.0.1" >> config.mak
+ echo "SPPMAJOR=${lavc_version/.*/}" >> config.mak
+ echo "SPPVERSION=$lavc_version" >> config.mak
+ echo "LAVCMAJOR=${lavc_version/.*/}" >> config.mak
+ echo "LAVCVERSION=$lavc_version" >> config.mak
+ echo "LAVFMAJOR=${lavf_version/.*/}" >> config.mak
+ echo "LAVFVERSION=$lavf_version" >> config.mak
+ echo "LAVUMAJOR=${lavu_version/.*/}" >> config.mak
+ echo "LAVUVERSION=$lavu_version" >> config.mak
fi
echo "EXTRALIBS=$extralibs" >> config.mak
version=`grep '#define FFMPEG_VERSION ' "$source_path/libavcodec/avcodec.h" |
@@ -1789,10 +1802,6 @@ rm -f $TMPO $TMPC $TMPE $TMPS $TMPH
# build pkg-config files libav*.pc and libpostproc.pc
-lavc_version=`grep '#define LIBAVCODEC_VERSION ' "$source_path/libavcodec/avcodec.h" | sed 's/[^0-9\.]//g'`
-lavf_version=`grep '#define LIBAVFORMAT_VERSION ' "$source_path/libavformat/avformat.h" | sed 's/[^0-9\.]//g'`
-lavu_version=`grep '#define LIBAVUTIL_VERSION ' "$source_path/libavutil/avutil.h" | sed 's/[^0-9\.]//g'`
-
# libavutil.pc
cat <<EOF >libavutil.pc
prefix=$prefix