From a7bc15fcce2be3b884201d71c07dfafadf1ec190 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Wed, 17 Apr 2019 20:53:08 -0700 Subject: [PATCH] Let --with-opengl default to automatic, don't link with the lib if it wasn't built. --- buildtools/build_wxwidgets.py | 1 - wscript | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/buildtools/build_wxwidgets.py b/buildtools/build_wxwidgets.py index 6f6bd883..9d4c5681 100644 --- a/buildtools/build_wxwidgets.py +++ b/buildtools/build_wxwidgets.py @@ -280,7 +280,6 @@ def main(wxDir, args): configure_opts.append("--with-gtk=2") wxpy_configure_opts = [ - "--with-opengl", "--enable-sound", "--enable-graphics_ctx", "--enable-display", diff --git a/wscript b/wscript index 7cd98daf..058cdb3d 100644 --- a/wscript +++ b/wscript @@ -221,8 +221,12 @@ def configure(conf): uselib_store='WXHTML', mandatory=True, msg='Finding libs for WXHTML') + if cfg.checkSetup(wxConfigDir, 'wxUSE_GLCANVAS'): + gl_libs = '--libs gl,core,net' + else: + gl_libs = '--libs core,net' conf.check_cfg(path=conf.options.wx_config, package='', - args='--cxxflags --libs gl,core,net' + rpath, + args='--cxxflags ' + gl_libs + rpath, uselib_store='WXGL', mandatory=True, msg='Finding libs for WXGL')