actions.py 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. #!/usr/bin/python
  2. # -*- coding: utf-8 -*-
  3. # Licensed under the GNU General Public License, version 3.
  4. # See the file http://www.gnu.org/copyleft/gpl.txt
  5. from pisi.actionsapi import shelltools
  6. from pisi.actionsapi import pisitools
  7. from pisi.actionsapi import qt6
  8. from pisi.actionsapi import get, cmaketools
  9. def setup():
  10. shelltools.export("CC", "clang")
  11. shelltools.export("CXX", "clang++")
  12. cmaketools.configure("-B build \
  13. -D-DCMAKE_MESSAGE_LOG_LEVEL=STATUS \
  14. -DCMAKE_BUILD_TYPE=Release")
  15. # qt6.configure()
  16. def build():
  17. cmaketools.make("-C build")
  18. shelltools.system("cmake --build build")
  19. # qt6.make()
  20. def install():
  21. shelltools.cd("build")
  22. cmaketools.rawInstall("DESTDIR=%s" % get.installDIR())
  23. # qt6.install()
  24. #I hope qtchooser will manage this issue
  25. for bin in shelltools.ls("%s/usr/lib/qt6/bin" % get.installDIR()):
  26. pisitools.dosym("/usr/lib/qt6/bin/%s" % bin, "/usr/bin/%s-qt6" % bin)
  27. pisitools.dodoc("../LICENSES/*")