actions.py 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  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/copyleft/gpl.txt.
  6. from pisi.actionsapi import autotools
  7. from pisi.actionsapi import pisitools
  8. from pisi.actionsapi import shelltools
  9. from pisi.actionsapi import get
  10. def setup():
  11. #autotools.autoreconf("-vfi")
  12. options = "--disable-static \
  13. --disable-rpath \
  14. "
  15. if get.buildTYPE() == "emul32":
  16. options += "--disable-qv4l2"
  17. autotools.configure(options)
  18. pisitools.dosed("libtool", " -shared ", " -Wl,-O1,--as-needed -shared ")
  19. def build():
  20. if get.buildTYPE() == "emul32":
  21. autotools.make("-C lib")
  22. else:
  23. autotools.make()
  24. def install():
  25. if get.buildTYPE() == "emul32":
  26. autotools.make("MAKEFLAGS='-j1' -C lib DESTDIR=%s install" % get.installDIR())
  27. pisitools.removeDir("/emul32")
  28. else:
  29. autotools.rawInstall("DESTDIR=%s" % get.installDIR())
  30. #if get.buildTYPE() == "emul32": return
  31. pisitools.dodoc("ChangeLog", "COPYING*", "README*", "TODO")
  32. pisitools.insinto("/%s/%s/" % (get.docDIR(), get.srcNAME()), "contrib")