Add basic support for the 'Utility' kind in gmake

This commit is contained in:
Sami Kankaristo 2015-10-01 05:34:46 +03:00
parent 991561c600
commit 77efd0bab3
2 changed files with 4 additions and 1 deletions

View File

@ -20,7 +20,7 @@
shortname = "GNU Make", shortname = "GNU Make",
description = "Generate GNU makefiles for POSIX, MinGW, and Cygwin", description = "Generate GNU makefiles for POSIX, MinGW, and Cygwin",
valid_kinds = { "ConsoleApp", "WindowedApp", "StaticLib", "SharedLib" }, valid_kinds = { "ConsoleApp", "WindowedApp", "StaticLib", "SharedLib", "Utility" },
valid_languages = { "C", "C++", "C#" }, valid_languages = { "C", "C++", "C#" },

View File

@ -434,6 +434,9 @@
else else
_p(' LINKCMD = $(AR) -rcs "$@" $(OBJECTS)') _p(' LINKCMD = $(AR) -rcs "$@" $(OBJECTS)')
end end
elseif cfg.kind == premake.UTILITY then
-- Empty LINKCMD for Utility (only custom build rules)
_p(' LINKCMD =')
else else
-- this was $(TARGET) $(LDFLAGS) $(OBJECTS) -- this was $(TARGET) $(LDFLAGS) $(OBJECTS)
-- but had trouble linking to certain static libs; $(OBJECTS) moved up -- but had trouble linking to certain static libs; $(OBJECTS) moved up