actions.py 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  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 mesontools
  10. from pisi.actionsapi import get
  11. def setup():
  12. shelltools.system("sed -i '/systemd_sysusers_dir/s/^/#/' meson.build")
  13. pisitools.dosed("meson.build", "pardus", "pisilinux")
  14. pisitools.dosed("meson_options.txt", "pardus", "pisilinux")
  15. #pisitools.dosed("configure", "pardus-release", "pisilinux-release")
  16. #autotools.autoreconf("-fiv")
  17. mesontools.configure("-Dos_type='pisilinux' \
  18. -Dpam_module_dir=/lib/security \
  19. -Dexamples=true \
  20. -Dauthfw='pam' \
  21. -Djs_engine='duktape' \
  22. -Dsession_tracking=elogind")
  23. def build():
  24. shelltools.export('HOME', get.workDIR())
  25. mesontools.build()
  26. def install():
  27. mesontools.install()
  28. pisitools.dodir("/var/lib/polkit-1")
  29. shelltools.chmod("%s/var/lib/polkit-1" % get.installDIR(), mode=00700)
  30. shelltools.chmod("%s/etc/polkit-1/rules.d" % get.installDIR(), mode=00700)
  31. shelltools.chown("%s/etc/polkit-1/rules.d" % get.installDIR(),"polkitd","root") #yada? "polkitd","root"
  32. shelltools.chown("%s/var/lib/polkit-1" % get.installDIR(),"polkitd","polkitd")
  33. shelltools.chown("%s/usr/share/polkit-1" % get.installDIR(),"polkitd","root") #yada? "polkitd","root"
  34. pisitools.removeDir("/usr/lib/systemd")
  35. pisitools.removeDir("/usr/lib/sysusers.d")
  36. pisitools.dodoc("AUTHORS", "NEWS*", "README*", "HACKING*", "COPYING*")