logo

overlay

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

pass-1.7.3-r1.ebuild (2234B)


  1. # Copyright 1999-2019 Gentoo Authors
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=6
  4. inherit bash-completion-r1 elisp-common
  5. DESCRIPTION="Stores, retrieves, generates, and synchronizes passwords securely"
  6. HOMEPAGE="https://www.passwordstore.org/"
  7. SRC_URI="https://git.zx2c4.com/password-store/snapshot/password-store-${PV}.tar.xz"
  8. SLOT="0"
  9. LICENSE="GPL-2"
  10. KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~x86-macos"
  11. IUSE="+git wayland X zsh-completion fish-completion emacs dmenu importers elibc_Darwin"
  12. RDEPEND="
  13. app-crypt/gnupg
  14. media-gfx/qrencode
  15. >=app-text/tree-1.7.0
  16. git? ( dev-vcs/git )
  17. X? ( x11-misc/xclip )
  18. wayland? ( gui-apps/wl-clipboard )
  19. elibc_Darwin? ( app-misc/getopt )
  20. zsh-completion? ( app-shells/gentoo-zsh-completions )
  21. fish-completion? ( app-shells/fish )
  22. dmenu? ( x11-misc/dmenu x11-misc/xdotool )
  23. emacs? ( virtual/emacs >=app-emacs/f-0.11.0 >=app-emacs/s-1.9.0 >=app-emacs/with-editor-2.5.11 )
  24. "
  25. S="${WORKDIR}/password-store-${PV}"
  26. src_prepare() {
  27. default
  28. use elibc_Darwin || return
  29. # use coreutils'
  30. sed -i -e 's/openssl base64/base64/g' src/platform/darwin.sh || die
  31. # host getopt isn't cool, and we aren't brew (rip out brew reference)
  32. sed -i -e '/^GETOPT=/s/=.*$/=getopt-long/' src/platform/darwin.sh || die
  33. # make sure we can find "mount"
  34. sed -i -e 's:mount -t:/sbin/mount -t:' src/platform/darwin.sh || die
  35. }
  36. src_compile() {
  37. use emacs && elisp-compile contrib/emacs/*.el
  38. }
  39. src_install() {
  40. emake install \
  41. DESTDIR="${D}" \
  42. PREFIX="${EPREFIX}/usr" \
  43. BASHCOMPDIR="$(get_bashcompdir)" \
  44. WITH_BASHCOMP=yes \
  45. WITH_ZSHCOMP=$(usex zsh-completion) \
  46. WITH_FISHCOMP=$(usex fish-completion)
  47. use dmenu && dobin contrib/dmenu/passmenu
  48. if use emacs; then
  49. elisp-install ${PN} contrib/emacs/*.{el,elc}
  50. elisp-site-file-install "${FILESDIR}/50${PN}-gentoo.el"
  51. fi
  52. if use importers; then
  53. exeinto /usr/share/${PN}/importers
  54. doexe contrib/importers/*
  55. fi
  56. }
  57. pkg_postinst() {
  58. use emacs && elisp-site-regen
  59. if use importers; then
  60. einfo "To import passwords from other password managers, you may use the"
  61. einfo "various importer scripts found in:"
  62. einfo " ${EROOT%/}/usr/share/${PN}/importers/"
  63. fi
  64. }
  65. pkg_postrm() {
  66. use emacs && elisp-site-regen
  67. }