fix baseline build (old cairo) - 'cairo_rectangle_int_t' does not name a type
[LibreOffice.git] / external / cairo / ExternalProject_cairo.mk
blobcc26096f23d61b49136767d44369515e0f4444d5
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_external_project,cairo,pixman))
14 $(eval $(call gb_ExternalProject_register_targets,cairo,\
15 build \
18 ifeq ($(OS)$(COM),WNTMSC)
20 $(call gb_ExternalProject_get_state_target,cairo,build) :
21 $(call gb_ExternalProject_run,build,\
22 $(MAKE) -f Makefile.win32 CFG=release ZLIB3RDLIB=zlib.lib \
26 else
28 # overwrite src/cairo-version.h because that is just a dummy file and included
29 # from cairo.h in non-overridable way
31 $(call gb_ExternalProject_get_state_target,cairo,build) :
32 $(call gb_ExternalProject_run,build,\
33 ./configure \
34 $(if $(debug),STRIP=" ") \
35 CFLAGS="$(if $(debug),-g) $(ZLIB_CFLAGS)" \
36 $(if $(filter ANDROID IOS,$(OS)),PKG_CONFIG=./dummy_pkg_config) \
37 pixman_CFLAGS="-I$(call gb_UnpackedTarball_get_dir,pixman)/pixman" \
38 pixman_LIBS="-L$(call gb_UnpackedTarball_get_dir,pixman)/pixman/.libs -lpixman-1" \
39 COMPRESS=$(if $(SYSTEM_ZLIB),compress,z_compress) \
40 ZLIB3RDLIB="$(if $(SYSTEM_ZLIB),,-L$(WORKDIR)/LinkTarget/StaticLibrary) -lz" \
41 png_REQUIRES="trick_configure_into_using_png_CFLAGS_and_LIBS" \
42 png_CFLAGS="$(LIBPNG_CFLAGS)" png_LIBS="$(LIBPNG_LIBS)" \
43 $(if $(filter IOS,$(OS)),--disable-shared,--disable-static) \
44 $(if $(filter ANDROID IOS,$(OS)),--disable-xlib,--enable-xlib) \
45 $(if $(filter IOS,$(OS)),--enable-quartz --enable-quartz-font) \
46 --disable-valgrind \
47 $(if $(filter IOS,$(OS)),--disable-ft,--enable-ft --enable-fc) \
48 --disable-svg --enable-gtk-doc=no --enable-test-surfaces=no \
49 $(if $(CROSS_COMPILING),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
50 $(if $(filter MACOSX,$(OS)),--prefix=/@.__________________________________________________OOO) \
51 && cp cairo-version.h src/cairo-version.h \
52 && cd src && $(MAKE) \
55 endif
57 # vim: set noet sw=4 ts=4: