aboutsummaryrefslogtreecommitdiff
path: root/libbutl/buildfile
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2018-07-12 12:18:03 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2018-07-12 12:18:03 +0300
commit8f63b9971ac6d5a0efa370fd8b294fcffd98fd09 (patch)
tree0427232c68f073928ef00e5b31df5ba23072e047 /libbutl/buildfile
parent237e1a6399172cf997dc24e1eea5161c0285f998 (diff)
Use prerequisite exclusion to simplify buildfile
Diffstat (limited to 'libbutl/buildfile')
-rw-r--r--libbutl/buildfile11
1 files changed, 5 insertions, 6 deletions
diff --git a/libbutl/buildfile b/libbutl/buildfile
index 8320ed0..d64f630 100644
--- a/libbutl/buildfile
+++ b/libbutl/buildfile
@@ -16,12 +16,11 @@ if ($force_std_modules == true)
lib{butl}: {mxx hxx ixx txx cxx}{** -win32-utility -version} {hxx}{version} \
$int_libs
+windows = ($cxx.target.class == 'windows')
+
# Exclude these from compilation on non-Windows targets.
#
-if ($cxx.target.class == "windows")
- lib{butl}: {hxx cxx}{win32-utility}
-else
- lib{butl}: file{win32-utility.?xx}
+lib{butl}: {hxx cxx}{win32-utility}: include = $windows
# The C-files are included into sha256.cxx (sha256c.c) and timestamp.cxx
# (strptime.c timelocal.h timelocal.c), so treat them as files to exclude from
@@ -55,9 +54,9 @@ lib{butl}: cxx.export.poptions = "-I$out_root" "-I$src_root"
liba{butl}: cxx.export.poptions += -DLIBBUTL_STATIC
libs{butl}: cxx.export.poptions += -DLIBBUTL_SHARED
-if ($cxx.target.class == "windows")
+if $windows
{
- if ($cxx.target.system == "mingw32")
+ if ($cxx.target.system == 'mingw32')
cxx.libs += -limagehlp
else
cxx.libs += imagehlp.lib