[Ffmpeg-devel] time for a release?
Alexander Strasser
eclipse7
Sat Jan 28 01:23:02 CET 2006
Hi,
Diego Biurrun wrote:
> On Sat, Dec 31, 2005 at 01:05:39PM +0100, Diego Biurrun wrote:
> > On Mon, Dec 12, 2005 at 01:54:13PM +0100, Alexander Strasser wrote:
> > >
> > > Michel Bardiaux wrote:
> > > > The shared-libs MingW build with VC++ compatibility produces DLLs merged
> > > > together (ie, avutil is in avcodec, and avcodec+avutil are in avformat).
> > >
> > > Yes, this should be corrected before a release. I am working on it.
> >
> > How is that coming along?
>
> ... ping ...
Here's my next try at this problem.
Please test on all platforms and report results.
Alex (beastd)
-------------- next part --------------
Index: configure
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/configure,v
retrieving revision 1.239
diff -u -r1.239 configure
--- configure 24 Jan 2006 19:57:41 -0000 1.239
+++ configure 28 Jan 2006 00:15:21 -0000
@@ -31,7 +31,10 @@
echo " --enable-a52bin open liba52.so.0 at runtime [default=no]"
echo " --enable-dts enable GPLed DTS support [default=no]"
echo " --enable-pp enable GPLed postprocessing support [default=no]"
+echo " --enable-static build static libraries [default=yes]"
+echo " --disable-static do not build static libraries [default=no]"
echo " --enable-shared build shared libraries [default=no]"
+echo " --disable-shared do not build shared libraries [default=yes]"
echo " --enable-amr_nb enable amr_nb float audio codec"
echo " --enable-amr_nb-fixed use fixed point for amr-nb codec"
echo " --enable-amr_wb enable amr_wb float audio codec"
@@ -206,6 +209,7 @@
mingwce="no"
cygwin="no"
os2="no"
+lstatic="yes"
lshared="no"
optimize="yes"
debug="yes"
@@ -549,8 +553,14 @@
;;
--enable-mingwce) mingwce="yes"
;;
+ --enable-static) lstatic="yes"
+ ;;
+ --disable-static) lstatic="no"
+ ;;
--enable-shared) lshared="yes"
;;
+ --disable-shared) lshared="no"
+ ;;
--disable-debug) debug="no"
;;
--disable-opts) optimize="no"
@@ -607,6 +617,17 @@
esac
done
+# we need to build at least one type of libs
+if test "$lstatic" = "no" && test "$lshared" = "no" ; then
+ cat <<EOF
+At least one type of libs must be build.
+ Specify --enable-static to build the static libs or --enable-shared to build
+the shared libs too. For only building the shared libs specify --disable-static
+in addition to --enable-shared.
+EOF
+ exit 1;
+fi
+
if test "$theora" = "yes" ; then
if test "$libogg" = "no"; then
echo "libogg must be enabled to enable Theora."
@@ -869,6 +890,15 @@
fi
if test "$mingw32" = "yes" -o "$mingwce" = "yes"; then
+ if test "$lshared" = "yes" && test "$lstatic" = "yes" ; then
+ cat <<EOF
+You can only build one type of libs at once on MinGW.
+ Specify --disable-static --enable-shared to build
+the shared libraries only. To build only the static
+libs you don't need to pass additional options.
+EOF
+ exit 1
+ fi
v4l="no"
bktr="no"
audio_oss="no"
@@ -1296,6 +1326,7 @@
echo "debug symbols $debug"
echo "strip symbols $dostrip"
echo "optimize $optimize"
+echo "static $lstatic"
echo "shared $lshared"
echo "video hooking $vhook"
echo "SDL support $sdl"
@@ -1364,7 +1395,6 @@
echo "BUILDSUF=$BUILDSUF" >> config.mak
echo "LIBPREF=$LIBPREF" >> config.mak
echo "LIBSUF=\${BUILDSUF}$LIBSUF" >> config.mak
-echo "LIB=$LIB" >> config.mak
echo "SLIBPREF=$SLIBPREF" >> config.mak
echo "SLIBSUF=\${BUILDSUF}$SLIBSUF" >> config.mak
echo "EXESUF=\${BUILDSUF}$EXESUF" >> config.mak
@@ -1507,7 +1537,11 @@
+if test "$lstatic" = "yes" ; then
+ echo "LIB=$LIB" >> config.mak
+fi
if test "$lshared" = "yes" ; then
+ echo "#define BUILD_SHARED_AV 1" >> $TMPH
echo "BUILD_SHARED=yes" >> config.mak
echo "PIC=-fPIC -DPIC" >> config.mak
echo "SPPMAJOR=${lavc_version%%.*}" >> config.mak
Index: libavcodec/Makefile
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/Makefile,v
retrieving revision 1.229
diff -u -r1.229 Makefile
--- libavcodec/Makefile 26 Jan 2006 23:42:28 -0000 1.229
+++ libavcodec/Makefile 28 Jan 2006 00:15:21 -0000
@@ -422,7 +422,7 @@
$(MAKE) -C libpostproc
endif
ifeq ($(CONFIG_WIN32),yes)
- $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def),--out-implib,lib$(SLIBNAME:$(SLIBSUF)=.dll.a) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
-lib /machine:i386 /def:$(@:.dll=.def)
else
$(CC) $(SHFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
@@ -446,6 +446,7 @@
clean: $(CLEANAMR)
rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll \
+ *.dll.a *.def *.exp \
i386/*.o i386/*~ \
armv4l/*.o armv4l/*~ \
mlib/*.o mlib/*~ \
Index: libavformat/Makefile
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavformat/Makefile,v
retrieving revision 1.111
diff -u -r1.111 Makefile
--- libavformat/Makefile 26 Jan 2006 23:42:29 -0000 1.111
+++ libavformat/Makefile 28 Jan 2006 00:15:22 -0000
@@ -107,7 +107,7 @@
$(SLIBNAME): $(OBJS)
ifeq ($(CONFIG_WIN32),yes)
- $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(PPOBJS) $(AVCLIBS) $(EXTRALIBS)
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def),--out-implib,lib$(SLIBNAME:$(SLIBSUF)=.dll.a) -o $@ $(OBJS) $(PPOBJS) $(AVCLIBS) $(EXTRALIBS)
-lib /machine:i386 /def:$(@:.dll=.def)
else
$(CC) $(SHFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(PPOBJS) $(AVCLIBS) $(EXTRALIBS)
@@ -154,7 +154,8 @@
g++ $(subst -Wall,,$(CFLAGS)) -c -o $@ $<
clean:
- rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll
+ rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll \
+ *.lib *.def *.dll.a *.exp
distclean: clean
rm -f .depend
Index: libavutil/Makefile
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavutil/Makefile,v
retrieving revision 1.11
diff -u -r1.11 Makefile
--- libavutil/Makefile 26 Jan 2006 23:42:29 -0000 1.11
+++ libavutil/Makefile 28 Jan 2006 00:15:22 -0000
@@ -6,7 +6,7 @@
VPATH=$(SRC_PATH)/libavutil
# NOTE: -I.. is needed to include config.h
-CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE
+CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -DBUILD_AVUTIL -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE
OBJS= mathematics.o \
integer.o \
@@ -35,7 +35,7 @@
$(SLIBNAME): $(OBJS)
ifeq ($(CONFIG_WIN32),yes)
- $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def),--out-implib,lib$(SLIBNAME:$(SLIBSUF)=.dll.a) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
-lib /machine:i386 /def:$(@:.dll=.def)
else
$(CC) $(SHFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
@@ -50,7 +50,8 @@
dep: depend
clean:
- rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll
+ rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll \
+ *.lib *.def *.dll.a *.exp
distclean: clean
rm -f .depend
Index: libavutil/common.h
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavutil/common.h,v
retrieving revision 1.160
diff -u -r1.160 common.h
--- libavutil/common.h 22 Jan 2006 18:34:17 -0000 1.160
+++ libavutil/common.h 28 Jan 2006 00:15:22 -0000
@@ -247,6 +247,13 @@
#ifdef HAVE_AV_CONFIG_H
+#if defined(__MINGW32__) && !defined(BUILD_AVUTIL) && defined(BUILD_SHARED_AV)
+# define FF_IMPORT_ATTR __declspec(dllimport)
+#else
+# define FF_IMPORT_ATTR
+#endif
+
+
# include "bswap.h"
// Use rip-relative addressing if compiling PIC code on x86-64.
@@ -345,7 +352,7 @@
#endif
/* misc math functions */
-extern const uint8_t ff_log2_tab[256];
+extern FF_IMPORT_ATTR const uint8_t ff_log2_tab[256];
static inline int av_log2(unsigned int v)
{
@@ -423,7 +430,7 @@
}
/* math */
-extern const uint8_t ff_sqrt_tab[128];
+extern FF_IMPORT_ATTR const uint8_t ff_sqrt_tab[128];
int64_t ff_gcd(int64_t a, int64_t b);
More information about the ffmpeg-devel
mailing list