Changeset - r16917:d6808c2ce4e9
[Not reviewed]
master
0 2 0
smatz - 14 years ago 2010-12-29 20:46:35
smatz@openttd.org
(svn r21662) -Codechange: use -flto=jobserver for GCC 4.6, it makes linking with LTO use number of processes passed to make -j
2 files changed with 7 insertions and 3 deletions:
0 comments (0 inline, 0 general)
Makefile.src.in
Show inline comments
 
@@ -256,9 +256,9 @@ ifeq ($(OS), PSP)
 
	# Because of a bug in the PSP GCC tools, linking via CXX results
 
	#  in total chaos and more problems then you can handle. So we need
 
	#  CC to link OpenTTD for PSP
 
	$(Q)$(CC_HOST) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
 
	$(Q)+$(CC_HOST) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
 
else
 
	$(Q)$(CXX_HOST) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
 
	$(Q)+$(CXX_HOST) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
 
endif
 
ifdef STRIP
 
	$(Q)$(STRIP) $@
config.lib
Show inline comments
 
@@ -1295,7 +1295,11 @@ make_compiler_cflags() {
 
			has_lto=`$1 -dumpspecs | grep '\%{flto'`
 
			if [ -n "$has_lto" ]; then
 
				# Use LTO only if we see LTO exists and is requested
 
				flags="$flags -flto"
 
				if [ $cc_version -lt 46 ]; then
 
					flags="$flags -flto"
 
				else
 
					flags="$flags -flto=jobserver"
 
				fi
 
				ldflags="$ldflags -fwhole-program"
 
				features="$features lto"
 
			fi
0 comments (0 inline, 0 general)