diff --git a/etc/bashrc b/etc/bashrc index c8e659d8fd..c04bd12599 100644 --- a/etc/bashrc +++ b/etc/bashrc @@ -79,7 +79,7 @@ export WM_PRECISION_OPTION=DP export WM_LABEL_SIZE=32 # [WM_COMPILE_OPTION] - Optimised(default), debug, profiling, other: -# = Opt | Debug | Prof +# = Opt | Dbg | Debug | Prof export WM_COMPILE_OPTION=Opt # [WM_COMPILE_CONTROL] - additional control for compiler rules diff --git a/etc/cshrc b/etc/cshrc index f117dad892..068b2e5ca1 100644 --- a/etc/cshrc +++ b/etc/cshrc @@ -79,7 +79,7 @@ setenv WM_PRECISION_OPTION DP setenv WM_LABEL_SIZE 32 # [WM_COMPILE_OPTION] - Optimised(default), debug, profiling, other: -# = Opt | Debug | Prof +# = Opt | Dbg | Debug | Prof setenv WM_COMPILE_OPTION Opt # [WM_COMPILE_CONTROL] - additional control for compiler rules diff --git a/wmake/makefiles/general b/wmake/makefiles/general index a4d6e11cf3..19e5ac4165 100644 --- a/wmake/makefiles/general +++ b/wmake/makefiles/general @@ -93,8 +93,8 @@ EXE = $(WM_PROJECT).out # Standalone executable (default which is to be overridden) SEXE = a.out -#DEBUG $(info "EXE_SO = ${EXE_SO}") -#DEBUG $(info "EXT_EXE = ${EXT_EXE}") +#DEBUG: $(info "EXE_SO = $(EXE_SO)") +#DEBUG: $(info "EXT_EXE = $(EXT_EXE)") #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Clang/c b/wmake/rules/General/Clang/c index efd501e007..34b55bee96 100644 --- a/wmake/rules/General/Clang/c +++ b/wmake/rules/General/Clang/c @@ -1,10 +1,16 @@ -SUFFIXES += .c +#------------------------------------------------------------------------------ +# clang compiler +#------------------------------------------------------------------------------ +SUFFIXES += .c -cc = clang$(COMPILER_VERSION) +cc := clang$(COMPILER_VERSION) -cARCH = -cDBUG = -cOPT = -O2 -cWARN = -Wall +cARCH := +cDBUG := +cOPT := -O2 +cWARN := -Wall + +# Tuning +sinclude $(GENERAL_RULES)/common/c$(WM_COMPILE_OPTION) #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Clang/c++ b/wmake/rules/General/Clang/c++ index 28d18859e7..a389b8c992 100644 --- a/wmake/rules/General/Clang/c++ +++ b/wmake/rules/General/Clang/c++ @@ -1,12 +1,14 @@ #------------------------------------------------------------------------------ -SUFFIXES += .C .cc .cpp .cxx +# clang compiler +#------------------------------------------------------------------------------ +SUFFIXES += .C .cc .cpp .cxx -CC = clang++$(COMPILER_VERSION) -std=c++14 +CC := clang++$(COMPILER_VERSION) -std=c++14 -c++ARCH = -c++DBUG = -c++OPT = -O2 -ptFLAGS = -DNoRepository -ftemplate-depth-100 +c++ARCH := +c++DBUG := +c++OPT := -O2 +ptFLAGS := -DNoRepository -ftemplate-depth-100 c++WARN = \ -Wall -Wextra -Wold-style-cast \ @@ -26,4 +28,7 @@ c++LESSWARN = \ -Wno-tautological-overlap-compare \ -Wno-#pragma-messages +# Tuning +sinclude $(GENERAL_RULES)/common/c++$(WM_COMPILE_OPTION) + #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Gcc/c b/wmake/rules/General/Gcc/c index e8407942b3..e43a85bd55 100644 --- a/wmake/rules/General/Gcc/c +++ b/wmake/rules/General/Gcc/c @@ -1,10 +1,16 @@ -SUFFIXES += .c +#------------------------------------------------------------------------------ +# gcc compiler +#------------------------------------------------------------------------------ +SUFFIXES += .c -cc = gcc$(COMPILER_VERSION) +cc := gcc$(COMPILER_VERSION) -cARCH = -cDBUG = -cOPT = -O2 -cWARN = -Wall +cARCH := +cDBUG := +cOPT := -O2 +cWARN := -Wall + +# Tuning +sinclude $(GENERAL_RULES)/common/c$(WM_COMPILE_OPTION) #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Gcc/c++ b/wmake/rules/General/Gcc/c++ index c88dbfe9be..1ccc6dd61a 100644 --- a/wmake/rules/General/Gcc/c++ +++ b/wmake/rules/General/Gcc/c++ @@ -4,14 +4,14 @@ # # NOTE if your system gcc is new enough can simply use c++14 too. #------------------------------------------------------------------------------ -SUFFIXES += .C .cc .cpp .cxx +SUFFIXES += .C .cc .cpp .cxx -CC = g++$(COMPILER_VERSION) -std=c++11 +CC := g++$(COMPILER_VERSION) -std=c++11 -c++ARCH = -c++DBUG = -c++OPT = -O2 -ptFLAGS = -DNoRepository -ftemplate-depth-100 +c++ARCH := +c++DBUG := +c++OPT := -O2 +ptFLAGS := -DNoRepository -ftemplate-depth-100 c++WARN = \ -Wall -Wextra -Wold-style-cast \ @@ -24,4 +24,7 @@ c++LESSWARN = \ -Wno-deprecated-declarations \ -fpermissive +# Tuning +sinclude $(GENERAL_RULES)/common/c++$(WM_COMPILE_OPTION) + #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Icc/c b/wmake/rules/General/Icc/c index 46a064ccfe..287a92a526 100644 --- a/wmake/rules/General/Icc/c +++ b/wmake/rules/General/Icc/c @@ -1,10 +1,16 @@ -SUFFIXES += .c +#------------------------------------------------------------------------------ +# Intel compiler +#------------------------------------------------------------------------------ +SUFFIXES += .c -cc = icc$(COMPILER_VERSION) +cc := icc$(COMPILER_VERSION) -cARCH = -cDBUG = -cOPT = -O2 -cWARN = +cARCH := +cDBUG := +cOPT := -O2 +cWARN := + +# Tuning +sinclude $(GENERAL_RULES)/common/c$(WM_COMPILE_OPTION) #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Icc/c++ b/wmake/rules/General/Icc/c++ index 4e13545245..d6448eaec5 100644 --- a/wmake/rules/General/Icc/c++ +++ b/wmake/rules/General/Icc/c++ @@ -1,14 +1,14 @@ #------------------------------------------------------------------------------ -# Intel compiler is new enough to support c++14 +# Intel compiler #------------------------------------------------------------------------------ -SUFFIXES += .C .cc .cpp .cxx +SUFFIXES += .C .cc .cpp .cxx -CC = icpc$(COMPILER_VERSION) -std=c++14 +CC := icpc$(COMPILER_VERSION) -std=c++14 -c++ARCH = -c++DBUG = -c++OPT = -O2 -ptFLAGS = -DNoRepository +c++ARCH := +c++DBUG := +c++OPT := -O2 +ptFLAGS := -DNoRepository c++WARN = \ -Wall -Wextra \ @@ -20,4 +20,7 @@ c++WARN = \ c++LESSWARN = \ -diag-disable 1224,2026,2305 +# Tuning +sinclude $(GENERAL_RULES)/common/c++$(WM_COMPILE_OPTION) + #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Icx/c b/wmake/rules/General/Icx/c index e329f9fe24..ae6b258dec 100644 --- a/wmake/rules/General/Icx/c +++ b/wmake/rules/General/Icx/c @@ -1,10 +1,16 @@ -SUFFIXES += .c +#------------------------------------------------------------------------------ +# Intel compiler +#------------------------------------------------------------------------------ +SUFFIXES += .c -cc = icx$(COMPILER_VERSION) +cc := icx$(COMPILER_VERSION) -cARCH = -cDBUG = -cOPT = -O2 -cWARN = +cARCH := +cDBUG := +cOPT := -O2 +cWARN := + +# Tuning +sinclude $(GENERAL_RULES)/common/c$(WM_COMPILE_OPTION) #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Icx/c++ b/wmake/rules/General/Icx/c++ index b6b831f599..d8c51bc12c 100644 --- a/wmake/rules/General/Icx/c++ +++ b/wmake/rules/General/Icx/c++ @@ -1,14 +1,14 @@ #------------------------------------------------------------------------------ -# Intel compiler is new enough to support c++14 +# Intel compiler #------------------------------------------------------------------------------ -SUFFIXES += .C .cc .cpp .cxx +SUFFIXES += .C .cc .cpp .cxx -CC = icpx$(COMPILER_VERSION) -std=c++14 +CC := icpx$(COMPILER_VERSION) -std=c++14 -c++ARCH = -c++DBUG = -c++OPT = -O2 -ptFLAGS = -DNoRepository +c++ARCH := +c++DBUG := +c++OPT := -O2 +ptFLAGS := -DNoRepository c++WARN = \ -Wall -Wextra \ @@ -21,4 +21,7 @@ c++WARN = \ c++LESSWARN = \ -diag-disable 1224,2026,2305 +# Tuning +sinclude $(GENERAL_RULES)/common/c++$(WM_COMPILE_OPTION) + #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Nvidia/c b/wmake/rules/General/Nvidia/c index 42648c606d..a9d1782bb0 100644 --- a/wmake/rules/General/Nvidia/c +++ b/wmake/rules/General/Nvidia/c @@ -1,13 +1,16 @@ #------------------------------------------------------------------------------ -# Nvidia compilers +# Nvidia compiler #------------------------------------------------------------------------------ -SUFFIXES += .c +SUFFIXES += .c -cc = nvc$(COMPILER_VERSION) +cc := nvc$(COMPILER_VERSION) -cARCH = -cDBUG = -cOPT = -O2 -cWARN = +cARCH := +cDBUG := +cOPT := -O2 +cWARN := + +# Tuning +sinclude $(GENERAL_RULES)/common/c$(WM_COMPILE_OPTION) #------------------------------------------------------------------------------ diff --git a/wmake/rules/General/Nvidia/c++ b/wmake/rules/General/Nvidia/c++ index 22ef41972b..1724ede82b 100644 --- a/wmake/rules/General/Nvidia/c++ +++ b/wmake/rules/General/Nvidia/c++ @@ -1,14 +1,14 @@ #------------------------------------------------------------------------------ -# Nvidia compilers +# Nvidia compiler #------------------------------------------------------------------------------ -SUFFIXES += .C .cc .cpp .cxx +SUFFIXES += .C .cc .cpp .cxx -CC = nvc++$(COMPILER_VERSION) -std=c++14 +CC := nvc++$(COMPILER_VERSION) -std=c++14 -c++ARCH = -c++DBUG = -c++OPT = -O2 -ptFLAGS = -DNoRepository +c++ARCH := +c++DBUG := +c++OPT := -O2 +ptFLAGS := -DNoRepository c++WARN = \ -Wall -Wextra \ @@ -18,6 +18,10 @@ c++WARN = \ # Less restrictive warnings (eg, for flex++, CGAL, etc.) c++LESSWARN = +# Tuning +sinclude $(GENERAL_RULES)/common/c++$(WM_COMPILE_OPTION) + +#------------------------------------------------------------------------------ # Warnings # -------- # Run with --display_error_number to get numbers diff --git a/wmake/rules/General/common/c++Dbg b/wmake/rules/General/common/c++Dbg new file mode 100644 index 0000000000..623fd4ff01 --- /dev/null +++ b/wmake/rules/General/common/c++Dbg @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +c++DBUG := -g -DFULLDEBUG +c++OPT := -O3 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/c++Debug b/wmake/rules/General/common/c++Debug new file mode 100644 index 0000000000..ca51460ab7 --- /dev/null +++ b/wmake/rules/General/common/c++Debug @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +c++DBUG := -g -DFULLDEBUG +c++OPT := -O0 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/c++Opt b/wmake/rules/General/common/c++Opt new file mode 100644 index 0000000000..0bad80aa2e --- /dev/null +++ b/wmake/rules/General/common/c++Opt @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +c++DBUG := +c++OPT := -O3 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/c++Prof b/wmake/rules/General/common/c++Prof new file mode 100644 index 0000000000..455ebfedc3 --- /dev/null +++ b/wmake/rules/General/common/c++Prof @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +c++DBUG := -pg +c++OPT := -O2 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/cDbg b/wmake/rules/General/common/cDbg new file mode 100644 index 0000000000..de9be9f222 --- /dev/null +++ b/wmake/rules/General/common/cDbg @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +cDBUG := -g -DFULLDEBUG +cOPT := -O3 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/cDebug b/wmake/rules/General/common/cDebug new file mode 100644 index 0000000000..bef839523f --- /dev/null +++ b/wmake/rules/General/common/cDebug @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +cDBUG := -g -DFULLDEBUG +cOPT := -O0 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/cOpt b/wmake/rules/General/common/cOpt new file mode 100644 index 0000000000..180876140b --- /dev/null +++ b/wmake/rules/General/common/cOpt @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +cDBUG := +cOPT := -O3 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/common/cProf b/wmake/rules/General/common/cProf new file mode 100644 index 0000000000..1ba23f3d6a --- /dev/null +++ b/wmake/rules/General/common/cProf @@ -0,0 +1,6 @@ +#------------------------------------------------------------------------------ + +cDBUG := -pg +cOPT := -O2 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/General/general b/wmake/rules/General/general index 9681a12b26..bb63668862 100644 --- a/wmake/rules/General/general +++ b/wmake/rules/General/general @@ -34,7 +34,7 @@ endif # Default compilation is 'Opt' - never permit an empty value ifeq (,$(WM_COMPILE_OPTION)) - WM_COMPILE_OPTION = Opt + WM_COMPILE_OPTION := Opt endif # Older macro for (shell) branching diff --git a/wmake/rules/General/transform b/wmake/rules/General/transform index 16a4336dee..82e8a358ff 100644 --- a/wmake/rules/General/transform +++ b/wmake/rules/General/transform @@ -1,10 +1,13 @@ #----------------------------*- makefile-gmake -*------------------------------ # The dependency generation program +# 1. wmkdepend : Ragel-based +# 2. wmkdep : Flex-based (slower, ulimit problem) +# 3. makeDepend : cpp -M (for testing only) -WMKDEP := $(WMAKE_BIN)/wmkdepend # 1. Ragel-based -# WMKDEP := $(WMAKE_BIN)/wmkdep # 2. Flex-based (slower, ulimit problem) -# WMKDEP := $(WM_SCRIPTS)/makeDepend # 3. cpp -M (for testing only) +WMKDEP := $(WMAKE_BIN)/wmkdepend +# WMKDEP := $(WMAKE_BIN)/wmkdep +# WMKDEP := $(WM_SCRIPTS)/makeDepend WMKDEP_FLAGS := -eWM_PROJECT_DIR -eWM_THIRD_PARTY_DIR diff --git a/wmake/rules/darwin64Clang/c b/wmake/rules/darwin64Clang/c index 70c7e06576..86e96faa1f 100644 --- a/wmake/rules/darwin64Clang/c +++ b/wmake/rules/darwin64Clang/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cARCH = -m64 -ftrapping-math +cARCH := -m64 -ftrapping-math -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/darwin64Clang/c++ b/wmake/rules/darwin64Clang/c++ index 8c2eeba107..935efb2a80 100644 --- a/wmake/rules/darwin64Clang/c++ +++ b/wmake/rules/darwin64Clang/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -c++ARCH = -m64 -pthread -ftrapping-math +c++ARCH := -m64 -pthread -ftrapping-math -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/darwin64Clang/c++Debug b/wmake/rules/darwin64Clang/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/darwin64Clang/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/darwin64Clang/c++Opt b/wmake/rules/darwin64Clang/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/darwin64Clang/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/darwin64Clang/c++Prof b/wmake/rules/darwin64Clang/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/darwin64Clang/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/darwin64Clang/cDebug b/wmake/rules/darwin64Clang/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/darwin64Clang/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/darwin64Clang/cOpt b/wmake/rules/darwin64Clang/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/darwin64Clang/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/darwin64Clang/cProf b/wmake/rules/darwin64Clang/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/darwin64Clang/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Amd/c b/wmake/rules/linux64Amd/c index 4c9ccb90a4..c3def79541 100644 --- a/wmake/rules/linux64Amd/c +++ b/wmake/rules/linux64Amd/c @@ -3,10 +3,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cARCH = -m64 +cARCH := -m64 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Amd/c++ b/wmake/rules/linux64Amd/c++ index dc505aea43..94db8dcc46 100644 --- a/wmake/rules/linux64Amd/c++ +++ b/wmake/rules/linux64Amd/c++ @@ -2,9 +2,11 @@ # AMD compiler - a clang variant include $(GENERAL_RULES)/Clang/c++ -c++ARCH = -m64 -pthread +c++ARCH := -m64 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Amd/c++Debug b/wmake/rules/linux64Amd/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linux64Amd/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linux64Amd/c++Opt b/wmake/rules/linux64Amd/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linux64Amd/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linux64Amd/c++Prof b/wmake/rules/linux64Amd/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Amd/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Amd/cDebug b/wmake/rules/linux64Amd/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linux64Amd/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linux64Amd/cOpt b/wmake/rules/linux64Amd/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Amd/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Amd/cProf b/wmake/rules/linux64Amd/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Amd/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Clang/c b/wmake/rules/linux64Clang/c index bba9283dc2..6df77aa155 100644 --- a/wmake/rules/linux64Clang/c +++ b/wmake/rules/linux64Clang/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cARCH = -m64 +cARCH := -m64 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Clang/c++ b/wmake/rules/linux64Clang/c++ index 13ddf7f566..2f4fabbb82 100644 --- a/wmake/rules/linux64Clang/c++ +++ b/wmake/rules/linux64Clang/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -c++ARCH = -m64 -pthread +c++ARCH := -m64 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Clang/c++Debug b/wmake/rules/linux64Clang/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linux64Clang/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linux64Clang/c++Opt b/wmake/rules/linux64Clang/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linux64Clang/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linux64Clang/c++Prof b/wmake/rules/linux64Clang/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Clang/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Clang/c++Scan b/wmake/rules/linux64Clang/c++Scan index bb63f5a322..ae3f47e86f 100644 --- a/wmake/rules/linux64Clang/c++Scan +++ b/wmake/rules/linux64Clang/c++Scan @@ -1,7 +1,10 @@ +#------------------------------------------------------------------------------ # Static analyzer with clang and Opt. # Call top-level Allwmake with 'scan-build' and corresponding compiler -include $(DEFAULT_RULES)/c++Opt +sinclude $(GENERAL_RULES)/common/c++Opt cxx_compiler := $(shell which clang++) -CC := $(shell echo "$(cxx_compiler)" | sed -e 's@/bin/[^/]*@/libexec/c++-analyzer@') -std=c++11 -m64 +CC := $(shell echo "$(cxx_compiler)" | sed -e 's@/bin/[^/]*@/libexec/c++-analyzer@') -std=c++14 -m64 + +#------------------------------------------------------------------------------ diff --git a/wmake/rules/linux64Clang/cDebug b/wmake/rules/linux64Clang/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linux64Clang/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linux64Clang/cOpt b/wmake/rules/linux64Clang/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Clang/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Clang/cProf b/wmake/rules/linux64Clang/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Clang/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Clang/cScan b/wmake/rules/linux64Clang/cScan index d5c4a6bd55..039084ae7e 100644 --- a/wmake/rules/linux64Clang/cScan +++ b/wmake/rules/linux64Clang/cScan @@ -1,7 +1,7 @@ # Static analyzer with clang and Opt. # Call top-level Allwmake with 'scan-build' and corresponding compiler -include $(DEFAULT_RULES)/cOpt +sinclude $(GENERAL_RULES)/common/cOpt c_compiler := $(shell which clang) cc := $(shell echo "$(c_compiler)" | sed -e 's@/bin/[^/]*@/libexec/ccc-analyzer@') -m64 diff --git a/wmake/rules/linux64Cray/c b/wmake/rules/linux64Cray/c index cfe2235d0c..3a53ffb28b 100644 --- a/wmake/rules/linux64Cray/c +++ b/wmake/rules/linux64Cray/c @@ -3,12 +3,12 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cc = cc +cc := cc +cARCH := -m64 -cARCH = -m64 - -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Cray/c++ b/wmake/rules/linux64Cray/c++ index 5d4468d64f..7278cc1ae4 100644 --- a/wmake/rules/linux64Cray/c++ +++ b/wmake/rules/linux64Cray/c++ @@ -1,14 +1,14 @@ #------------------------------------------------------------------------------ -# Cray compiler - a gcc variant/wrapper -# presumably new enough to support c++14 +# Cray compiler - gcc variant/wrapper. New enough to support c++14 #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -CC = CC -std=c++14 +CC := CC -std=c++14 +c++ARCH := -m64 -pthread -c++ARCH = -m64 -pthread - -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Cray/c++Prof b/wmake/rules/linux64Cray/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Cray/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Cray/cOpt b/wmake/rules/linux64Cray/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Cray/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Cray/cProf b/wmake/rules/linux64Cray/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Cray/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Gcc/c b/wmake/rules/linux64Gcc/c index 61b4b1e089..e617ec02c0 100644 --- a/wmake/rules/linux64Gcc/c +++ b/wmake/rules/linux64Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m64 +cARCH := -m64 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Gcc/c++ b/wmake/rules/linux64Gcc/c++ index a698ff281f..b321c1f605 100644 --- a/wmake/rules/linux64Gcc/c++ +++ b/wmake/rules/linux64Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m64 -pthread +c++ARCH := -m64 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Gcc/c++Prof b/wmake/rules/linux64Gcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Gcc/cOpt b/wmake/rules/linux64Gcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Gcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Gcc/cProf b/wmake/rules/linux64Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Icc/c b/wmake/rules/linux64Icc/c index 34d6b1dd54..4f784df4db 100644 --- a/wmake/rules/linux64Icc/c +++ b/wmake/rules/linux64Icc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Icc/c++ b/wmake/rules/linux64Icc/c++ index 52c4f81ec1..e29e706a7c 100644 --- a/wmake/rules/linux64Icc/c++ +++ b/wmake/rules/linux64Icc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c++ -c++ARCH = -pthread -fp-trap=common -fp-model precise +c++ARCH := -pthread -fp-trap=common -fp-model precise -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Icc/c++Debug b/wmake/rules/linux64Icc/c++Debug deleted file mode 100644 index 0aec1fbffe..0000000000 --- a/wmake/rules/linux64Icc/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -O0 -c++OPT = diff --git a/wmake/rules/linux64Icc/c++Opt b/wmake/rules/linux64Icc/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linux64Icc/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linux64Icc/c++Prof b/wmake/rules/linux64Icc/c++Prof deleted file mode 100644 index 48e788c415..0000000000 --- a/wmake/rules/linux64Icc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -p -c++OPT = -O2 diff --git a/wmake/rules/linux64Icc/cDebug b/wmake/rules/linux64Icc/cDebug deleted file mode 100644 index 73dce0dfd0..0000000000 --- a/wmake/rules/linux64Icc/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -O0 -cOPT = diff --git a/wmake/rules/linux64Icc/cOpt b/wmake/rules/linux64Icc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icc/cOptAVX2 b/wmake/rules/linux64Icc/cOptAVX2 deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icc/cOptAVX2 +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icc/cOptAVX512 b/wmake/rules/linux64Icc/cOptAVX512 deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icc/cOptAVX512 +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icc/cProf b/wmake/rules/linux64Icc/cProf deleted file mode 100644 index f31aabbd9b..0000000000 --- a/wmake/rules/linux64Icc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -p -cOPT = -O2 diff --git a/wmake/rules/linux64Icx/c b/wmake/rules/linux64Icx/c index d9d8e19b0e..f274c7ed36 100644 --- a/wmake/rules/linux64Icx/c +++ b/wmake/rules/linux64Icx/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icx/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Icx/c++ b/wmake/rules/linux64Icx/c++ index ae174b3322..23f119a0a2 100644 --- a/wmake/rules/linux64Icx/c++ +++ b/wmake/rules/linux64Icx/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icx/c++ -c++ARCH = -fp-model precise +c++ARCH := -fp-model precise -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Icx/c++Debug b/wmake/rules/linux64Icx/c++Debug deleted file mode 100644 index 0aec1fbffe..0000000000 --- a/wmake/rules/linux64Icx/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -O0 -c++OPT = diff --git a/wmake/rules/linux64Icx/c++Opt b/wmake/rules/linux64Icx/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linux64Icx/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linux64Icx/c++Prof b/wmake/rules/linux64Icx/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Icx/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Icx/cDebug b/wmake/rules/linux64Icx/cDebug deleted file mode 100644 index 73dce0dfd0..0000000000 --- a/wmake/rules/linux64Icx/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -O0 -cOPT = diff --git a/wmake/rules/linux64Icx/cOpt b/wmake/rules/linux64Icx/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icx/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icx/cOptAVX2 b/wmake/rules/linux64Icx/cOptAVX2 deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icx/cOptAVX2 +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icx/cOptAVX512 b/wmake/rules/linux64Icx/cOptAVX512 deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Icx/cOptAVX512 +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Icx/cProf b/wmake/rules/linux64Icx/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Icx/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linux64Mingw/c b/wmake/rules/linux64Mingw/c index 7490a1bdec..8e4d731f0d 100644 --- a/wmake/rules/linux64Mingw/c +++ b/wmake/rules/linux64Mingw/c @@ -1,12 +1,14 @@ #------------------------------------------------------------------------------ +# mingw is gcc +#------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m64 +cc := x86_64-w64-mingw32-gcc +cARCH := -m64 -cc = x86_64-w64-mingw32-gcc - -# Compile option is non-mandatory, but must be non-empty -sinclude $(RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Mingw/c++ b/wmake/rules/linux64Mingw/c++ index 071e93b5ff..ac769d670c 100644 --- a/wmake/rules/linux64Mingw/c++ +++ b/wmake/rules/linux64Mingw/c++ @@ -1,14 +1,15 @@ #------------------------------------------------------------------------------ # mingw is gcc, but new enough to support c++14 +# NB: gnu++14 (not c++14) to ensure __STRICT_ANSI__ is not defined #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m64 -pthread +CC := x86_64-w64-mingw32-g++ -std=gnu++14 +c++ARCH := -m64 -pthread -# With gnu++14 (not c++14) to ensure __STRICT_ANSI__ is not defined -CC = x86_64-w64-mingw32-g++ -std=gnu++14 - -include $(RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Nvidia/c b/wmake/rules/linux64Nvidia/c index 783f888a5e..daf418b3d2 100644 --- a/wmake/rules/linux64Nvidia/c +++ b/wmake/rules/linux64Nvidia/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Nvidia/c -cARCH = -m64 +cARCH := -m64 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linux64Nvidia/c++ b/wmake/rules/linux64Nvidia/c++ index e1048e2068..27f02c832b 100644 --- a/wmake/rules/linux64Nvidia/c++ +++ b/wmake/rules/linux64Nvidia/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Nvidia/c++ -c++ARCH = -m64 +c++ARCH := -m64 -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linux64Nvidia/c++Debug b/wmake/rules/linux64Nvidia/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linux64Nvidia/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linux64Nvidia/c++Opt b/wmake/rules/linux64Nvidia/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linux64Nvidia/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linux64Nvidia/c++Prof b/wmake/rules/linux64Nvidia/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linux64Nvidia/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linux64Nvidia/cDebug b/wmake/rules/linux64Nvidia/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linux64Nvidia/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linux64Nvidia/cOpt b/wmake/rules/linux64Nvidia/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linux64Nvidia/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linux64Nvidia/cProf b/wmake/rules/linux64Nvidia/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linux64Nvidia/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM64Arm/c b/wmake/rules/linuxARM64Arm/c index 7cf6cb6f4a..4f31d7b8ee 100644 --- a/wmake/rules/linuxARM64Arm/c +++ b/wmake/rules/linuxARM64Arm/c @@ -3,12 +3,12 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cc = armclang$(COMPILER_VERSION) +cc := armclang$(COMPILER_VERSION) +cARCH := -mcpu=native -cARCH = -mcpu=native - -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM64Arm/c++ b/wmake/rules/linuxARM64Arm/c++ index f3111f6c04..facf2e416a 100644 --- a/wmake/rules/linuxARM64Arm/c++ +++ b/wmake/rules/linuxARM64Arm/c++ @@ -3,11 +3,12 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -CC = armclang++$(COMPILER_VERSION) -std=c++14 +CC := armclang++$(COMPILER_VERSION) -std=c++14 +c++ARCH := -mcpu=native -pthread -c++ARCH = -mcpu=native -pthread - -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM64Arm/c++Debug b/wmake/rules/linuxARM64Arm/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linuxARM64Arm/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linuxARM64Arm/c++Prof b/wmake/rules/linuxARM64Arm/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxARM64Arm/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM64Arm/cDebug b/wmake/rules/linuxARM64Arm/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linuxARM64Arm/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linuxARM64Arm/cProf b/wmake/rules/linuxARM64Arm/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM64Arm/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM64Clang/c b/wmake/rules/linuxARM64Clang/c index ad4b153a6f..35eca386f8 100644 --- a/wmake/rules/linuxARM64Clang/c +++ b/wmake/rules/linuxARM64Clang/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM64Clang/c++ b/wmake/rules/linuxARM64Clang/c++ index b9209aace2..6a5c61081f 100644 --- a/wmake/rules/linuxARM64Clang/c++ +++ b/wmake/rules/linuxARM64Clang/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -c++ARCH = -pthread +c++ARCH := -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM64Clang/c++Debug b/wmake/rules/linuxARM64Clang/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linuxARM64Clang/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linuxARM64Clang/c++Opt b/wmake/rules/linuxARM64Clang/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linuxARM64Clang/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linuxARM64Clang/c++Prof b/wmake/rules/linuxARM64Clang/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxARM64Clang/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM64Clang/cDebug b/wmake/rules/linuxARM64Clang/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linuxARM64Clang/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linuxARM64Clang/cOpt b/wmake/rules/linuxARM64Clang/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxARM64Clang/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxARM64Clang/cProf b/wmake/rules/linuxARM64Clang/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM64Clang/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM64Fujitsu/c b/wmake/rules/linuxARM64Fujitsu/c index c8e74fc1f5..ad308acc3a 100644 --- a/wmake/rules/linuxARM64Fujitsu/c +++ b/wmake/rules/linuxARM64Fujitsu/c @@ -3,12 +3,12 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cc = fcc$(COMPILER_VERSION) +cc := fcc$(COMPILER_VERSION) +cARCH := -cARCH = - -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM64Fujitsu/c++ b/wmake/rules/linuxARM64Fujitsu/c++ index e04cdb79b3..2e98791ec1 100644 --- a/wmake/rules/linuxARM64Fujitsu/c++ +++ b/wmake/rules/linuxARM64Fujitsu/c++ @@ -3,11 +3,12 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -CC = FCC$(COMPILER_VERSION) -std=c++14 +CC := FCC$(COMPILER_VERSION) -std=c++14 +c++ARCH := -pthread -c++ARCH = -pthread - -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM64Fujitsu/c++Debug b/wmake/rules/linuxARM64Fujitsu/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linuxARM64Fujitsu/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linuxARM64Fujitsu/c++Prof b/wmake/rules/linuxARM64Fujitsu/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxARM64Fujitsu/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM64Fujitsu/cDebug b/wmake/rules/linuxARM64Fujitsu/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linuxARM64Fujitsu/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linuxARM64Fujitsu/cProf b/wmake/rules/linuxARM64Fujitsu/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM64Fujitsu/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM64Gcc/c b/wmake/rules/linuxARM64Gcc/c index 43975404c3..3bed0d729c 100644 --- a/wmake/rules/linuxARM64Gcc/c +++ b/wmake/rules/linuxARM64Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM64Gcc/c++ b/wmake/rules/linuxARM64Gcc/c++ index a42cc55e95..5823d2850a 100644 --- a/wmake/rules/linuxARM64Gcc/c++ +++ b/wmake/rules/linuxARM64Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -pthread +c++ARCH := -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM64Gcc/c++Prof b/wmake/rules/linuxARM64Gcc/c++Prof deleted file mode 100644 index 858dde1ed2..0000000000 --- a/wmake/rules/linuxARM64Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM64Gcc/cProf b/wmake/rules/linuxARM64Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM64Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM64Nvidia/c b/wmake/rules/linuxARM64Nvidia/c index 90da0e87fb..45cf342616 100644 --- a/wmake/rules/linuxARM64Nvidia/c +++ b/wmake/rules/linuxARM64Nvidia/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Nvidia/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM64Nvidia/c++ b/wmake/rules/linuxARM64Nvidia/c++ index d8fa193375..4aadfffb96 100644 --- a/wmake/rules/linuxARM64Nvidia/c++ +++ b/wmake/rules/linuxARM64Nvidia/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Nvidia/c++ -c++ARCH = +c++ARCH := -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM64Nvidia/c++Debug b/wmake/rules/linuxARM64Nvidia/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linuxARM64Nvidia/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linuxARM64Nvidia/c++Opt b/wmake/rules/linuxARM64Nvidia/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linuxARM64Nvidia/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linuxARM64Nvidia/c++Prof b/wmake/rules/linuxARM64Nvidia/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxARM64Nvidia/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM64Nvidia/cDebug b/wmake/rules/linuxARM64Nvidia/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linuxARM64Nvidia/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linuxARM64Nvidia/cOpt b/wmake/rules/linuxARM64Nvidia/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxARM64Nvidia/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxARM64Nvidia/cProf b/wmake/rules/linuxARM64Nvidia/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM64Nvidia/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxARM7Gcc/c b/wmake/rules/linuxARM7Gcc/c index d55ba40c01..cf19662b5e 100644 --- a/wmake/rules/linuxARM7Gcc/c +++ b/wmake/rules/linuxARM7Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -mcpu=cortex-a9 +cARCH := -mcpu=cortex-a9 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxARM7Gcc/c++ b/wmake/rules/linuxARM7Gcc/c++ index 0182c5d20a..08b1ed5aa3 100644 --- a/wmake/rules/linuxARM7Gcc/c++ +++ b/wmake/rules/linuxARM7Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -mcpu=cortex-a9 -pthread +c++ARCH := -mcpu=cortex-a9 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxARM7Gcc/c++Prof b/wmake/rules/linuxARM7Gcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxARM7Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxARM7Gcc/cProf b/wmake/rules/linuxARM7Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxARM7Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxClang/c b/wmake/rules/linuxClang/c index 82ed3a452a..86cef8fca8 100644 --- a/wmake/rules/linuxClang/c +++ b/wmake/rules/linuxClang/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c -cARCH = -m32 +cARCH := -m32 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxClang/c++ b/wmake/rules/linuxClang/c++ index 2e2d8e06da..ad62c8585d 100644 --- a/wmake/rules/linuxClang/c++ +++ b/wmake/rules/linuxClang/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Clang/c++ -c++ARCH = -m32 -pthread +c++ARCH := -m32 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxClang/c++Debug b/wmake/rules/linuxClang/c++Debug deleted file mode 100644 index 48f0b6643e..0000000000 --- a/wmake/rules/linuxClang/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -c++OPT = -O0 diff --git a/wmake/rules/linuxClang/c++Opt b/wmake/rules/linuxClang/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linuxClang/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linuxClang/c++Prof b/wmake/rules/linuxClang/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxClang/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxClang/cDebug b/wmake/rules/linuxClang/cDebug deleted file mode 100644 index 7b7adf10de..0000000000 --- a/wmake/rules/linuxClang/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -cOPT = -O0 diff --git a/wmake/rules/linuxClang/cOpt b/wmake/rules/linuxClang/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxClang/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxClang/cProf b/wmake/rules/linuxClang/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxClang/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxGcc/c b/wmake/rules/linuxGcc/c index b8f94d5e2a..7fe107eefb 100644 --- a/wmake/rules/linuxGcc/c +++ b/wmake/rules/linuxGcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m32 +cARCH := -m32 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxGcc/c++ b/wmake/rules/linuxGcc/c++ index 2f10dce225..9a82727d99 100644 --- a/wmake/rules/linuxGcc/c++ +++ b/wmake/rules/linuxGcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m32 -pthread +c++ARCH := -m32 -pthread -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxGcc/c++Prof b/wmake/rules/linuxGcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxGcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxGcc/cOpt b/wmake/rules/linuxGcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxGcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxGcc/cProf b/wmake/rules/linuxGcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxGcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxIA64Gcc/c b/wmake/rules/linuxIA64Gcc/c index 43975404c3..3bed0d729c 100644 --- a/wmake/rules/linuxIA64Gcc/c +++ b/wmake/rules/linuxIA64Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxIA64Gcc/c++ b/wmake/rules/linuxIA64Gcc/c++ index c6c8eda9e1..ca39a0a204 100644 --- a/wmake/rules/linuxIA64Gcc/c++ +++ b/wmake/rules/linuxIA64Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = +c++ARCH := -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxIA64Gcc/c++Opt b/wmake/rules/linuxIA64Gcc/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linuxIA64Gcc/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linuxIA64Gcc/c++Prof b/wmake/rules/linuxIA64Gcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxIA64Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxIA64Gcc/cOpt b/wmake/rules/linuxIA64Gcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxIA64Gcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxIA64Gcc/cProf b/wmake/rules/linuxIA64Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxIA64Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxIA64Icc/c b/wmake/rules/linuxIA64Icc/c index de628fdb32..8fbd70272d 100644 --- a/wmake/rules/linuxIA64Icc/c +++ b/wmake/rules/linuxIA64Icc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c -cARCH = +cARCH := -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxIA64Icc/c++ b/wmake/rules/linuxIA64Icc/c++ index 54a5d2cb1c..0117e7dea4 100644 --- a/wmake/rules/linuxIA64Icc/c++ +++ b/wmake/rules/linuxIA64Icc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c++ -c++ARCH = +c++ARCH := -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxIA64Icc/c++Debug b/wmake/rules/linuxIA64Icc/c++Debug deleted file mode 100644 index 0aec1fbffe..0000000000 --- a/wmake/rules/linuxIA64Icc/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -O0 -c++OPT = diff --git a/wmake/rules/linuxIA64Icc/cDebug b/wmake/rules/linuxIA64Icc/cDebug deleted file mode 100644 index 73dce0dfd0..0000000000 --- a/wmake/rules/linuxIA64Icc/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -O0 -cOPT = diff --git a/wmake/rules/linuxIA64Icc/cOpt b/wmake/rules/linuxIA64Icc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxIA64Icc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxIA64Icc/cProf b/wmake/rules/linuxIA64Icc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxIA64Icc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxIcc/c b/wmake/rules/linuxIcc/c index 28084de505..706f1bdeeb 100644 --- a/wmake/rules/linuxIcc/c +++ b/wmake/rules/linuxIcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c -cARCH = -gcc-version=400 +cARCH := -gcc-version=400 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxIcc/c++ b/wmake/rules/linuxIcc/c++ index f98f2001f3..d4ed37b404 100644 --- a/wmake/rules/linuxIcc/c++ +++ b/wmake/rules/linuxIcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Icc/c++ -c++ARCH = -pthread -fp-trap=common -fp-model precise +c++ARCH := -pthread -fp-trap=common -fp-model precise -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxIcc/c++Debug b/wmake/rules/linuxIcc/c++Debug deleted file mode 100644 index 0aec1fbffe..0000000000 --- a/wmake/rules/linuxIcc/c++Debug +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -g -DFULLDEBUG -O0 -c++OPT = diff --git a/wmake/rules/linuxIcc/c++Opt b/wmake/rules/linuxIcc/c++Opt deleted file mode 100644 index 2aedabd628..0000000000 --- a/wmake/rules/linuxIcc/c++Opt +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -c++OPT = -O3 diff --git a/wmake/rules/linuxIcc/c++Prof b/wmake/rules/linuxIcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxIcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxIcc/cDebug b/wmake/rules/linuxIcc/cDebug deleted file mode 100644 index 73dce0dfd0..0000000000 --- a/wmake/rules/linuxIcc/cDebug +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -g -DFULLDEBUG -O0 -cOPT = diff --git a/wmake/rules/linuxIcc/cOpt b/wmake/rules/linuxIcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxIcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxIcc/cProf b/wmake/rules/linuxIcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxIcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxPPC64Gcc/c b/wmake/rules/linuxPPC64Gcc/c index e383499f44..cb2876f261 100644 --- a/wmake/rules/linuxPPC64Gcc/c +++ b/wmake/rules/linuxPPC64Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m64 -mcpu=power5+ +cARCH := -m64 -mcpu=power5+ -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxPPC64Gcc/c++ b/wmake/rules/linuxPPC64Gcc/c++ index 7bc6794119..d9fe3be9a4 100644 --- a/wmake/rules/linuxPPC64Gcc/c++ +++ b/wmake/rules/linuxPPC64Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m64 -mcpu=power5+ +c++ARCH := -m64 -mcpu=power5+ -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxPPC64Gcc/c++Prof b/wmake/rules/linuxPPC64Gcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxPPC64Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxPPC64Gcc/cOpt b/wmake/rules/linuxPPC64Gcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxPPC64Gcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxPPC64Gcc/cProf b/wmake/rules/linuxPPC64Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxPPC64Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/linuxPPC64leGcc/c b/wmake/rules/linuxPPC64leGcc/c index 4ec55a67c0..f4d92fcdfc 100644 --- a/wmake/rules/linuxPPC64leGcc/c +++ b/wmake/rules/linuxPPC64leGcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m64 -mcpu=power8 +cARCH := -m64 -mcpu=power8 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/linuxPPC64leGcc/c++ b/wmake/rules/linuxPPC64leGcc/c++ index facaa50a4c..ebc02ea626 100644 --- a/wmake/rules/linuxPPC64leGcc/c++ +++ b/wmake/rules/linuxPPC64leGcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m64 -mcpu=power8 +c++ARCH := -m64 -mcpu=power8 -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/linuxPPC64leGcc/c++Prof b/wmake/rules/linuxPPC64leGcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/linuxPPC64leGcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/linuxPPC64leGcc/cOpt b/wmake/rules/linuxPPC64leGcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/linuxPPC64leGcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/linuxPPC64leGcc/cProf b/wmake/rules/linuxPPC64leGcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/linuxPPC64leGcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/rules/solaris64Gcc/c b/wmake/rules/solaris64Gcc/c index 61b4b1e089..e617ec02c0 100644 --- a/wmake/rules/solaris64Gcc/c +++ b/wmake/rules/solaris64Gcc/c @@ -1,10 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c -cARCH = -m64 +cARCH := -m64 -# Compile option is non-mandatory, but must be non-empty -sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c$(WM_COMPILE_OPTION) +endif cFLAGS = \ $(cARCH) $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) \ diff --git a/wmake/rules/solaris64Gcc/c++ b/wmake/rules/solaris64Gcc/c++ index cd1c3bd138..1a5adcecae 100644 --- a/wmake/rules/solaris64Gcc/c++ +++ b/wmake/rules/solaris64Gcc/c++ @@ -1,9 +1,11 @@ #------------------------------------------------------------------------------ include $(GENERAL_RULES)/Gcc/c++ -c++ARCH = -m64 +c++ARCH := -m64 -include $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +ifneq (,$(WM_COMPILE_OPTION)) + sinclude $(DEFAULT_RULES)/c++$(WM_COMPILE_OPTION) +endif c++FLAGS = \ $(c++ARCH) $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) \ diff --git a/wmake/rules/solaris64Gcc/c++Prof b/wmake/rules/solaris64Gcc/c++Prof deleted file mode 100644 index 3bda4dad55..0000000000 --- a/wmake/rules/solaris64Gcc/c++Prof +++ /dev/null @@ -1,2 +0,0 @@ -c++DBUG = -pg -c++OPT = -O2 diff --git a/wmake/rules/solaris64Gcc/cOpt b/wmake/rules/solaris64Gcc/cOpt deleted file mode 100644 index 17318709f1..0000000000 --- a/wmake/rules/solaris64Gcc/cOpt +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -cOPT = -O3 diff --git a/wmake/rules/solaris64Gcc/cProf b/wmake/rules/solaris64Gcc/cProf deleted file mode 100644 index ca3ac9bf5f..0000000000 --- a/wmake/rules/solaris64Gcc/cProf +++ /dev/null @@ -1,2 +0,0 @@ -cDBUG = -pg -cOPT = -O2 diff --git a/wmake/wmake b/wmake/wmake index a5aead20d9..3a7e29c693 100755 --- a/wmake/wmake +++ b/wmake/wmake @@ -69,8 +69,8 @@ HELP_HEAD if [ -n "$1" ] then cat<