2

I'm trying to use different modules (with independent wscript files) across several projects, so that modules can be developed in a one place and can be checked out in many places.

I have a project's top wscript like this:

def configure(cfg):
  ...
  cfg.recurse('a')
  cfg.recurse('b')
  ...

And wscript's in modules from subdirs './a' and './b':

def configure(cfg):
  ...
  cfg.check_cxx(lib='z')
  ...

So, is there a way to tell waf to check libz only once?

abyss.7
  • 13,882
  • 11
  • 56
  • 100

1 Answers1

0

Nope, there isn't something built-in to do that. I can just suggest workarounds : - get something you know will be defined by the check_cxx if "LIB_Z" not in cfg.env: cfg.check_cxx(...) - or add make check_cxx define something if cfg.get_define("HAVE_ZLIB") is not None: cfg.check_cxx(lib='z', define_name="HAVE_ZLIB")

I doubt any caching can be performed in methods such as check_cxx, they can do a lot of things and are controlled by keywords...

cJ Zougloub
  • 1,484
  • 10
  • 19