Avoid potential negative array index access to cached text.
[LibreOffice.git] / external / redland / ExternalProject_rasqal.mk
blobde53b4e4f3d2c9a32acc0144aaec5a952919ac44
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,rasqal))
12 $(eval $(call gb_ExternalProject_use_external,rasqal,libxml2))
14 $(eval $(call gb_ExternalProject_use_package,rasqal,raptor))
16 $(eval $(call gb_ExternalProject_register_targets,rasqal,\
17 build \
20 # note: this can intentionally only build against internal raptor (not system)
22 $(call gb_ExternalProject_get_state_target,rasqal,build):
23 $(call gb_Trace_StartRange,rasqal,EXTERNAL)
24 $(call gb_ExternalProject_run,build,\
25 $(if $(filter -fsanitize=undefined,$(CC)),CC='$(CC) -fno-sanitize=function') \
26 CFLAGS="$(CFLAGS) $(if $(filter TRUE,$(DISABLE_DYNLOADING)),-fvisibility=hidden) $(call gb_ExternalProject_get_build_flags,rasqal) $(gb_EMSCRIPTEN_CPPFLAGS)" \
27 LDFLAGS=" \
28 $(if $(filter LINUX FREEBSD,$(OS)),-Wl$(COMMA)-z$(COMMA)origin -Wl$(COMMA)-rpath$(COMMA)\\"\$$\$$ORIGIN") \
29 $(if $(SYSBASE),$(if $(filter LINUX SOLARIS,$(OS)),-L$(SYSBASE)/lib -L$(SYSBASE)/usr/lib -lpthread -ldl))" \
30 $(if $(SYSBASE),CPPFLAGS="-I$(SYSBASE)/usr/include") \
31 PKG_CONFIG="" \
32 RAPTOR2_CFLAGS="-I$(call gb_UnpackedTarball_get_dir,raptor)/src" \
33 RAPTOR2_LIBS="-L$(call gb_UnpackedTarball_get_dir,raptor)/src/.libs -lraptor2" \
34 $(gb_RUN_CONFIGURE) ./configure --disable-gtk-doc \
35 --with-regex-library=posix \
36 --with-decimal=none \
37 --with-uuid-library=internal \
38 --with-digest-library=internal \
39 $(gb_CONFIGURE_PLATFORMS) \
40 $(if $(CROSS_COMPILING),$(if $(filter INTEL ARM,$(CPUNAME)),ac_cv_c_bigendian=no)) \
41 $(if $(filter MACOSX,$(OS)),--prefix=/@.__________________________________________________OOO) \
42 $(if $(DISABLE_DYNLOADING), \
43 --enable-static --disable-shared \
44 , \
45 --enable-shared --disable-static \
46 ) \
47 $(if $(SYSTEM_LIBXML),,--with-xml2-config=$(call gb_UnpackedTarball_get_dir,libxml2)/xml2-config) \
48 && $(MAKE) \
49 $(if $(filter MACOSX,$(OS)),&& $(PERL) \
50 $(SRCDIR)/solenv/bin/macosx-change-install-names.pl shl OOO \
51 $(EXTERNAL_WORKDIR)/src/.libs/librasqal-lo.$(RASQAL_MAJOR).dylib) \
53 $(call gb_Trace_EndRange,rasqal,EXTERNAL)
55 # vim: set noet sw=4 ts=4: