scons bindings=cpp test works

This commit is contained in:
Meredith L. Patterson 2014-01-16 19:45:32 +01:00
parent 7e5e0f00b6
commit fb1410c049
2 changed files with 8 additions and 2 deletions

View file

@ -1,5 +1,6 @@
# -*- python -*-
Import("env libhammer_shared")
import os.path
Import("env libhammer_shared testruns targets")
cppenv = env.Clone()
cppenv.Append(CPPPATH=[".", "vendor/gtest-1.7.0/fused-src", "../.."])
@ -10,4 +11,10 @@ gtest = cppenv.Object("vendor/gtest-1.7.0/fused-src/gtest/gtest-all.cc")
hammer_test = cppenv.Program("hammer_test", libhammer_shared + gtest + ['cpp_tests.cpp'])
cpptest = Alias('testcpp', [hammer_test], "".join(["env LD_LIBRARY_PATH=", os.path.dirname(str(libhammer_shared[0])), " ", hammer_test[0].path]))
AlwaysBuild(cpptest)
testruns.append(cpptest)
cppinstallexec = cppenv.Install("$incpath", ['hammer/hammer.hpp', 'hammer/hammer_test.hpp'])
cppinstall = Alias("installcpp", [cppinstallexec], cppinstallexec)
targets.append(cppinstall)

View file

@ -1 +0,0 @@