-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathSConstruct
More file actions
60 lines (52 loc) · 1.76 KB
/
SConstruct
File metadata and controls
60 lines (52 loc) · 1.76 KB
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
48
49
50
51
52
53
54
55
56
57
58
59
60
# -*- python -*-
import os
from lsst.sconsUtils import scripts, targets
from lsst.sconsUtils.state import env
from lsst.sconsUtils.utils import libraryLoaderEnvironment
from SCons.Script import Default
# Python-only package
# Force shebang and policy to come first so the file first appears in the bin
# directory before it is used. This is required to run on macos.
PKG_ROOT = env.ProductDir("ap_pipe")
additional_fakes_tasks = os.path.join(
PKG_ROOT,
"pipelines",
"_ingredients",
"injection",
"ApPipePostInjectedTasks.yaml",
)
ap_pipe_with_fakes_path = os.path.join(
PKG_ROOT,
"pipelines",
"_ingredients",
"ApPipeWithFakes.yaml"
)
subset_names = ["apPipe", "prompt"]
ingredients_ap_pipe_with_fakes = env.Command(
target=ap_pipe_with_fakes_path,
source=os.path.join(PKG_ROOT, "pipelines", "_ingredients", "ApPipe.yaml"),
action=" ".join(
[
libraryLoaderEnvironment(),
f"make_injection_pipeline -t preliminary_visit_image -r $SOURCE -f $TARGET "
f"-a {additional_fakes_tasks} ",
" ".join(f"-s {subset_name}" for subset_name in subset_names),
f"--config injectVisit:external_psf=False ",
f"--config injectVisit:external_photo_calib=False ",
f"--config injectVisit:external_wcs=False ",
f"--prefix 'fakes_' -c parameters:apdb_config='-' --overwrite ",
]
),
)
Default([ingredients_ap_pipe_with_fakes])
targetList = (
"version",
"shebang",
"policy",
ap_pipe_with_fakes_path,
) + scripts.DEFAULT_TARGETS
scripts.BasicSConstruct(
"ap_pipe", disableCc=True, noCfgFile=False, defaultTargets=targetList,
)
env.Depends(ap_pipe_with_fakes_path, targets["version"])
env.Depends(targets["tests"], ap_pipe_with_fakes_path)