actions.py 1.0 KB

1234567891011121314151617181920212223242526272829303132
  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 autotools
  7. from inary.actionsapi import inarytools
  8. from inary.actionsapi import get
  9. from inary.actionsapi import shelltools
  10. def setup():
  11. autotools.configure("--libexecdir=/usr/lib/dhcpcd \
  12. --dbdir=/var/lib/dhcpcd \
  13. --localstatedir=/var \
  14. --sbindir=/usr/bin \
  15. --rundir=/run")
  16. def build():
  17. autotools.make()
  18. def install():
  19. autotools.rawInstall("DESTDIR=%s" % get.installDIR())
  20. # Set Options in /etc/dhcpcd.conf Disable ip4vall
  21. shelltools.echo("%s/etc/dhcpcd.conf" % get.installDIR(), "noipv4ll")
  22. # Remove hooks install the compat one
  23. inarytools.remove("/usr/lib/dhcpcd/dhcpcd-hooks/*")
  24. inarytools.insinto("/usr/lib/dhcpcd/dhcpcd-hooks", "hooks/50-dhcpcd-compat")
  25. inarytools.dodoc("README.md")
  26. #DBDIR=/var/lib/dhcpcd LIBEXECDIR=/usr/lib/dhcpcd