inadyn-9999.ebuild 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. # Copyright 1999-2023 Gentoo Authors
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=8
  4. inherit autotools systemd
  5. DESCRIPTION="Dynamic DNS client with SSL/TLS support"
  6. HOMEPAGE="http://troglobit.com/projects/inadyn"
  7. if [[ ${PV} == "9999" ]]; then
  8. inherit git-r3
  9. EGIT_REPO_URI="https://github.com/troglobit/${PN}"
  10. EGIT_BRANCH="master"
  11. else
  12. SRC_URI="https://github.com/troglobit/${PN}/releases/download/v${PV}/${P}.tar.xz"
  13. fi
  14. LICENSE="|| ( GPL-2 GPL-3 )"
  15. SLOT="0"
  16. KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~mips"
  17. IUSE="systemd man"
  18. BDEPEND="
  19. app-arch/xz
  20. dev-libs/confuse
  21. "
  22. DEPEND="${BDEPEND}"
  23. RESTRICT="mirror"
  24. src_prepare() {
  25. default
  26. eautoreconf
  27. }
  28. src_compile() {
  29. [[ ${PV} != "9999" ]] && cd src
  30. emake || die
  31. }
  32. src_install() {
  33. dosbin src/${PN}
  34. use man && doman "man/${PN}.8" "man/${PN}.conf.5"
  35. newinitd "${FILESDIR}"/${PN}.initd inadyn
  36. if use "systemd"; then
  37. systemd_dounit "${PN}.service"
  38. systemd_enable_service "system-services.target" "${PN}.service"
  39. fi
  40. insinto /etc
  41. doins ${S}/examples/inadyn.conf
  42. }
  43. pkg_postinst() {
  44. elog "You will need to edit /etc/inadyn.conf file before"
  45. elog "running inadyn for the first time. The file is basically"
  46. elog "command line options; see inadyn and inadyn.conf manpages."
  47. }