Package Details: gnome-shell-extension-cpupower-git 10.1.2.r5.ge9e89c0-1

Git Clone URL: https://aur.archlinux.org/gnome-shell-extension-cpupower-git.git (read-only, click to copy)
Package Base: gnome-shell-extension-cpupower-git
Description: Gnome-Shell Extension for intel-pstate driver
Upstream URL: https://github.com/martin31821/cpupower.git
Licenses: GPL3
Submitter: m3thodic
Maintainer: m3thodic
Last Packager: m3thodic
Votes: 4
Popularity: 0.000000
First Submitted: 2017-03-06 19:47 (UTC)
Last Updated: 2022-05-31 09:07 (UTC)

Latest Comments

FredBezies commented on 2022-05-31 09:12 (UTC)

Cannot be installed.

==> Installing package gnome-shell-extension-cpupower-git with pacman -U...
loading packages...
resolving dependencies...
looking for conflicting packages...

Packages (1) gnome-shell-extension-cpupower-git-10.1.2.r5.ge9e89c0-1

Total Installed Size:  1,01 MiB

:: Proceed with installation? [Y/n] 
(1/1) checking keys in keyring                     [######################] 100%
(1/1) checking package integrity                   [######################] 100%
(1/1) loading package files                        [######################] 100%
(1/1) checking for file conflicts                  [######################] 100%
error: failed to commit transaction (conflicting files)
gnome-shell-extension-cpupower-git: /usr/bin/cpufreqctl exists in filesystem
Errors occurred, no packages were upgraded.

peter.kehl commented on 2021-12-10 03:54 (UTC) (edited on 2021-12-10 04:01 (UTC) by peter.kehl)

Please update to reflect upstream. Especially important since GNOME doesn't allow to publish the new version yet, since the new version is for GNOME 40 (and possibly GNOME 41).

towo commented on 2020-11-12 10:26 (UTC)

For completeness sake, this package should either conflict with cpufreqctl or depend on it and remove shipping cpufreqctl.

Cervox commented on 2020-10-06 14:01 (UTC) (edited on 2020-10-06 14:01 (UTC) by Cervox)

This extension breaks on 3.38 at the time of writing. Until the developers themselves can you please add in the patch found in here? https://github.com/martin31821/cpupower/issues/135

rodolpheh commented on 2020-05-16 12:35 (UTC) (edited on 2020-05-16 13:25 (UTC) by rodolpheh)

It seems that the latest version changed the polkit rule and is now asking for permission to run the installer.sh script as root. It seems that the rules must now be in /usr/share/polkit-1/rules.d and the cpufreqctl tool must be in /usr/bin or /usr/local/bin. I tried to change the PKGBUILD myself but apparently I don't have the proper skills. Would your be kind enough to fix it ?

EDIT: I think I was heavily mistaken on the polkit rules and actions. Hang on, I think I'll get to it...

EDIT2: This is what I came up with :

package() {
        cd $_gitname

        _extid="cpupower@mko-sl.de"
        _extpath="${pkgdir}/usr/share/gnome-shell/extensions/${_extid}"

        DIR="/usr/share/gnome-shell/extensions/cpupower@mko-sl.de"
        CFC="/usr/bin/cpufreqctl"
        POLICY="mko.cpupower.setcpufreq"

        SCHEMADIR="${pkgdir}/usr/share/glib-2.0/schemas"

        ACTION_IN="${_extpath}/data/mko.cpupower.policy.in"
        ACTION_DIR="${pkgdir}/usr/share/polkit-1/actions"
        ACTION_OUT="${ACTION_DIR}/${POLICY}.policy"

        RULE_IN="${_extpath}/data/10-mko.cpupower.setcpufreq.rules"
        RULE_DIR="${pkgdir}/usr/share/polkit-1/rules.d"
        RULE_OUT="${RULE_DIR}/10-mko.cpupower.setcpufreq.rules"

        install -dm755 "${_extpath}"
        cp -a * "${_extpath}"

        # INSTALLING CPUFREQCTL
        echo "Installing cpufreqctl tool..."
        mkdir -p "${pkgdir}/usr/bin"
        cp -a "tool/cpufreqctl" "${pkgdir}/${CFC}"

        # INSTALLING POLKIT ACTION
        echo "Installing policykit action..."
        mkdir -p "${ACTION_DIR}"
        sed -e "s:{{PATH}}:${CFC}:g" -e "s:{{ID}}:${POLICY}:g" "${ACTION_IN}" > "${ACTION_OUT}"

        # INSTALLING POLICYKIT RULE
        echo "Installing policykit rule..."
        mkdir -p "${RULE_DIR}"
        chmod 750 "${RULE_DIR}"
        cp "${RULE_IN}" "${RULE_OUT}"
        chmod 644 "${RULE_OUT}"

        # INSTALLING SCHEMA
        echo "Installing schema..."
        mkdir -p "${SCHEMADIR}"
        cp schemas/org.gnome.shell.extensions.cpupower.gschema.xml "${SCHEMADIR}"
}

I think it's a little bit dirty but it works for me. If someone could have a second look on it before using it, that would be perfect.

uno20001 commented on 2020-04-06 16:32 (UTC)

I found that modifying the package() part of the PKGBUILD file like this:

package() {
    cd $_gitname
    make PREFIX="$pkgdir/usr" install
}

solves the building problem.

oconnor663 commented on 2020-04-06 14:20 (UTC) (edited on 2020-04-06 14:20 (UTC) by oconnor663)

I've started seeing an error building this package:

==> Starting package()...
chown: cannot access '/home/jacko/.cache/yay/gnome-shell-extension-cpupower-git/pkg/gnome-shell-extension-cpupower-git//usr/share/gnome-shell/extensions/cpupower@mko-sl.de/src/cpufreqctl': No such file or directory
==> ERROR: A failure occurred in package().

It looks like the failure bisects to this upstream commit:

commit e89b71174f369137eaf03dc1b61039dce200008f
Author: Fin Christensen <christensen.fin@gmail.com>
Date:   Mon Mar 30 12:39:37 2020 +0200

    Add Makefile and adjust installation according to #102, #84, #95