mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2025-02-26 08:22:31 +00:00
Put lib/lib{ebml,matroska} first in include/library paths during compilation if internal libs are to be used
This commit is contained in:
parent
a9a4bf9d35
commit
868edce381
@ -1,3 +1,11 @@
|
||||
2011-02-06 Moritz Bunkus <moritz@bunkus.org>
|
||||
|
||||
* build system: Fixed compilation if configure choses the internal
|
||||
versions of libebml and libmatroska while older versions are still
|
||||
installed in a location named with "-I..." or "-L..." in
|
||||
CFLAGS/CXXFLAGS/LDFLAGS or with configure's
|
||||
"--with-extra-includes" and "--with-extra-libs" options.
|
||||
|
||||
2011-01-31 Moritz Bunkus <moritz@bunkus.org>
|
||||
|
||||
* Released v4.5.0.
|
||||
|
4
Rakefile
4
Rakefile
@ -78,13 +78,13 @@ def setup_globals
|
||||
|
||||
$build_tools ||= c?(:TOOLS)
|
||||
|
||||
cflags_common = "-Wall -Wno-comment #{c(:OPTIMIZATION_CFLAGS)} -D_FILE_OFFSET_BITS=64 #{c(:EXTRA_CFLAGS)} #{c(:DEBUG_CFLAGS)} #{c(:PROFILING_CFLAGS)} #{c(:MATROSKA_CFLAGS)} #{c(:EBML_CFLAGS)} #{c(:USER_CPPFLAGS)} -DPACKAGE=\\\"#{c(:PACKAGE)}\\\" -DVERSION=\\\"#{c(:VERSION)}\\\" -DMTX_LOCALE_DIR=\\\"#{c(:localedir)}\\\" -DMTX_PKG_DATA_DIR=\\\"#{c(:pkgdatadir)}\\\" -DMTX_DOC_DIR=\\\"#{c(:docdir)}\\\""
|
||||
cflags_common = "-Wall -Wno-comment #{c(:OPTIMIZATION_CFLAGS)} -D_FILE_OFFSET_BITS=64 #{c(:MATROSKA_CFLAGS)} #{c(:EBML_CFLAGS)} #{c(:EXTRA_CFLAGS)} #{c(:DEBUG_CFLAGS)} #{c(:PROFILING_CFLAGS)} #{c(:USER_CPPFLAGS)} -DPACKAGE=\\\"#{c(:PACKAGE)}\\\" -DVERSION=\\\"#{c(:VERSION)}\\\" -DMTX_LOCALE_DIR=\\\"#{c(:localedir)}\\\" -DMTX_PKG_DATA_DIR=\\\"#{c(:pkgdatadir)}\\\" -DMTX_DOC_DIR=\\\"#{c(:docdir)}\\\""
|
||||
ldflags_extra = c?(:MINGW) ? '' : "-Wl,--enable-auto-import"
|
||||
$flags = {
|
||||
:cflags => "#{cflags_common} #{c(:USER_CFLAGS)}",
|
||||
:cxxflags => "#{cflags_common} #{c(:WXWIDGETS_CFLAGS)} #{c(:QT_CFLAGS)} #{c(:BOOST_CPPFLAGS)} #{c(:CURL_CFLAGS)} #{c(:USER_CXXFLAGS)}",
|
||||
:cppflags => "#{c(:USER_CPPFLAGS)}",
|
||||
:ldflags => "#{c(:EXTRA_LDFLAGS)} #{c(:PROFILING_LIBS)} #{c(:USER_LDFLAGS)} #{c(:LDFLAGS_RPATHS)} #{c(:BOOST_LDFLAGS)}",
|
||||
:ldflags => "#{c(:EBML_LDFLAGS)} #{c(:MATROSKA_LDFLAGS)} #{c(:EXTRA_LDFLAGS)} #{c(:PROFILING_LIBS)} #{c(:USER_LDFLAGS)} #{c(:LDFLAGS_RPATHS)} #{c(:BOOST_LDFLAGS)}",
|
||||
}
|
||||
end
|
||||
|
||||
|
11
ac/ebml.m4
11
ac/ebml.m4
@ -1,5 +1,5 @@
|
||||
dnl
|
||||
dnl Test for libebml, and define EBML_CFLAGS and EBML_LIBS
|
||||
dnl Test for libebml, and define EBML_CFLAGS, EBML_LDFLAGS and EBML_LIBS
|
||||
dnl
|
||||
ebml_ver_req_major=1
|
||||
ebml_ver_req_minor=2
|
||||
@ -29,7 +29,8 @@ using namespace libebml;
|
||||
|
||||
if test "${ac_cv_ebml_found}" = "no" ; then
|
||||
EBML_CFLAGS="-I/usr/local/include"
|
||||
EBML_LIBS="-L/usr/local/lib $EBML_LIBS"
|
||||
EBML_LDFLAGS="-L/usr/local/lib"
|
||||
EBML_LIBS="$EBML_LIBS"
|
||||
CXXFLAGS="-I/usr/local/include $CXXFLAGS"
|
||||
LIBS="-L/usr/local/lib $LIBS"
|
||||
AC_TRY_COMPILE([
|
||||
@ -58,7 +59,8 @@ using namespace libebml;
|
||||
|
||||
if test x"${ac_cv_ebml_found}" = "xinternal" ; then
|
||||
EBML_CFLAGS="-Ilib/libebml"
|
||||
EBML_LIBS="-Llib/libebml/src -lebml"
|
||||
EBML_LDFLAGS="-Llib/libebml/src"
|
||||
EBML_LIBS="-lebml"
|
||||
|
||||
else
|
||||
dnl
|
||||
@ -73,7 +75,7 @@ dnl
|
||||
ac_save_CXXFLAGS="$CXXFLAGS"
|
||||
ac_save_LIBS="$LIBS"
|
||||
CXXFLAGS="$CXXFLAGS $EBML_CFLAGS"
|
||||
LIBS="$LIBS $EBML_LIBS"
|
||||
LIBS="$LIBS $EBML_LDFLAGS $EBML_LIBS"
|
||||
AC_TRY_LINK([
|
||||
#include <ebml/EbmlVersion.h>
|
||||
#include <ebml/EbmlDummy.h>
|
||||
@ -113,4 +115,5 @@ using namespace libebml;
|
||||
fi
|
||||
|
||||
AC_SUBST(EBML_CFLAGS)
|
||||
AC_SUBST(EBML_LDFLAGS)
|
||||
AC_SUBST(EBML_LIBS)
|
||||
|
@ -1,5 +1,5 @@
|
||||
dnl
|
||||
dnl Test for libmatroska, and define MATROSKA_CFLAGS and MATROSKA_LIBS
|
||||
dnl Test for libmatroska, and define MATROSKA_CFLAGS, MATROSKA_LDFLAGS and MATROSKA_LIBS
|
||||
dnl
|
||||
kax_ver_req_major=1
|
||||
kax_ver_req_minor=1
|
||||
@ -34,7 +34,8 @@ using namespace libmatroska;
|
||||
|
||||
if test x"${ac_cv_matroska_found}" != "xyes" ; then
|
||||
MATROSKA_CFLAGS="-I/usr/local/include"
|
||||
MATROSKA_LIBS="-L/usr/local/lib $MATROSKA_LIBS"
|
||||
MATROSKA_LDFLAGS="-L/usr/local/lib"
|
||||
MATROSKA_LIBS="$MATROSKA_LIBS"
|
||||
CXXFLAGS="-I/usr/local/include $CXXFLAGS"
|
||||
LIBS="-L/usr/local/lib $LIBS"
|
||||
AC_TRY_COMPILE([
|
||||
@ -67,7 +68,8 @@ using namespace libmatroska;
|
||||
EBML_CFLAGS="-Ilib/libebml"
|
||||
EBML_LIBS="-Llib/libebml/src -lebml"
|
||||
MATROSKA_CFLAGS="-Ilib/libmatroska"
|
||||
MATROSKA_LIBS="-Llib/libmatroska/src -lmatroska"
|
||||
MATROSKA_LDFLAGS="-Llib/libmatroska/src"
|
||||
MATROSKA_LIBS="-lmatroska"
|
||||
EBML_MATROSKA_INTERNAL=yes
|
||||
|
||||
else
|
||||
@ -80,7 +82,7 @@ using namespace libmatroska;
|
||||
ac_save_CXXFLAGS="$CXXFLAGS"
|
||||
ac_save_LIBS="$LIBS"
|
||||
CXXFLAGS="$CXXFLAGS $EBML_CFLAGS $MATROSKA_CFLAGS"
|
||||
LIBS="$LIBS $MATROSKA_LIBS $EBML_LIBS"
|
||||
LIBS="$LIBS $MATROSKA_LDFLAGS $MATROSKA_LIBS $EBML_LIBS"
|
||||
AC_TRY_LINK([
|
||||
#include <matroska/KaxVersion.h>
|
||||
#include <matroska/KaxSegment.h>
|
||||
@ -124,5 +126,6 @@ using namespace libmatroska;
|
||||
fi
|
||||
|
||||
AC_SUBST(MATROSKA_CFLAGS)
|
||||
AC_SUBST(MATROSKA_LDFLAGS)
|
||||
AC_SUBST(MATROSKA_LIBS)
|
||||
AC_SUBST(EBML_MATROSKA_INTERNAL)
|
||||
|
@ -74,6 +74,7 @@ DEBUG_CFLAGS = @DEBUG_CFLAGS@
|
||||
DOCBOOK_MANPAGES_STYLESHEET = @DOCBOOK_MANPAGES_STYLESHEET@
|
||||
DOCBOOK_ROOT = @DOCBOOK_ROOT@
|
||||
EBML_CFLAGS = @EBML_CFLAGS@
|
||||
EBML_LDFLAGS = @EBML_LDFLAGS@
|
||||
EBML_LIBS = @EBML_LIBS@
|
||||
EBML_MATROSKA_INTERNAL = @EBML_MATROSKA_INTERNAL@
|
||||
EGREP = @EGREP@
|
||||
@ -88,6 +89,7 @@ LIBINTL_LIBS = @LIBINTL_LIBS@
|
||||
LZO_LIBS = @LZO_LIBS@
|
||||
MAGIC_LIBS = @MAGIC_LIBS@
|
||||
MATROSKA_CFLAGS = @MATROSKA_CFLAGS@
|
||||
MATROSKA_LDFLAGS = @MATROSKA_LDFLAGS@
|
||||
MATROSKA_LIBS = @MATROSKA_LIBS@
|
||||
MINGW_GUIAPP = @MINGW_GUIAPP@
|
||||
MINGW_LIBS = @MINGW_LIBS@
|
||||
|
Loading…
Reference in New Issue
Block a user