Jamfile.v2 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. # Copyright (C) 2006 Vladimir Prus
  2. # Copyright (C) 2006 Arkadiy Vertleyb
  3. # Use, modification and distribution is subject to the Boost Software
  4. # License, Version 1.0. (http://www.boost.org/LICENSE_1_0.txt)
  5. # Boost Typeof Library test Jamfile
  6. import testing ;
  7. import set ;
  8. # The special requirement is not ported yet.
  9. #
  10. #local rule special-requirements ( toolset variant : properties * )
  11. #{
  12. # # Tru64/CXX6.5 hangs on most tests, so just turn it off completely.
  13. #
  14. # if $(UNIX) && $(OS) = OSF
  15. # {
  16. # switch $(toolset)
  17. # {
  18. # case tru64cxx65* : properties =
  19. # [ replace-properties $(properties) : <build>no ] ;
  20. # }
  21. # }
  22. #
  23. # return $(properties) ;
  24. #}
  25. rule typeof-test ( source )
  26. {
  27. return [ compile $(source) : <define>BOOST_TYPEOF_NATIVE :
  28. $(source:B)_native ]
  29. [ compile $(source) : <define>BOOST_TYPEOF_EMULATION :
  30. $(source:B)_emulation ]
  31. ;
  32. }
  33. rule all-tests ( )
  34. {
  35. local all ;
  36. # for local t in [ set.difference [ glob *.cpp ] : odr1.cpp odr2.cpp ]
  37. for local t in [ set.difference [ glob *.cpp ] : [ glob odr*.cpp ] ]
  38. {
  39. all += [ typeof-test $(t) ] ;
  40. }
  41. all += [ run odr1.cpp odr2.cpp : : : <define>BOOST_TYPEOF_NATIVE :
  42. odr_native ] ;
  43. all += [ run odr1.cpp odr2.cpp : : : <define>BOOST_TYPEOF_EMULATION :
  44. odr_emulation ] ;
  45. all += [ run odr_no_uns1.cpp odr_no_uns2.cpp : : : <define>BOOST_TYPEOF_EMULATION :
  46. odr_no_uns ] ;
  47. return $(all) ;
  48. }
  49. test-suite "typeof"
  50. : [ all-tests ]
  51. ;