mirror of https://github.com/odrling/Aegisub
* Add support for universalchardet
* Fix #ifdef for STIDO/fstream with a proper ifdef/else * Make auto3 subdir inclusion conditional * Rename libspell_hunspell to libmisc* Please note that universalchardet is only set to work with X86 for now, I'll fi$ the rest later. Originally committed to SVN as r1907.
This commit is contained in:
parent
93db5bfd96
commit
f55ffd6d91
18
Makefile.am
18
Makefile.am
|
@ -1,6 +1,22 @@
|
||||||
AUTOMAKE_OPTIONS = foreign
|
AUTOMAKE_OPTIONS = foreign
|
||||||
|
|
||||||
SUBDIRS = aegisub auto3 automation po m4macros
|
|
||||||
|
if HAVE_UNIVCHARDET
|
||||||
|
univchardet = universalchardet
|
||||||
|
endif
|
||||||
|
|
||||||
|
if HAVE_AUTO3_LUA
|
||||||
|
auto3 = auto3
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
SUBDIRS = \
|
||||||
|
$(univchardet) \
|
||||||
|
$(auto3) \
|
||||||
|
aegisub \
|
||||||
|
automation \
|
||||||
|
po \
|
||||||
|
m4macros
|
||||||
|
|
||||||
EXTRA_DIST = \
|
EXTRA_DIST = \
|
||||||
intltool-extract.in \
|
intltool-extract.in \
|
||||||
|
|
|
@ -61,13 +61,6 @@ aegisub_LDFLAGS += @LIBASS_LIBS@
|
||||||
aegisub_LDADD += libsubtitle_ass.a
|
aegisub_LDADD += libsubtitle_ass.a
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if HAVE_HUNSPELL
|
|
||||||
noinst_LIBRARIES += libspell_hunspell.a
|
|
||||||
libspell_hunspell_a_SOURCES = spellchecker_hunspell.cpp
|
|
||||||
aegisub_LDFLAGS += @HUNSPELL_LDFLAGS@
|
|
||||||
aegisub_LDADD += libspell_hunspell.a
|
|
||||||
endif
|
|
||||||
|
|
||||||
if HAVE_AUTO4_LUA
|
if HAVE_AUTO4_LUA
|
||||||
noinst_LIBRARIES += libauto4_lua.a
|
noinst_LIBRARIES += libauto4_lua.a
|
||||||
libauto4_lua_a_SOURCES = auto4_lua.cpp auto4_lua_assfile.cpp auto4_lua_dialog.cpp auto4_lua_scriptreader.cpp
|
libauto4_lua_a_SOURCES = auto4_lua.cpp auto4_lua_assfile.cpp auto4_lua_dialog.cpp auto4_lua_scriptreader.cpp
|
||||||
|
@ -98,6 +91,21 @@ aegisub_LDADD += -L$(srcdir)/../auto3 -laegisub-auto3
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
if HAVE_HUNSPELL
|
||||||
|
noinst_LIBRARIES += libmisc_hunspell.a
|
||||||
|
libmisc_hunspell_a_SOURCES = spellchecker_hunspell.cpp
|
||||||
|
aegisub_LDFLAGS += @HUNSPELL_LDFLAGS@
|
||||||
|
aegisub_LDADD += libmisc_hunspell.a
|
||||||
|
endif
|
||||||
|
|
||||||
|
if HAVE_UNIVCHARDET
|
||||||
|
noinst_LIBRARIES += libmisc_universalchardet.a
|
||||||
|
libmisc_universalchardet_a_SOURCES = charset_detect.cpp
|
||||||
|
libmisc_universalchardet_a_CPPFLAGS = -D_X86_ -DTEXT_READER_USE_STDIO
|
||||||
|
aegisub_LDADD += libmisc_universalchardet.a ../universalchardet/libuniversalchardet.a
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## These aren't built, but are listed here so 'make dist' can always find all the sources
|
## These aren't built, but are listed here so 'make dist' can always find all the sources
|
||||||
## This should also list all Win32 specific files
|
## This should also list all Win32 specific files
|
||||||
|
|
|
@ -42,9 +42,10 @@
|
||||||
#include <wx/wxprec.h>
|
#include <wx/wxprec.h>
|
||||||
#include <wx/dynarray.h>
|
#include <wx/dynarray.h>
|
||||||
#include <wx/string.h>
|
#include <wx/string.h>
|
||||||
#include <fstream>
|
|
||||||
#ifdef TEXT_READER_USE_STDIO
|
#ifdef TEXT_READER_USE_STDIO
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#else
|
||||||
|
#include <fstream>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
30
configure.in
30
configure.in
|
@ -282,12 +282,24 @@ fi
|
||||||
if test "$with_hunspell" = "yes"; then
|
if test "$with_hunspell" = "yes"; then
|
||||||
AC_DEFINE(WITH_HUNSPELL, 1, [Enable hunspell support])
|
AC_DEFINE(WITH_HUNSPELL, 1, [Enable hunspell support])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AM_CONDITIONAL([HAVE_HUNSPELL], [test "$with_hunspell" != "no"])
|
AM_CONDITIONAL([HAVE_HUNSPELL], [test "$with_hunspell" != "no"])
|
||||||
AC_SUBST(HUNSPELL_LDFLAGS)
|
AC_SUBST(HUNSPELL_LDFLAGS)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
AC_ARG_WITH(univchardet, [ --without-univchardet build without universalchardet support], univchardet_disabled="(disabled)")
|
||||||
|
if test "$with_univchardet" != "no"; then
|
||||||
|
with_univchardet="yes"
|
||||||
|
AC_DEFINE(WITH_UNIVCHARDET, 1, [Enable universalchardet support])
|
||||||
|
else
|
||||||
|
with_univchardet="no"
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL([HAVE_UNIVCHARDET], [test "$with_univchardet" != "no"])
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
############
|
############
|
||||||
# Automation
|
# Automation
|
||||||
|
@ -509,13 +521,14 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",
|
||||||
|
|
||||||
|
|
||||||
AC_OUTPUT([
|
AC_OUTPUT([
|
||||||
Makefile
|
Makefile
|
||||||
auto3/Makefile
|
aegisub/Makefile
|
||||||
automation/Makefile
|
aegisub/bitmaps/Makefile
|
||||||
po/Makefile.in
|
aegisub/posix/Makefile
|
||||||
aegisub/Makefile
|
universalchardet/Makefile
|
||||||
aegisub/bitmaps/Makefile
|
auto3/Makefile
|
||||||
aegisub/posix/Makefile
|
automation/Makefile
|
||||||
|
po/Makefile.in
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
||||||
|
@ -576,4 +589,5 @@ Subtitle Providers:
|
||||||
|
|
||||||
Misc Packages:
|
Misc Packages:
|
||||||
hunspell: $with_hunspell $hunspell_disabled
|
hunspell: $with_hunspell $hunspell_disabled
|
||||||
|
universalchardet: $with_univchardet $univchardet_disabled
|
||||||
]);
|
]);
|
||||||
|
|
|
@ -0,0 +1,58 @@
|
||||||
|
noinst_LIBRARIES = libuniversalchardet.a
|
||||||
|
|
||||||
|
AM_CPPFLAGS = -D_X86_
|
||||||
|
|
||||||
|
nodist_libuniversalchardet_a_SOURCES = \
|
||||||
|
CharDistribution.cpp \
|
||||||
|
JpCntx.cpp \
|
||||||
|
LangBulgarianModel.cpp \
|
||||||
|
LangCyrillicModel.cpp \
|
||||||
|
LangGreekModel.cpp \
|
||||||
|
LangHebrewModel.cpp \
|
||||||
|
LangHungarianModel.cpp \
|
||||||
|
LangThaiModel.cpp \
|
||||||
|
nsBig5Prober.cpp \
|
||||||
|
nsCharSetProber.cpp \
|
||||||
|
nsEUCJPProber.cpp \
|
||||||
|
nsEUCKRProber.cpp \
|
||||||
|
nsEUCTWProber.cpp \
|
||||||
|
nsEscCharsetProber.cpp \
|
||||||
|
nsEscSM.cpp \
|
||||||
|
nsGB2312Prober.cpp \
|
||||||
|
nsHebrewProber.cpp \
|
||||||
|
nsLatin1Prober.cpp \
|
||||||
|
nsMBCSGroupProber.cpp \
|
||||||
|
nsMBCSSM.cpp \
|
||||||
|
nsSBCSGroupProber.cpp \
|
||||||
|
nsSBCharSetProber.cpp \
|
||||||
|
nsSJISProber.cpp \
|
||||||
|
nsUTF8Prober.cpp \
|
||||||
|
nsUniversalDetector.cpp
|
||||||
|
|
||||||
|
nodist_libuniversalchardet_a_SOURCES += \
|
||||||
|
CharDistribution.h \
|
||||||
|
JpCntx.h \
|
||||||
|
nsBig5Prober.h \
|
||||||
|
nsCharSetProber.h \
|
||||||
|
nsCodingStateMachine.h \
|
||||||
|
nsEUCJPProber.h \
|
||||||
|
nsEUCKRProber.h \
|
||||||
|
nsEUCTWProber.h \
|
||||||
|
nsError.h \
|
||||||
|
nsEscCharsetProber.h \
|
||||||
|
nsGB2312Prober.h \
|
||||||
|
nsHebrewProber.h \
|
||||||
|
nsLatin1Prober.h \
|
||||||
|
nsMBCSGroupProber.h \
|
||||||
|
nsPkgInt.h \
|
||||||
|
nsSBCSGroupProber.h \
|
||||||
|
nsSBCharSetProber.h \
|
||||||
|
nsSJISProber.h \
|
||||||
|
nsUTF8Prober.h \
|
||||||
|
nsUniversalDetector.h \
|
||||||
|
nscore.h \
|
||||||
|
prcpucfg.h \
|
||||||
|
prmem.h \
|
||||||
|
protypes.h \
|
||||||
|
prtypes.h \
|
||||||
|
xpcom-config.h
|
Loading…
Reference in New Issue