modify gmake Makefile LINKCMD $(TARGET) to "$@" issue #125
This commit is contained in:
parent
7101edc54d
commit
91ec1f2f4f
@ -426,9 +426,9 @@
|
|||||||
function make.linkCmd(cfg, toolset)
|
function make.linkCmd(cfg, toolset)
|
||||||
if cfg.kind == premake.STATICLIB then
|
if cfg.kind == premake.STATICLIB then
|
||||||
if cfg.architecture == premake.UNIVERSAL then
|
if cfg.architecture == premake.UNIVERSAL then
|
||||||
_p(' LINKCMD = libtool -o $(TARGET) $(OBJECTS)')
|
_p(' LINKCMD = libtool -o "$@" $(OBJECTS)')
|
||||||
else
|
else
|
||||||
_p(' LINKCMD = $(AR) -rcs $(TARGET) $(OBJECTS)')
|
_p(' LINKCMD = $(AR) -rcs "$@" $(OBJECTS)')
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
-- this was $(TARGET) $(LDFLAGS) $(OBJECTS)
|
-- this was $(TARGET) $(LDFLAGS) $(OBJECTS)
|
||||||
@ -437,7 +437,7 @@
|
|||||||
-- $(LIBS) moved to end (http://sourceforge.net/p/premake/bugs/279/)
|
-- $(LIBS) moved to end (http://sourceforge.net/p/premake/bugs/279/)
|
||||||
|
|
||||||
local cc = iif(cfg.language == "C", "CC", "CXX")
|
local cc = iif(cfg.language == "C", "CC", "CXX")
|
||||||
_p(' LINKCMD = $(%s) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)', cc)
|
_p(' LINKCMD = $(%s) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)', cc)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
prepare { "ldFlags", "linkCmd" }
|
prepare { "ldFlags", "linkCmd" }
|
||||||
test.capture [[
|
test.capture [[
|
||||||
ALL_LDFLAGS += $(LDFLAGS) -s -shared
|
ALL_LDFLAGS += $(LDFLAGS) -s -shared
|
||||||
LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
|
LINKCMD = $(CXX) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
|
||||||
]]
|
]]
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -51,7 +51,7 @@
|
|||||||
prepare { "ldFlags", "linkCmd" }
|
prepare { "ldFlags", "linkCmd" }
|
||||||
test.capture [[
|
test.capture [[
|
||||||
ALL_LDFLAGS += $(LDFLAGS) -s -shared
|
ALL_LDFLAGS += $(LDFLAGS) -s -shared
|
||||||
LINKCMD = $(CC) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
|
LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
|
||||||
]]
|
]]
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -65,7 +65,7 @@
|
|||||||
prepare { "ldFlags", "linkCmd" }
|
prepare { "ldFlags", "linkCmd" }
|
||||||
test.capture [[
|
test.capture [[
|
||||||
ALL_LDFLAGS += $(LDFLAGS) -s
|
ALL_LDFLAGS += $(LDFLAGS) -s
|
||||||
LINKCMD = $(AR) -rcs $(TARGET) $(OBJECTS)
|
LINKCMD = $(AR) -rcs "$@" $(OBJECTS)
|
||||||
]]
|
]]
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -80,7 +80,7 @@
|
|||||||
prepare { "ldFlags", "linkCmd" }
|
prepare { "ldFlags", "linkCmd" }
|
||||||
test.capture [[
|
test.capture [[
|
||||||
ALL_LDFLAGS += $(LDFLAGS) -s
|
ALL_LDFLAGS += $(LDFLAGS) -s
|
||||||
LINKCMD = libtool -o $(TARGET) $(OBJECTS)
|
LINKCMD = libtool -o "$@" $(OBJECTS)
|
||||||
]]
|
]]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user