actions.py 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  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_STATIC=OFF \
  20. -DUSE_EXTERNAL_LCMS=ON", sourceDir="..")
  21. def build():
  22. shelltools.cd("build")
  23. cmaketools.make()
  24. def install():
  25. shelltools.cd("build")
  26. cmaketools.rawInstall("DESTDIR=%s" % get.installDIR())
  27. shelltools.cd("..")
  28. pisitools.dodoc("README*")