...instead of using the default -static-libsan, where dynamic libraries must be built without -z defs and where all executables must link against the static libsan. Dropping the latter requirement means that we no longer need the static sal hack in Library_jpipe. But instead, at runtime, when a process loads any library that links against the dynamic libsan, then that dynamic libsan must be loaded first into the process. For executables that are themselves linked against the dynamic libsan, that is already the case. For scenarios where we invoke a Java executable, we now use LD_PRELOAD to fulfil that requirement. (And for invocation of Python executables, this commit assumes a --enable-python=fully-internal configuration, so that executable will be itself linked against the dynamic libsan.) Dropping the requirement to build without -z defs revealed that using -fsanitize=vptr often requires RTTI symbols from libraries that are not usually linked against. Such cases are now handled by conditionally including those libraries in gb_*_use_libraries calls. (This could be restricted even further to only be done under -shared-libsan, but it arguably doesn't hurt to also do it under the default -static-libsan.) The expectation is that -shared-libsan will explicitly be passed into the configuration along with any other -fsanitize... arguments via --with-extra-cc-flags and --with-extra-cxx-flags. This commit does not yet remove the code that is only needed for the (default) -static-libsan caes, but that code could eventually be cleaned up, once all (Clang) builds using sanitizers use -shared-libsan. (GCC already defaults to a shared model. Instead of a combined -shared-libsan, it has individual -shared-libasan etc., though. This commit does not intend to make any changes to any potential GCC sanitizer builds; my assumption is that we do not have any such, and that they wouldn't work out of the box, neither before nor after this change.) Change-Id: I932e4b75c299c158211e122adf33d7988892a87e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200935 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
127 lines
3.5 KiB
Makefile
127 lines
3.5 KiB
Makefile
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
|
|
#
|
|
# This file is part of the LibreOffice project.
|
|
#
|
|
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
#
|
|
# This file incorporates work covered by the following license notice:
|
|
#
|
|
# Licensed to the Apache Software Foundation (ASF) under one or more
|
|
# contributor license agreements. See the NOTICE file distributed
|
|
# with this work for additional information regarding copyright
|
|
# ownership. The ASF licenses this file to you under the Apache
|
|
# License, Version 2.0 (the "License"); you may not use this file
|
|
# except in compliance with the License. You may obtain a copy of
|
|
# the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
#
|
|
|
|
$(eval $(call gb_Library_Library,msword))
|
|
|
|
$(eval $(call gb_Library_set_componentfile,msword,sw/util/msword,services))
|
|
|
|
$(eval $(call gb_Library_use_custom_headers,msword,\
|
|
officecfg/registry \
|
|
oox/generated \
|
|
))
|
|
|
|
$(eval $(call gb_Library_set_precompiled_header,msword,sw/inc/pch/precompiled_msword))
|
|
|
|
$(eval $(call gb_Library_set_include,msword,\
|
|
-I$(SRCDIR)/sw/source/core/inc \
|
|
-I$(SRCDIR)/sw/source/filter/inc \
|
|
-I$(SRCDIR)/sw/inc \
|
|
-I$(SRCDIR)/sw/source/uibase/inc \
|
|
$$(INCLUDE) \
|
|
))
|
|
|
|
$(eval $(call gb_Library_use_api,msword,\
|
|
udkapi \
|
|
offapi \
|
|
oovbaapi \
|
|
))
|
|
|
|
$(eval $(call gb_Library_use_libraries,msword,\
|
|
basegfx \
|
|
comphelper \
|
|
cppu \
|
|
cppuhelper \
|
|
docmodel \
|
|
editeng \
|
|
i18nlangtag \
|
|
i18nutil \
|
|
msfilter \
|
|
sal \
|
|
sax \
|
|
sb \
|
|
oox \
|
|
sfx \
|
|
sot \
|
|
svl \
|
|
svt \
|
|
svx \
|
|
svxcore \
|
|
sw \
|
|
tk \
|
|
tl \
|
|
ucbhelper \
|
|
utl \
|
|
vcl \
|
|
$(if $(filter -fsanitize=vptr,$(gb_CXX)),i18npool) \
|
|
$(if $(filter -fsanitize=vptr,$(gb_CXX)),salhelper) \
|
|
))
|
|
|
|
$(eval $(call gb_Library_use_externals,msword,\
|
|
boost_headers \
|
|
frozen \
|
|
icui18n \
|
|
icuuc \
|
|
icu_headers \
|
|
libxml2 \
|
|
))
|
|
|
|
$(eval $(call gb_Library_add_exception_objects,msword,\
|
|
sw/source/filter/docx/swdocxreader \
|
|
sw/source/filter/rtf/swparrtf \
|
|
sw/source/filter/ww8/docxattributeoutput \
|
|
sw/source/filter/ww8/docxexport \
|
|
sw/source/filter/ww8/docxexportfilter \
|
|
sw/source/filter/ww8/docxsdrexport \
|
|
sw/source/filter/ww8/docxtableexport \
|
|
sw/source/filter/ww8/docxtablestyleexport \
|
|
sw/source/filter/ww8/rtfattributeoutput \
|
|
sw/source/filter/ww8/rtfexport \
|
|
sw/source/filter/ww8/rtfexportfilter \
|
|
sw/source/filter/ww8/rtfsdrexport \
|
|
sw/source/filter/ww8/rtfstringbuffer \
|
|
sw/source/filter/ww8/WW8FFData \
|
|
sw/source/filter/ww8/WW8FibData \
|
|
sw/source/filter/ww8/WW8Sttbf \
|
|
sw/source/filter/ww8/WW8TableInfo \
|
|
sw/source/filter/ww8/fields \
|
|
sw/source/filter/ww8/styles \
|
|
sw/source/filter/ww8/writerhelper \
|
|
sw/source/filter/ww8/writerwordglue \
|
|
sw/source/filter/ww8/wrtw8esh \
|
|
sw/source/filter/ww8/wrtw8nds \
|
|
sw/source/filter/ww8/wrtw8num \
|
|
sw/source/filter/ww8/wrtw8sty \
|
|
sw/source/filter/ww8/wrtww8 \
|
|
sw/source/filter/ww8/wrtww8gr \
|
|
sw/source/filter/ww8/ww8atr \
|
|
sw/source/filter/ww8/ww8glsy \
|
|
sw/source/filter/ww8/ww8graf \
|
|
sw/source/filter/ww8/ww8graf2 \
|
|
sw/source/filter/ww8/ww8par \
|
|
sw/source/filter/ww8/ww8par2 \
|
|
sw/source/filter/ww8/ww8par3 \
|
|
sw/source/filter/ww8/ww8par4 \
|
|
sw/source/filter/ww8/ww8par5 \
|
|
sw/source/filter/ww8/ww8par6 \
|
|
sw/source/filter/ww8/ww8scan \
|
|
sw/source/filter/ww8/ww8toolbar \
|
|
))
|
|
|
|
# vim: set noet sw=4 ts=4:
|