actions.py 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #!/usr/bin/env python3
  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 inary.actionsapi import shelltools
  7. from inary.actionsapi import autotools
  8. from inary.actionsapi import inarytools
  9. from inary.actionsapi import get
  10. def setup():
  11. autotools.configure("PYTHON=/usr/bin/python3 \
  12. --enable-gpl \
  13. --enable-gpl3 \
  14. --enable-gtk2 \
  15. --enable-gtk3 \
  16. --qt-libdir=/usr/lib/ \
  17. --qt-includedir=/usr/include/qt5 \
  18. --avformat-swscale")
  19. # Enable bindings
  20. shelltools.echo("%s/src/swig/config.mak" % get.curDIR(), "SUBDIRS = perl python")
  21. def build():
  22. autotools.make()
  23. autotools.make("-C src/swig")
  24. def install():
  25. autotools.rawInstall("DESTDIR=%s" % get.installDIR())
  26. # We should manually install the bindings :(
  27. inarytools.insinto("/usr/lib/python3.7/site-packages/", "src/swig/python/mlt.py")
  28. inarytools.dolib("src/swig/python/_mlt.so", "/usr/lib/python3.7/site-packages/")
  29. inarytools.insinto("/usr/lib/perl5/vendor_perl/{}/".format(get.curPERL()), "src/swig/perl/blib/lib/mlt.pm")
  30. inarytools.dolib("src/swig/perl/blib/arch/auto/mlt/mlt.so", "/usr/lib/perl5/vendor_perl/{}/i686-linux-thread-multi/auto/mlt/".format(get.curPERL()))
  31. inarytools.dodoc("ChangeLog", "COPYING", "GPL*", "README")