-
Notifications
You must be signed in to change notification settings - Fork 8
/
Sconstruct
47 lines (39 loc) · 1.51 KB
/
Sconstruct
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!python3
from parts import *
#enable smart linking
SetOptionDefault("LINKFLAGS", ['-Wl,--copy-dt-needed-entries', '-Wl,--as-needed'])
SetOptionDefault("CPPFLAGS", ['-std=c++17', '-Wnon-virtual-dtor'])
SetOptionDefault("INSTALL_ROOT", "#")
# control shim for trafficserver
AddOption("--with-trafficserver",
dest='with_trafficserver',
nargs=1,
type='string',
action='store',
metavar='DIR',
default=None,
help='Optional path to custom build of trafficserver')
AddOption("--with-ssl",
dest='with_ssl',
nargs=1,
type='string',
action='store',
metavar='DIR',
default=None,
help='Optional path to custom build of OpenSSL'
)
# the depends
Part("code/libswoc.part"
,vcs_type=VcsGit(server="github.com", repository="SolidWallOfCode/libswoc", tag="1.5.8")
)
Part("#lib/libyaml-cpp.part", vcs_type=VcsGit(server="github.com", repository="jbeder/yaml-cpp.git", protocol="https", tag="0.8.0"))
#Part("#lib/libyaml-cpp.part")
# this is just a shim part. it passes info based on stuff being installed on the box
# it should have a better check for the real version of trafficserver being used
ts_path = GetOption("with_trafficserver")
Part("#lib/trafficserver.part", PKG_PREFIX=ts_path, PKG_VERSION="10.0.0")
path = GetOption("with_ssl")
Part("#lib/openssl.part", CUSTOM_PATH=path)
# The main build.
Part("plugin/txn_box.part", package_group='txn_box')
#Part("test/unit_tests/unit_tests.part")