icpc.py 589 B

1234567891011121314151617181920212223242526272829
  1. #!/usr/bin/env python
  2. # encoding: utf-8
  3. # Thomas Nagy 2009-2018 (ita)
  4. """
  5. Detects the Intel C++ compiler
  6. """
  7. from waflib.Tools import ccroot, ar, gxx
  8. from waflib.Configure import conf
  9. @conf
  10. def find_icpc(conf):
  11. """
  12. Finds the program icpc, and execute it to ensure it really is icpc
  13. """
  14. cxx = conf.find_program(['icpx', 'icpc'], var='CXX')
  15. conf.get_cc_version(cxx, icc=True)
  16. conf.env.CXX_NAME = 'icc'
  17. def configure(conf):
  18. conf.find_icpc()
  19. conf.find_ar()
  20. conf.gxx_common_flags()
  21. conf.gxx_modifier_platform()
  22. conf.cxx_load_tools()
  23. conf.cxx_add_flags()
  24. conf.link_add_flags()