wscript_build 342 B

12345678910111213141516171819202122
  1. #! /usr/bin/env python
  2. """
  3. * the static lib order should be preserved
  4. * the static libraries must be given in reverse order
  5. """
  6. bld.stlib(
  7. source = 'a.c',
  8. target = 'ST_A'
  9. )
  10. bld.stlib(
  11. source = 'b.c',
  12. target = 'ST_B'
  13. )
  14. bld.program(
  15. source = 'main.c',
  16. target = 'static_app',
  17. use = 'ST_B ST_A' # this is the correct order for ld
  18. )