1*b1cdbd2cSJim Jagielski# ************************************************************* 2*b1cdbd2cSJim Jagielski# 3*b1cdbd2cSJim Jagielski# Licensed to the Apache Software Foundation (ASF) under one 4*b1cdbd2cSJim Jagielski# or more contributor license agreements. See the NOTICE file 5*b1cdbd2cSJim Jagielski# distributed with this work for additional information 6*b1cdbd2cSJim Jagielski# regarding copyright ownership. The ASF licenses this file 7*b1cdbd2cSJim Jagielski# to you under the Apache License, Version 2.0 (the 8*b1cdbd2cSJim Jagielski# "License"); you may not use this file except in compliance 9*b1cdbd2cSJim Jagielski# with the License. You may obtain a copy of the License at 10*b1cdbd2cSJim Jagielski# 11*b1cdbd2cSJim Jagielski# http://www.apache.org/licenses/LICENSE-2.0 12*b1cdbd2cSJim Jagielski# 13*b1cdbd2cSJim Jagielski# Unless required by applicable law or agreed to in writing, 14*b1cdbd2cSJim Jagielski# software distributed under the License is distributed on an 15*b1cdbd2cSJim Jagielski# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*b1cdbd2cSJim Jagielski# KIND, either express or implied. See the License for the 17*b1cdbd2cSJim Jagielski# specific language governing permissions and limitations 18*b1cdbd2cSJim Jagielski# under the License. 19*b1cdbd2cSJim Jagielski# 20*b1cdbd2cSJim Jagielski# ************************************************************* 21*b1cdbd2cSJim Jagielski# This is the root DMAKE startup file. 22*b1cdbd2cSJim Jagielski# 23*b1cdbd2cSJim Jagielski# Definitions common to all environments are given at the root. 24*b1cdbd2cSJim Jagielski# Definitions parameterized at the root have their parameters specified 25*b1cdbd2cSJim Jagielski# in sub-makefiles which are included based on the values of the three 26*b1cdbd2cSJim Jagielski# make variables: 27*b1cdbd2cSJim Jagielski# 28*b1cdbd2cSJim Jagielski# OS - core operating system flavour 29*b1cdbd2cSJim Jagielski# 30*b1cdbd2cSJim Jagielski# See the file 'summary', found in this directory for a list of 31*b1cdbd2cSJim Jagielski# environments supported by this release. 32*b1cdbd2cSJim Jagielski 33*b1cdbd2cSJim Jagielski# Disable warnings for macros given on the command line but redefined here. 34*b1cdbd2cSJim Jagielski__.silent !:= $(.SILENT) # Preserve user's .SILENT flag 35*b1cdbd2cSJim Jagielski.SILENT !:= yes 36*b1cdbd2cSJim Jagielski.NOTABS !:= yes 37*b1cdbd2cSJim Jagielski.ERROR : 38*b1cdbd2cSJim Jagielski @echo '---* $(MKFILENAME) *---' 39*b1cdbd2cSJim Jagielski 40*b1cdbd2cSJim Jagielski# Define the directory separator string. 41*b1cdbd2cSJim Jagielski/ *= $(DIRSEPSTR) 42*b1cdbd2cSJim Jagielski 43*b1cdbd2cSJim Jagielski.IMPORT .IGNORE : .EVERYTHING 44*b1cdbd2cSJim Jagielski 45*b1cdbd2cSJim Jagielski.IF "$(TNR)" == "" 46*b1cdbd2cSJim Jagielski 47*b1cdbd2cSJim JagielskiCALLMACROS:=$(MAKEMACROS) 48*b1cdbd2cSJim Jagielski.EXPORT : CALLMACROS 49*b1cdbd2cSJim Jagielski 50*b1cdbd2cSJim JagielskiCALLTARGETS=$(MAKETARGETS) 51*b1cdbd2cSJim Jagielski.ENDIF # "$(TNR)" == "" 52*b1cdbd2cSJim Jagielski 53*b1cdbd2cSJim Jagielski.INCLUDEDIRS : $(DMAKE_INC) $(SOLARVERSION)$/$(INPATH)$/inc$(UPDMINOREXT) $(SOLARENV)$/inc 54*b1cdbd2cSJim Jagielski 55*b1cdbd2cSJim Jagielski# Grab key definitions from the environment 56*b1cdbd2cSJim Jagielski# .IMPORT .IGNORE : OS TMPDIR UPD INPATH OUTPATH GUI COM EX CLASSPATH PRODUCT GUIBASE SOLARENV SOLARVER GUIENV CPU CPUNAME CVER GVER COMPATH LIB INCLUDE TR SORT UNIQ ROOTDIR SED AWK TOUCH IENV ILIB PRODUCT_ENV COMEX UPD BUILD DEVROOT VCL SO3 ENVCFLAGS 57*b1cdbd2cSJim Jagielski 58*b1cdbd2cSJim Jagielski.IF "$(OS)" == "" || "$(OS)" == "Windows_NT" 59*b1cdbd2cSJim Jagielski.ERROR : ; @echo Forced error: Environment variable OS has to be set for OOo build! 60*b1cdbd2cSJim JagielskiOS_variable_needed 61*b1cdbd2cSJim Jagielski.ENDIF 62*b1cdbd2cSJim Jagielski 63*b1cdbd2cSJim Jagielski# Customize macro definitions based on seting of OS. 64*b1cdbd2cSJim Jagielski# This must come before the default macro definitions which follow. 65*b1cdbd2cSJim Jagielski.IF "$(OS)" == "OS2" 66*b1cdbd2cSJim Jagielski.INCLUDE: $(INCFILENAME:d)OS2/macros.mk 67*b1cdbd2cSJim Jagielski.ELIF "$(OS)" == "WNT" 68*b1cdbd2cSJim Jagielski.INCLUDE: $(INCFILENAME:d)wnt/macros.mk 69*b1cdbd2cSJim Jagielski.END 70*b1cdbd2cSJim Jagielski 71*b1cdbd2cSJim Jagielski# ----------------- Default Control Macro definitions ----------------------- 72*b1cdbd2cSJim Jagielski# Select appropriate defaults for basic macros 73*b1cdbd2cSJim JagielskiMAKE *= $(MAKECMD) $(MFLAGS) 74*b1cdbd2cSJim JagielskiTMPDIR *:= $/tmp 75*b1cdbd2cSJim JagielskiDIVFILE *= $(TMPFILE) 76*b1cdbd2cSJim Jagielski 77*b1cdbd2cSJim JagielskiMAXLINELENGTH = 65530 78*b1cdbd2cSJim Jagielski 79*b1cdbd2cSJim Jagielski# Recipe execution configuration 80*b1cdbd2cSJim JagielskiSHELL := $(OOO_SHELL) 81*b1cdbd2cSJim JagielskiSHELLFLAGS := -c 82*b1cdbd2cSJim JagielskiSHELLMETAS := !"\#$$%&'()*;<=>?[\]`{{|}}~ 83*b1cdbd2cSJim Jagielski # the colon (":") utility is typically only available as a shell built-in, 84*b1cdbd2cSJim Jagielski # so it should be included in SHELLMETAS; however, this would result in very 85*b1cdbd2cSJim Jagielski # many false positives on Windows where ":" is used in drive letter notation 86*b1cdbd2cSJim JagielskiGROUPSHELL := $(SHELL) 87*b1cdbd2cSJim JagielskiGROUPFLAGS := 88*b1cdbd2cSJim JagielskiGROUPSUFFIX := 89*b1cdbd2cSJim Jagielski 90*b1cdbd2cSJim Jagielski# Intermediate target removal configuration 91*b1cdbd2cSJim JagielskiRM *:= rm 92*b1cdbd2cSJim JagielskiRMFLAGS *= -f 93*b1cdbd2cSJim JagielskiRMTARGET *= $< 94*b1cdbd2cSJim Jagielski 95*b1cdbd2cSJim Jagielski# Default recipe that is used to remove intermediate targets. 96*b1cdbd2cSJim Jagielski.REMOVE :; #echo dummy remove #$(RM) $(RMFLAGS) $(RMTARGET) 97*b1cdbd2cSJim Jagielski#.REMOVE :; echo $(RM) $(RMFLAGS) $(RMTARGET) 98*b1cdbd2cSJim Jagielski 99*b1cdbd2cSJim Jagielski# Directory caching configuration. 100*b1cdbd2cSJim Jagielski.DIRCACHE *:= yes 101*b1cdbd2cSJim Jagielski.DIRCACHERESPCASE *:= yes 102*b1cdbd2cSJim Jagielski 103*b1cdbd2cSJim Jagielski# Define the special NULL Prerequisite 104*b1cdbd2cSJim JagielskiNULLPRQ *:= __.NULLPRQ 105*b1cdbd2cSJim Jagielski 106*b1cdbd2cSJim Jagielski# Primary suffixes in common use 107*b1cdbd2cSJim JagielskiE *:= # Executables 108*b1cdbd2cSJim Jagielski 109*b1cdbd2cSJim Jagielski# Other Compilers, Tools and their flags 110*b1cdbd2cSJim JagielskiMV *:= mv # File rename command 111*b1cdbd2cSJim Jagielski 112*b1cdbd2cSJim Jagielski 113*b1cdbd2cSJim Jagielski# Finally, define the default construction strategy 114*b1cdbd2cSJim Jagielski.ROOT .PHONY .NOSTATE .SEQUENTIAL :- .INIT .TARGETS .DONE; 115*b1cdbd2cSJim Jagielski.INIT .DONE .PHONY: $(NULLPRQ); 116*b1cdbd2cSJim Jagielski 117*b1cdbd2cSJim Jagielski# Define the NULL Prerequisite as having no recipe. 118*b1cdbd2cSJim Jagielski$(NULLPRQ) .PHONY :; 119*b1cdbd2cSJim Jagielski 120*b1cdbd2cSJim Jagielski# Reset warnings back to previous setting. 121*b1cdbd2cSJim Jagielski.SILENT !:= $(__.silent) 122*b1cdbd2cSJim Jagielski 123*b1cdbd2cSJim Jagielski# Check for a Local project file, gets parsed before user makefile. 124*b1cdbd2cSJim Jagielski.INCLUDE .IGNORE .NOINFER: "project.mk" 125*b1cdbd2cSJim Jagielski 126*b1cdbd2cSJim Jagielski.MAKEFILES :- makefile.mk MAKEFILE.MK $(CONFIG_PROJECT)$/makefile.rc $(SOLARENV)$/inc$/found_no.mk 127*b1cdbd2cSJim Jagielski 128*b1cdbd2cSJim JagielskiLANG=C 129*b1cdbd2cSJim Jagielski.EXPORT : LANG 130