SConscript (13098:e5f37a4dbbd0) SConscript (13438:924abb66cea7)
1# Copyright 2018 Google, Inc.
2#
3# Redistribution and use in source and binary forms, with or without
4# modification, are permitted provided that the following conditions are
5# met: redistributions of source code must retain the above copyright
6# notice, this list of conditions and the following disclaimer;
7# redistributions in binary form must reproduce the above copyright
8# notice, this list of conditions and the following disclaimer in the

--- 47 unchanged lines hidden (view full) ---

56
57 def properties(self):
58 return {
59 'name' : self.name,
60 'path' : self.reldir,
61 'compile_only' : self.compile_only
62 }
63
1# Copyright 2018 Google, Inc.
2#
3# Redistribution and use in source and binary forms, with or without
4# modification, are permitted provided that the following conditions are
5# met: redistributions of source code must retain the above copyright
6# notice, this list of conditions and the following disclaimer;
7# redistributions in binary form must reproduce the above copyright
8# notice, this list of conditions and the following disclaimer in the

--- 47 unchanged lines hidden (view full) ---

56
57 def properties(self):
58 return {
59 'name' : self.name,
60 'path' : self.reldir,
61 'compile_only' : self.compile_only
62 }
63
64 ext_dir = Dir('..').Dir('ext')
65 test_dir = Dir('.')
66 class SystemCTestBin(Executable):
67 def __init__(self, test):
68 super(SystemCTestBin, self).__init__(test.target, *test.sources)
69
70 @classmethod
71 def declare_all(cls, env):
72 env = env.Clone()
73
74 # Turn off extra warnings and Werror for the tests.
75 to_remove = ['-Wall', '-Wundef', '-Wextra', '-Werror']
76 env['CCFLAGS'] = \
77 filter(lambda f: f not in to_remove, env['CCFLAGS'])
78
79 env.Append(CPPPATH=test_dir.Dir('include'))
64 test_dir = Dir('.')
65 class SystemCTestBin(Executable):
66 def __init__(self, test):
67 super(SystemCTestBin, self).__init__(test.target, *test.sources)
68
69 @classmethod
70 def declare_all(cls, env):
71 env = env.Clone()
72
73 # Turn off extra warnings and Werror for the tests.
74 to_remove = ['-Wall', '-Wundef', '-Wextra', '-Werror']
75 env['CCFLAGS'] = \
76 filter(lambda f: f not in to_remove, env['CCFLAGS'])
77
78 env.Append(CPPPATH=test_dir.Dir('include'))
80 env.Append(CPPPATH=ext_dir)
81
82 shared_lib_path = env['SHARED_LIB'][0].abspath
83 sl_dir, sl_base = os.path.split(shared_lib_path)
84 env.Append(LIBPATH=[sl_dir], LIBS=[sl_base])
85
86 super(SystemCTestBin, cls).declare_all(env)
87
88 def declare(self, env):

--- 85 unchanged lines hidden ---
79
80 shared_lib_path = env['SHARED_LIB'][0].abspath
81 sl_dir, sl_base = os.path.split(shared_lib_path)
82 env.Append(LIBPATH=[sl_dir], LIBS=[sl_base])
83
84 super(SystemCTestBin, cls).declare_all(env)
85
86 def declare(self, env):

--- 85 unchanged lines hidden ---