summaryrefslogtreecommitdiff
path: root/wscript
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-10-18 22:18:15 +0100
committerCarl Hetherington <cth@carlh.net>2014-10-18 22:18:15 +0100
commit734340b52d30cb2dde9aa9e81c77277b261b128e (patch)
tree1671d2f9c409cf2c58570b3d068bb4f071355848 /wscript
parent49a5dd1b69c4bb7ed27ba0e23b2161fe4521f775 (diff)
Fix build on Debian unstable which now has GraphicsMagick rather than ImageMagick.
Diffstat (limited to 'wscript')
-rw-r--r--wscript10
1 files changed, 9 insertions, 1 deletions
diff --git a/wscript b/wscript
index eb80b9efc..f5d1a1c34 100644
--- a/wscript
+++ b/wscript
@@ -1,6 +1,8 @@
import subprocess
import os
import sys
+import distutils
+import distutils.spawn
APPNAME = 'dcpomatic'
VERSION = '1.75.1devel'
@@ -322,7 +324,13 @@ def configure(conf):
# Dependencies which are always dynamically linked
conf.check_cfg(package='sndfile', args='--cflags --libs', uselib_store='SNDFILE', mandatory=True)
conf.check_cfg(package='glib-2.0', args='--cflags --libs', uselib_store='GLIB', mandatory=True)
- conf.check_cfg(package= '', path=conf.options.magickpp_config, args='--cppflags --cxxflags --libs', uselib_store='MAGICK', mandatory=True)
+ if distutils.spawn.find_executable(conf.options.magickpp_config):
+ conf.check_cfg(package='', path=conf.options.magickpp_config, args='--cppflags --cxxflags --libs', uselib_store='MAGICK', mandatory=True)
+ conf.env.append_value('CXXFLAGS', '-DDCPOMATIC_IMAGE_MAGICK')
+ else:
+ conf.check_cfg(package='GraphicsMagick++', args='--cppflags --cxxflags --libs', uselib_store='MAGICK', mandatory=True)
+ conf.env.append_value('CXXFLAGS', '-DDCPOMATIC_GRAPHICS_MAGICK')
+
conf.check_cfg(package='libzip', args='--cflags --libs', uselib_store='ZIP', mandatory=True)
conf.check_cc(fragment="""