Makefile (a893be29) | Makefile (4dc2a9a2) |
---|---|
1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 13 unchanged lines hidden (view full) --- 22# Builds the complextoolbarcontrols C++ component example of the SDK. 23 24PRJ=../../.. 25SETTINGS=$(PRJ)/settings 26 27include $(SETTINGS)/settings.mk 28include $(SETTINGS)/std.mk 29include $(SETTINGS)/dk.mk | 1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 13 unchanged lines hidden (view full) --- 22# Builds the complextoolbarcontrols C++ component example of the SDK. 23 24PRJ=../../.. 25SETTINGS=$(PRJ)/settings 26 27include $(SETTINGS)/settings.mk 28include $(SETTINGS)/std.mk 29include $(SETTINGS)/dk.mk |
30include $(SETTINGS)/platform.mk |
|
30 31# Define non-platform/compiler specific settings 32COMP_NAME=complextoolbarcontrols 33COMP_IMPL_NAME=$(COMP_NAME).uno.$(SHAREDLIB_EXT) 34OUT_COMP_INC=$(OUT_INC)/$(COMP_NAME) 35OUT_COMP_GEN=$(OUT_MISC)/$(COMP_NAME) 36OUT_COMP_SLO=$(OUT_SLO)/$(COMP_NAME) 37COMP_PACKAGE = $(OUT_BIN)/$(COMP_NAME).$(UNOOXT_EXT) 38COMP_PACKAGE_URL = $(subst \\,\,"$(COMP_PACKAGE_DIR)$(PS)$(COMP_NAME).$(UNOOXT_EXT)") 39COMP_UNOPKG_MANIFEST = $(OUT_COMP_GEN)/$(COMP_NAME)/META-INF/manifest.xml | 31 32# Define non-platform/compiler specific settings 33COMP_NAME=complextoolbarcontrols 34COMP_IMPL_NAME=$(COMP_NAME).uno.$(SHAREDLIB_EXT) 35OUT_COMP_INC=$(OUT_INC)/$(COMP_NAME) 36OUT_COMP_GEN=$(OUT_MISC)/$(COMP_NAME) 37OUT_COMP_SLO=$(OUT_SLO)/$(COMP_NAME) 38COMP_PACKAGE = $(OUT_BIN)/$(COMP_NAME).$(UNOOXT_EXT) 39COMP_PACKAGE_URL = $(subst \\,\,"$(COMP_PACKAGE_DIR)$(PS)$(COMP_NAME).$(UNOOXT_EXT)") 40COMP_UNOPKG_MANIFEST = $(OUT_COMP_GEN)/$(COMP_NAME)/META-INF/manifest.xml |
41COMP_UNOPKG_DESCRIPTION = $(OUT_COMP_GEN)/$(COMPONENT_NAME)/description.xml |
|
40COMP_MAPFILE = $(OUT_COMP_GEN)/$(COMP_NAME).uno.map 41COMP_COMPONENTS = $(OUT_COMP_GEN)/$(COMP_NAME).components 42COMP_REGISTERFLAG = $(OUT_MISC)/cpp_$(COMP_NAME)_register_component.flag 43COMP_TYPEFLAG = $(OUT_MISC)/cpp_$(COMP_NAME)_types.flag 44 45CXXFILES = \ 46 MyProtocolHandler.cxx \ 47 ListenerHelper.cxx \ 48 exports.cxx 49 50SLOFILES = $(patsubst %.cxx,$(OUT_COMP_SLO)/%.$(OBJ_EXT),$(CXXFILES)) 51 | 42COMP_MAPFILE = $(OUT_COMP_GEN)/$(COMP_NAME).uno.map 43COMP_COMPONENTS = $(OUT_COMP_GEN)/$(COMP_NAME).components 44COMP_REGISTERFLAG = $(OUT_MISC)/cpp_$(COMP_NAME)_register_component.flag 45COMP_TYPEFLAG = $(OUT_MISC)/cpp_$(COMP_NAME)_types.flag 46 47CXXFILES = \ 48 MyProtocolHandler.cxx \ 49 ListenerHelper.cxx \ 50 exports.cxx 51 52SLOFILES = $(patsubst %.cxx,$(OUT_COMP_SLO)/%.$(OBJ_EXT),$(CXXFILES)) 53 |
52# Add OSL_DEBUG_LEVEL to compiler the flags (for OSL_TRACE et. al.) 53ifeq "$(DEBUG)" "yes" 54CC_FLAGS += -DOSL_DEBUG_LEVEL=2 55endif 56 | |
57# Targets 58.PHONY: ALL 59ALL : \ 60 Example 61 62include $(SETTINGS)/stdtarget.mk 63 64$(OUT_COMP_SLO)/%.$(OBJ_EXT) : %.cxx $(SDKTYPEFLAG) --- 22 unchanged lines hidden (view full) --- 87 -$(MKDIR) $(subst /,$(PS),$(@D)) 88 $(LINK) $(COMP_LINK_FLAGS) $(LINK_LIBS) -o $@ $(SLOFILES) \ 89 $(CPPUHELPERLIB) $(CPPULIB) $(SALLIB) $(STC++LIB) $(CPPUHELPERDYLIB) $(CPPUDYLIB) $(SALDYLIB) 90ifeq "$(OS)" "MACOSX" 91 $(INSTALL_NAME_URELIBS) $@ 92endif 93endif 94 | 54# Targets 55.PHONY: ALL 56ALL : \ 57 Example 58 59include $(SETTINGS)/stdtarget.mk 60 61$(OUT_COMP_SLO)/%.$(OBJ_EXT) : %.cxx $(SDKTYPEFLAG) --- 22 unchanged lines hidden (view full) --- 84 -$(MKDIR) $(subst /,$(PS),$(@D)) 85 $(LINK) $(COMP_LINK_FLAGS) $(LINK_LIBS) -o $@ $(SLOFILES) \ 86 $(CPPUHELPERLIB) $(CPPULIB) $(SALLIB) $(STC++LIB) $(CPPUHELPERDYLIB) $(CPPUDYLIB) $(SALDYLIB) 87ifeq "$(OS)" "MACOSX" 88 $(INSTALL_NAME_URELIBS) $@ 89endif 90endif 91 |
92# rule for extension description.xml 93$(COMP_UNOPKG_DESCRIPTION) : description.xml 94 -$(MKDIR) $(subst /,$(PS),$(@D)) 95 $(SDK_CAT) $< | $(SDK_SED) -e "s/#EXTENSION_PLATFORM#/$(EXTENSION_PLATFORM)/" > $@ 96 |
|
95# rule for component package manifest 96$(OUT_COMP_GEN)/%/manifest.xml : 97 -$(MKDIR) $(subst /,$(PS),$(@D)) 98 @echo $(OSEP)?xml version="$(QM)1.0$(QM)" encoding="$(QM)UTF-8$(QM)"?$(CSEP) > $@ 99 @echo $(OSEP)!DOCTYPE manifest:manifest PUBLIC "$(QM)-//OpenOffice.org//DTD Manifest 1.0//EN$(QM)" "$(QM)Manifest.dtd$(QM)"$(CSEP) >> $@ 100 @echo $(OSEP)manifest:manifest xmlns:manifest="$(QM)http://openoffice.org/2001/manifest$(QM)"$(CSEP) >> $@ 101 @echo $(SQM) $(SQM)$(OSEP)manifest:file-entry manifest:media-type="$(QM)application/vnd.sun.star.configuration-data$(QM)" >> $@ 102 @echo $(SQM) $(SQM)manifest:full-path="$(QM)Addons.xcu$(QM)"/$(CSEP) >> $@ --- 13 unchanged lines hidden (view full) --- 116 @echo $(SQM) $(SQM)$(OSEP)component loader="$(QM)com.sun.star.loader.SharedLibrary$(QM)" uri="$(QM)$(UNOPKG_PLATFORM)/$(COMP_IMPL_NAME)$(QM)"$(CSEP) >> $@ 117 @echo $(SQM) $(SQM)$(OSEP)implementation name="$(QM)vnd.demo.Impl.ProtocolHandler$(QM)"$(CSEP) >> $@ 118 @echo $(SQM) $(SQM)$(OSEP)service name="$(QM)vnd.demo.ProtocolHandler$(QM)"/$(CSEP) >> $@ 119 @echo $(SQM) $(SQM)$(OSEP)/implementation$(CSEP) >> $@ 120 @echo $(SQM) $(SQM)$(OSEP)/component$(CSEP) >> $@ 121 @echo $(OSEP)/components$(CSEP) >> $@ 122 123# rule for component package file | 97# rule for component package manifest 98$(OUT_COMP_GEN)/%/manifest.xml : 99 -$(MKDIR) $(subst /,$(PS),$(@D)) 100 @echo $(OSEP)?xml version="$(QM)1.0$(QM)" encoding="$(QM)UTF-8$(QM)"?$(CSEP) > $@ 101 @echo $(OSEP)!DOCTYPE manifest:manifest PUBLIC "$(QM)-//OpenOffice.org//DTD Manifest 1.0//EN$(QM)" "$(QM)Manifest.dtd$(QM)"$(CSEP) >> $@ 102 @echo $(OSEP)manifest:manifest xmlns:manifest="$(QM)http://openoffice.org/2001/manifest$(QM)"$(CSEP) >> $@ 103 @echo $(SQM) $(SQM)$(OSEP)manifest:file-entry manifest:media-type="$(QM)application/vnd.sun.star.configuration-data$(QM)" >> $@ 104 @echo $(SQM) $(SQM)manifest:full-path="$(QM)Addons.xcu$(QM)"/$(CSEP) >> $@ --- 13 unchanged lines hidden (view full) --- 118 @echo $(SQM) $(SQM)$(OSEP)component loader="$(QM)com.sun.star.loader.SharedLibrary$(QM)" uri="$(QM)$(UNOPKG_PLATFORM)/$(COMP_IMPL_NAME)$(QM)"$(CSEP) >> $@ 119 @echo $(SQM) $(SQM)$(OSEP)implementation name="$(QM)vnd.demo.Impl.ProtocolHandler$(QM)"$(CSEP) >> $@ 120 @echo $(SQM) $(SQM)$(OSEP)service name="$(QM)vnd.demo.ProtocolHandler$(QM)"/$(CSEP) >> $@ 121 @echo $(SQM) $(SQM)$(OSEP)/implementation$(CSEP) >> $@ 122 @echo $(SQM) $(SQM)$(OSEP)/component$(CSEP) >> $@ 123 @echo $(OSEP)/components$(CSEP) >> $@ 124 125# rule for component package file |
124$(COMP_PACKAGE) : $(SHAREDLIB_OUT)/$(COMP_IMPL_NAME) Addons.xcu ProtocolHandler.xcu $(COMP_UNOPKG_MANIFEST) $(COMP_COMPONENTS) | 126$(COMP_PACKAGE) : $(SHAREDLIB_OUT)/$(COMP_IMPL_NAME) Addons.xcu ProtocolHandler.xcu $(COMP_UNOPKG_MANIFEST) $(COMP_COMPONENTS) $(COMP_UNOPKG_DESCRIPTION) |
125 -$(MKDIR) $(subst /,$(PS),$(@D)) && $(DEL) $(subst \\,\,$(subst /,$(PS),$@)) 126 -$(MKDIR) $(subst /,$(PS),$(OUT_COMP_GEN)/$(UNOPKG_PLATFORM)) 127 $(COPY) $(subst /,$(PS),$<) $(subst /,$(PS),$(OUT_COMP_GEN)/$(UNOPKG_PLATFORM)) | 127 -$(MKDIR) $(subst /,$(PS),$(@D)) && $(DEL) $(subst \\,\,$(subst /,$(PS),$@)) 128 -$(MKDIR) $(subst /,$(PS),$(OUT_COMP_GEN)/$(UNOPKG_PLATFORM)) 129 $(COPY) $(subst /,$(PS),$<) $(subst /,$(PS),$(OUT_COMP_GEN)/$(UNOPKG_PLATFORM)) |
128 cd $(subst /,$(PS),$(OUT_COMP_GEN)) && $(SDK_ZIP) -u ../../bin/$(@F) $(COMP_NAME).components | 130 cd $(subst /,$(PS),$(OUT_COMP_GEN)) && $(SDK_ZIP) -u ../../bin/$(@F) $(COMP_NAME).components description.xml |
129 cd $(subst /,$(PS),$(OUT_COMP_GEN)) && $(SDK_ZIP) -u ../../bin/$(@F) $(UNOPKG_PLATFORM)/$(<F) 130 $(SDK_ZIP) -u $@ Addons.xcu ProtocolHandler.xcu logo_small.png logo_big.png 131 cd $(subst /,$(PS),$(OUT_COMP_GEN)/$(subst .$(UNOOXT_EXT),,$(@F))) && $(SDK_ZIP) -u ../../../bin/$(@F) META-INF/manifest.xml 132 133$(COMP_REGISTERFLAG) : $(COMP_PACKAGE) 134ifeq "$(SDK_AUTO_DEPLOYMENT)" "YES" 135 -$(DEL) $(subst \\,\,$(subst /,$(PS),$@)) 136 $(DEPLOYTOOL) $(COMP_PACKAGE_URL) --- 29 unchanged lines hidden --- | 131 cd $(subst /,$(PS),$(OUT_COMP_GEN)) && $(SDK_ZIP) -u ../../bin/$(@F) $(UNOPKG_PLATFORM)/$(<F) 132 $(SDK_ZIP) -u $@ Addons.xcu ProtocolHandler.xcu logo_small.png logo_big.png 133 cd $(subst /,$(PS),$(OUT_COMP_GEN)/$(subst .$(UNOOXT_EXT),,$(@F))) && $(SDK_ZIP) -u ../../../bin/$(@F) META-INF/manifest.xml 134 135$(COMP_REGISTERFLAG) : $(COMP_PACKAGE) 136ifeq "$(SDK_AUTO_DEPLOYMENT)" "YES" 137 -$(DEL) $(subst \\,\,$(subst /,$(PS),$@)) 138 $(DEPLOYTOOL) $(COMP_PACKAGE_URL) --- 29 unchanged lines hidden --- |