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_Library_Library
,jpipe
))
12 $(eval
$(call gb_Library_use_libraries
,jpipe
,\
18 # The real library is called jpipx on Windows. We build only a wrapper
20 $(eval
$(call gb_Library_add_cobjects
,jpipe
,\
21 jurt
/source
/pipe
/wrapper
/wrapper \
26 ifeq ($(COM_GCC_IS_CLANG
),TRUE
)
27 ifneq ($(filter -fsanitize
=%,$(gb_CC
)),)
28 Library_jpipe__staticsalhack
= TRUE
32 ifeq ($(Library_jpipe__staticsalhack
),)
34 $(eval
$(call gb_Library_use_libraries
,jpipe
,\
38 $(eval
$(call gb_Library_add_cobjects
,jpipe
,\
39 jurt
/source
/pipe
/com_sun_star_lib_connections_pipe_PipeConnection \
44 # HACK for Clang -fsanitize=address etc. to build libjpipe.so (dlopen'ed from
45 # java executable) without dependence on __asan_* etc. symbols (expected to be
46 # provided by the executable), incl. statically linking in the relevant parts of
49 $(eval
$(call gb_Library_add_cobjects
,jpipe
, \
50 jurt
/source
/pipe
/com_sun_star_lib_connections_pipe_PipeConnection \
53 $(eval
$(call gb_Library_add_exception_objects
,jpipe
, \
54 jurt
/source
/pipe
/staticsalhack \
57 $(eval
$(call gb_Library_add_defs
,jpipe
, \
58 -DRTL_OS
="\"$(RTL_OS)"\" \
59 -DRTL_ARCH
="\"$(RTL_ARCH)"\" \
62 $(eval
$(call gb_Library_set_include
,jpipe
, \
66 -I
$(SRCDIR
)/sal
/osl
/unx \
68 -I
$(SRCDIR
)/sal
/textenc \
71 $(eval
$(call gb_Library_use_externals
,jpipe
, \
75 $(eval
$(call gb_Library_add_libs
,jpipe
, \
76 $(if
$(filter-out $(OS
),ANDROID
),-lpthread
) \
79 $(call gb_LinkTarget_get_target
,$(call gb_Library_get_linktarget
,jpipe
)): \
80 gb_CC
:= $(filter-out -fsanitize
=%,$(gb_CC
))
81 $(call gb_LinkTarget_get_target
,$(call gb_Library_get_linktarget
,jpipe
)): \
82 gb_CXX
:= $(filter-out -fsanitize
=%,$(gb_CXX
))
87 # vim:set noet sw=4 ts=4: