[*] bypass cmd limits when linking

This commit is contained in:
Reece Wilson 2023-12-19 05:12:51 +00:00
parent 5fabba42e9
commit b6e035aa35

View File

@ -455,8 +455,7 @@
-- $(LDFLAGS) moved to end (http://sourceforge.net/p/premake/patches/107/)
-- $(LIBS) moved to end (http://sourceforge.net/p/premake/bugs/279/)
local cc = iif(p.languages.isc(cfg.language), "CC", "CXX")
p.outln('LINKCMD = $(' .. cc .. ') -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)')
p.outln('LINKCMD = -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)')
end
end
@ -663,10 +662,12 @@
targets = targets .. ' $(RESOURCES)'
end
local cc = iif(p.languages.isc(cfg.language), "CC", "CXX")
_p('$(TARGET): %s | $(TARGETDIR)', targets)
_p('\t$(PRELINKCMDS)')
_p('\t@echo Linking %s', cfg.project.name)
_p('\t$(SILENT) $(LINKCMD)')
_p('\t$(file > $(OBJDIR)/linkcmds.cli, $(LINKCMD))')
_p('\t$(' .. cc .. ') @$(OBJDIR)/linkcmds.cli')
_p('\t$(POSTBUILDCMDS)')
_p('')
end