17871dc3eSAndrew Rist#************************************************************** 27871dc3eSAndrew Rist# 37871dc3eSAndrew Rist# Licensed to the Apache Software Foundation (ASF) under one 47871dc3eSAndrew Rist# or more contributor license agreements. See the NOTICE file 57871dc3eSAndrew Rist# distributed with this work for additional information 67871dc3eSAndrew Rist# regarding copyright ownership. The ASF licenses this file 77871dc3eSAndrew Rist# to you under the Apache License, Version 2.0 (the 87871dc3eSAndrew Rist# "License"); you may not use this file except in compliance 97871dc3eSAndrew Rist# with the License. You may obtain a copy of the License at 107871dc3eSAndrew Rist# 117871dc3eSAndrew Rist# http://www.apache.org/licenses/LICENSE-2.0 127871dc3eSAndrew Rist# 137871dc3eSAndrew Rist# Unless required by applicable law or agreed to in writing, 147871dc3eSAndrew Rist# software distributed under the License is distributed on an 157871dc3eSAndrew Rist# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 167871dc3eSAndrew Rist# KIND, either express or implied. See the License for the 177871dc3eSAndrew Rist# specific language governing permissions and limitations 187871dc3eSAndrew Rist# under the License. 197871dc3eSAndrew Rist# 207871dc3eSAndrew Rist#************************************************************** 217871dc3eSAndrew Rist 227871dc3eSAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweirGUI := UNX 25cdf0e10cSrcweirCOM := C52 26cdf0e10cSrcweir 27cdf0e10cSrcweirgb_MKTEMP := mktemp -t gbuild.XXXXXX 28cdf0e10cSrcweir 29cdf0e10cSrcweirgb_CC := cc 30cdf0e10cSrcweirgb_CXX := CC 31cdf0e10cSrcweirgb_GCCP := cc 32cdf0e10cSrcweirgb_AR := ar 33cdf0e10cSrcweirgb_AWK := /usr/xpg4/bin/awk 34cdf0e10cSrcweirgb_CLASSPATHSEP := : 35cdf0e10cSrcweir 36cdf0e10cSrcweir# use CC/CXX if they are nondefaults 37cdf0e10cSrcweirifneq ($(origin CC),default) 38cdf0e10cSrcweirgb_CC := $(CC) 39cdf0e10cSrcweirgb_GCCP := $(CC) 40cdf0e10cSrcweirendif 41cdf0e10cSrcweirifneq ($(origin CXX),default) 42cdf0e10cSrcweirgb_CXX := $(CXX) 43cdf0e10cSrcweirendif 44cdf0e10cSrcweir 45cdf0e10cSrcweirgb_OSDEFS := \ 46cdf0e10cSrcweir -D$(OS) \ 47cdf0e10cSrcweir -D$(GUI) \ 48cdf0e10cSrcweir -DSYSV \ 49cdf0e10cSrcweir -DSUN \ 50cdf0e10cSrcweir -DSUN4 \ 51cdf0e10cSrcweir -D_REENTRANT \ 52cdf0e10cSrcweir -D_POSIX_PTHREAD_SEMANTICS \ 53cdf0e10cSrcweir -D_PTHREADS \ 54cdf0e10cSrcweir -DUNIX \ 55cdf0e10cSrcweir 56cdf0e10cSrcweirgb_COMPILERDEFS := \ 57cdf0e10cSrcweir -D$(COM) \ 58cdf0e10cSrcweir -DCPPU_ENV=sunpro5 \ 59cdf0e10cSrcweir 60cdf0e10cSrcweirgb_CPUDEFS := -D$(CPUNAME) 61cdf0e10cSrcweirifeq ($(CPUNAME),SPARC) 62cdf0e10cSrcweirgb_CPUDEFS += -D__sparcv8plus 63cdf0e10cSrcweirendif 64cdf0e10cSrcweir 65cdf0e10cSrcweirgb_CFLAGS := \ 66cdf0e10cSrcweir -temp=/tmp \ 67cdf0e10cSrcweir -KPIC \ 68cdf0e10cSrcweir -mt \ 69cdf0e10cSrcweir -xldscope=hidden \ 70cdf0e10cSrcweir -xCC \ 71cdf0e10cSrcweir -xc99=none \ 72cdf0e10cSrcweir 73cdf0e10cSrcweirgb_CXXFLAGS := \ 74cdf0e10cSrcweir -temp=/tmp \ 75cdf0e10cSrcweir -KPIC \ 76cdf0e10cSrcweir -mt \ 77cdf0e10cSrcweir -xldscope=hidden \ 78cdf0e10cSrcweir -features=no%altspell \ 79cdf0e10cSrcweir -library=no%Cstd \ 80cdf0e10cSrcweir +w2 \ 81cdf0e10cSrcweir -erroff=doubunder,identexpected,inllargeuse,inllargeint,notemsource,reftotemp,truncwarn,wnoretvalue,anonnotype \ 82cdf0e10cSrcweir 83cdf0e10cSrcweirifneq ($(EXTERNAL_WARNINGS_NOT_ERRORS),TRUE) 84cdf0e10cSrcweirgb_CFLAGS_WERROR := -errwarn=%all 85cdf0e10cSrcweirgb_CXXFLAGS_WERROR := -xwe 86cdf0e10cSrcweirendif 87cdf0e10cSrcweir 88cdf0e10cSrcweirgb_LinkTarget_EXCEPTIONFLAGS := \ 89cdf0e10cSrcweir -DEXCEPTIONS_ON \ 90cdf0e10cSrcweir 91cdf0e10cSrcweirgb_LinkTarget_NOEXCEPTIONFLAGS := \ 92cdf0e10cSrcweir -DEXCEPTIONS_OFF \ 93cdf0e10cSrcweir -noex \ 94cdf0e10cSrcweir 95cdf0e10cSrcweirgb_LinkTarget_LDFLAGS := \ 96cdf0e10cSrcweir $(subst -L../lib , ,$(SOLARLIB)) \ 97cdf0e10cSrcweir -temp=/tmp \ 98cdf0e10cSrcweir -w \ 99cdf0e10cSrcweir -mt \ 100cdf0e10cSrcweir -Bdirect \ 101cdf0e10cSrcweir -z defs \ 102cdf0e10cSrcweir -z combreloc \ 103cdf0e10cSrcweir -norunpath \ 104cdf0e10cSrcweir -PIC \ 105cdf0e10cSrcweir -library=no%Cstd \ 106cdf0e10cSrcweir 107cdf0e10cSrcweirifeq ($(gb_DEBUGLEVEL),2) 108cdf0e10cSrcweirgb_COMPILEROPTFLAGS := 109cdf0e10cSrcweirelse 110cdf0e10cSrcweirifeq ($(CPUNAME),INTEL) 111cdf0e10cSrcweirgb_COMPILEROPTFLAGS := -xarch=generic -xO3 112cdf0e10cSrcweirelse # ifeq ($(CPUNAME),SPARC) 113cdf0e10cSrcweir# -m32 -xarch=sparc restrict target to 32 bit sparc 114cdf0e10cSrcweir# -xO3 optimization level 3 115cdf0e10cSrcweir# -xspace don't do optimizations which do increase binary size 116cdf0e10cSrcweir# -xprefetch=yes do prefetching (helps on UltraSparc III) 117cdf0e10cSrcweirgb_COMPILEROPTFLAGS := -m32 -xarch=sparc -xO3 -xspace -xprefetch=yes 118cdf0e10cSrcweirendif 119cdf0e10cSrcweirendif 120cdf0e10cSrcweir 121cdf0e10cSrcweirgb_COMPILERNOOPTFLAGS := 122cdf0e10cSrcweir 123cdf0e10cSrcweir# Helper class 124cdf0e10cSrcweir 125cdf0e10cSrcweirgb_Helper_abbreviate_dirs_native = $(gb_Helper_abbreviate_dirs) 126cdf0e10cSrcweir 127cdf0e10cSrcweir# convert parametters filesystem root to native notation 128cdf0e10cSrcweir# does some real work only on windows, make sure not to 129cdf0e10cSrcweir# break the dummy implementations on unx* 130cdf0e10cSrcweirdefine gb_Helper_convert_native 131cdf0e10cSrcweir$(1) 132cdf0e10cSrcweirendef 133cdf0e10cSrcweir 134cdf0e10cSrcweir 135cdf0e10cSrcweir# CObject class 136cdf0e10cSrcweir 137cdf0e10cSrcweirdefine gb_CObject__command 138cdf0e10cSrcweir$(call gb_Output_announce,$(2),$(true),C ,3) 139cdf0e10cSrcweir$(call gb_Helper_abbreviate_dirs,\ 140cdf0e10cSrcweir mkdir -p $(dir $(1)) && \ 141cdf0e10cSrcweir rm -f $(call gb_CObject_get_dep_target,$(2)) && \ 142cdf0e10cSrcweir mkdir -p $(dir $(call gb_CObject_get_dep_target,$(2))) && \ 143cdf0e10cSrcweir $(gb_CC) \ 144cdf0e10cSrcweir -c $(3) \ 145cdf0e10cSrcweir -o $(1) \ 146cdf0e10cSrcweir -xMMD \ 147cdf0e10cSrcweir -xMF $(call gb_CObject_get_dep_target,$(2)) \ 148cdf0e10cSrcweir $(DEFS) $(CFLAGS) \ 149cdf0e10cSrcweir -I$(dir $(3)) \ 150cdf0e10cSrcweir $(INCLUDE)) 151cdf0e10cSrcweirendef 152cdf0e10cSrcweir 153cdf0e10cSrcweir 154cdf0e10cSrcweir# CxxObject class 155cdf0e10cSrcweir 156cdf0e10cSrcweirdefine gb_CxxObject__command 157cdf0e10cSrcweir$(call gb_Output_announce,$(2),$(true),CXX,3) 158cdf0e10cSrcweir$(call gb_Helper_abbreviate_dirs,\ 159cdf0e10cSrcweir mkdir -p $(dir $(1)) && \ 160cdf0e10cSrcweir mkdir -p $(dir $(call gb_CxxObject_get_dep_target,$(2))) && \ 161cdf0e10cSrcweir $(gb_CXX) \ 162cdf0e10cSrcweir $(DEFS) $(CXXFLAGS) \ 163cdf0e10cSrcweir -c $(3) \ 164cdf0e10cSrcweir -o $(1) \ 165cdf0e10cSrcweir -xMMD \ 166cdf0e10cSrcweir -xMF $(call gb_CxxObject_get_dep_target,$(2)) \ 167cdf0e10cSrcweir -I$(dir $(3)) \ 168cdf0e10cSrcweir $(INCLUDE_STL) $(INCLUDE)) 169cdf0e10cSrcweirendef 170cdf0e10cSrcweir 171cdf0e10cSrcweir 172cdf0e10cSrcweir# LinkTarget class 173cdf0e10cSrcweir 174cdf0e10cSrcweirdefine gb_LinkTarget__get_rpath_for_layer 175cdf0e10cSrcweir$(patsubst $(1):%,%,$(filter $(1):%,$(gb_LinkTarget__RPATHS))) 176cdf0e10cSrcweirendef 177cdf0e10cSrcweir 178cdf0e10cSrcweirgb_LinkTarget__RPATHS := \ 179cdf0e10cSrcweir URELIB:\dORIGIN \ 180cdf0e10cSrcweir UREBIN:\dORIGIN/../lib:\dORIGIN \ 181cdf0e10cSrcweir OOO:\dORIGIN:\dORIGIN/../ure-link/lib \ 182cdf0e10cSrcweir BRAND:\dORIGIN:\dORIGIN/../basis-link/program:\dORIGIN/../basis-link/ure-link/lib \ 183cdf0e10cSrcweir SDKBIN:\dORIGIN/../../ure-link/lib \ 184cdf0e10cSrcweir NONEBIN:\dORIGIN/../lib:\dORIGIN \ 185cdf0e10cSrcweir 186cdf0e10cSrcweirgb_LinkTarget_CFLAGS := $(gb_CFLAGS) $(gb_CFLAGS_WERROR) $(gb_COMPILEROPTFLAGS) 187cdf0e10cSrcweirgb_LinkTarget_CXXFLAGS := $(gb_CXXFLAGS) $(gb_CXXFLAGS_WERROR) 188cdf0e10cSrcweir 189cdf0e10cSrcweirifeq ($(gb_DEBUGLEVEL),2) 190cdf0e10cSrcweirgb_LinkTarget_CXXFLAGS += -g 191cdf0e10cSrcweirgb_LinkTarget_CFLAGS += -g 192cdf0e10cSrcweirendif 193cdf0e10cSrcweir 194cdf0e10cSrcweirgb_LinkTarget_INCLUDE := $(filter-out %/stl, $(subst -I. , ,$(SOLARINC))) 195cdf0e10cSrcweirgb_LinkTarget_INCLUDE_STL := $(filter %/stl, $(subst -I. , ,$(SOLARINC))) 196cdf0e10cSrcweir 197cdf0e10cSrcweirdefine gb_LinkTarget__command_dynamiclink 198cdf0e10cSrcweir$(call gb_Helper_abbreviate_dirs,\ 199cdf0e10cSrcweir mkdir -p $(dir $(1)) && \ 200cdf0e10cSrcweir $(gb_CXX) \ 201*dfce871fSDamjan Jovanovic $(if $(filter Library,$(TARGETTYPE)),$(gb_Library_TARGETTYPEFLAGS)) \ 202cdf0e10cSrcweir $(subst \d,$$,$(RPATH)) $(LDFLAGS) \ 203cdf0e10cSrcweir $(patsubst lib%.so,-l%,$(foreach lib,$(LINKED_LIBS),$(call gb_Library_get_filename,$(lib)))) \ 20444c25570SAndre Fischer $(patsubst %,-l%,$(EXTERNAL_LIBS)) \ 205cdf0e10cSrcweir $(foreach object,$(COBJECTS),$(call gb_CObject_get_target,$(object))) \ 206cdf0e10cSrcweir $(foreach object,$(CXXOBJECTS),$(call gb_CxxObject_get_target,$(object))) \ 207cdf0e10cSrcweir $(foreach object,$(GENCXXOBJECTS),$(call gb_GenCxxObject_get_target,$(object))) \ 208cdf0e10cSrcweir $(foreach lib,$(LINKED_STATIC_LIBS),$(call gb_StaticLibrary_get_target,$(lib))) \ 209cdf0e10cSrcweir -o $(1)) 210cdf0e10cSrcweirendef 211cdf0e10cSrcweir 212cdf0e10cSrcweirdefine gb_LinkTarget__command_staticlink 213cdf0e10cSrcweir$(call gb_Helper_abbreviate_dirs,\ 214cdf0e10cSrcweir mkdir -p $(dir $(1)) && \ 215cdf0e10cSrcweir $(gb_AR) -rsu $(1) \ 216cdf0e10cSrcweir $(foreach object,$(COBJECTS),$(call gb_CObject_get_target,$(object))) \ 217cdf0e10cSrcweir $(foreach object,$(CXXOBJECTS),$(call gb_CxxObject_get_target,$(object))) \ 218cdf0e10cSrcweir $(foreach object,$(GENCXXOBJECTS),$(call gb_GenCxxObject_get_target,$(object))) \ 219cdf0e10cSrcweir 2> /dev/null) 220cdf0e10cSrcweirendef 221cdf0e10cSrcweir 222cdf0e10cSrcweirdefine gb_LinkTarget__command 223cdf0e10cSrcweir$(call gb_Output_announce,$(2),$(true),LNK,4) 224*dfce871fSDamjan Jovanovic$(if $(filter Library GoogleTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1))) 225cdf0e10cSrcweir$(if $(filter StaticLibrary,$(TARGETTYPE)),$(call gb_LinkTarget__command_staticlink,$(1))) 226cdf0e10cSrcweirendef 227cdf0e10cSrcweir 228cdf0e10cSrcweir# Library class 229cdf0e10cSrcweir 230cdf0e10cSrcweirgb_Library_DEFS := 231cdf0e10cSrcweirgb_Library_TARGETTYPEFLAGS := -Bdynamic -z text -G 232cdf0e10cSrcweirgb_Library_SYSPRE := lib 233cdf0e10cSrcweirgb_Library_UNOVERPRE := $(gb_Library_SYSPRE)uno_ 234cdf0e10cSrcweirgb_Library_PLAINEXT := .so 235cdf0e10cSrcweirgb_Library_RTEXT := C52$(gb_Library_PLAINEXT) 236cdf0e10cSrcweirifeq ($(gb_PRODUCT),$(true)) 237cdf0e10cSrcweirgb_Library_STLEXT := port_sunpro$(gb_Library_PLAINEXT) 238cdf0e10cSrcweirelse 239cdf0e10cSrcweirgb_Library_STLEXT := port_sunpro_debug$(gb_Library_PLAINEXT) 240cdf0e10cSrcweirendif 241cdf0e10cSrcweir 242cdf0e10cSrcweirifeq ($(CPUNAME),INTEL) 2435f9a7a39SHerbert Dürrgb_Library_OOOEXT := $(gb_Library_PLAINEXT) 244cdf0e10cSrcweirgb_Library_UNOEXT := .uno$(gb_Library_PLAINEXT) 245cdf0e10cSrcweirelse # ifeq ($(CPUNAME),SPARC) 2465f9a7a39SHerbert Dürrgb_Library_OOOEXT := $(gb_Library_PLAINEXT) 247cdf0e10cSrcweirgb_Library_UNOEXT := .uno$(gb_Library_PLAINEXT) 248cdf0e10cSrcweirendif 249cdf0e10cSrcweir 250cdf0e10cSrcweirgb_STDLIBS := \ 251cdf0e10cSrcweir Crun \ 252cdf0e10cSrcweir m \ 253cdf0e10cSrcweir c \ 254cdf0e10cSrcweir 255cdf0e10cSrcweirgb_Library_PLAINLIBS_NONE += \ 256cdf0e10cSrcweir $(gb_STDLIBS) \ 257cdf0e10cSrcweir dl \ 258cdf0e10cSrcweir freetype \ 259cdf0e10cSrcweir jpeg \ 260cdf0e10cSrcweir pthread \ 261cdf0e10cSrcweir X11 \ 262cdf0e10cSrcweir Xext \ 263cdf0e10cSrcweir SM \ 264cdf0e10cSrcweir ICE \ 265*dfce871fSDamjan Jovanovic z 266cdf0e10cSrcweir 267cdf0e10cSrcweirgb_Library_FILENAMES := \ 268cdf0e10cSrcweir $(foreach lib,$(gb_Library_OOOLIBS),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_OOOEXT)) \ 269cdf0e10cSrcweir $(foreach lib,$(gb_Library_PLAINLIBS_NONE),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_PLAINEXT)) \ 270cdf0e10cSrcweir $(foreach lib,$(gb_Library_PLAINLIBS_URE),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_PLAINEXT)) \ 271cdf0e10cSrcweir $(foreach lib,$(gb_Library_PLAINLIBS_OOO),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_PLAINEXT)) \ 272cdf0e10cSrcweir $(foreach lib,$(gb_Library_RTLIBS),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_RTEXT)) \ 273cdf0e10cSrcweir $(foreach lib,$(gb_Library_RTVERLIBS),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_RTEXT)) \ 274cdf0e10cSrcweir $(foreach lib,$(gb_Library_STLLIBS),$(lib):$(gb_Library_SYSPRE)$(lib)$(gb_Library_STLEXT)) \ 275cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOLIBS_URE),$(lib):$(lib)$(gb_Library_UNOEXT)) \ 276cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOLIBS_OOO),$(lib):$(lib)$(gb_Library_UNOEXT)) \ 277cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOVERLIBS),$(lib):$(gb_Library_UNOVERPRE)$(lib)$(gb_Library_PLAINEXT)) \ 278cdf0e10cSrcweir 279cdf0e10cSrcweir 280cdf0e10cSrcweirgb_Library_LAYER := \ 281cdf0e10cSrcweir $(foreach lib,$(gb_Library_OOOLIBS),$(lib):OOO) \ 282cdf0e10cSrcweir $(foreach lib,$(gb_Library_PLAINLIBS_URE),$(lib):URELIB) \ 283cdf0e10cSrcweir $(foreach lib,$(gb_Library_PLAINLIBS_OOO),$(lib):OOO) \ 284cdf0e10cSrcweir $(foreach lib,$(gb_Library_RTLIBS),$(lib):OOO) \ 285cdf0e10cSrcweir $(foreach lib,$(gb_Library_RTVERLIBS),$(lib):URELIB) \ 286cdf0e10cSrcweir $(foreach lib,$(gb_Library_STLLIBS),$(lib):URELIB) \ 287cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOLIBS_URE),$(lib):URELIB) \ 288cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOLIBS_OOO),$(lib):OOO) \ 289cdf0e10cSrcweir $(foreach lib,$(gb_Library_UNOVERLIBS),$(lib):URELIB) \ 290cdf0e10cSrcweir 291cdf0e10cSrcweirdefine gb_Library_get_rpath 292cdf0e10cSrcweir'-R$(call gb_LinkTarget__get_rpath_for_layer,$(call gb_Library_get_layer,$(1)))' 293cdf0e10cSrcweirendef 294cdf0e10cSrcweir 295cdf0e10cSrcweirdefine gb_Library_Library_platform 296cdf0e10cSrcweir$(call gb_LinkTarget_get_target,$(2)) : RPATH := $(call gb_Library_get_rpath,$(1)) 297cdf0e10cSrcweir 298cdf0e10cSrcweirendef 299cdf0e10cSrcweir 300cdf0e10cSrcweir 301cdf0e10cSrcweir# StaticLibrary class 302cdf0e10cSrcweir 303cdf0e10cSrcweirgb_StaticLibrary_DEFS := 304cdf0e10cSrcweirgb_StaticLibrary_SYSPRE := lib 305cdf0e10cSrcweirgb_StaticLibrary_PLAINEXT := .a 306cdf0e10cSrcweirgb_StaticLibrary_JPEGEXT := lib$(gb_StaticLibrary_PLAINEXT) 307cdf0e10cSrcweir 308cdf0e10cSrcweirgb_StaticLibrary_FILENAMES := \ 309cdf0e10cSrcweir $(foreach lib,$(gb_StaticLibrary_JPEGLIBS),$(lib):$(gb_StaticLibrary_SYSPRE)$(lib)$(gb_StaticLibrary_JPEGEXT)) \ 310cdf0e10cSrcweir $(foreach lib,$(gb_StaticLibrary_PLAINLIBS),$(lib):$(gb_StaticLibrary_SYSPRE)$(lib)$(gb_StaticLibrary_PLAINEXT)) \ 311cdf0e10cSrcweir 312cdf0e10cSrcweirgb_StaticLibrary_StaticLibrary_platform = 313cdf0e10cSrcweir 314cdf0e10cSrcweir 315cdf0e10cSrcweir# Executable class 316cdf0e10cSrcweir 317cdf0e10cSrcweirgb_Executable_EXT := 318cdf0e10cSrcweir 319cdf0e10cSrcweirgb_Executable_LAYER := \ 320cdf0e10cSrcweir $(foreach exe,$(gb_Executable_UREBIN),$(exe):UREBIN) \ 321cdf0e10cSrcweir $(foreach exe,$(gb_Executable_SDK),$(exe):SDKBIN) \ 322cdf0e10cSrcweir $(foreach exe,$(gb_Executable_OOO),$(exe):OOO) \ 323cdf0e10cSrcweir $(foreach exe,$(gb_Executable_BRAND),$(exe):BRAND) \ 324cdf0e10cSrcweir $(foreach exe,$(gb_Executable_NONE),$(exe):NONEBIN) \ 325cdf0e10cSrcweir 326cdf0e10cSrcweir 327cdf0e10cSrcweirdefine gb_Executable_get_rpath 328cdf0e10cSrcweir'-R$(call gb_LinkTarget__get_rpath_for_layer,$(call gb_Executable_get_layer,$(1)))' 329cdf0e10cSrcweirendef 330cdf0e10cSrcweir 331cdf0e10cSrcweirdefine gb_Executable_Executable_platform 332cdf0e10cSrcweir$(call gb_LinkTarget_get_target,$(2)) : RPATH := $(call gb_Executable_get_rpath,$(1)) 333cdf0e10cSrcweir 334cdf0e10cSrcweirendef 335cdf0e10cSrcweir 336cdf0e10cSrcweir 337e75d772dSDamjan Jovanovic# GoogleTest class 338e75d772dSDamjan Jovanovic 339e75d772dSDamjan Jovanovicgb_GoogleTest_GTESTPRECOMMAND := LD_LIBRARY_PATH=$(OUTDIR)/lib 340e75d772dSDamjan Jovanovicgb_GoogleTest_get_filename = $(1)$(gb_Executable_EXT) 341e75d772dSDamjan Jovanovic 342e75d772dSDamjan Jovanovicdefine gb_GoogleTest_GoogleTest_platform 343e75d772dSDamjan Jovanovic$(call gb_LinkTarget_get_target,$(2)) : RPATH := 344e75d772dSDamjan Jovanovicendef 345e75d772dSDamjan Jovanovic 346cdf0e10cSrcweir# JunitTest class 347cdf0e10cSrcweir 348cdf0e10cSrcweirdefine gb_JunitTest_JunitTest_platform 349cdf0e10cSrcweir$(call gb_JunitTest_get_target,$(1)) : DEFS := \ 350cdf0e10cSrcweir -Dorg.openoffice.test.arg.soffice="$$$${OOO_TEST_SOFFICE:-path:$(OUTDIR)/installation/opt/openoffice.org3/program/soffice}" \ 351cdf0e10cSrcweir -Dorg.openoffice.test.arg.env=LD_LIBRARY_PATH \ 352cdf0e10cSrcweir -Dorg.openoffice.test.arg.user=file://$(call gb_JunitTest_get_userdir,$(1)) \ 353cdf0e10cSrcweir 354cdf0e10cSrcweirendef 355cdf0e10cSrcweir 356cdf0e10cSrcweir# SdiTarget class 357cdf0e10cSrcweir 358cdf0e10cSrcweirgb_SdiTarget_SVIDLPRECOMMAND := LD_LIBRARY_PATH=$(OUTDIR)/lib 359cdf0e10cSrcweir 360cdf0e10cSrcweir# SrsPartMergeTarget 361cdf0e10cSrcweir 362cdf0e10cSrcweirgb_SrsPartMergeTarget_TRANSEXPRECOMMAND := LD_LIBRARY_PATH=$(OUTDIR)/lib 363cdf0e10cSrcweir 364cdf0e10cSrcweir# SrsPartTarget class 365cdf0e10cSrcweir 366cdf0e10cSrcweirgb_SrsPartTarget_RSCTARGET := $(OUTDIR)/bin/rsc 367cdf0e10cSrcweirgb_SrsPartTarget_RSCCOMMAND := LD_LIBRARY_PATH=$(OUTDIR)/lib SOLARBINDIR=$(OUTDIR)/bin $(gb_SrsPartTarget_RSCTARGET) 368cdf0e10cSrcweir 369cdf0e10cSrcweir# Sun cc/CC support -xM1/-xMF flags, but unfortunately refuse input files that 370cdf0e10cSrcweir# do not have the right suffix, so use makedepend here... 371cdf0e10cSrcweirdefine gb_SrsPartTarget__command_dep 372cdf0e10cSrcweir$(call gb_Helper_abbreviate_dirs_native,\ 373cdf0e10cSrcweir $(OUTDIR)/bin/makedepend$(gb_Executable_EXT) \ 374cdf0e10cSrcweir $(INCLUDE) \ 375cdf0e10cSrcweir $(DEFS) \ 376cdf0e10cSrcweir $(2) \ 377cdf0e10cSrcweir -f - \ 378cdf0e10cSrcweir | $(gb_AWK) -f $(GBUILDDIR)/processdeps.awk \ 379cdf0e10cSrcweir -v OBJECTFILE=$(call gb_SrsPartTarget_get_target,$(1)) \ 380cdf0e10cSrcweir -v OUTDIR=$(OUTDIR)/ \ 381cdf0e10cSrcweir -v WORKDIR=$(WORKDIR)/ \ 382cdf0e10cSrcweir -v SRCDIR=$(SRCDIR)/ \ 383cdf0e10cSrcweir -v REPODIR=$(REPODIR)/ \ 384cdf0e10cSrcweir > $(call gb_SrsPartTarget_get_dep_target,$(1))) 385cdf0e10cSrcweirendef 386cdf0e10cSrcweir 387cdf0e10cSrcweir 388cdf0e10cSrcweir# ComponentTarget 389cdf0e10cSrcweir 390cdf0e10cSrcweirgb_XSLTPROCPRECOMMAND := LD_LIBRARY_PATH=$(OUTDIR)/lib 391cdf0e10cSrcweirgb_Library_COMPONENTPREFIXES := \ 392cdf0e10cSrcweir OOO:vnd.sun.star.expand:\dOOO_BASE_DIR/program/ \ 393cdf0e10cSrcweir URELIB:vnd.sun.star.expand:\dURE_INTERNAL_LIB_DIR/ \ 394cdf0e10cSrcweir 395cdf0e10cSrcweir 396cdf0e10cSrcweir# vim: set noet sw=4 ts=4: 397