actions.py 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  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/copyleft/gpl.txt.
  6. from pisi.actionsapi import autotools
  7. from pisi.actionsapi import get
  8. from pisi.actionsapi import pisitools
  9. from pisi.actionsapi import shelltools
  10. def setup():
  11. #Fix htmldir
  12. pisitools.dosed("doc/Makefile.am", "doc/icecast", "doc/icecast/html")
  13. #pisitools.dosed("debian/icecast2.1", "icecast2", "icecast")
  14. autotools.autoreconf("-vif")
  15. autotools.configure("--sysconfdir=/etc/icecast \
  16. --disable-static \
  17. --with-curl \
  18. --with-ogg \
  19. --with-theora \
  20. --with-speex \
  21. --enable-yp \
  22. --with-openssl=/usr")
  23. def build():
  24. autotools.make()
  25. def install():
  26. autotools.rawInstall("DESTDIR=%s" % get.installDIR())
  27. #Create Log Dir
  28. pisitools.dodir("/var/log/icecast")
  29. pisitools.dodir("/run/icecast")
  30. #Correct permissions
  31. shelltools.chmod("%s/var/log/icecast" % get.installDIR(), 0755 )
  32. shelltools.chmod("%s/etc/icecast/icecast.xml" % get.installDIR(), 0640)
  33. shelltools.chmod("%s/run/icecast" % get.installDIR(), 0755)
  34. pisitools.insinto("/usr/share/pixmaps", "web/icecast.png")
  35. #pisitools.doman("debian/icecast2.1")