forked from SCons/scons
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSConstruct
More file actions
30 lines (26 loc) · 724 Bytes
/
SConstruct
File metadata and controls
30 lines (26 loc) · 724 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# SPDX-License-Identifier: MIT
#
# Copyright The SCons Foundation
env = Environment(
CPPPATH=['#'],
LIBPATH=['libB', 'libA'],
LIBS=['A', 'B'],
RPATH=['libA', 'libB'],
)
conf = Configure(env)
if not conf.CheckLibWithHeader(
['B'],
header="libB/libB.h",
language='C',
extra_libs=['A'],
call='libB();',
autoadd=False,
):
print("Cannot build against 'B' library, exiting.")
Exit(1)
env = conf.Finish()
# TODO: we should be able to build and run a test program now,
# to make sure Configure() didn't lie to us about usability.
# Disabled for now, because that's trickier in Windows (the rpath
# only works for Linux)
# env.Program(target="testlibs", source="src/test.c")