1 # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 $(eval
$(call gb_ExternalProject_ExternalProject
,cairo
))
12 $(eval
$(call gb_ExternalProject_use_unpacked
,cairo
,cairo
))
14 $(eval
$(call gb_ExternalProject_use_external_project
,cairo
,pixman
))
16 $(eval
$(call gb_ExternalProject_register_targets
,cairo
,\
20 ifeq ($(OS
)$(COM
),WNTMSC
)
22 $(call gb_ExternalProject_get_state_target
,cairo
,build
) :
23 cd
$(EXTERNAL_WORKDIR
) \
24 && $(MAKE
) -f Makefile.win32 CFG
=release ZLIB3RDLIB
=zlib.lib \
29 # overwrite src/cairo-version.h because that is just a dummy file and included
30 # from cairo.h in non-overridable way
32 $(call gb_ExternalProject_get_state_target
,cairo
,build
) :
33 cd
$(EXTERNAL_WORKDIR
) \
35 $(if
$(debug
),STRIP
=" ") \
36 CFLAGS
="$(if $(debug),-g) $(SOLARINC)" \
37 LDFLAGS
='-L$(OUTDIR)/lib' \
38 $(if
$(filter ANDROID IOS
,$(OS
)),PKG_CONFIG
=.
/dummy_pkg_config
) \
39 pixman_CFLAGS
="-I$(call gb_UnpackedTarball_get_dir,pixman)/pixman" \
40 pixman_LIBS
="-L$(call gb_UnpackedTarball_get_dir,pixman)/pixman/.libs -lpixman-1" \
41 COMPRESS
=$(if
$(filter YES
,$(SYSTEM_ZLIB
)),compress
,z_compress
) \
43 $(if
$(filter NO
,$(SYSTEM_LIBPNG
)),png_CFLAGS
="-I$(OUTDIR)/inc/external/libpng" png_LIBS
="-L$(OUTDIR)/lib -lpng") \
44 $(if
$(filter IOS
,$(OS
)),--disable-shared
,--disable-static
) \
45 $(if
$(filter ANDROID IOS
,$(OS
)),--disable-xlib
,--enable-xlib
) \
46 $(if
$(filter IOS
,$(OS
)),--enable-quartz
--enable-quartz-font
) \
48 $(if
$(filter IOS
,$(OS
)),--disable-ft
,--enable-ft
--enable-fc
) \
49 --disable-svg
--enable-gtk-doc
=no
--enable-test-surfaces
=no \
50 $(if
$(filter YES
,$(CROSS_COMPILING
)),--build
=$(BUILD_PLATFORM
) --host
=$(HOST_PLATFORM
)) \
51 $(if
$(filter MACOSX
,$(OS
)),--prefix=/@.__________________________________________________OOO
) \
52 && cp cairo-version.h src
/cairo-version.h \
53 && cd src
&& $(MAKE
) \
58 # vim: set noet sw=4 ts=4: