Skip to content

Commit

Permalink
add conditional logic for freebsd vs linux
Browse files Browse the repository at this point in the history
  • Loading branch information
bovine committed Jul 6, 2012
1 parent ae3bd96 commit 53f335f
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions wscript
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# -*- python -*-

import sys

def set_options(opt):
opt.tool_options("compiler_cxx")

Expand All @@ -9,8 +11,13 @@ def configure(conf):

def build(bld):
obj = bld.new_task_gen("cxx", "shlib", "node_addon")
obj.cxxflags = ["-g", "-D_FILE_OFFSET_BITS=64", "-D_LARGEFILE_SOURCE", "-Wall",
"-I/usr/local/include/tcl8.5" ]
obj.ldflags = [ "-ltcl85" ]
obj.cxxflags = ["-g", "-D_FILE_OFFSET_BITS=64", "-D_LARGEFILE_SOURCE", "-Wall"]

if sys.platform.startswith('freebsd'):
obj.cxxflags.append("-I/usr/local/include/tcl8.5")
obj.ldflags = [ "-ltcl85" ]
else:
obj.ldflags = [ "-ltcl8.5" ]

obj.target = "nodetcl"
obj.source = "src/nodetcl.cc"

0 comments on commit 53f335f

Please sign in to comment.