mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 00:31:13 +00:00
Allow building against an external FFMpeg install. Fixes: #363363
Original commit message from CVS: * Makefile.am: * configure.ac: * ext/ffmpeg/Makefile.am: * ext/ffmpeg/gstffmpeg.c: * ext/ffmpeg/gstffmpegdemux.c: * ext/libpostproc/Makefile.am: * ext/libpostproc/gstpostproc.c: Allow building against an external FFMpeg install. Fixes: #363363 Patch by: Josselin Mouette <joss at debian dot org> When built against an external install, the plugin description will say "system install" instead of "local snapshot"
This commit is contained in:
parent
2bb3e48e52
commit
1f2cd3de4b
8 changed files with 57 additions and 20 deletions
15
ChangeLog
15
ChangeLog
|
@ -1,3 +1,18 @@
|
||||||
|
2006-12-15 Jan Schmidt <thaytan@mad.scientist.com>
|
||||||
|
|
||||||
|
* Makefile.am:
|
||||||
|
* configure.ac:
|
||||||
|
* ext/ffmpeg/Makefile.am:
|
||||||
|
* ext/ffmpeg/gstffmpeg.c:
|
||||||
|
* ext/ffmpeg/gstffmpegdemux.c:
|
||||||
|
* ext/libpostproc/Makefile.am:
|
||||||
|
* ext/libpostproc/gstpostproc.c:
|
||||||
|
|
||||||
|
Allow building against an external FFMpeg install. Fixes: #363363
|
||||||
|
Patch by: Josselin Mouette <joss at debian dot org>
|
||||||
|
When built against an external install, the plugin description will
|
||||||
|
say "system install" instead of "local snapshot"
|
||||||
|
|
||||||
2006-12-14 Jan Schmidt <thaytan@mad.scientist.com>
|
2006-12-14 Jan Schmidt <thaytan@mad.scientist.com>
|
||||||
|
|
||||||
* configure.ac:
|
* configure.ac:
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc
|
DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc
|
||||||
|
|
||||||
SUBDIRS = gst-libs ext docs common tests
|
SUBDIRS = $(FFMPEG_SUBDIRS) ext docs common tests
|
||||||
|
|
||||||
EXTRA_DIST = \
|
EXTRA_DIST = \
|
||||||
gst-ffmpeg.spec depcomp \
|
gst-ffmpeg.spec depcomp \
|
||||||
|
|
29
configure.ac
29
configure.ac
|
@ -173,8 +173,37 @@ dnl *** configure external libs ***
|
||||||
|
|
||||||
AC_DEFINE_UNQUOTED(HAVE_FFMPEG_UNINSTALLED, 1,
|
AC_DEFINE_UNQUOTED(HAVE_FFMPEG_UNINSTALLED, 1,
|
||||||
[Defined if building against uninstalled FFmpeg source])
|
[Defined if building against uninstalled FFmpeg source])
|
||||||
|
|
||||||
|
AC_ARG_WITH(system-ffmpeg,
|
||||||
|
[AC_HELP_STRING([--with-system-ffmpeg], [use system FFmpeg libraries])])
|
||||||
|
|
||||||
|
if test "x$with_system_ffmpeg" = "xyes"; then
|
||||||
|
PKG_CHECK_MODULES(FFMPEG, libavutil libavcodec libavformat)
|
||||||
|
PKG_CHECK_MODULES(POSTPROC, libavcodec libpostproc)
|
||||||
|
saved_CPPFLAGS="$CPPFLAGS"
|
||||||
|
CPPFLAGS="$CPPFLAGS $FFMPEG_CFLAGS"
|
||||||
|
AC_CHECK_HEADERS([avi.h])
|
||||||
|
CPPFLAGS="$saved_CPPFLAGS"
|
||||||
|
AC_DEFINE([FFMPEG_SOURCE], ["system install"], [Describes where the FFmpeg libraries come from.])
|
||||||
|
else
|
||||||
|
FFMPEG_CFLAGS='-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavformat \
|
||||||
|
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavutil \
|
||||||
|
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavcodec'
|
||||||
|
FFMPEG_LIBS='$(top_builddir)/gst-libs/ext/ffmpeg/libavformat/libavformat.la'
|
||||||
|
POSTPROC_CFLAGS='-I $(top_srcdir)/gst-libs/ext/ffmpeg/libpostproc \
|
||||||
|
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavformat \
|
||||||
|
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavutil \
|
||||||
|
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavcodec'
|
||||||
|
POSTPROC_LIBS='$(top_builddir)/gst-libs/ext/ffmpeg/libavcodec/libavcodec.la'
|
||||||
|
FFMPEG_SUBDIRS=gst-libs
|
||||||
|
AC_DEFINE(HAVE_AVI_H)
|
||||||
|
AC_DEFINE([FFMPEG_SOURCE], ["local snapshot"], [Describes where the FFmpeg libraries come from.])
|
||||||
ac_configure_args="$ac_configure_args --disable-v4l --disable-audio-oss --disable-dv1394 --disable-vhook --disable-ffmpeg --disable-ffserver --disable-ffplay --disable-sdltest --enable-pp"
|
ac_configure_args="$ac_configure_args --disable-v4l --disable-audio-oss --disable-dv1394 --disable-vhook --disable-ffmpeg --disable-ffserver --disable-ffplay --disable-sdltest --enable-pp"
|
||||||
AC_CONFIG_SUBDIRS(gst-libs/ext/ffmpeg)
|
AC_CONFIG_SUBDIRS(gst-libs/ext/ffmpeg)
|
||||||
|
fi
|
||||||
|
AC_SUBST(FFMPEG_CFLAGS)
|
||||||
|
AC_SUBST(FFMPEG_LIBS)
|
||||||
|
AC_SUBST(FFMPEG_SUBDIRS)
|
||||||
|
|
||||||
AC_CONFIG_FILES(
|
AC_CONFIG_FILES(
|
||||||
Makefile
|
Makefile
|
||||||
|
|
|
@ -12,12 +12,8 @@ libgstffmpeg_la_SOURCES = gstffmpeg.c \
|
||||||
gstffmpegscale.c
|
gstffmpegscale.c
|
||||||
|
|
||||||
libgstffmpeg_la_CFLAGS = $(GST_CFLAGS) $(GST_PLUGINS_BASE_CFLAGS) \
|
libgstffmpeg_la_CFLAGS = $(GST_CFLAGS) $(GST_PLUGINS_BASE_CFLAGS) \
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavformat \
|
$(FFMPEG_CFLAGS)
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavutil \
|
libgstffmpeg_la_LIBADD = $(FFMPEG_LIBS) $(GST_BASE_LIBS)
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavcodec
|
|
||||||
libgstffmpeg_la_LIBADD = \
|
|
||||||
$(top_builddir)/gst-libs/ext/ffmpeg/libavformat/libavformat.la \
|
|
||||||
$(GST_BASE_LIBS)
|
|
||||||
libgstffmpeg_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
libgstffmpeg_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
||||||
|
|
||||||
noinst_HEADERS = \
|
noinst_HEADERS = \
|
||||||
|
|
|
@ -130,7 +130,7 @@ plugin_init (GstPlugin * plugin)
|
||||||
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
||||||
GST_VERSION_MINOR,
|
GST_VERSION_MINOR,
|
||||||
"ffmpeg",
|
"ffmpeg",
|
||||||
"All FFMPEG codecs",
|
"All FFMPEG codecs (" FFMPEG_SOURCE ")",
|
||||||
plugin_init,
|
plugin_init,
|
||||||
PACKAGE_VERSION, "LGPL", "FFMpeg", "http://ffmpeg.sourceforge.net/")
|
PACKAGE_VERSION, "LGPL", "FFMpeg", "http://ffmpeg.sourceforge.net/")
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,9 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#ifdef HAVE_FFMPEG_UNINSTALLED
|
#ifdef HAVE_FFMPEG_UNINSTALLED
|
||||||
#include <avformat.h>
|
#include <avformat.h>
|
||||||
|
#ifdef HAVE_AVI_H
|
||||||
#include <avi.h>
|
#include <avi.h>
|
||||||
|
#endif
|
||||||
#else
|
#else
|
||||||
#include <ffmpeg/avformat.h>
|
#include <ffmpeg/avformat.h>
|
||||||
#include <ffmpeg/avi.h>
|
#include <ffmpeg/avi.h>
|
||||||
|
|
|
@ -3,12 +3,9 @@ plugin_LTLIBRARIES = libgstpostproc.la
|
||||||
libgstpostproc_la_SOURCES = gstpostproc.c
|
libgstpostproc_la_SOURCES = gstpostproc.c
|
||||||
|
|
||||||
libgstpostproc_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS) $(LIBOIL_CFLAGS) \
|
libgstpostproc_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS) $(LIBOIL_CFLAGS) \
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg \
|
$(POSTPROC_CFLAGS)
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavformat \
|
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavutil \
|
|
||||||
-I $(top_srcdir)/gst-libs/ext/ffmpeg/libavcodec
|
|
||||||
libgstpostproc_la_LIBADD = -lgstvideo-@GST_MAJORMINOR@ \
|
libgstpostproc_la_LIBADD = -lgstvideo-@GST_MAJORMINOR@ \
|
||||||
$(top_builddir)/gst-libs/ext/ffmpeg/libavcodec/libavcodec.la \
|
$(POSTPROC_LIBS) \
|
||||||
$(GST_PLUGINS_BASE_LIBS) $(GST_BASE_LIBS) $(LIBOIL_LIBS)
|
$(GST_PLUGINS_BASE_LIBS) $(GST_BASE_LIBS) $(LIBOIL_LIBS)
|
||||||
|
|
||||||
libgstpostproc_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
libgstpostproc_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
||||||
|
|
|
@ -30,11 +30,9 @@
|
||||||
|
|
||||||
#ifdef HAVE_FFMPEG_UNINSTALLED
|
#ifdef HAVE_FFMPEG_UNINSTALLED
|
||||||
#include <avcodec.h>
|
#include <avcodec.h>
|
||||||
#include <version.h>
|
#include <postprocess.h>
|
||||||
#include <libpostproc/postprocess.h>
|
|
||||||
#else
|
#else
|
||||||
#include <ffmpeg/avcodec.h>
|
#include <ffmpeg/avcodec.h>
|
||||||
#include <ffmpeg/version.h>
|
|
||||||
#include <ffmpeg/libpostproc/postprocess.h>
|
#include <ffmpeg/libpostproc/postprocess.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -897,8 +895,8 @@ plugin_init (GstPlugin * plugin)
|
||||||
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
||||||
GST_VERSION_MINOR,
|
GST_VERSION_MINOR,
|
||||||
"postproc",
|
"postproc",
|
||||||
"postprocessing elements",
|
"postprocessing elements (" FFMPEG_SOURCE ")",
|
||||||
plugin_init,
|
plugin_init,
|
||||||
FFMPEG_VERSION, "GPL", "FFMpeg", "http://ffmpeg.sourceforge.net/")
|
PACKAGE_VERSION, "GPL", "FFMpeg", "http://ffmpeg.sourceforge.net/")
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue