scenefx-9999.ebuild 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. # Copyright 1999-2024 Gentoo Authors
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=8
  4. inherit meson
  5. if [[ ${PV} == 9999 ]]; then
  6. inherit git-r3
  7. EGIT_REPO_URI="https://github.com/wlrfx/scenefx"
  8. else
  9. MY_PV=${PV/_rc/-rc}
  10. SRC_URI="https://github.com/wlrfx/scenefx/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
  11. S="${WORKDIR}/${PN}-${MY_PV}"
  12. KEYWORDS="~amd64 ~arm64 ~arm ~loong ~ppc64 ~riscv ~x86"
  13. fi
  14. DESCRIPTION="A replacement for the wlroots scene API with eye-candy effects."
  15. HOMEPAGE="https://github.com/wlrfx/scenefx"
  16. LICENSE="MIT"
  17. SLOT="0"
  18. IUSE="+drm +gbm examples +liftoff +libinput vulkan x11-backend xcb-errors X"
  19. REQUIRED_USE="
  20. xcb-errors? ( || ( x11-backend ) )
  21. "
  22. DEPEND="
  23. >=dev-libs/wayland-1.22.0
  24. >=x11-libs/libdrm-2.4.114
  25. media-libs/mesa[egl(+),gles2(+),vulkan?]
  26. >=x11-libs/pixman-0.42.0
  27. media-libs/libglvnd
  28. x11-libs/libxkbcommon
  29. drm? (
  30. media-libs/libdisplay-info
  31. sys-apps/hwdata
  32. liftoff? ( >=dev-libs/libliftoff-0.4 )
  33. )
  34. libinput? ( >=dev-libs/libinput-1.14.0:= )
  35. x11-backend? (
  36. x11-libs/libxcb:=
  37. x11-libs/xcb-util-renderutil
  38. )
  39. vulkan? (
  40. dev-util/glslang:=
  41. dev-util/vulkan-headers
  42. media-libs/vulkan-loader
  43. )
  44. xcb-errors? ( x11-libs/xcb-util-errors )
  45. X? (
  46. x11-libs/libxcb:=
  47. x11-libs/xcb-util-wm
  48. x11-base/xwayland
  49. )
  50. "
  51. # Check this on every update
  52. DEPEND+="
  53. >=gui-libs/wlroots-0.17:=[X?,liftoff?,vulkan?,x11-backend?,xcb-errors?]
  54. <gui-libs/wlroots-0.18:=[X?,liftoff?,vulkan?,x11-backend?,xcb-errors?]
  55. "
  56. RDEPEND="${DEPEND}"
  57. BDEPEND="
  58. >=dev-libs/wayland-protocols-1.24
  59. >=dev-build/meson-0.59.0
  60. virtual/pkgconfig
  61. dev-build/ninja
  62. vulkan? ( >=dev-util/vulkan-headers-1.3.255 )
  63. "
  64. RESTRICT="mirror"
  65. src_configure() {
  66. local backends=(
  67. $(usev drm)
  68. $(usev libinput)
  69. $(usev x11-backend 'x11')
  70. )
  71. local meson_backends=$(IFS=','; echo "${backends[*]}")
  72. local emesonargs=(
  73. -Drenderers=$(usex vulkan 'gles2,vulkan' gles2)
  74. $(meson_feature X xwayland)
  75. $(meson_feature xcb-errors)
  76. $(meson_use examples)
  77. -Dbackends=${meson_backends}
  78. -Dallocators="$(usex gbm gbm auto)"
  79. )
  80. meson_src_configure
  81. }