From c2dc4316bdfb59972c2d1b204f46f059f898ea0f Mon Sep 17 00:00:00 2001 From: Vas Crabb Date: Thu, 29 Nov 2018 14:10:27 +1100 Subject: (nw) fix stuff: * Add per-language compiler flag options to help with exotic setups * Get rid of a potention buffer overrun in NuBus image card * CHAR_WIDTH and LONG_WIDTH are preprocessor macros in limits.h with glibc if __GLIBC_USE (IEC_60559_BFP_EXT) is enabled - avoid using them as names * Make formats/upd765_dsk.h slightly safer with defualt initialisers for key format members * Don't rely on random BSS data being zero in imagedev/floppy.cpp --- scripts/genie.lua | 46 +++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) (limited to 'scripts/genie.lua') diff --git a/scripts/genie.lua b/scripts/genie.lua index b11b99203d4..46a4f9310d9 100644 --- a/scripts/genie.lua +++ b/scripts/genie.lua @@ -219,7 +219,27 @@ newoption { newoption { trigger = "ARCHOPTS", - description = "ARCHOPTS.", + description = "Additional options for target C/C++/Objective-C/Objective-C++ compilers and linker.", +} + +newoption { + trigger = "ARCHOPTS_C", + description = "Additional options for target C++ compiler.", +} + +newoption { + trigger = "ARCHOPTS_CXX", + description = "Additional options for target C++ compiler.", +} + +newoption { + trigger = "ARCHOPTS_OBJC", + description = "Additional options for target Objective-C compiler.", +} + +newoption { + trigger = "ARCHOPTS_OBJCXX", + description = "Additional options for target Objective-C++ compiler.", } newoption { @@ -869,6 +889,30 @@ if _OPTIONS["ARCHOPTS"] then } end +if _OPTIONS["ARCHOPTS_C"] then + buildoptions_c { + _OPTIONS["ARCHOPTS_C"] + } +end + +if _OPTIONS["ARCHOPTS_CXX"] then + buildoptions_cpp { + _OPTIONS["ARCHOPTS_CXX"] + } +end + +if _OPTIONS["ARCHOPTS_OBJC"] then + buildoptions_objc { + _OPTIONS["ARCHOPTS_OBJC"] + } +end + +if _OPTIONS["ARCHOPTS_OBJCXX"] then + buildoptions_objcpp { + _OPTIONS["ARCHOPTS_OBJCXX"] + } +end + if _OPTIONS["SHLIB"] then buildoptions { "-fPIC" -- cgit v1.2.3-70-g09d2