summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/wx/wx_util.cc2
-rw-r--r--wscript4
2 files changed, 5 insertions, 1 deletions
diff --git a/src/wx/wx_util.cc b/src/wx/wx_util.cc
index 8e86a5408..9526b234c 100644
--- a/src/wx/wx_util.cc
+++ b/src/wx/wx_util.cc
@@ -627,7 +627,7 @@ bitmap_path(string name)
{
boost::filesystem::path base;
-#ifdef DCPOMATIC_DEBUG
+#ifdef DCPOMATIC_DEVELOPER
/* Hack to allow Linux and OS X to find icons when running from the source tree */
char* path = getenv("DCPOMATIC_GRAPHICS");
if (path) {
diff --git a/wscript b/wscript
index f55e241ab..d1e71d7d6 100644
--- a/wscript
+++ b/wscript
@@ -80,6 +80,7 @@ def options(opt):
opt.add_option('--enable-asan', action='store_true', help='build with asan')
opt.add_option('--c++17', action='store_true', default=False, help='build with C++17 and libxml++-4.0')
opt.add_option('--variant', help="build with variant")
+ opt.add_option('--developer', action='store_true', default=False, help='find resources (e.g. bitmaps) when running from the source tree')
def configure(conf):
conf.load('compiler_cxx')
@@ -176,6 +177,9 @@ def configure(conf):
if conf.options.enable_grok:
conf.env.append_value('CXXFLAGS', '-DDCPOMATIC_GROK')
+ if conf.options.developer:
+ conf.env.append_value('CXXFLAGS', '-DDCPOMATIC_DEVELOPER')
+
if conf.options.use_lld:
try:
conf.find_program('ld.lld')