actions.py 865 B

123456789101112131415161718192021222324252627282930
  1. #!/usr/bin/python
  2. # -*- coding: utf-8 -*-
  3. #
  4. # Licensed under the GNU General Public License, version 3.
  5. # See the file http://www.gnu.org/licenses/gpl.txt
  6. from pisi.actionsapi import autotools
  7. from pisi.actionsapi import pisitools
  8. from pisi.actionsapi import get
  9. def build():
  10. for com in [ "bcc86", "unproto", "copt", "as86", "ld86",
  11. "-C cpp", "-C ar", "-C ld" ]:
  12. make_opts = { 'cflags' : get.CFLAGS(),
  13. 'com' : com }
  14. autotools.make('%(com)s CFLAGS="%(cflags)s -D_POSIX_SOURCE" -j1' % make_opts)
  15. # ncc does not support gcc optflags
  16. autotools.make('-j1')
  17. def install():
  18. for binary in ["bin/*","cpp/bcc-cpp","bcc/bcc-cc1"]:
  19. pisitools.dobin(binary)
  20. pisitools.rename("/usr/bin/Bcc","bcc")
  21. pisitools.doman("man/*.1")
  22. pisitools.dodoc("Changes","COPYING","MAGIC","README")