X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Fclam%2Fcpp%2Fvariables.def;h=7ad4c79c1801d7d8d35ee67f4eeda1a4ba7a5827;hb=7d715f6667e8bb5d7a4f965adb5f36853eb47818;hp=1581e075c94022527ed095927981c579776651e7;hpb=19ab994d8ea15bf16ed2f20c651f1a1d5abd12e3;p=feisty_meow.git diff --git a/scripts/clam/cpp/variables.def b/scripts/clam/cpp/variables.def index 1581e075..7ad4c79c 100644 --- a/scripts/clam/cpp/variables.def +++ b/scripts/clam/cpp/variables.def @@ -11,7 +11,7 @@ ifneq "$(BUILD_PARAMETER_FILE)" "" endif ifeq "$(PARAMETER_FILE)" "" # last ditch attempt to get one that will work. - export PARAMETER_FILE = $(PRODUCTION_DIR)/feisty_meow_config.ini + export PARAMETER_FILE = $(PRODUCTION_STORE)/feisty_meow_config.ini endif ############################################################################### @@ -21,7 +21,7 @@ include variables.def ############################################################################### -#no # set the repository directory if it's still set to the base version. +#no # set the repository directory if it is still set to the base version. #ifeq "$(FEISTY_MEOW_APEX)" "" # ifeq "$(OP_SYSTEM)" "UNIX" # export FEISTY_MEOW_APEX = $(HOME)/hoople @@ -31,7 +31,7 @@ include variables.def # endif #endif -#export CLAM_BINARY_DIR = $(CLAM_DIR)/../bin +#export CLAM_BINARIES = $(CLAM_SCRIPTS)/../bin ############################################################################### @@ -91,7 +91,7 @@ export COMPILER_VERSION # "TYPE" is the kind of product being generated by this project. this is # used to decide where to put the final products of compilation. this is a -# variable in the user's makefile. +# variable in the user makefile. # Valid Types: # TYPE = library (outputs are static or dynamic libraries) # TYPE = application (outputs are main-line executables) @@ -141,7 +141,7 @@ export TEST_MAKEFILE = # be passed on the command line to a make. if they are intended to be used # from inside a makefile, then they must appear before this file is included. -# "REBUILD" causes a rebuild of all source files if it's true. +# "REBUILD" causes a rebuild of all source files if it is true. export REBUILD # "DEBUG" is used to specify a debugging build. the default is for this to @@ -179,12 +179,12 @@ FLAG_FILES += $(BUILD_LIST_FILE) $(BUILD_WHACK_FILE) ############################################################################### # This section implements the HOOPLE directory scheme. If your scheme differs, -# then you'll want to modify these appropriately. +# then you will want to modify these appropriately. # "THIRD_PARTY_DIR" is the root of our support libraries. export THIRD_PARTY_DIR ifeq "$(THIRD_PARTY_DIR)" "" - export THIRD_PARTY_DIR := "$(PRODUCTION_DIR)/3rdparty" + export THIRD_PARTY_DIR := "$(PRODUCTION_STORE)/3rdparty" endif # "OUTPUT_ROOT" is the root of all output directories for objects and other @@ -209,8 +209,8 @@ export BASE_OUTPUT_PATH = $(OUTPUT_ROOT)/$(CPU_BUILD_DIR) # special case when doing arm-linux builds ifeq "$(COMPILER)" "GNU_ARM_LINUX" - export TARGETS_DIR = $(FEISTY_MEOW_APEX)/$(CPU_BUILD_DIR) - # special output directory for firmware doesn't include CPU name because + export TARGETS_STORE = $(FEISTY_MEOW_APEX)/$(CPU_BUILD_DIR) + # special output directory for firmware does not include CPU name because # the repository already include the CPU name BASE_OUTPUT_PATH = $(OUTPUT_ROOT) endif @@ -223,12 +223,13 @@ export OUTPUT_PATH = $(BASE_OUTPUT_PATH)/$(PROJECT) export OBJECT_DIR = $(OUTPUT_PATH) # These specify where files are to be created or located for our local build. -export EXECUTABLE_DIR = $(TARGETS_DIR) -export DYNAMIC_LIBRARY_DIR = $(TARGETS_DIR) -export STATIC_LIBRARY_DIR = $(TARGETS_DIR) +export EXECUTABLE_DIR = $(TARGETS_STORE) +export DYNAMIC_LIBRARY_DIR = $(TARGETS_STORE) +export STATIC_LIBRARY_DIR = $(TARGETS_STORE) # "HEADER_SEARCH_PATH" is where the class interface files are to be found. -#HEADER_SEARCH_PATH = +# we add the generated store folder for the build version file. +HEADER_SEARCH_PATH = $(FEISTY_MEOW_GENERATED_STORE)/versions # "HOOPLE_HEADERS" are locations where the HOOPLE headers can be found. ifeq "$(HOOPLE_HEADERS)" "" @@ -261,7 +262,7 @@ LOCAL_HEADERS = $(THIRD_PARTY_DIR) HOOPLE_LIBRARIES = # "EXTRA_COPIES" is a list of files that need to be among the files copied -# to a project's output folder. +# to a project output folder. export EXTRA_COPIES # "EXTRA_VERSIONS" is a list of version files to synchronize with the main @@ -276,7 +277,7 @@ export EXTRA_VERSIONS export DEPS_FILE = $(OUTPUT_PATH)/$(PROJECT).deps # "NO_DEPS" is an exclusion flag. if it is defined, then no auto-dependency -# files will be generated. this is useful if you're missing makedep or trying +# files will be generated. this is useful if you are missing makedep or trying # to compile it... #NO_DEPS = t @@ -285,9 +286,10 @@ export DEPS_FILE = $(OUTPUT_PATH)/$(PROJECT).deps # such files. this is needed when rebuilding version_stamper. #OMIT_VERSIONS = t -# Add the obligatory junk to be cleaned up. Individual compiler sections -# should customize this by adding their object output directories. -CLEANUPS += $(ACTUAL_TARGETS) $(OUTPUT_PATH) +# add the cleanup values we already know. +CLEANUPS += $(OUTPUT_PATH) $(DEPS_FILE) + +SUPPLEMENTAL_CLEANUP_TARGETS = cpp_add_to_cleanups_variable # "GENDEPS" is a flag that causes dependencies to be generated into # statically built applications. @@ -358,7 +360,7 @@ LIBS_USED = # included (although they should be listed in a different form in LIBS_USED). # Remember that the unix loader looks for functions in libraries in a bizarre # way: ld searches for a function only when it has already been asked for it. -# This means that it doesn't remember what functions it has already been +# This means that it does not remember what functions it has already been # provided with in the libraries and object files, and it will fail if those # functions are only asked for after they have already been encountered. #LOAD_FLAG_PREFIX = @@ -403,7 +405,7 @@ LIBRARY_PATH_FLAG = -L # the root name of the version file. This is currently irrelevant on # non-win32 platforms. -VERSION_RC_ROOT = $(shell $(SHELL) $(CLAM_DIR)/cpp/rc_name.sh) +VERSION_RC_ROOT = $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/rc_name.sh) ifneq "$(CONSOLE_MODE)" "" # this definition can be used to signal different behavior when the app is @@ -436,7 +438,7 @@ endif # # "COMPILER_ROOT_DIR" is the top-level for the C++ compiler location. export COMPILER_ROOT_DIR -# "COMPILER_HEADER_DIR" is where the compiler's headers are. +# "COMPILER_HEADER_DIR" is where the compiler headers are. export COMPILER_HEADER_DIR # "COMPILER_LIBRARY_DIR" is where archived libraries are. # "CC" is the name of the C++ compiler to be used. @@ -456,6 +458,10 @@ ifneq "$(OMIT_VERSIONS)" "" DEFINITIONS += NO_VERSION endif +############################################################################ +# compiler specific section below. +############################################################################ + ifeq "$(COMPILER)" "GNU_LINUX" # Unix GNU compiler... CC = g++ @@ -463,7 +469,7 @@ ifeq "$(COMPILER)" "GNU_LINUX" PLATFORM_ADD_IN = linux_ ARCHITECTURE = $(shell machine 2>/dev/null || arch 2>/dev/null || echo i686) - export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_DIR)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) + export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) DEFINITIONS += _FILE_OFFSET_BITS=64 @@ -529,22 +535,24 @@ ifeq "$(COMPILER)" "GNU_LINUX" ###COMPILER_FLAGS += -pg ###LOAD_FLAG_PREFIX += -pg -####trying out profiling: doesn't work so well yet. generates gmon.out files -#### in pretty random places. the parameters to the linker don't even -#### mention this flag, and the compiler flags don't seem to provide an -#### option for where the file goes. so, it's on hold. +####trying out profiling: does not work so well yet. generates gmon.out files +#### in pretty random places. the parameters to the linker do not even +#### mention this flag, and the compiler flags do not seem to provide an +#### option for where the file goes. so, it is on hold. endif endif +############################################################################ + ifeq "$(COMPILER)" "GNU_ARM_LINUX" # ARM-linux GNU compiler... COMPILER_ROOT_DIR = /usr/local/arm-linux CC = $(COMPILER_ROOT_DIR)/bin/g++ PLATFORM_ADD_IN = linux_ - export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_DIR)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) + export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) SNAPGEAR_ROOT_DIR = $(HOME)/snapgear @@ -582,6 +590,8 @@ ifeq "$(COMPILER)" "GNU_ARM_LINUX" endif +############################################################################ + ifeq "$(COMPILER)" "GNU_WINDOWS" # GNU compiler for MS Windoze... CC = g++ @@ -589,7 +599,7 @@ ifeq "$(COMPILER)" "GNU_WINDOWS" COMPILER_ROOT_DIR = $(CYGROOT) endif - export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_DIR)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) + export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) RC := $(COMPILER_ROOT_DIR)/bin/windres PLATFORM_ADD_IN = w32_ @@ -606,6 +616,7 @@ ifeq "$(COMPILER)" "GNU_WINDOWS" LIBRARY_TOOL = ar LIBRARY_PATH_FLAG = -L LIB_PREFIX = lib + LIB_ENDING = .a # LOAD_FLAG_PREFIX += -lpthread LOAD_FLAG_PREFIX += -mwindows CREATE_LIBRARY_FLAG += -r @@ -619,6 +630,8 @@ ifeq "$(COMPILER)" "GNU_WINDOWS" endif +############################################################################ + ifeq "$(COMPILER)" "VISUAL_CPP" # microsoft visual c++ 4.x, 5.x or 6.x. @@ -627,7 +640,7 @@ ifeq "$(COMPILER)" "VISUAL_CPP" TRIPART_VERSION = CLEANUPS += $(PDB_DIR)/$(PROJECT)_bookkeeping.pdb -#hmmm: import libs for dynamic libraries on ms-win32 don't currently get +#hmmm: import libs for dynamic libraries on ms-win32 do not currently get # cleaned up nicely. # ensure that any setting for this is seen by sub-shells. @@ -662,7 +675,7 @@ ifeq "$(COMPILER)" "VISUAL_CPP" # calculate the visual studio root directory. ifeq "$(VIS_STU_ROOT)" "" - export VIS_STU_ROOT := $(shell $(SHELL) $(CLAM_DIR)/cpp/ms_root_dir.sh ) + export VIS_STU_ROOT := $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/ms_root_dir.sh ) endif ifneq "$(VIS_STU_ROOT)" "" export COMPILER_ROOT_DIR = $(VIS_STU_ROOT)/VC @@ -675,16 +688,16 @@ ifeq "$(COMPILER)" "VISUAL_CPP" endif # redo the compiler version with our new info. - export COMPILER_VERSION := $(shell $(SHELL) $(CLAM_DIR)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) + export COMPILER_VERSION := $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) # set up a directory for debugging files to be stored. these are not # moved with the postconditions--they are generated in place. - export PDB_DIR = $(TARGETS_DIR) + export PDB_DIR = $(TARGETS_STORE) # set these way up here so we can override them later. - CC = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/cl.exe - LINK_TOOL = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/link.exe - LIBRARY_TOOL = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/lib + CC = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/cl.exe + LINK_TOOL = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/link.exe + LIBRARY_TOOL = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/lib # This is needed to protect against the use of 64-bit time_t structure # on windows. We are casting to time_t from a 32-bit structure. @@ -694,19 +707,19 @@ ifeq "$(COMPILER)" "VISUAL_CPP" ifeq "$(COMPILER_VERSION)" "6" COMPILER_HEADER_DIR = $(COMPILER_ROOT_DIR)/include $(COMPILER_ROOT_DIR)/atl/include COMPILER_LIBRARY_DIR = $(COMPILER_ROOT_DIR)/lib $(COMPILER_ROOT_DIR)/atl/lib - RC = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/../common/msdev98/bin/rc + RC = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/../common/msdev98/bin/rc endif ifeq "$(COMPILER_VERSION)" "7" COMPILER_HEADER_DIR = $(COMPILER_ROOT_DIR)/include $(COMPILER_ROOT_DIR)/atlmfc/include $(COMPILER_ROOT_DIR)/platformsdk/include $(FRAMEWORK_DIR) COMPILER_LIBRARY_DIR = $(COMPILER_ROOT_DIR)/lib $(COMPILER_ROOT_DIR)/atlmfc/lib $(COMPILER_ROOT_DIR)/platformsdk/lib - RC = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/rc + RC = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/rc COMPILER_FLAGS += -Zc:forScope # turn on proper loop scoping. endif ifeq "$(COMPILER_VERSION)" "8" COMPILER_HEADER_DIR = $(COMPILER_ROOT_DIR)/include $(COMPILER_ROOT_DIR)/atlmfc/include $(COMPILER_ROOT_DIR)/platformsdk/include $(FRAMEWORK_DIR) COMPILER_LIBRARY_DIR = $(COMPILER_ROOT_DIR)/lib $(COMPILER_ROOT_DIR)/atlmfc/lib $(COMPILER_ROOT_DIR)/platformsdk/lib - RC = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/rc + RC = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(COMPILER_ROOT_DIR)/bin/rc COMPILER_FLAGS += -Zc:forScope # turn on proper loop scoping. DEFINITIONS += _WIN32_WINNT=0x501 @@ -722,7 +735,7 @@ ifeq "$(COMPILER)" "VISUAL_CPP" COMPILER_LIBRARY_DIR = $(COMPILER_ROOT_DIR)/lib $(COMPILER_ROOT_DIR)/atlmfc/lib $(PLATYPUS)/lib DEFINITIONS += _WIN32_WINNT=0x501 DEPENDENCY_DEFINITIONS += _WIN32_WINNT=0x501 - RC = $(BUILD_SCRIPTS_DIR)/wrapdoze.sh $(PLATYPUS)/bin/rc + RC = $(BUILD_SCRIPTS_PATH)/wrapdoze.sh $(PLATYPUS)/bin/rc COMPILER_FLAGS += -Zc:forScope # turn on proper loop scoping. endif @@ -782,7 +795,7 @@ ifeq "$(COMPILER)" "VISUAL_CPP" # -ML signifies uni-threaded executable (MLd means debug). # -MT indicates multi-threaded executable (MTd means debug) # -O is for optimization (1 small code, 2 fast code, d disabled). - # don't use 1 or 2 though; they both include "global optimization", + # do not use 1 or 2 though; they both include "global optimization", # which seems plagued with problems. the specific optimizations are: # -Oa assume no aliasing # -Obn inline function expansion, where n is 1 (enable) or 0 (disable) @@ -854,7 +867,7 @@ ifeq "$(COMPILER)" "VISUAL_CPP" # add the common linker flags. the debugging flag is added because we # want to be able to debug into release code, but since the pdb files - # are separate, we're not exposing ourselves when we don't include them. + # are separate, we are not exposing ourselves when we do not include them. LOAD_FLAG_PREFIX += $(PROFILER_FLAG) -debug -opt:ref -opt:icf #-warn:3 @@ -893,29 +906,34 @@ ifeq "$(COMPILER)" "VISUAL_CPP" ifneq "$(STRICT_WARNINGS)" "" COMPILER_FLAGS += -WX -#would like to add W4 but that triggers warnings in ms's own headers. +#would like to add W4 but that triggers warnings in microsoft headers. endif endif +############################################################################ + ifeq "$(COMPILER)" "GNU_DARWIN" - # Darwin kernel GNU compiler... + # Darwin kernel GNU compiler... really more general macos (MacOS) here these days. CC = g++ COMPILER_ROOT_DIR = / PLATFORM_ADD_IN = darwin ARCHITECTURE = $(shell machine 2>/dev/null || arch 2>/dev/null || echo i686) # COMPILER_FLAGS += -fgnu-runtime - export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_DIR)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) + export COMPILER_VERSION = $(shell $(SHELL) $(CLAM_SCRIPTS)/cpp/get_version.sh $(COMPILER) $(COMPILER_ROOT_DIR) ) DEFINITIONS += _FILE_OFFSET_BITS=64 DEPENDENCY_DEFINITIONS += NO_VERSION - DEPENDENCY_ADDITIONS = -X/usr/include -X/usr/include/c++/$(COMPILER_VERSION) -X/usr/include/c++/$(COMPILER_VERSION)/tr1 -X/usr/local/include -X/usr/include/linux -X/usr/include/wx-2.8 -X/usr/lib/gcc/i586-suse-linux/$(COMPILER_VERSION)/include -X/usr/lib/gcc/i486-linux-gnu/$(COMPILER_VERSION)/include +# DEPENDENCY_ADDITIONS = -X/usr/include -X/usr/include/c++/$(COMPILER_VERSION) -X/usr/include/c++/$(COMPILER_VERSION)/tr1 -X/usr/local/include -X/usr/include/linux -X/usr/include/wx-2.8 -X/usr/lib/gcc/i586-suse-linux/$(COMPILER_VERSION)/include -X/usr/lib/gcc/i486-linux-gnu/$(COMPILER_VERSION)/include + DEPENDENCY_ADDITIONS = -X/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include -#protect other additions to make them only for debian? -# COMPILER_HEADER_DIR := /usr/include /usr/local/include - COMPILER_HEADER_DIR := /System/Library/Frameworks/Foundation.framework/Versions/C/Headers + COMPILER_HEADER_DIR := /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include +#/usr/local/include /usr/include +#old /System/Library/Frameworks/Foundation.framework/Versions/C/Headers +#/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include +#/Library/Developer/CommandLineTools/usr/include # "USE_XWIN" specifies that this project needs X window system support. #USE_XWIN = @@ -923,13 +941,12 @@ ifeq "$(COMPILER)" "GNU_DARWIN" # ifeq "x86_64" "$(ARCHITECTURE)" # COMPILER_LIBRARY_DIR = /lib64 /usr/lib64 /usr/local/lib64 # else - - COMPILER_LIBRARY_DIR = /usr/lib -###/usr/local/lib -#/lib - + COMPILER_LIBRARY_DIR = /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib +#/usr/lib /usr/local/lib # endif - DEFINITIONS += __LINUX__ linux __linux__ UNIX unix __UNIX__ __USE_GNU + +# DEFINITIONS += __LINUX__ linux __linux__ UNIX unix __UNIX__ __USE_GNU + DEFINITIONS += UNIX unix __UNIX__ __USE_GNU # X Window System not enabled by default. #DEFINITIONS += __XWINDOWS__