Jamfile.v2 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. # Boost Interprocess Library Example Jamfile
  2. # (C) Copyright Ion Gaztanaga 2006-2012.
  3. # Use, modification and distribution are subject to the
  4. # Boost Software License, Version 1.0. (See accompanying file
  5. # LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  6. # Adapted from John Maddock's TR1 Jamfile.v2
  7. # Copyright John Maddock 2005.
  8. # Use, modification and distribution are subject to the
  9. # Boost Software License, Version 1.0. (See accompanying file
  10. # LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  11. # this rule enumerates through all the sources and invokes
  12. # the run rule for each source, the result is a list of all
  13. # the run rules, which we can pass on to the test_suite rule:
  14. rule test_all
  15. {
  16. local all_rules = ;
  17. for local fileb in [ glob comp*.cpp ]
  18. {
  19. all_rules += [ link $(fileb)
  20. : # additional args
  21. <toolset>acc:<linkflags>-lrt
  22. <toolset>acc-pa_risc:<linkflags>-lrt
  23. <toolset>gcc,<target-os>windows:<linkflags>"-lole32 -loleaut32 -lpsapi -ladvapi32"
  24. <target-os>hpux,<toolset>gcc:<linkflags>"-Wl,+as,mpas"
  25. <target-os>windows,<toolset>clang:<linkflags>"-lole32 -loleaut32 -lpsapi -ladvapi32"
  26. <target-os>linux:<linkflags>"-lrt"
  27. : # test-files
  28. : # requirements
  29. ] ;
  30. }
  31. for local fileb in [ glob doc_*.cpp ]
  32. {
  33. all_rules += [ run $(fileb)
  34. : # additional args
  35. : # test-files
  36. : # requirements
  37. <toolset>acc:<linkflags>-lrt
  38. <toolset>acc-pa_risc:<linkflags>-lrt
  39. <toolset>gcc-mingw:<linkflags>"-lole32 -loleaut32 -lpsapi -ladvapi32"
  40. <target-os>hpux,<toolset>gcc:<linkflags>"-Wl,+as,mpas"
  41. <target-os>windows,<toolset>clang:<linkflags>"-lole32 -loleaut32 -lpsapi -ladvapi32"
  42. <target-os>linux:<linkflags>"-lrt"
  43. ] ;
  44. }
  45. return $(all_rules) ;
  46. }
  47. test-suite interprocess_example : [ test_all r ] : <threading>multi ;