Freetype is needed by libgltf on all platforms

Change-Id: I042cbc5f4cabfa7ec387594189e2f86be6ec7fbf
This commit is contained in:
Zolnai Tamás 2014-04-18 10:10:39 +02:00
parent ec95e6a17c
commit b6cbb15026
6 changed files with 31 additions and 15 deletions

View File

@ -1254,7 +1254,7 @@ endef
gb_ExternalProject__use_freetype := gb_ExternalProject__use_freetype :=
else ifeq ($(OS),ANDROID) else ifneq (,$(or $(filter-out ANDROID,$(OS)),$(ENABLE_GLTF)))
define gb_LinkTarget__use_freetype_headers define gb_LinkTarget__use_freetype_headers
$(call gb_LinkTarget_use_external_project,$(1),freetype) $(call gb_LinkTarget_use_external_project,$(1),freetype)

View File

@ -126,6 +126,7 @@ export ENABLE_GNOMEVFS=@ENABLE_GNOMEVFS@
export ENABLE_GRAPHITE=@ENABLE_GRAPHITE@ export ENABLE_GRAPHITE=@ENABLE_GRAPHITE@
export ENABLE_ORCUS=@ENABLE_ORCUS@ export ENABLE_ORCUS=@ENABLE_ORCUS@
export ENABLE_HARFBUZZ=@ENABLE_HARFBUZZ@ export ENABLE_HARFBUZZ=@ENABLE_HARFBUZZ@
export ENABLE_GLTF=@ENABLE_GLTF@
export ENABLE_GSTREAMER=@ENABLE_GSTREAMER@ export ENABLE_GSTREAMER=@ENABLE_GSTREAMER@
export ENABLE_GSTREAMER_0_10=@ENABLE_GSTREAMER_0_10@ export ENABLE_GSTREAMER_0_10=@ENABLE_GSTREAMER_0_10@
export ENABLE_GTK3=@ENABLE_GTK3@ export ENABLE_GTK3=@ENABLE_GTK3@

View File

@ -10359,6 +10359,23 @@ fi
AC_SUBST(ENABLE_OPENCL) AC_SUBST(ENABLE_OPENCL)
dnl ===================================================================
dnl Check whether to enable glTF support
dnl ===================================================================
ENABLE_GLTF=
AC_MSG_CHECKING([whether to enable glTF support])
if test "$enable_opengl" = "yes"; then
ENABLE_GLTF=TRUE
AC_MSG_RESULT([yes])
if test "$test_freetype" = "no"; then
BUILD_TYPE="$BUILD_TYPE FREETYPE"
fi
else
AC_MSG_RESULT([no])
fi
AC_SUBST(ENABLE_GLTF)
# pdf import? # pdf import?
AC_MSG_CHECKING([whether to build the PDF import feature]) AC_MSG_CHECKING([whether to build the PDF import feature])
ENABLE_PDFIMPORT= ENABLE_PDFIMPORT=

View File

@ -14,16 +14,16 @@ $(eval $(call gb_ExternalProject_register_targets,freetype,\
)) ))
$(call gb_ExternalProject_get_state_target,freetype,build) : $(call gb_ExternalProject_get_state_target,freetype,build) :
cd $(EXTERNAL_WORKDIR) \ $(call gb_ExternalProject_run,build,\
&& CFLAGS="$(if $(debug),-g) $(gb_VISIBILITY_FLAGS)" \
./configure \ ./configure \
--disable-shared \ --disable-shared \
--without-zlib \ --without-zlib \
--without-bzip2 \ --without-bzip2 \
--prefix=$(call gb_UnpackedTarball_get_dir,freetype/instdir) \ --prefix=$(call gb_UnpackedTarball_get_dir,freetype/instdir) \
--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM) \ --build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM) \
&& chmod +x builds/unix/freetype-config \ CFLAGS="$(if $(debug),-g) $(gb_VISIBILITY_FLAGS)" \
&& $(MAKE) install \ && chmod +x builds/unix/freetype-config \
&& touch $@ && $(MAKE) install \
&& touch $@ )
# vim: set noet sw=4 ts=4: # vim: set noet sw=4 ts=4:

View File

@ -9,7 +9,7 @@
$(eval $(call gb_Module_Module,freetype)) $(eval $(call gb_Module_Module,freetype))
ifeq ($(OS),ANDROID) ifneq (,$(or $(filter-out ANDROID,$(OS)),$(ENABLE_GLTF)))
$(eval $(call gb_Module_add_targets,freetype,\ $(eval $(call gb_Module_add_targets,freetype,\
ExternalProject_freetype \ ExternalProject_freetype \

View File

@ -1,8 +1,6 @@
This "bundled" freetype is built only in an Android build
FreeType 2 is a software font engine that is designed to be small, efficient, highly customizable, FreeType 2 is a software font engine that is designed to be small, efficient, highly customizable,
and portable while capable of producing high-quality output (glyph images). It can be and portable while capable of producing high-quality output (glyph images). It can be
used in graphics libraries, display servers, font conversion tools, text image generation used in graphics libraries, display servers, font conversion tools, text image generation
tools, and many other products as well. tools, and many other products as well.
From [http://freetype.sourceforge.net/freetype2/index.html] From [http://freetype.sourceforge.net/freetype2/index.html]