diff --git a/gui-apps/wlopm/wlopm-0.1.0.ebuild b/gui-apps/wlopm/wlopm-0.1.0-r1.ebuild similarity index 70% rename from gui-apps/wlopm/wlopm-0.1.0.ebuild rename to gui-apps/wlopm/wlopm-0.1.0-r1.ebuild index 44cf143bf1..3a2d611aaf 100644 --- a/gui-apps/wlopm/wlopm-0.1.0.ebuild +++ b/gui-apps/wlopm/wlopm-0.1.0-r1.ebuild @@ -6,6 +6,8 @@ EAPI=8 DESCRIPTION="wlr-output-power-management-v1 client" HOMEPAGE="https://git.sr.ht/~leon_plickat/wlopm/" +inherit toolchain-funcs + if [[ ${PV} == *9999* ]]; then inherit git-r3 EGIT_REPO_URI="https://git.sr.ht/~leon_plickat/wlopm" @@ -20,10 +22,17 @@ SLOT="0" DEPEND="dev-libs/wayland" RDEPEND="${DEPEND}" -BDEPEND="dev-libs/wayland-protocols" +BDEPEND="dev-util/wayland-scanner" + +src_prepare() { + default + sed '/^CFLAGS/s/-Werror//' -i Makefile || die +} + +src_compile() { + emake CC="$(tc-getCC)" +} src_install() { - # Need to install to /usr instead of /usr/local - # and the Makefile doens't handle DESTDIR properly - emake PREFIX="${D}"/usr install + emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install } diff --git a/gui-apps/wlopm/wlopm-9999.ebuild b/gui-apps/wlopm/wlopm-9999.ebuild index 6672063089..c4dfd4eead 100644 --- a/gui-apps/wlopm/wlopm-9999.ebuild +++ b/gui-apps/wlopm/wlopm-9999.ebuild @@ -6,13 +6,15 @@ EAPI=8 DESCRIPTION="wlr-output-power-management-v1 client" HOMEPAGE="https://git.sr.ht/~leon_plickat/wlopm/" +inherit bash-completion-r1 toolchain-funcs + if [[ ${PV} == *9999* ]]; then inherit git-r3 EGIT_REPO_URI="https://git.sr.ht/~leon_plickat/wlopm" else SRC_URI="https://git.sr.ht/~leon_plickat/wlopm/archive/v${PV}.tar.gz -> ${P}.tar.gz" S="${WORKDIR}/${PN}-v${PV}" - KEYWORDS="~amd64" + KEYWORDS="~amd64 ~arm64" fi LICENSE="GPL-3" @@ -20,10 +22,18 @@ SLOT="0" DEPEND="dev-libs/wayland" RDEPEND="${DEPEND}" -BDEPEND="dev-libs/wayland-protocols" +BDEPEND="dev-util/wayland-scanner" + +src_prepare() { + default + sed '/^CFLAGS/s/-Werror//' -i Makefile || die +} + +src_compile() { + emake CC="$(tc-getCC)" +} src_install() { - # Need to install to /usr instead of /usr/local - # and the Makefile doens't handle DESTDIR properly - emake PREFIX="${D}"/usr install + install -d "${D}$(get_bashcompdir)" + emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" BASHCOMPDIR="$(get_bashcompdir)" install }