actions.py 1004 B

123456789101112131415161718192021222324252627
  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 pythonmodules
  7. from pisi.actionsapi import shelltools
  8. from pisi.actionsapi import pisitools
  9. from pisi.actionsapi import get
  10. docdir = "%s/%s" % (get.docDIR(), get.srcNAME())
  11. def build():
  12. # suppress compiler warnings:
  13. pisitools.cflags.add("-Wno-format -Wno-comment -Wno-unused -Wno-incompatible-pointer-types \
  14. -Wno-logical-not-parentheses -Wno-bool-compare -Wno-maybe-uninitialized \
  15. -Wno-discarded-qualifiers -Wno-pointer-sign -Wno-pointer-to-int-cast \
  16. -Wno-unknown-pragmas")
  17. # fix unused dependency analysis:
  18. shelltools.export("LDSHARED", "x86_64-pc-linux-gnu-gcc -Wl,-O1,--as-needed -shared -lpthread")
  19. pythonmodules.compile()
  20. def install():
  21. pythonmodules.install()
  22. pisitools.insinto(docdir, "docs", "examples")