Try to check for boost 1.45 for filesystem::resize_file().
authorCarl Hetherington <cth@carlh.net>
Sat, 2 Feb 2013 15:17:16 +0000 (15:17 +0000)
committerCarl Hetherington <cth@carlh.net>
Sat, 2 Feb 2013 15:17:16 +0000 (15:17 +0000)
wscript

diff --git a/wscript b/wscript
index a0734d090af0948e040234118f1e67a1b1749de0..76e08ef53e0b7ec4bd052bb2dddeba6d5b922b5b 100644 (file)
--- a/wscript
+++ b/wscript
@@ -46,6 +46,18 @@ def configure(conf):
         # Windows builds are any more reliable
         conf.env.append_value('CXXFLAGS', '-O2')
 
+    conf.check_cxx(fragment = """
+                              #include <boost/version.hpp>\n
+                              #if BOOST_VERSION < 104500\n
+                              #error boost too old\n
+                              #endif\n
+                              int main(void) { return 0; }\n
+                              """,
+                   mandatory = True,
+                   msg = 'Checking for boost library >= 1.45',
+                   okmsg = 'ok',
+                   errmsg = 'too old\nPlease install boost version 1.45 or higher.')
+
     conf.check_cxx(fragment = """
                              #include <boost/filesystem.hpp>\n
                              int main() { boost::filesystem::copy_file ("a", "b"); }\n