Handle 'Full' and 'FastLink' arguments to 'symbols'. Add associated gmake and gmake2 tests
This commit is contained in:
parent
da90c1ffd0
commit
85ed6bbda1
@ -52,6 +52,39 @@
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- symbols default to 'off'
|
||||
--
|
||||
function suite.symbols_default()
|
||||
symbols "default"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS)
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS)
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- All other symbols flags also produce -g
|
||||
--
|
||||
function suite.symbols_fastlink()
|
||||
symbols "FastLink"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -g
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g
|
||||
]]
|
||||
end
|
||||
|
||||
function suite.symbols_full()
|
||||
symbols "full"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -g
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- symbols "off" should not produce -g
|
||||
--
|
||||
|
@ -53,6 +53,18 @@ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- symbols default to 'off'
|
||||
--
|
||||
function suite.symbols_default()
|
||||
symbols "default"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS)
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS)
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- symbols "off" should not produce -g
|
||||
--
|
||||
@ -65,6 +77,27 @@ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS)
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- All other symbols flags also produce -g
|
||||
--
|
||||
function suite.symbols_fastlink()
|
||||
symbols "FastLink"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -g
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g
|
||||
]]
|
||||
end
|
||||
|
||||
function suite.symbols_full()
|
||||
symbols "full"
|
||||
prepare { "cFlags", "cxxFlags" }
|
||||
test.capture [[
|
||||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -g
|
||||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g
|
||||
]]
|
||||
end
|
||||
|
||||
--
|
||||
-- symbols "on" with a proper debugformat should produce a corresponding -g
|
||||
--
|
||||
|
@ -108,7 +108,11 @@
|
||||
symbols = function(cfg, mappings)
|
||||
local values = gcc.getdebugformat(cfg)
|
||||
local debugformat = values[cfg.debugformat] or ""
|
||||
return { On = "-g" .. debugformat }
|
||||
return {
|
||||
On = "-g" .. debugformat,
|
||||
FastLink = "-g" .. debugformat,
|
||||
Full = "-g" .. debugformat,
|
||||
}
|
||||
end,
|
||||
unsignedchar = {
|
||||
On = "-funsigned-char",
|
||||
|
Loading…
Reference in New Issue
Block a user