Skip to content

Commit

Permalink
build: Replace lingering instances of Options.platform
Browse files Browse the repository at this point in the history
  • Loading branch information
tomhenderson committed Aug 26, 2018
1 parent 8ccb787 commit 971c25b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion contrib/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ def ns3_python_bindings(bld):
pymod.env.append_value('LINKFLAGS', '-Wl,-Bdynamic,--no-whole-archive')
defines = list(pymod.env['DEFINES'])
defines.extend(['NS_DEPRECATED=', 'NS3_DEPRECATED_H'])
if Options.platform == 'win32':
if Utils.unversioned_sys_platform() == 'win32':
try:
defines.remove('_DEBUG') # causes undefined symbols on win32
except ValueError:
Expand Down
2 changes: 1 addition & 1 deletion src/internet/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def configure(conf):
"NSC not found (see option --with-nsc)")
return

if Options.platform in ['linux', 'freebsd']:
if Utils.unversioned_sys_platform() in ['linux', 'freebsd']:
arch = os.uname()[4]
else:
arch = None
Expand Down
4 changes: 2 additions & 2 deletions wscript
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ def configure(conf):

# bug 2181 on clang warning suppressions
if conf.env['CXX_NAME'] in ['clang']:
if Options.platform == 'darwin':
if Utils.unversioned_sys_platform() == 'darwin':
if conf.env['CC_VERSION'] >= darwin_clang_version_warn_unused_local_typedefs:
env.append_value('CXXFLAGS', '-Wno-unused-local-typedefs')
if conf.env['CC_VERSION'] >= darwin_clang_version_warn_potentially_evaluated:
Expand All @@ -435,7 +435,7 @@ def configure(conf):
env.append_value('CXXFLAGS', '-Wno-potentially-evaluated-expression')
env['ENABLE_STATIC_NS3'] = False
if Options.options.enable_static:
if Options.platform == 'darwin':
if Utils.unversioned_sys_platform() == 'darwin':
if conf.check_compilation_flag(flag=[], linkflags=['-Wl,-all_load']):
conf.report_optional_feature("static", "Static build", True, '')
env['ENABLE_STATIC_NS3'] = True
Expand Down

0 comments on commit 971c25b

Please sign in to comment.