X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=wscript;h=6dd7417cda41fefa7cd0b76389a0f829820f7523;hb=a45f6245e8cc785fab436c9282fa3d1baf3a8575;hp=2ca54488e32df843e184c57d82939c66f8e155b3;hpb=c59a10bcf428154c7d1c9e3fad4469af36bb7d91;p=dcpomatic.git diff --git a/wscript b/wscript index 2ca54488e..6dd7417cd 100644 --- a/wscript +++ b/wscript @@ -147,8 +147,10 @@ def configure(conf): conf.env.append_value('CXXFLAGS', ['-Wno-cast-function-type']) # Most gccs still give these warnings from boost::optional conf.env.append_value('CXXFLAGS', ['-Wno-maybe-uninitialized']) - if int(gcc[0]) > 4: + if int(gcc[0]) > 8: # gcc 4.8.5 on Centos 7 does not have this warning + # gcc 7.5.0 on Ubuntu 18.04 and gcc 8.3.0 on Debian 10 do, but + # I didn't manage to turn it back off again with a pragma conf.env.append_value('CXXFLAGS', ['-Wsuggest-override']) if conf.options.enable_debug: @@ -288,6 +290,15 @@ def configure(conf): uselib="ZIP", define_name='DCPOMATIC_HAVE_ZIP_FILE_ADD' ) + conf.check_cxx(fragment=""" + #include + int main() { int error; zip_open("foo", ZIP_RDONLY, &error); } + """, + mandatory=False, + msg="Checking for ZIP_RDONLY", + uselib="ZIP", + define_name='DCPOMATIC_HAVE_ZIP_RDONLY' + ) # libbz2; must be explicitly linked on macOS for some reason conf.check_cxx(fragment="""