From 40a480a83a10d1718e26a6f4fc54d271c1f13a95 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Thu, 20 Oct 2022 14:00:29 +0100 Subject: gentoo auto-resync : 20:10:2022 - 14:00:29 --- x11-misc/Manifest.gz | Bin 47382 -> 47387 bytes x11-misc/autorandr/Manifest | 5 +- x11-misc/autorandr/autorandr-1.12.1-r1.ebuild | 65 ----------------- x11-misc/autorandr/autorandr-1.12.1-r2.ebuild | 77 +++++++++++++++++++++ x11-misc/autorandr/autorandr-9999.ebuild | 7 ++ ...x-install_udev-target-by-s-TARGETS-MAKECM.patch | 28 ++++++++ 6 files changed, 115 insertions(+), 67 deletions(-) delete mode 100644 x11-misc/autorandr/autorandr-1.12.1-r1.ebuild create mode 100644 x11-misc/autorandr/autorandr-1.12.1-r2.ebuild create mode 100644 x11-misc/autorandr/files/autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch (limited to 'x11-misc') diff --git a/x11-misc/Manifest.gz b/x11-misc/Manifest.gz index 268f069ec0fb..c4b16b0a27ef 100644 Binary files a/x11-misc/Manifest.gz and b/x11-misc/Manifest.gz differ diff --git a/x11-misc/autorandr/Manifest b/x11-misc/autorandr/Manifest index 3f44fc9dcee4..5dfa2ff70ee9 100644 --- a/x11-misc/autorandr/Manifest +++ b/x11-misc/autorandr/Manifest @@ -1,5 +1,6 @@ +AUX autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch 1682 BLAKE2B 6c168ffc8e0b217999e4780a9776c6ca7d1fd16868a00ec8301ab8b94412033a38cec28929bb21d7a39fe18544244a947891715a32fe1e80d927b3550dec8513 SHA512 8d3b1164e962bd6b6d741e22f1328b98037b6f2ea878ffe26da07f22947476ca35c5fa066462b913fda7319b8671055c3f28354261daf6e5c3301d7a85f5dc88 DIST autorandr-1.12.1.tar.gz 45550 BLAKE2B 5b434325d13c00c3fa70b5d09edb540cdcf3bb921307c60f2c616231e7a87ea85f60e39500ed8116f28619139f71ecc4a8fa153ffadc6b8d74df570736a0d815 SHA512 a7e095eb96e7e0d3a5b3b2122d68a3d3a5121d8be7a86ddd9f837ad42b7a53ed5ee45151f23861c5b900e214a4dfc0c575f45fe70c8c5587562a4035458137a0 -EBUILD autorandr-1.12.1-r1.ebuild 1334 BLAKE2B 989f72dd2b1a728bf59c0d6cfc273efe81e1b4fd4bb53136f500d087b5f6d035fbe5f5d714b426cfa7aecba1c18e2e3bf49dabb213a8bdc22ef14e3858fb9338 SHA512 cb4b2dcdd702612e04822fd9eafff8863f4563dbf965c83a3c393f5793020a53e63031627e6dc889ca49712c07d901d8da88840edf548d4d3b580bd5bcd66936 +EBUILD autorandr-1.12.1-r2.ebuild 1573 BLAKE2B c9d276c3e4ea2c9f925b2352cd3bacb418c12e9e79052e6d0301ac9c96f87f046df51ab8fcc77747efe5edfc5ef5f6a872602512332d37c1c6365738aec4675d SHA512 adf086f5c178231b6510994efe615f919ed9ccaee462f39e55a1fba265f09fc7569204aef37308ad06610a3e56305a860886c1e163c714c3507568a9be8b8cc2 EBUILD autorandr-1.12.1.ebuild 1316 BLAKE2B 5c13c316e1a1878f7507178c15dea312af45867841bc70baa26f0ea5aab8f9e98a99e9953a85aacff68a075abacf914c9e8009726cc4890a733086ada9c2a74f SHA512 5b6f8d86a28c19763d690abfc65787e3a1b7fac32be2a5689e29fd2ef92928865771e12163f242e25be9297eaaba238d7fa6d13420ca645933a9ed0eb7905a83 -EBUILD autorandr-9999.ebuild 1334 BLAKE2B 989f72dd2b1a728bf59c0d6cfc273efe81e1b4fd4bb53136f500d087b5f6d035fbe5f5d714b426cfa7aecba1c18e2e3bf49dabb213a8bdc22ef14e3858fb9338 SHA512 cb4b2dcdd702612e04822fd9eafff8863f4563dbf965c83a3c393f5793020a53e63031627e6dc889ca49712c07d901d8da88840edf548d4d3b580bd5bcd66936 +EBUILD autorandr-9999.ebuild 1421 BLAKE2B 96fe4556497c046d77161a1895316420af00a70c6c8d26a0ad09158e957255a6077824c4a7a7aa9950f0a4c83c72ff3395f090fd1e9f16ae32a7e163908ba2cf SHA512 748a1bb5d38443225bad47aeb4d53b5673ecc047455123fec38ef1771af69e1d74247699360853fb9d24c2a1384b2c4b52ddc08aee6c415e0b13cf3d65c6d693 MISC metadata.xml 355 BLAKE2B 51f7f0670462cbded6b65379488447fca9862fd75ecc262e3a627c268d184abae82feb8a3835486d2c39d18ad0882db6f1f6c9ff9df4fac19457b4ec3a1f6621 SHA512 a9e16f58beeda5d64b48240ef23dfe4349d8c962e08df19cd3fa60846891719fceba2f69b3affba64b8d6f8c2ec96b1dc544a4ada52efd53e6d15b1aa1734677 diff --git a/x11-misc/autorandr/autorandr-1.12.1-r1.ebuild b/x11-misc/autorandr/autorandr-1.12.1-r1.ebuild deleted file mode 100644 index 0badb8f708aa..000000000000 --- a/x11-misc/autorandr/autorandr-1.12.1-r1.ebuild +++ /dev/null @@ -1,65 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -PYTHON_COMPAT=( python3_{8..11} ) - -inherit bash-completion-r1 distutils-r1 systemd udev - -if [[ "${PV}" = "9999" ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/phillipberndt/${PN}.git" -else - SRC_URI="https://github.com/phillipberndt/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" - KEYWORDS="~amd64 ~x86" -fi - -DESCRIPTION="Automatically select a display configuration based on connected devices" -HOMEPAGE="https://github.com/phillipberndt/autorandr" - -LICENSE="GPL-3" -SLOT="0" -IUSE="launcher systemd udev" - -RDEPEND=" - x11-apps/xrandr - launcher? ( x11-libs/libxcb ) - udev? ( virtual/udev ) -" -DEPEND="${RDEPEND}" -BDEPEND="virtual/pkgconfig" - -src_compile() { - distutils-r1_src_compile - - if use launcher; then - emake contrib/autorandr_launcher/autorandr-launcher - fi -} - -src_install() { - distutils-r1_src_install - - doman autorandr.1 - - local targets=( - autostart_config - bash_completion - $(usev launcher) - $(usev systemd) - $(usev udev) - ) - - emake DESTDIR="${D}" \ - BASH_COMPLETIONS_DIR="$(get_bashcompdir)" \ - SYSTEMD_UNIT_DIR="$(systemd_get_systemunitdir)" \ - UDEV_RULES_DIR="$(get_udevdir)"/rules.d \ - $(printf "install_%s " "${targets[@]}") -} - -pkg_postinst() { - if use udev; then - udev_reload - fi -} diff --git a/x11-misc/autorandr/autorandr-1.12.1-r2.ebuild b/x11-misc/autorandr/autorandr-1.12.1-r2.ebuild new file mode 100644 index 000000000000..77f954a8aaa0 --- /dev/null +++ b/x11-misc/autorandr/autorandr-1.12.1-r2.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{8..11} ) + +inherit bash-completion-r1 distutils-r1 systemd udev + +if [[ "${PV}" = "9999" ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/phillipberndt/${PN}.git" +else + SRC_URI="https://github.com/phillipberndt/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +DESCRIPTION="Automatically select a display configuration based on connected devices" +HOMEPAGE="https://github.com/phillipberndt/autorandr" + +LICENSE="GPL-3" +SLOT="0" +IUSE="launcher systemd udev" + +RDEPEND=" + x11-apps/xrandr + launcher? ( x11-libs/libxcb ) + udev? ( virtual/udev ) +" +DEPEND="${RDEPEND}" +BDEPEND="virtual/pkgconfig" + +PATCHES=( + # https://github.com/phillipberndt/autorandr/pull/306 + "${FILESDIR}"/autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch +) + +src_compile() { + distutils-r1_src_compile + + if use launcher; then + emake contrib/autorandr_launcher/autorandr-launcher + fi +} + +src_install() { + distutils-r1_src_install + + doman autorandr.1 + + local targets=( + autostart_config + bash_completion + $(usev launcher) + $(usev systemd) + $(usev udev) + ) + + emake DESTDIR="${D}" \ + BASH_COMPLETIONS_DIR="$(get_bashcompdir)" \ + SYSTEMD_UNIT_DIR="$(systemd_get_systemunitdir)" \ + UDEV_RULES_DIR="$(get_udevdir)"/rules.d \ + $(printf "install_%s " "${targets[@]}") +} + +pkg_postinst() { + if use udev; then + udev_reload + fi +} + +pkg_postrm() { + if use udev; then + udev_reload + fi +} diff --git a/x11-misc/autorandr/autorandr-9999.ebuild b/x11-misc/autorandr/autorandr-9999.ebuild index 0badb8f708aa..7f0dd9c1da1b 100644 --- a/x11-misc/autorandr/autorandr-9999.ebuild +++ b/x11-misc/autorandr/autorandr-9999.ebuild @@ -3,6 +3,7 @@ EAPI=7 +DISTUTILS_USE_PEP517=setuptools PYTHON_COMPAT=( python3_{8..11} ) inherit bash-completion-r1 distutils-r1 systemd udev @@ -63,3 +64,9 @@ pkg_postinst() { udev_reload fi } + +pkg_postrm() { + if use udev; then + udev_reload + fi +} diff --git a/x11-misc/autorandr/files/autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch b/x11-misc/autorandr/files/autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch new file mode 100644 index 000000000000..ff3b31d01326 --- /dev/null +++ b/x11-misc/autorandr/files/autorandr-Makefile-fix-install_udev-target-by-s-TARGETS-MAKECM.patch @@ -0,0 +1,28 @@ +From 4b8d397fc7a0d22a51ee13428ae13d892c0cc911 Mon Sep 17 00:00:00 2001 +From: Florian Schmaus +Date: Thu, 20 Oct 2022 10:48:54 +0200 +Subject: [PATCH] Makefile: fix install_udev target by s/TARGETS/MAKECMDGOALS/ + +A Gentoo user reported [1] that the 'install_udev' target would +install a systemd-flavored udev rules, despite the 'systemd' target +not being selected. Replacing 'TARGETS' with 'MAKECMDGOALS' in the +Makefile rule fixes this . + +I am not sure where the TARGETS variable origniates from, but GNU make +uses MAKECMDGOALS (FreeBSD make uses .TARGETS, i.e., with a leading +dot). So if further portability between make variants is required, +then this needs to be adjusted. + +1: https://bugs.gentoo.org/803545#c3 +Fixes: ae1f18a06039 ("udev rule: Dynamically call either systemd or autorandr directly depending on whether systemd unit is available") +--- a/Makefile ++++ b/Makefile +@@ -129,7 +129,7 @@ endif + install_udev: + $(if $(UDEV_RULES_DIR),,$(error UDEV_RULES_DIR is not defined)) + mkdir -p ${DESTDIR}/${UDEV_RULES_DIR}/ +- echo 'ACTION=="change", SUBSYSTEM=="drm", RUN+="$(if $(findstring systemd, $(TARGETS)),/bin/systemctl start --no-block autorandr.service,${PREFIX}/bin/autorandr --batch --change --default default)"' > ${DESTDIR}/${UDEV_RULES_DIR}/40-monitor-hotplug.rules ++ echo 'ACTION=="change", SUBSYSTEM=="drm", RUN+="$(if $(findstring systemd, $(MAKECMDGOALS)),/bin/systemctl start --no-block autorandr.service,${PREFIX}/bin/autorandr --batch --change --default default)"' > ${DESTDIR}/${UDEV_RULES_DIR}/40-monitor-hotplug.rules + @echo + @echo "To activate the udev rules, run this command as root:" + @echo " udevadm control --reload-rules" -- cgit v1.2.3