Add Debian patch for separate stripping options for Win32 & cross-platform options

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@5368 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
pabs3 2007-11-14 06:20:44 +00:00
parent 1422e49ff8
commit 018b9cc347
2 changed files with 17 additions and 5 deletions

View file

@ -67,7 +67,7 @@ stub_env.Append(CCFLAGS = '-Wall') # all warnings
stub_env.Append(CCFLAGS = '-x c') # force compile as c
stub_env.Append(CCFLAGS = '-fno-strict-aliasing') # not safe for strict aliasing
if not defenv['DEBUG'] and defenv['STRIP']:
if not defenv['DEBUG'] and defenv['STRIP'] and defenv['STRIP_W32']:
stub_env.Append(LINKFLAGS = '-s') # strip
stub_env.Append(LINKFLAGS = '-mwindows') # build windows executables
stub_env.Append(LINKFLAGS = '$NODEFLIBS_FLAG') # no standard libraries
@ -88,7 +88,7 @@ conf = FlagsConfigure(makensis_env)
conf.CheckCompileFlag('-m32') #
conf.CheckLinkFlag('-m32') #
conf.CheckLinkFlag('$MAP_FLAG') # generate map file
if not defenv['DEBUG'] and defenv['STRIP']:
if not defenv['DEBUG'] and defenv['STRIP'] and defenv['STRIP_CP']:
TestStrip(conf) # strip
conf.Finish()
@ -102,7 +102,7 @@ if not defenv['DEBUG']:
plugin_env.Append(CCFLAGS = '-Wall') # level 3 warnings
plugin_env.Append(CCFLAGS = '-fno-strict-aliasing') # not safe for strict aliasing
if not defenv['DEBUG'] and defenv['STRIP']:
if not defenv['DEBUG'] and defenv['STRIP'] and defenv['STRIP_W32']:
plugin_env.Append(LINKFLAGS = '-s') # strip
plugin_env.Append(LINKFLAGS = '-mwindows') # build windows executables
plugin_env.Append(LINKFLAGS = '$ALIGN_FLAG') # 512 bytes align
@ -119,8 +119,6 @@ cp_util_env.Append(CCFLAGS = '-fno-strict-aliasing') # not safe for strict alias
conf = FlagsConfigure(cp_util_env)
conf.CheckLinkFlag('$MAP_FLAG') # generate map file
if not defenv['DEBUG'] and defenv['STRIP']:
TestStrip(conf) # strip
conf.Finish()
### util environment
@ -131,6 +129,18 @@ cross_env(util_env)
util_env.Append(LINKFLAGS = '-mwindows') # build windows executables
util_env.Append(LINKFLAGS = '$ALIGN_FLAG') # 512 bytes align
conf = FlagsConfigure(util_env)
if not defenv['DEBUG'] and defenv['STRIP'] and defenv['STRIP_W32']:
util_env.Append(LINKFLAGS = '-s') # strip
conf.Finish()
### cross-platform util environment stripping
conf = FlagsConfigure(cp_util_env)
if not defenv['DEBUG'] and defenv['STRIP'] and defenv['STRIP_CP']:
TestStrip(conf) # strip
conf.Finish()
### test environment
test_env = defenv.Clone()