[Scummvm-cvs-logs] SF.net SVN: scummvm:[46642] tools/branches/gsoc2009-gui
sev at users.sourceforge.net
sev at users.sourceforge.net
Sun Dec 27 15:09:10 CET 2009
Revision: 46642
http://scummvm.svn.sourceforge.net/scummvm/?rev=46642&view=rev
Author: sev
Date: 2009-12-27 14:09:10 +0000 (Sun, 27 Dec 2009)
Log Message:
-----------
Add detection for freetype and made create_sjisfont conditionally compilable
Modified Paths:
--------------
tools/branches/gsoc2009-gui/Makefile.common
tools/branches/gsoc2009-gui/configure
Modified: tools/branches/gsoc2009-gui/Makefile.common
===================================================================
--- tools/branches/gsoc2009-gui/Makefile.common 2009-12-27 13:58:00 UTC (rev 46641)
+++ tools/branches/gsoc2009-gui/Makefile.common 2009-12-27 14:09:10 UTC (rev 46642)
@@ -68,6 +68,11 @@
tools_cli$(EXEEXT) \
tools_gui$(EXEEXT)
+ifdef USE_FREETYPE
+TARGETS += \
+ create_sjisfnt$(EXEEXT)
+endif
+
UTILS := \
common/file.o \
common/md5.o \
@@ -138,9 +143,9 @@
create_sjisfnt_OBJS := create_sjisfnt.o $(UTILS)
-create_sjisfnt_LIBS := `freetype-config --libs` #-liconv # TODO: Some systems seem to require "iconv" to be linked, we need to handle that...
+create_sjisfnt_LIBS := $(FREETYPELIBS) #-liconv # TODO: Some systems seem to require "iconv" to be linked, we need to handle that...
# Set custom build flags
-create_sjisfnt.o: CPPFLAGS+=`freetype-config --cflags`
+create_sjisfnt.o: CPPFLAGS+=$(FREETYPEINCLUDES)
sword2_clue_OBJS := engines/sword2/sword2_clue.o
Modified: tools/branches/gsoc2009-gui/configure
===================================================================
--- tools/branches/gsoc2009-gui/configure 2009-12-27 13:58:00 UTC (rev 46641)
+++ tools/branches/gsoc2009-gui/configure 2009-12-27 14:09:10 UTC (rev 46642)
@@ -75,6 +75,7 @@
_mad=auto
_zlib=auto
_png=auto
+_freetype=auto
_endian=unknown
_need_memalign=no
_verbose_build=no
@@ -87,6 +88,8 @@
_prefix=/usr/local
_wxincludes=""
_wxlibs=""
+_freetypeincludes=""
+_freetypelibs=""
_srcdir=`dirname $0`
@@ -308,6 +311,8 @@
--disable-zlib) _zlib=no ;;
--enable-png) _png=yes ;;
--disable-png) _png=no ;;
+ --enable-freetype) _freetype=yes ;;
+ --disable-freetype) _freetype=no ;;
--enable-verbose-build) _verbose_build=yes ;;
--with-ogg-prefix=*)
arg=`echo $ac_option | cut -d '=' -f 2`
@@ -619,6 +624,7 @@
DEFINES="$DEFINES -DUNIX"
LDFLAGS="$LDFLAGS -L/usr/local/lib"
CXXFLAGS="$CXXFLAGS -I/usr/local/include"
+ _iconv_const=yes
;;
beos*)
DEFINES="$DEFINES -DUNIX -DSYSTEM_NOT_SUPPORTING_D_TYPE"
@@ -917,6 +923,30 @@
echo "$_png"
#
+# Check for FreeType
+#
+echocheck "freetype"
+if test "$_freetype" = auto ; then
+ _freetype=no
+ if type freetype-config > /dev/null 2>&1 ; then
+ _freetype=yes
+ fi
+fi
+
+if test "$_freetype" = yes ; then
+ freetype_version=`freetype-config --ftversion 2>/dev/null`
+
+ _def_freetype='#define USE_FREETYPE'
+ _freetypelibs=`freetype-config --libs`
+ _freetypeincludes=`freetype-config --cflags`
+else
+ _def_freetype='#undef USE_FREETYPE'
+ freetype_version="no"
+fi
+add_to_config_mk_if_yes "$_freetype" 'USE_FREETYPE = 1'
+echo "$freetype_version"
+
+#
# Figure out installation directories
#
test -z "$_bindir" && _bindir="$_prefix/bin"
@@ -993,6 +1023,8 @@
$_def_flac
$_def_mad
$_def_zlib
+$_def_png
+$_def_freetype
#endif /* CONFIG_H */
EOF
@@ -1030,8 +1062,11 @@
LDFLAGS += $LDFLAGS
WXINCLUDES := $_wxincludes
-WXLIBS:= $_wxlibs
+WXLIBS := $_wxlibs
+FREETYPEINCLUDES := $_freetypeincludes
+FREETYPELIBS := $_freetypelibs
+
SAVED_CONFIGFLAGS := $SAVED_CONFIGFLAGS
SAVED_LDFLAGS := $SAVED_LDFLAGS
SAVED_CXX := $SAVED_CXX
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list