logo

overlay

My own overlay for experimentations, use with caution, no support is provided git clone https://anongit.hacktivis.me/git/overlay.git/

utils-std-9999.ebuild (1773B)


  1. # Copyright 2021-2024 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=8
  4. if [[ "${PV}" = 9999* ]]; then
  5. inherit git-r3
  6. EGIT_REPO_URI="https://anongit.hacktivis.me/git/utils-std.git"
  7. else
  8. VERIFY_SIG_METHOD=signify
  9. inherit verify-sig
  10. SRC_URI="
  11. https://hacktivis.me/releases/utils-std/${P}.tar.gz
  12. verify-sig? ( https://hacktivis.me/releases/utils-std/${P}.tar.gz.sign )
  13. "
  14. KEYWORDS="~amd64 ~arm64 ~riscv"
  15. fi
  16. DESCRIPTION="Collection of commonly available Unix tools"
  17. HOMEPAGE="https://hacktivis.me/git/utils-std"
  18. LICENSE="MPL-2.0"
  19. SLOT="0"
  20. IUSE="test static system"
  21. RESTRICT="!test? ( test )"
  22. RDEPEND="
  23. system? (
  24. !sys-apps/coreutils[system(+)]
  25. !sys-apps/diffutils[system(+)]
  26. )
  27. "
  28. BDEPEND="
  29. app-alternatives/yacc
  30. test? ( dev-util/cram )
  31. "
  32. if [[ "${PV}" != 9999* ]]
  33. then
  34. BDEPEND="${BDEPEND} verify-sig? ( sec-keys/signify-keys-lanodan:2024 )"
  35. VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/signify-keys/signify-keys-lanodan-2024.pub"
  36. src_unpack() {
  37. if use verify-sig; then
  38. # Too many levels of symbolic links workaround
  39. cd "${WORKDIR}" || die
  40. cp "${DISTDIR}/${P}.tar.gz" "${DISTDIR}/${P}.tar.gz.sign" "${WORKDIR}/" || die
  41. verify-sig_verify_detached "${P}.tar.gz" "${P}.tar.gz.sign"
  42. unpack "${WORKDIR}/${P}.tar.gz"
  43. rm "${WORKDIR}/${P}.tar.gz"
  44. else
  45. default
  46. fi
  47. }
  48. fi
  49. src_configure() {
  50. export NO_BWRAP=1
  51. use static && export LDSTATIC="-static-pie"
  52. ./configure PREFIX=$(usex system '/usr' '/opt/lanodan')
  53. }
  54. src_install() {
  55. emake install DESTDIR="${D}"
  56. # before 50baselayout
  57. use system || newenvd - 40lanodan <<-EOF
  58. PATH="/opt/lanodan/bin:/opt/lanodan/sbin"
  59. ROOTPATH="/opt/lanodan/bin:/opt/lanodan/sbin"
  60. MANPATH="/opt/lanodan/share/man"
  61. EOF
  62. }