forked from 0ad/0ad
Fix premake build on OS X by linking with the CoreServices framework. Fixes #1505.
Remove obsolete and unused parameters. Fixes #1179. This was SVN commit r11995.
This commit is contained in:
parent
b35bebbdbf
commit
efb6ac808b
@ -92,8 +92,16 @@ case "`uname -s`" in
|
||||
# Only GNU and FreeBSD sed have the -i option (and redirecting
|
||||
# to the same file results in an empty file and starting a subshell
|
||||
# isn't as obvious as redirecting to a new file and replacing the old)
|
||||
sed -e 's/ -ldl/ /g' build/gmake.unix/Premake4.make > build/gmake.unix/Premake4.make_new
|
||||
mv build/gmake.unix/Premake4.make_new build/gmake.unix/Premake4.make
|
||||
mv build/gmake.unix/Premake4.make build/gmake.unix/Premake4.make.bak
|
||||
sed -e 's/ -ldl/ /g' build/gmake.unix/Premake4.make.bak > build/gmake.unix/Premake4.make
|
||||
;;
|
||||
"Darwin" )
|
||||
# Remove the obsolete -s and the unused -rdynamic parameter and
|
||||
# link with the CoreServices framework.
|
||||
sed -e 's/^\([ ]*LDFLAGS[ ]*+=[ ]*\)\(\( [^ ]*\)*\) -s\(\( [^ ]*\)*\)$/\1\2\4/' \
|
||||
-e 's/^\([ ]*LDFLAGS[ ]*+=[ ]*\)\(\( [^ ]*\)*\) -rdynamic\(\( [^ ]*\)*\)$/\1\2\4/' \
|
||||
-e 's/^\([ ]*LIBS[ ]*+=[ ]*\)\(\( [^ ]*\)*\)$/\1\2 -framework CoreServices /' \
|
||||
-i.bak build/gmake.unix/Premake4.make
|
||||
;;
|
||||
esac
|
||||
${MAKE} -C build/gmake.unix ${JOBS} || die "Premake build failed"
|
||||
|
Loading…
Reference in New Issue
Block a user