jack2 codebase
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

55 lines
1.1KB

  1. #! /usr/bin/env python
  2. # encoding: utf-8
  3. # imported from samba
  4. """
  5. Compiler definition for irix/MIPSpro cc compiler
  6. """
  7. from waflib import Errors
  8. from waflib.Tools import ccroot, ar
  9. from waflib.Configure import conf
  10. @conf
  11. def find_irixcc(conf):
  12. v = conf.env
  13. cc = conf.find_program('cc', var='CC')
  14. try:
  15. conf.cmd_and_log(cc + ['-version'])
  16. except Errors.WafError:
  17. conf.fatal('%r -version could not be executed' % cc)
  18. v.CC_NAME = 'irix'
  19. @conf
  20. def irixcc_common_flags(conf):
  21. v = conf.env
  22. v.CC_SRC_F = ''
  23. v.CC_TGT_F = ['-c', '-o']
  24. v.CPPPATH_ST = '-I%s'
  25. v.DEFINES_ST = '-D%s'
  26. if not v.LINK_CC:
  27. v.LINK_CC = v.CC
  28. v.CCLNK_SRC_F = ''
  29. v.CCLNK_TGT_F = ['-o']
  30. v.LIB_ST = '-l%s' # template for adding libs
  31. v.LIBPATH_ST = '-L%s' # template for adding libpaths
  32. v.STLIB_ST = '-l%s'
  33. v.STLIBPATH_ST = '-L%s'
  34. v.cprogram_PATTERN = '%s'
  35. v.cshlib_PATTERN = 'lib%s.so'
  36. v.cstlib_PATTERN = 'lib%s.a'
  37. def configure(conf):
  38. conf.find_irixcc()
  39. conf.find_ar()
  40. conf.irixcc_common_flags()
  41. conf.cc_load_tools()
  42. conf.cc_add_flags()
  43. conf.link_add_flags()