diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2018-07-12 12:18:03 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2018-07-12 12:18:03 +0300 |
commit | 8f63b9971ac6d5a0efa370fd8b294fcffd98fd09 (patch) | |
tree | 0427232c68f073928ef00e5b31df5ba23072e047 | |
parent | 237e1a6399172cf997dc24e1eea5161c0285f998 (diff) |
Use prerequisite exclusion to simplify buildfile
-rw-r--r-- | libbutl/buildfile | 11 |
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 |