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
,langtag
))
12 $(eval
$(call gb_ExternalProject_use_unpacked
,langtag
,langtag
))
14 $(eval
$(call gb_ExternalProject_register_targets
,langtag
,\
18 $(call gb_ExternalProject_get_state_target
,langtag
,build
):
19 cd
$(EXTERNAL_WORKDIR
) \
20 $(if
$(filter MSC
,$(COM
)), \
21 && export LIB
="$(ILIB)" \
22 CC
="$(CC) -MD -nologo \
23 $(if $(filter TRUE,$(ENABLE_DEBUG)),-Zi) \
25 && .
/configure
--disable-modules
--disable-test
--disable-introspection
--disable-shared
--enable-static
--with-pic \
26 $(if
$(filter TRUE
,$(HAVE_GCC_BUILTIN_ATOMIC
)),"lt_cv_has_atomic=yes","lt_cv_has_atomic=no") \
27 $(if
$(filter YES
,$(CROSS_COMPILING
)),--build
=$(BUILD_PLATFORM
) --host
=$(HOST_PLATFORM
)) \
28 $(if
$(filter NO
,$(SYSTEM_LIBXML
)),LIBXML2_CFLAGS
="-I$(OUTDIR)/inc/external" \
29 $(if
$(filter MSC
,$(COM
)),LIBXML2_LIBS
="$(OUTDIR)/lib/libxml2.lib",LIBXML2_LIBS
="-L$(OUTDIR)/lib -lxml2"),\
30 $(if
$(filter MACOSX
,$(OS
)),LIBXML2_CFLAGS
="$(LIBXML_CFLAGS)" LIBXML2_LIBS
="$(LIBXML_LIBS)")) \
31 $(if
$(filter MACOSX
,$(OS
)),--prefix=/@.__________________________________________________OOO
) \
32 $(if
$(filter-out LINUX FREEBSD
,$(OS
)),,LDFLAGS
="-Wl,-z,origin -Wl,-rpath,$$ORIGIN:$$ORIGIN/../ure-link/lib") \
33 $(if
$(filter-out SOLARIS
,$(OS
)),,LDFLAGS
="-Wl,-z,origin -Wl,-R,$$ORIGIN:$$ORIGIN/../ure-link/lib") \
34 $(if
$(filter-out WNTGCC
,$(GUI
)$(COM
)),,LDFLAGS
="-Wl,--enable-runtime-pseudo-reloc-v2") \
37 # vim: set noet sw=4 ts=4: