logo

overlay

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

libucontext-0.9.0.ebuild (1002B)


  1. # Copyright 2018-2020 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=7
  4. inherit multilib-minimal
  5. DESCRIPTION="library which provides the <ucontext.h> API from older POSIX revisions"
  6. HOMEPAGE="https://code.foxkit.us/adelie/libucontext"
  7. KEYWORDS=" ~amd64 ~arm ~ppc ~ppc64 ~x86"
  8. LICENSE="MIT"
  9. SRC_URI="https://distfiles.adelielinux.org/source/${PN}/${P}.tar.xz"
  10. SLOT="0"
  11. IUSE="test"
  12. RESTRICT="!test? ( test )"
  13. get_kernel_arch() {
  14. case "$ABI" in
  15. amd64) echo "x86_64";;
  16. *) echo $ABI;;
  17. esac
  18. }
  19. src_prepare() {
  20. default
  21. sed -i \
  22. -e 's;^LIBUCONTEXT_PATH = ;\0 /usr;' \
  23. -e 's;^LIBUCONTEXT_STATIC_PATH = ;\0 /usr;' \
  24. -e 's;ln -sf ${LIBUCONTEXT_SONAME} ${DESTDIR};\0/usr;' \
  25. "${S}/Makefile" || die "Failed adjusting prefix to /usr"
  26. }
  27. src_compile() {
  28. emake ARCH="$(get_kernel_arch)"
  29. }
  30. src_test() {
  31. emake ARCH="$(get_kernel_arch)" check
  32. }
  33. src_install() {
  34. emake ARCH="$(get_kernel_arch)" DESTDIR="${ED}" install
  35. }