mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-25 07:31:01 +02:00
sys-power/acpid: Sync with Gentoo
It's from Gentoo commit 816de8d38c4798590e088a0a5cf0647ce3a4c897.
This commit is contained in:
parent
a11c09a451
commit
ef22740157
@ -1,3 +1 @@
|
||||
DIST acpid-2.0.32.tar.xz 155768 BLAKE2B 829b2f78f497d9c0bbd90d952cadad96beece3070240bee69f2a5cf28903e9e5f969a3bf9000552c63a52c17f8b94285a181f4301449a9b64c573032d9a4d255 SHA512 c7afffdf9818504e1ac03b0ad693a05f772bfd07af9808262b3b6bb82ca4dabe6253c94e6dc59e5be6f0da9e815e8bcf2d3e16f02b23d0248b6bad4509e78be7
|
||||
DIST acpid-2.0.33.tar.xz 156580 BLAKE2B 72a0835f3d88f4ccae44016809fdb930977f6b02dae6f74068186a8c850237764a1e8cd69a478e5af42115d5f630a9f91cd77b35b8cf01854e24b7e06bbdd536 SHA512 491a58c62fcad44dc57cbd9294437fbc215c2ec99a030286601cd1956ea504e723e61b11b315983073d66aace1997bc40e6421475f6073298f60b8dcda2add75
|
||||
DIST sys-power_acpid_2.0.32-r2_extras.tar.xz 2196 BLAKE2B 0975289f7cff6ce24523246f1daac22149d69c410e07a19a5952457e269fc1f736bd3636c93038f660c411f3085d375250c31dc3de3ac1bc6335a97e1fa3dea3 SHA512 f49cf3f75f5db4ca454d29330ae40461deb1109f076e140188a7560fedd78970572a6c023146c4d33c0778ff65056abcbc66725c000ece8e6861419d02d0c6ca
|
||||
DIST acpid-2.0.34.tar.xz 159924 BLAKE2B 1379978f8c5816febcde2d3bb641f8a51736ae0caed97a45caa990576d314608a455307df11f6abafa2ef8bbaa47554f581605aa9c1af150ee64b9eb684fee15 SHA512 2bf92295b55bb44fe83074b3e0c1ae639f63edaeea84b2184ae95b38852be40f380d5413110b8c0fcb2efc2ec01bf4764e1dcb97022fc724bebbfc35c0b63c81
|
||||
|
@ -1,71 +0,0 @@
|
||||
# Copyright 1999-2021 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
inherit linux-info systemd
|
||||
|
||||
DESCRIPTION="Daemon for Advanced Configuration and Power Interface"
|
||||
HOMEPAGE="https://sourceforge.net/projects/acpid2"
|
||||
EXTRAS_VER="2.0.32-r2"
|
||||
EXTRAS_NAME="${CATEGORY}_${PN}_${EXTRAS_VER}_extras"
|
||||
SRC_URI="mirror://sourceforge/${PN}2/${P}.tar.xz
|
||||
https://dev.gentoo.org/~andrey_utkin/distfiles/${EXTRAS_NAME}.tar.xz
|
||||
"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 ~arm arm64 ~ia64 ~riscv x86"
|
||||
IUSE="selinux"
|
||||
|
||||
RDEPEND="selinux? ( sec-policy/selinux-apm )"
|
||||
DEPEND=">=sys-kernel/linux-headers-3"
|
||||
|
||||
pkg_pretend() {
|
||||
local CONFIG_CHECK="~INPUT_EVDEV"
|
||||
local WARNING_INPUT_EVDEV="CONFIG_INPUT_EVDEV is required for ACPI button event support."
|
||||
[[ ${MERGE_TYPE} != buildonly ]] && check_extra_config
|
||||
}
|
||||
|
||||
pkg_setup() { :; }
|
||||
|
||||
PATCHES=(
|
||||
"${WORKDIR}/${EXTRAS_NAME}/${PN}-2.0.32-powerbtn-gsd-power.patch" #702700
|
||||
)
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
|
||||
newdoc kacpimon/README README.kacpimon
|
||||
dodoc -r samples
|
||||
rm -f "${D}"/usr/share/doc/${PF}/COPYING || die
|
||||
|
||||
exeinto /etc/acpi
|
||||
newexe "${WORKDIR}/${EXTRAS_NAME}/${PN}-1.0.6-default.sh" default.sh
|
||||
exeinto /etc/acpi/actions
|
||||
newexe samples/powerbtn/powerbtn.sh powerbtn.sh
|
||||
insinto /etc/acpi/events
|
||||
newins "${WORKDIR}/${EXTRAS_NAME}/${PN}-1.0.4-default" default
|
||||
|
||||
newinitd "${WORKDIR}/${EXTRAS_NAME}/${PN}-2.0.26-init.d" ${PN}
|
||||
newconfd "${WORKDIR}/${EXTRAS_NAME}/${PN}-2.0.16-conf.d" ${PN}
|
||||
|
||||
systemd_dounit "${WORKDIR}"/${EXTRAS_NAME}/systemd/${PN}.{service,socket}
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
if [[ -z ${REPLACING_VERSIONS} ]]; then
|
||||
elog
|
||||
elog "You may wish to read the Gentoo Linux Power Management Guide,"
|
||||
elog "which can be found online at:"
|
||||
elog "https://wiki.gentoo.org/wiki/Power_management/Guide"
|
||||
elog
|
||||
fi
|
||||
|
||||
# files/systemd/acpid.socket -> ListenStream=/run/acpid.socket
|
||||
mkdir -p "${ROOT%/}"/run
|
||||
|
||||
if ! grep -qs "^tmpfs.*/run " "${ROOT%/}"/proc/mounts ; then
|
||||
echo
|
||||
ewarn "You should reboot the system now to get /run mounted with tmpfs!"
|
||||
fi
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
# Copyright 1999-2022 Gentoo Authors
|
||||
# Copyright 1999-2023 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
@ -11,12 +11,16 @@ SRC_URI="mirror://sourceforge/${PN}2/${P}.tar.xz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~loong ~riscv ~x86"
|
||||
KEYWORDS="amd64 ~arm arm64 ~ia64 ~loong ~riscv x86"
|
||||
IUSE="selinux"
|
||||
|
||||
RDEPEND="selinux? ( sec-policy/selinux-apm )"
|
||||
DEPEND=">=sys-kernel/linux-headers-3"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-2.0.34-lfs.patch
|
||||
)
|
||||
|
||||
pkg_pretend() {
|
||||
local CONFIG_CHECK="~INPUT_EVDEV"
|
||||
local WARNING_INPUT_EVDEV="CONFIG_INPUT_EVDEV is required for ACPI button event support."
|
19
sdk_container/src/third_party/portage-stable/sys-power/acpid/files/acpid-2.0.34-lfs.patch
vendored
Normal file
19
sdk_container/src/third_party/portage-stable/sys-power/acpid/files/acpid-2.0.34-lfs.patch
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
Since version 1.2.4 musl no longer enables legacy LFS interfaces as part
|
||||
of _GNU_SOURCE, and will remove them altogether in a future release [1].
|
||||
Just switch to the standard interfaces.
|
||||
|
||||
[1] https://musl.libc.org/releases.html
|
||||
|
||||
--- a/sock.c
|
||||
+++ b/sock.c
|
||||
@@ -54,8 +54,8 @@
|
||||
static int
|
||||
isfdtype(int fd, int fdtype)
|
||||
{
|
||||
- struct stat64 st;
|
||||
- if (fstat64(fd, &st) != 0)
|
||||
+ struct stat st;
|
||||
+ if (fstat(fd, &st) != 0)
|
||||
return -1;
|
||||
return ((st.st_mode & S_IFMT) == (mode_t)fdtype);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user