forked from mia/Aegisub
Completely remove support for an external libass:
* The internal libass will always be newer than external packages. * aegisub requires fontconfig _and_ iconv support, some systems have either/or but rarely both. * There's zero benifit to supporting an external version. In the future I might add some flags to allow it, if there is a compelling reason to. Originally committed to SVN as r2125.
This commit is contained in:
parent
7a423e02b3
commit
e4d77f6474
3 changed files with 19 additions and 48 deletions
|
@ -9,7 +9,7 @@ if HAVE_AUTO3_LUA
|
||||||
auto3 = auto3
|
auto3 = auto3
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if WITH_INTERNAL_LIBASS
|
if WITH_LIBASS
|
||||||
libass = libass
|
libass = libass
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
|
@ -49,16 +49,13 @@ aegisub_LDFLAGS += @AVFORMAT_LDFLAGS@ @AVCODEC_LDFLAGS@ @SWSCALE_LDFLAGS@
|
||||||
aegisub_LDADD += libaudiovideo_ffmpeg.a
|
aegisub_LDADD += libaudiovideo_ffmpeg.a
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if WITH_INTERNAL_LIBASS
|
if WITH_LIBASS
|
||||||
aegisub_LDFLAGS += @FONTCONFIG_LIBS@
|
|
||||||
endif
|
|
||||||
|
|
||||||
if HAVE_LIBASS
|
|
||||||
noinst_LIBRARIES += libsubtitle_ass.a
|
noinst_LIBRARIES += libsubtitle_ass.a
|
||||||
libsubtitle_ass_a_SOURCES = subtitles_provider_libass.cpp
|
libsubtitle_ass_a_SOURCES = subtitles_provider_libass.cpp
|
||||||
libsubtitle_ass_a_CPPFLAGS = @LIBASS_CFLAGS@
|
libsubtitle_ass_a_CPPFLAGS = @LIBASS_CFLAGS@
|
||||||
LIBS += @LIBASS_LIBS@
|
LIBS += @LIBASS_LIBS@
|
||||||
aegisub_LDADD += libsubtitle_ass.a
|
aegisub_LDADD += libsubtitle_ass.a
|
||||||
|
aegisub_LDFLAGS += @FONTCONFIG_LIBS@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if HAVE_AUTO4_LUA
|
if HAVE_AUTO4_LUA
|
||||||
|
|
58
configure.in
58
configure.in
|
@ -16,7 +16,6 @@ m4_define([portaudio_required_version], [1])
|
||||||
m4_define([pulseaudio_required_version], [1])
|
m4_define([pulseaudio_required_version], [1])
|
||||||
|
|
||||||
m4_define([pkgconfig_required_version], [0.20])
|
m4_define([pkgconfig_required_version], [0.20])
|
||||||
m4_define([libass_required_version], [0.9.1])
|
|
||||||
m4_define([freetype_required_version], [9.7.0])
|
m4_define([freetype_required_version], [9.7.0])
|
||||||
m4_define([fontconfig_required_version], [2.4])
|
m4_define([fontconfig_required_version], [2.4])
|
||||||
m4_define([perl_required_version], [5.004])
|
m4_define([perl_required_version], [5.004])
|
||||||
|
@ -326,8 +325,7 @@ AM_CONDITIONAL([HAVE_FFMPEG], [test "$with_ffmpeg" != "no"])
|
||||||
# Subtitle Provider
|
# Subtitle Provider
|
||||||
###################
|
###################
|
||||||
|
|
||||||
AC_ARG_WITH(libass, [ --without-libass disable libass (default=enable)],libass_disabled="(disabled)")
|
AC_ARG_ENABLE(libass, [ --disable-libass disable libass support (default=enabled)],libass_disabled="(disabled)")
|
||||||
AC_ARG_ENABLE(libass, [ --disable-libass disable internal libass support (default=enabled)],libass_internal_disabled="(disabled)")
|
|
||||||
|
|
||||||
AC_ARG_VAR([ICONV_CFLAGS], [CFLAGS to use for iconv (default: CPPFLAGS)])
|
AC_ARG_VAR([ICONV_CFLAGS], [CFLAGS to use for iconv (default: CPPFLAGS)])
|
||||||
AC_ARG_VAR([ICONV_LDFLAGS], [LDFLAGS to use for iconv (default: LDFLAGS -liconv)])
|
AC_ARG_VAR([ICONV_LDFLAGS], [LDFLAGS to use for iconv (default: LDFLAGS -liconv)])
|
||||||
|
@ -336,55 +334,31 @@ if test -z "ICONV_LDFLAGS"; then
|
||||||
ICONV_LDFLAGS="-liconv";
|
ICONV_LDFLAGS="-liconv";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$with_libass" != "no"; then
|
if test "$enable_libass" != "no"; then
|
||||||
|
AC_CHECK_HEADER(iconv.h, [ICONV_CFLAGS="$ICONV_CFLAGS"; with_iconv="yes"], with_iconv="no")
|
||||||
|
aegisub_save_LDFLAGS="$LDFLAGS"
|
||||||
|
LDFLAGS="$LDFLAGS $ICONV_LDFLAGS"
|
||||||
|
AC_CHECK_LIB([iconv], [iconv_open],[ICONV_LDFLAGS="$ICONV_LIBS"; with_iconv="yes"], with_iconv="no")
|
||||||
|
LDFLAGS="$aegisub_save_LDFLAGS"
|
||||||
|
|
||||||
if test "$enable_libass" != "no"; then
|
if test "$with_iconv" = "yes"; then
|
||||||
AC_CHECK_HEADER(iconv.h, [ICONV_CFLAGS="$ICONV_CFLAGS"; with_iconv="yes"], with_iconv="no")
|
LIBASS_LIBS="-L../libass -lass_aegisub"
|
||||||
aegisub_save_LDFLAGS="$LDFLAGS"
|
LIBASS_CFLAGS="-I../libass"
|
||||||
LDFLAGS="$LDFLAGS $ICONV_LDFLAGS"
|
with_libass="yes"
|
||||||
AC_CHECK_LIB([iconv], [iconv_open],[ICONV_LDFLAGS="$ICONV_LIBS"; with_iconv="yes"], with_iconv="no")
|
|
||||||
LDFLAGS="$aegisub_save_LDFLAGS"
|
|
||||||
|
|
||||||
if test "$with_iconv" = "yes"; then
|
|
||||||
LIBASS_LIBS="-L../libass -lass_aegisub"
|
|
||||||
LIBASS_CFLAGS="-I../libass"
|
|
||||||
with_internal_libass="yes"
|
|
||||||
else
|
|
||||||
with_internal_libass="no"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "$with_internal_libass" != "yes"; then
|
|
||||||
PKG_CHECK_MODULES(LIBASS, libass >= 0.9.1)
|
|
||||||
|
|
||||||
aegisub_save_LDFLAGS="$LDFLAGS"
|
|
||||||
LDFLAGS="$LIBASS_LIBS"
|
|
||||||
AC_CHECK_LIB([ass], [ass_read_styles],[LIBASS_LIBS="$LIBASS_LIBS"; with_libass="yes"], with_libass=no)
|
|
||||||
LDFLAGS="$aegisub_save_LDFLAGS"
|
|
||||||
|
|
||||||
aegisub_save_CPPFLAGS="$CPPFLAGS"
|
|
||||||
CPPFLAGS="$LIBASS_CFLAGS"
|
|
||||||
AC_CHECK_HEADER([ass/ass.h], [LIBASS_CFLAGS="$LIBASS_CFLAGS"; with_libass="yes"], with_libass="no")
|
|
||||||
CPPFLAGS="$aegisub_save_CPPFLAGS"
|
|
||||||
with_internal_libass="no"
|
|
||||||
else
|
else
|
||||||
|
AC_MSG_WARN([libiconv is required for libass support.])
|
||||||
with_libass="no"
|
with_libass="no"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
else
|
|
||||||
with_internal_libass="no"
|
|
||||||
with_libass="no"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if test "$with_libass" = "yes" || test "$with_internal_libass" = "yes"; then
|
if test "$with_libass" = "yes"; then
|
||||||
AC_DEFINE(WITH_LIBASS, 1, [Enable libass Subtitle Provider])
|
AC_DEFINE(WITH_LIBASS, 1, [Enable libass Subtitle Provider])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_SUBST(LIBASS_LIBS)
|
AC_SUBST(LIBASS_LIBS)
|
||||||
AC_SUBST(LIBASS_CFLAGS)
|
AC_SUBST(LIBASS_CFLAGS)
|
||||||
AM_CONDITIONAL([WITH_INTERNAL_LIBASS], [test "$with_libass" = "yes" || test "$with_internal_libass" = "yes"])
|
AM_CONDITIONAL([WITH_LIBASS], [test "$with_libass" = "yes"])
|
||||||
AM_CONDITIONAL([HAVE_LIBASS], [test "$with_libass" = "yes" || test "$with_internal_libass" = "yes"])
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -787,8 +761,8 @@ Video Providers
|
||||||
|
|
||||||
Subtitle Providers:
|
Subtitle Providers:
|
||||||
asa: $with_asa
|
asa: $with_asa
|
||||||
libass (external): $with_libass $libass_disabled
|
libass $with_libass (requires iconv, fontconfig) $libass_disabled
|
||||||
libass (internal) $with_internal_libass (requires iconv, fontconfig) $libass_internal_disabled
|
|
||||||
Misc Packages:
|
Misc Packages:
|
||||||
hunspell: $with_hunspell $with_hunspell_version $hunspell_disabled
|
hunspell: $with_hunspell $with_hunspell_version $hunspell_disabled
|
||||||
universalchardet: $with_univchardet $univchardet_disabled
|
universalchardet: $with_univchardet $univchardet_disabled
|
||||||
|
|
Loading…
Reference in a new issue