actions.py 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  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/licenses/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. shelltools.sym("makefiles/configure.in", "configure.in")
  12. shelltools.sym("makefiles/Makefile.am", "Makefile.am")
  13. shelltools.sym("makefiles/makefile.linux", "Makefile")
  14. #shelltools.sym("contrib/gcc/sdl-mngplay/acinclude.m4", "acinclude.m4")
  15. shelltools.system("sed -i -e 's/unroll-loops/& -fPIC/' Makefile ")
  16. autotools.autoreconf("-fiv")
  17. autotools.configure("--with-jpeg \
  18. --with-lcms \
  19. --disable-static \
  20. --disable-dependency-tracking")
  21. if get.buildTYPE() == "emul32":
  22. options = " --libdir=/usr/lib32 \
  23. --with-jpeg \
  24. --disable-static \
  25. --disable-dependency-tracking"
  26. shelltools.export("CFLAGS", "%s -m32" % get.CFLAGS())
  27. autotools.configure(options)
  28. def build():
  29. autotools.make()
  30. def install():
  31. autotools.rawInstall("DESTDIR=%s" % get.installDIR())
  32. pisitools.doman("doc/man/*")
  33. pisitools.dodoc("CHANGES", "LICENSE", "README*", "doc/doc.readme", "doc/misc/*", "doc/libmng.txt")