actions.py 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  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 shelltools
  7. from pisi.actionsapi import autotools
  8. from pisi.actionsapi import pisitools
  9. from pisi.actionsapi import get
  10. def setup():
  11. shelltools.export("OPTIMIZER", "%s" % get.CFLAGS())
  12. shelltools.export("DEBUG", "-DNDEBUG")
  13. autotools.configure("--enable-readline=yes \
  14. root_libdir=/lib \
  15. --enable-blkid=yes")
  16. def build():
  17. autotools.make()
  18. def install():
  19. autotools.rawInstall("DIST_ROOT=%s" % get.installDIR())
  20. autotools.rawInstall("DIST_ROOT=%s" % get.installDIR(), "install-dev")
  21. # Needed for building the QA testsuite
  22. #autotools.rawInstall("DIST_ROOT=%s" % get.installDIR(), "install-qa")
  23. # Nuke static libraries
  24. #pisitools.remove("/lib/libhandle.a")
  25. #pisitools.remove("/lib/libhandle.la")
  26. #pisitools.remove("/usr/lib/*.a")
  27. # Fix the symlink
  28. #pisitools.remove("/usr/lib/libhandle.so")
  29. #pisitools.dosym("/lib/libhandle.so.1", "/usr/lib/libhandle.so")
  30. # Set +x bit for the library
  31. shelltools.chmod("%s/usr/lib/libhandle.so.*.*.*" % get.installDIR(), 0755)