Questions tagged [waf]

Waf is a Python-based framework for configuring, compiling and installing applications. It derives from the concepts of other build tools such as Scons, Autotools, CMake or Ant. If your question is about AWS WAF, use [amazon-waf] instead. If your question is about web application firewall, use [web-application-firewall] instead.

More information about the Waf project can be found at the following locations.

Help is also available:

  • on the waf-users mailing list
  • on IRC (#waf on freenode, with searchable, archived logs here).
309 questions
3
votes
1 answer

Dynamic task generators

I am evaluating waf build for an existing project that has tasks similar to that: 1. preprocessing phase: datafile => TransformationTask => library name list 2. for each library name: 2.1 import files from repository 2.2 build library The…
maver
  • 41
  • 3
3
votes
1 answer

Going mad trying to compile against OpenSSL/libcrypto

I have been trying to do this for nearly 3 days now. Its driving me nuts. As you can imagine I'm quite new to C++. Can anyone give me step by step instructions to do a hello world program making use of a function in openssl and compile it from a…
Tom
  • 7,994
  • 8
  • 45
  • 62
3
votes
1 answer

How to run WAF compiled C++ program from within test script?

Dear WAF build system experts, Let's suppose that you use the WAF build system to build a library fooLib and a program fooProg. Then, you want to check the program fooProg by a Python script fooProgTest that checks the output of fooProg. Here is…
M_Kulas
  • 53
  • 5
3
votes
3 answers

is there any way to configure waf to build c++ program in mac os?

I just suffer a problem that the all the things works well on my ubuntu. However, I want to get things work on my mac, bad thing happens. it shows the following errors cc1plus: error: unrecognized command line option "-std=c++0x" I am total new…
Monkey_Taolun
  • 49
  • 1
  • 6
3
votes
2 answers

Waf can't be invoked - ImportError: cannot import name Scripting

I'm trying to install ns-3 network simulator, and I'm building a simple script that would install all prerequisites on fresh install of latest Ubuntu LTS OS(18.04). Everything goes smooth but once I try to run any test, I get following…
Rorschach
  • 734
  • 2
  • 7
  • 22
3
votes
1 answer

Specify different compilers in waf

I want to have several build configurations (meaning different C compilers) configured in waf. I managed to do it that way, but it looks a bit smelly to me. How do I do it currently: I make different envs, and reset the c_compiler list before…
user69453
  • 1,279
  • 1
  • 17
  • 43
3
votes
1 answer

Custom waf task does neither run nor find sources

In my wscript I run some custom Task (dummy) after the apply_link method, and this works fine. After this dummy-task has finished I want to collect all of my output files (let it be *.dll, *.exe, *.o, *.a or *.elf) and run another task on these…
wafwafwaf
  • 191
  • 9
3
votes
1 answer

Use output of waf Task in other waf Task

I want to use the target of a waf Task as source in another waf Task, but this does not work as expected. A simple but complete example: I added two Tasks (t_1, t_2) I want to add as a feature and added their constraints by before and after. In…
wafwafwaf
  • 191
  • 9
3
votes
2 answers

Can't configure node.js for make install on OS X (Snow Leopard)

I cloned the node git repo but the "waf" build tool that comes with node seems to not work with the latest version of Python. $ ./configure Traceback (most recent call last): File "/Users/greim/nodestuff/node/tools/waf-light", line 157, in…
greim
  • 9,149
  • 6
  • 34
  • 35
3
votes
1 answer

WAF - combine static libraries

My project has external library dependencies and I am using waf scripts to build it - C, C++. I am trying to build static library which will have all the dependent libraries statically linked. For example, I use this to build dynamic shared…
Mojo28
  • 335
  • 1
  • 3
  • 9
3
votes
0 answers

Compile cython extension with waf in development mode

Here is a simple Cython package: foo/ __init__.py # Contains: from . import foo foo.pyx I use waf (I know pyximport or setup.py can be used too) to build the Python extension from foo.pyx: foo/ __init__.py # Contains: from . import…
David Froger
  • 645
  • 6
  • 15
3
votes
1 answer

Using waf, how to check for a minimum version of a python module during configure?

In addition to check for presence of a particular python module during ./waf configure, I need to also check for it to be of minimum version number. This is what I'm already doing in my wscript: def configure(cfg): cfg.load('python') …
zaadeh
  • 1,711
  • 2
  • 23
  • 37
3
votes
1 answer

Using waf, how can I refer to a file in build directory as input to another build command?

I'm using waf as the build system for my project and I need to execute two consecutive shell commands during build process, in which output file from first command should be given as an input file at command-line to second command. According to waf…
zaadeh
  • 1,711
  • 2
  • 23
  • 37
3
votes
1 answer

waf will not find correct python version

I've been trying to build pycairo on my machine, which ships with waf. Upon running ./waf configure, I get the following result: Checking for program python : /usr/bin/python Checking for python version : (2, 7, 6,…
Muddmaker
  • 33
  • 3
3
votes
1 answer

How can I add a code that is always executed by Waf before exit?

I want to make Waf generate a beep when it finishes the execution of any command that took more than 10 seconds. I don't know how do add this and assure that the code executes when Waf exits. This should run for any Waf command not only build. I…
sorin
  • 161,544
  • 178
  • 535
  • 806