Kaydet (Commit) 9aae8ade authored tarafından Norbert Thiebaud's avatar Norbert Thiebaud

refactoring

üst 1c4101ca
......@@ -25,7 +25,9 @@
#
#*************************************************************************
include ./solenv/inc/gbuild.mk
GBUILDDIR := $(SOLARENV)/gbuild
include $(GBUILDDIR)/gbuild.mk
include $(foreach module,\
framework \
......
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
# SrsPartTarget class
# defined by platform
# gb_SrsPartTarget_RSCTARGET
# gb_SrsPartTarget_RSCCOMMAND
# gb_SrsPartTarget_command_dep
$(call gb_SrsPartTarget_get_target,%) : $(SRCDIR)/% $(gb_Helper_MISCDUMMY) | $(gb_SrsPartTarget_RSCTARGET)
$(call gb_SrsPartTarget_command_dep,$*,$<,$(INCLUDE),$(DEFS))
$(call gb_Helper_abbreviate_dirs_native,\
mkdir -p $(dir $@) && \
RESPONSEFILE=`mktemp -p $(gb_Helper_MISC)` && \
echo "-s \
$(INCLUDE) \
$(DEFS) \
-fp=$@ \
$<" > $${RESPONSEFILE} && \
$(gb_SrsPartTarget_RSCCOMMAND) -presponse @$${RESPONSEFILE} && \
rm -rf $${RESPONSEFILE})
$(call gb_SrsPartTarget_get_dep_target,%) : $(SRCDIR)/%
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && \
echo '$(call gb_SrsPartTarget_get_target,$*) : $(gb_Helper_PHONY)' > $@)
$(call gb_SrsPartTarget_get_dep_target,%) :
$(error unable to find resource definition file $(SRCDIR)/$*)
define gb_SrsPartTarget_SrsPartTarget
endef
# SrsTarget class
gb_SrsTarget_DEFAULTDEFS := $(gb_GLOBALDEFS)
.PHONY : $(call gb_SrsTarget_get_clean_target,%)
$(call gb_SrsTarget_get_clean_target,%) :
$(call gb_Helper_announce,Cleaning up srs $* ...)
-$(call gb_Helper_abbreviate_dirs,\
rm -f $(call gb_SrsTarget_get_target,$*) \
$(call gb_SrsTarget_get_dep_target,$*) \
$(foreach part,$(PARTS),$(call gb_SrsPartTarget_get_target,$(part))) \
$(foreach part,$(PARTS),$(call gb_SrsPartTarget_get_dep_target,$(part))))
define gb_SrsTarget_command_dep
$(call gb_Helper_announce,Collecting dependencies for srs $(2) ...)
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $(1)) && \
cat $(3) > $(1))
endef
$(call gb_SrsTarget_get_target,%) :
$(call gb_SrsTarget_command_dep,$(call gb_SrsTarget_get_dep_target,$*),$*,$(foreach part,$(PARTS),$(call gb_SrsPartTarget_get_dep_target,$(part))))
$(call gb_Helper_announce,Processing srs $* ...)
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && \
cat $^ > $@)
$(call gb_SrsTarget_get_dep_target,%) :
$(call gb_SrsTarget_command_dep,$@,$*,$^)
define gb_SrsTarget_SrsTarget
$(call gb_SrsTarget_get_target,$(1)) : DEFS := $(gb_SrsTarget_DEFAULTDEFS)
$(call gb_SrsTarget_get_target,$(1)) : INCLUDE := $(SOLARINC)
$(call gb_SrsTarget_get_clean_target,$(1)) : PARTS :=
$(call gb_SrsTarget_get_target,$(1)) : PARTS :=
ifeq ($(gb_FULLDEPS),$(true))
include $(call gb_SrsTarget_get_dep_target,$(1))
endif
endef
define gb_SrsTarget_set_defs
$(call gb_SrsTarget_get_target,$(1)) : DEFS := $(2)
$(call gb_SrsTarget_get_dep_target,$(1)) : DEFS := $(2)
endef
define gb_SrsTarget_set_include
$(call gb_SrsTarget_get_target,$(1)) : INCLUDE := $(2)
$(call gb_SrsTarget_get_dep_target,$(1)) : INCLUDE := $(2)
endef
define gb_SrsTarget_add_file
ifeq ($(gb_FULLDEPS),$(true))
$(call gb_SrsTarget_get_dep_target,$(1)) : $(call gb_SrsPartTarget_get_dep_target,$(2))
endif
$(call gb_SrsTarget_get_target,$(1)) : $(call gb_SrsPartTarget_get_target,$(2))
$(call gb_SrsTarget_get_clean_target,$(1)) : PARTS += $(2)
$(call gb_SrsTarget_get_target,$(1)) : PARTS += $(2)
endef
define gb_SrsTarget_add_files
$(foreach file,$(2),$(call gb_SrsTarget_add_file,$(1),$(file)))
endef
# ResTarget
gb_ResTarget_RSCTARGET := $(gb_SrsPartTarget_RSCTARGET)
gb_ResTarget_RSCCOMMAND := $(gb_SrsPartTarget_RSCCOMMAND)
$(call gb_ResTarget_get_clean_target,%) :
$(call gb_Helper_announce,Cleaning up resource $* ...)
$(call gb_Helper_abbreviate_dirs,\
rm -f $(OUTDIR)/bin/$*.res $(call gb_ResTarget_get_target,$*))
$(call gb_ResTarget_get_target,%) : $(gb_Helper_MISCDUMMY) | $(gb_ResTarget_RSCTARGET)
$(call gb_Helper_announce,Building resource $@ ...)
$(call gb_Helper_abbreviate_dirs_native,\
mkdir -p $(dir $@) $(OUTDIR)/bin \
$(dir $(call gb_ResTarget_get_imagelist_target,$(1))) && \
RESPONSEFILE=`mktemp -p $(gb_Helper_MISC)` && \
echo "-r -p \
-lg$(LANGUAGE) \
-fs=$(OUTDIR)/bin/$(LIBRARY)$(LANGUAGE).res \
-lip=$(SRCDIR)/default_images/$(RESLOCATION)/imglst/$(LANGUAGE) \
-lip=$(SRCDIR)/default_images/$(RESLOCATION)/imglst \
-lip=$(SRCDIR)/default_images/$(RESLOCATION)/res/$(LANGUAGE) \
-lip=$(SRCDIR)/default_images/$(RESLOCATION)/res \
-lip=$(SRCDIR)/default_images/$(RESLOCATION) \
-lip=$(SRCDIR)/default_images/res/$(LANGUAGE) \
-lip=$(SRCDIR)/default_images/res \
-subMODULE=$(SRCDIR)/default_images \
-subGLOBALRES=$(SRCDIR)/default_images/res \
-oil=$(dir $(call gb_ResTarget_get_imagelist_target,$(1))) \
-ft=$@ \
$(filter-out $(gb_Helper_MISCDUMMY),$^)" > $${RESPONSEFILE} && \
$(gb_ResTarget_RSCCOMMAND) @$${RESPONSEFILE} && \
rm -f $${RESPONSEFILE})
define gb_ResTarget_ResTarget
$(call gb_ResTarget_get_target,$(1)) : LIBRARY = $(2)
$(call gb_ResTarget_get_target,$(1)) : LANGUAGE = $(3)
$(call gb_ResTarget_get_target,$(1)) : RESLOCATION = $(2)
$(call gb_AllLangResTarget_get_target,$(2)) : $(call gb_ResTarget_get_target,$(1))
$(call gb_AllLangResTarget_get_clean_target,$(2)) : $(call gb_ResTarget_get_clean_target,$(1))
$(call gb_ResTarget_get_imagelist_target,$(1)) : $(call gb_ResTarget_get_target,$(1))
endef
define gb_ResTarget_add_file
$(call gb_ResTarget_get_target,$(1)) : $(2)
endef
define gb_ResTarget_add_one_srs
$(call gb_ResTarget_add_file,$(1),$(call gb_SrsTarget_get_target,$(2)))
$(call gb_ResTarget_get_clean_target,$(1)) : $(call gb_SrsTarget_get_clean_target,$(2))
endef
define gb_ResTarget_add_files
$(foreach file,$(2),\
$(call gb_ResTarget_add_file,$(1),$(file)))
endef
define gb_ResTarget_add_srs
$(foreach srs,$(2),\
$(call gb_ResTarget_add_one_srs,$(1),$(srs)))
endef
define gb_ResTarget_set_reslocation
$(call gb_ResTarget_get_target,$(1)) : RESLOCATION = $(2)
endef
# AllLangResTarget
gb_AllLangResTarget_LANGS := en-US
define gb_AllLangResTarget_set_langs
gb_AllLangResTarget_LANGS := $(1)
endef
$(call gb_AllLangResTarget_get_clean_target,%) :
$(call gb_Helper_abbreviate_dirs,\
rm -f $(call gb_AllLangResTarget_get_target,$*))
$(call gb_AllLangResTarget_get_target,%) :
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && touch $@)
define gb_AllLangResTarget_AllLangResTarget
$(call gb_ResTarget_ResTarget,$(1)en-US,$(1),en-US)
endef
define gb_AllLangResTarget_add_file
$(foreach lang,$(gb_AllLangResTarget_LANGS),\
$(call gb_ResTarget_add_file,$(1)$(lang),$(2)))
endef
define gb_AllLangResTarget_add_one_srs
$(foreach lang,$(gb_AllLangResTarget_LANGS),\
$(call gb_ResTarget_add_one_srs,$(1)$(lang),$(2)))
endef
define gb_AllLangResTarget_add_files
$(foreach file,$(2),\
$(call gb_AllLangResTarget_add_file,$(1),$(file)))
endef
define gb_AllLangResTarget_add_srs
$(foreach srs,$(2),\
$(call gb_AllLangResTarget_add_one_srs,$(1),$(srs)))
endef
define gb_AllLangResTarget_set_reslocation
$(foreach lang,$(gb_AllLangResTarget_LANGS),\
$(call gb_ResTarget_set_reslocation,$(1)$(lang),$(2)))
endef
# vim: set noet sw=4 ts=4:
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
# Executable class
# defined by platform
# gb_Executable_TARGETTYPEFLAGS
# gb_Executable_Executable_platform
.PHONY : $(call gb_Executable_get_clean_target,%)
$(call gb_Executable_get_clean_target,%) :
$(call gb_Helper_abbreviate_dirs,\
rm -f $(call gb_Executable_get_target,$*))
$(call gb_Executable_get_target,%) :
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && cp -pf $< $@)
define gb_Executable_Executable
$(call gb_Executable_Executable__impl,$(1),Executable/$(1)$(gb_Executable_EXT))
endef
define gb_Executable_Executable__impl
$(call gb_LinkTarget_LinkTarget,$(2))
$(call gb_LinkTarget_set_targettype_flags,$(2),$(gb_Executable_TARGETTYPEFLAGS))
$(call gb_Executable_get_target,$(1)) : $(call gb_LinkTarget_get_target,$(2))
$(call gb_Executable_get_clean_target,$(1)) : $(call gb_LinkTarget_get_clean_target,$(2))
$(call gb_Executable_Executable_platform,$(1),$(2))
endef
define gb_Executable_forward_to_Linktarget
gb_Executable_$(1) = $$(call gb_LinkTarget_$(1),Executable/$$(1)$$(gb_Executable_EXT),$$(2))
endef
$(eval $(foreach method,\
add_cobject \
add_cobjects \
add_cxxobject \
add_cxxobjects \
add_exception_objects \
add_noexception_objects \
set_cxxflags \
set_defs \
set_include \
set_ldflags \
set_library_path_flags \
add_linked_libs \
add_linked_static_libs \
add_package_headers \
add_sdi_headers \
,\
$(call gb_Executable_forward_to_Linktarget,$(method))\
))
# vim: set noet sw=4 ts=4:
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
# vars needed from the env/calling makefile
# CVER
# DEBUG
# GBUILDDIR
# INPATH
# JAVA_HOME
# JDKINCS
# LIBXML_CFLAGS
# OS
# PRODUCT
# SOLARINC
# SOLARLIB
# STLPORT_VER
# UPD
# GXX_INCLUDE_PATH (Linux)
# PTHREAD_CFLAGS (Linux)
# SYSTEM_ICU (Linux)
# SYSTEM_JPEG (Linux)
# SYSTEM_LIBXML (Linux)
# USE_SYSTEM_STL (Linux)
SHELL := /bin/sh
ifeq ($(strip $(SOLARSRC)),)
$(error No environment set)
endif
# extend for JDK include (seems only needed in setsolar env?)
SOLARINC += $(JDKINCS)
SRCDIR := $(SOLARSRC)
OUTDIR := $(SOLARVERSION)/$(INPATH)
WORKDIR := $(SOLARVERSION)/$(INPATH)/workdir
# HACK
ifeq ($(OS),WNT)
SRCDIR := $(shell cygpath -u $(SRCDIR))
WORKDIR := $(shell cygpath -u $(WORKDIR))
OUTDIR := $(shell cygpath -u $(OUTDIR))
endif
true := T
false :=
ifneq ($(strip $(PRODUCT)),)
gb_PRODUCT := $(true)
else
gb_PRODUCT := $(false)
endif
ifneq ($(strip $(DEBUG)),)
gb_DEBUGLEVEL := 2
else
ifeq ($(gb_PRODUCT),$(true))
gb_DEBUGLEVEL := 0
else
gb_DEBUGLEVEL := 1
endif
endif
gb_FULLDEPS := $(true)
#gb_FULLDEPS := $(false)
ifeq ($(MAKECMDGOALS),clean)
gb_FULLDEPS := $(false)
endif
include $(GBUILDDIR)/helper.mk
include $(GBUILDDIR)/libnames.mk
gb_Library_TARGETS := $(foreach namescheme,$(gb_Library_NAMESCHEMES),$(gb_Library_$(namescheme)LIBS))
gb_StaticLibrary_TARGETS := $(foreach namescheme,$(gb_StaticLibrary_NAMESCHEMES),$(gb_StaticLibrary_$(namescheme)LIBS))
ifeq ($(OS),LINUX)
include $(GBUILDDIR)/platform/linux.mk
else
ifeq ($(OS),WNT)
include $(GBUILDDIR)/platform/windows.mk
else
ifeq ($(OS),SOLARIS)
include $(SRCDIR)/solenv/inc/platform/solaris.mk
else
$(error unsupported OS: $(OS))
endif
endif
endif
gb_Library_KNOWNLIBS := $(foreach namescheme,$(gb_Library_NAMESCHEMES),$(gb_Library_$(namescheme)LIBS))
gb_StaticLibrary_KNOWNLIBS := $(foreach namescheme,$(gb_StaticLibrary_NAMESCHEMES),$(gb_StaticLibrary_$(namescheme)LIBS))
ifeq ($(USE_SYSTEM_STL),YES)
gb_Library_TARGETS := $(filter-out stl,$(gb_Library_TARGETS))
endif
ifeq ($(SYSTEM_LIBXML),YES)
gb_Library_TARGETS := $(filter-out xml2,$(gb_Library_TARGETS))
endif
ifeq ($(SYSTEM_ICU),YES)
gb_Library_TARGETS := $(filter-out icuuc,$(gb_Library_TARGETS))
endif
gb_GLOBALDEFS := \
-D__DMAKE \
-D_REENTRANT \
-D_USE_NAMESPACE=1 \
-DCUI \
-DENABLE_LAYOUT_EXPERIMENTAL=0 \
-DENABLE_LAYOUT=0 \
-DNEW_SOLAR \
-DOSL_DEBUG_LEVEL=$(gb_DEBUGLEVEL) \
-DSOLAR_JAVA \
-DSTLPORT_VERSION=$(STLPORT_VER) \
-DSUPD=$(UPD) \
-DVCL \
$(gb_OSDEFS) \
$(gb_COMPILERDEFS) \
$(gb_CPUDEFS) \
ifeq ($(gb_PRODUCT),$(true))
gb_GLOBALDEFS += \
-DPRODUCT \
-DPRODUCT_FULL \
else
gb_GLOBALDEFS += \
-DDBG_UTIL \
-D_STLP_DEBUG \
endif
ifeq ($(gb_DEBUGLEVEL),2)
gb_GLOBALDEFS += \
-DDEBUG \
else
gb_GLOBALDEFS += \
-DOPTIMIZE \
-DNDEBUG \
endif
gb_GLOBALDEFS := $(sort $(gb_GLOBALDEFS))
include $(GBUILDDIR)/target_names.mk
# static members declared here because they are used globally
gb_Library_OUTDIRLOCATION := $(OUTDIR)/lib
gb_Library_DLLDIR := $(WORKDIR)/LinkTarget/Library
gb_StaticLibrary_OUTDIRLOCATION := $(OUTDIR)/lib
# We are using a set of scopes that we might as well call classes.
include $(foreach class,\
linktarget\
library\
static_library\
executable\
sdi\
alllangres\
package\
,$(GBUILDDIR)/$(class).mk)
# Module class
gb_Module_ALLMODULES :=
.PHONY : $(call gb_Module_get_clean_target,%)
$(call gb_Module_get_clean_target,%) :
$(call gb_Helper_announce,Cleaning up module $* ...)
-$(call gb_Helper_abbreviate_dirs,\
rm -f $(call gb_Module_get_target,$*))
$(call gb_Module_get_target,%) :
$(call gb_Helper_announce,Completed module $* ...)
-$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && \
touch $@)
define gb_Module_Module
$(call gb_Module_get_target,$(1)) : $(2)
$(call gb_Module_get_clean_target,$(1)) : $$(foreach target,$(2),$(call gb_Helper_get_outdir_clean_target,$$(target)))
gb_Module_ALLMODULES += $(1)
endef
define gb_Module_make_global_targets
include $(SRCDIR)/$(1)/prj/target_module_$(1).mk
.PHONY : all clean
all : $(call gb_Module_get_target,$(1))
clean : $(call gb_Module_get_clean_target,$(1))
.DEFAULT_GOAL := all
endef
define gb_Module_read_includes
include $$(foreach targetdef,$(2),$(SRCDIR)/$(1)/prj/target_$$(targetdef).mk)
endef
# vim: set noet sw=4 ts=4:
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
# Library class
# defined globally in gbuild.mk
# gb_Library_OUTDIRLOCATION := $(OUTDIR)/lib
# gb_Library_DLLDIR := $(WORKDIR)/LinkTarget/Library
# defined by platform
# gb_Library_DEFS
# gb_Library_DLLFILENAMES
# gb_Library_FILENAMES
# gb_Library_TARGETS
# gb_Library_TARGETTYPEFLAGS
# gb_Library_Library_platform
.PHONY : $(WORKDIR)/Clean/OutDir/lib/%$(gb_Library_PLAINEXT)
$(WORKDIR)/Clean/OutDir/lib/%$(gb_Library_PLAINEXT) : $(call gb_LinkTarget_get_clean_target,$(call gb_Library_get_linktargetname,%$(gb_Library_PLAINEXT)))
$(call gb_Helper_abbreviate_dirs,\
rm -f $(OUTDIR)/lib/$*$(gb_Library_PLAINEXT))
$(gb_Library_OUTDIRLOCATION)/%$(gb_Library_PLAINEXT) :
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $@) && cp -pf $< $@)
define gb_Library_Library
ifeq (,$$(findstring $(1),$$(gb_Library_KNOWNLIBS)))
$$(info currently known libraries are: $(sort $(gb_Library_KNOWNLIBS)))
$$(error Library $(1) must be registered in $(GBUILDDIR)/inc/libnames.mk)
endif
$(call gb_Library_Library__impl,$(1),$(call gb_Library_get_linktargetname,$(call gb_Library_get_filename,$(1))))
endef
define gb_Library_Library__impl
$(call gb_LinkTarget_LinkTarget,$(2))
$(call gb_LinkTarget_set_targettype_flags,$(2),$(gb_Library_TARGETTYPEFLAGS))
$(call gb_LinkTarget_set_defs,$(2),\
$$(DEFS) \
$(gb_Library_DEFS) \
)
$(call gb_Library_get_target,$(1)) : $(call gb_LinkTarget_get_target,$(2))
$(call gb_Library_Library_platform,$(1),$(2),$(gb_Library_DLLDIR)/$(call gb_Library_get_dllname,$(1)))
endef
define gb_Library_forward_to_Linktarget
gb_Library_$(1) = $$(call gb_LinkTarget_$(1),$(call gb_Library_get_linktargetname,$$(call gb_Library_get_filename,$$(1))),$$(2))
endef
$(eval $(foreach method,\
add_cobject \
add_cobjects \
add_cxxobject \
add_cxxobjects \
add_exception_objects \
add_noexception_objects \
set_cxxflags \
set_defs \
set_include \
set_ldflags \
set_library_path_flags \
add_linked_libs \
add_linked_static_libs \
add_package_headers \
add_sdi_headers \
,\
$(call gb_Library_forward_to_Linktarget,$(method))\
))
# vim: set noet sw=4 ts=4:
This diff is collapsed.
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
# PackagePart class
$(foreach destination,$(call gb_PackagePart_get_destinations), $(destination)/%) :
mkdir -p $(dir $@) && cp -pf $< $@
define gb_PackagePart_PackagePart
$(OUTDIR)/$(1) : $(2)
endef
# Package class
.PHONY : $(call gb_Package_get_clean_target,%)
$(call gb_Package_get_clean_target,%) :
$(call gb_Helper_announce,Cleaning up package $* ...)
-$(call gb_Helper_abbreviate_dirs,\
rm -f $(FILES))
$(call gb_Package_get_target,%) :
$(call gb_Helper_announce,Copied all for package $* ...)
mkdir -p $(dir $@) && touch $@
define gb_Package_Package
gb_TARGET_PACKAGE_$(1)_SOURCEDIR := $(2)
$(call gb_Package_get_clean_target,$(1)) : FILES := $(call gb_Package_get_target,$(1))
endef
define gb_Package_add_file
$(call gb_Package_get_target,$(1)) : $(OUTDIR)/$(2)
$(call gb_Package_get_clean_target,$(1)) : FILES += $(OUTDIR)/$(2)
$(call gb_PackagePart_PackagePart,$(2),$$(gb_TARGET_PACKAGE_$(1)_SOURCEDIR)/$(3))
$(OUTDIR)/$(2) : $$(gb_TARGET_PACKAGE_$(1)_SOURCEDIR)/$(3)
endef
# vim: set noet sw=4 ts=4:
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2009 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************