summaryrefslogtreecommitdiff
path: root/RepositoryExternal.mk
diff options
context:
space:
mode:
authorMatúš Kukan <matus.kukan@collabora.com>2014-11-17 09:16:34 +0100
committerMatúš Kukan <matus.kukan@collabora.com>2014-11-17 14:47:57 +0100
commit71fae5db27255fb51a25a307205a8fe76cc56b6a (patch)
treecec2164a8b885870975e75d367447dba56f5cdd4 /RepositoryExternal.mk
parent65f41639e219470c80f896129731f9ed6f072b6b (diff)
Add internal libjpeg-turbo library to be used instead of libjpeg
Unfortunately requires nasm - the netwide assembler - http://www.nasm.us/ Upstream libjpeg-turbo is meant to be built with CMake on Windows but thanks to our gcc-wrappers we are able to avoid that. jpeg is kept mostly for platforms we are cross-compiling to. For now, it's used also for Mac OS X because jpeg-turbo does not build there, which should be fixed later. Change-Id: Id87b7072a8acc2578c3abf7e82cb1499e5094dbf
Diffstat (limited to 'RepositoryExternal.mk')
-rw-r--r--RepositoryExternal.mk14
1 files changed, 14 insertions, 0 deletions
diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index 911dab1fd748..47f6e90d9268 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -444,6 +444,20 @@ $(call gb_LinkTarget_set_ldflags,$(1),\
endef
+else ifeq ($(WITH_JPEG_TURBO),TRUE)
+
+define gb_LinkTarget__use_jpeg
+$(call gb_LinkTarget_set_include,$(1),\
+ -I$(call gb_UnpackedTarball_get_dir,jpeg-turbo) \
+ $$(INCLUDE) \
+)
+$(call gb_LinkTarget_add_libs,$(1),\
+ $(call gb_UnpackedTarball_get_dir,jpeg-turbo)/.libs/libjpeg$(gb_StaticLibrary_PLAINEXT) \
+)
+$(call gb_LinkTarget_use_external_project,$(1),jpeg-turbo)
+
+endef
+
else # !SYSTEM_JPEG
define gb_LinkTarget__use_jpeg