Missing include and boost::
[dcpomatic.git] / wscript
diff --git a/wscript b/wscript
index 98a098f7e7ce67ad991f01695a81a6cd4374f932..46f2a6815ecdb388d1eee2ee560f9433fd3dee3b 100644 (file)
--- a/wscript
+++ b/wscript
@@ -25,7 +25,10 @@ def configure(conf):
     conf.options.disable_player = True
 
     if conf.options.target_windows:
-        conf.env.append_value('CXXFLAGS', ['-DDVDOMATIC_WINDOWS', '-DWIN32_LEAN_AND_MEAN'])
+        conf.env.append_value('CXXFLAGS', ['-DDVDOMATIC_WINDOWS', '-DWIN32_LEAN_AND_MEAN', '-DBOOST_USE_WINDOWS_H'])
+        if conf.options.enable_debug:
+            conf.env.append_value('CXXFLAGS', ['-mconsole'])
+            conf.env.append_value('LINKFLAGS', ['-mconsole'])
         conf.options.disable_player = True
         conf.check(lib = 'ws2_32', uselib_store = 'WINSOCK2', msg = "Checking for library winsock2")
         boost_lib_suffix = '-mt'
@@ -48,7 +51,6 @@ def configure(conf):
     else:
         conf.env.append_value('CXXFLAGS', '-O3')
 
-    conf.check_cfg(package = 'sigc++-2.0', args = '--cflags --libs', uselib_store = 'SIGC++', mandatory = True)
     conf.check_cfg(package = 'libavformat', args = '--cflags --libs', uselib_store = 'AVFORMAT', mandatory = True)
     conf.check_cfg(package = 'libavfilter', args = '--cflags --libs', uselib_store = 'AVFILTER', mandatory = True)
     conf.check_cfg(package = 'libavcodec', args = '--cflags --libs', uselib_store = 'AVCODEC', mandatory = True)
@@ -57,7 +59,7 @@ def configure(conf):
     conf.check_cfg(package = 'libswresample', args = '--cflags --libs', uselib_store = 'SWRESAMPLE', mandatory = False)
     conf.check_cfg(package = 'libpostproc', args = '--cflags --libs', uselib_store = 'POSTPROC', mandatory = True)
     conf.check_cfg(package = 'sndfile', args = '--cflags --libs', uselib_store = 'SNDFILE', mandatory = True)
-    conf.check_cfg(package = 'libdcp', atleast_version = '0.21', args = '--cflags --libs', uselib_store = 'DCP', mandatory = True)
+    conf.check_cfg(package = 'libdcp', atleast_version = '0.24', args = '--cflags --libs', uselib_store = 'DCP', mandatory = True)
     conf.check_cfg(package = 'glib-2.0', args = '--cflags --libs', uselib_store = 'GLIB', mandatory = True)
     conf.check_cfg(package = '', path = 'Magick++-config', args = '--cppflags --cxxflags --libs', uselib_store = 'MAGICK', mandatory = True)
     conf.check_cc(msg = 'Checking for library libtiff', function_name = 'TIFFOpen', header_name = 'tiffio.h', lib = 'tiff', uselib_store = 'TIFF')
@@ -101,6 +103,13 @@ def configure(conf):
                               lib = ['boost_date_time%s' % boost_lib_suffix, 'boost_system%s' % boost_lib_suffix],
                               uselib_store = 'BOOST_DATETIME')
 
+    conf.check_cxx(fragment = """
+                             #include <boost/signals2.hpp>\n
+                             int main() { boost::signals2::signal<void (int)> x; }\n
+                             """,
+                              msg = 'Checking for boost signals2 library',
+                              uselib_store = 'BOOST_SIGNALS2')
+
     conf.check_cc(fragment = """
                              #include <glib.h>
                              int main() { g_format_size (1); }