actions.py 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. #!/usr/bin/env 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 cmaketools
  7. from pisi.actionsapi import pisitools
  8. from pisi.actionsapi import shelltools
  9. from pisi.actionsapi import get
  10. def setup():
  11. #shelltools.system('sed -i "s/-Werror//g" src/core/CMakeLists.txt')
  12. #shelltools.system('sed -i "s/-Werror//g" src/pyglue/CMakeLists.txt')
  13. #shelltools.system('sed -i "s/push(hidden)/push(default)/g" src/core/OCIOYaml.cpp')
  14. shelltools.makedirs("build")
  15. shelltools.cd("build")
  16. cmaketools.configure("-DUSE_EXTERNAL_YAML=ON \
  17. -DUSE_EXTERNAL_TINYXML=ON \
  18. -DPYTHON=python3 \
  19. -DOCIO_BUILD_pystring=OFF \
  20. -DOCIO_BUILD_STATIC=OFF \
  21. -DUSE_EXTERNAL_LCMS=ON", sourceDir="..")
  22. def build():
  23. shelltools.cd("build")
  24. cmaketools.make("-j2")
  25. def install():
  26. shelltools.cd("build")
  27. cmaketools.rawInstall("DESTDIR=%s" % get.installDIR())
  28. shelltools.cd("..")
  29. pisitools.dodoc("README*")