Hi all, this is an unofficial HOWTO about installing (k)powersave the Gentoo Way(TM). Hopefully this saves Gentoo users some trouble when they try to get (k)powersave up and running.
As (k)powersave is not (yet) officially included in the Gentoo portage tree we will use something called a "portage overlay" [1]. I will explain the procedure step by step Installing (k)powersave ~~~~~~~~~~~~~~~~~~~~~~~ 0) Login as root. 1.) Open /etc/make.conf and add the line PORTDIR_OVERLAY="/usr/local/portage" if not yet existent. 2.) Create the overlay directory via "mkdir /usr/local/portage" 3.) Download the powersave_overlay.tar.bz2 tarball. 4.) Go to the directory /usr/local/portage and extract the tarball with "tar -xvjf powersave_overlay.tar.bz" This creates the directories sys-power/powersave and sys-power/kpowersave and places some ebuils and files in there. 5.) Now you can already install kpowersave simply calling "emerge kpowersave". This will install all the dependencies, even the powersave daemon itself. If you only want to install the powersave daemon use "emerge powersave". 6.) If you want to start the powersave daemon automatically during startup, you can add it to the default runlevel via "rc-update add powersaved default". If you have an ACPI enabled system it is also a good idea to add acpid to the default runlevel via "rc-update add acpid default". The init system of Gentoo is dependency based. The powersaved init script contains the necessary dependency information. This ensures that hald and dbus are started automatically before powersaved. If acpid is enabled, powersaved will also use this service and start afterwards. Access to the powersave daemon is handled via dbus policies defined in /etc/dbus-1/system.d/powersave.conf. Gentoo systems can be compiled with the "pam_console" USE flag, please see [2] for more information on this topic. pam_console basically means that you grant users certain rights if they are logged in on a local console. If you set the pam_console USE flag, the powersave ebuild will respect this setting and install the powersave.conf file for dbus accordingly. If you don't use pam_console the powersave.conf file is adapted to allow users that are in group "plugdev" the access to the powersave daemon. You can use "usermod -a -G plugdev username" to add users to the group "plugdev". 7.) As a last step you should start the powersave daemon. You can either do this via "/etc/init.d/powersaved start" or if you added it to the default runlevel by simply rebooting. Upgrading (k)powersave ~~~~~~~~~~~~~~~~~~~~~~ The current versions in the powersave overlay are kpowersave 0.5 (stable) and 0.5.4 (unstable) and powersave 0.10.21 (stable) and powersave 0.11.6. These are the current up to date versions. I would strongly suggest to use the current unstable versions because they already contain many fixes to make (k)powersave less SUSE specific and have more features. Let's assume powersave 0.10.7 is released tomorrow. Given that the build dependencies haven't changed all you have to do, is the following: 1.) Go to the directory /usr/local/portage/sys-power/powersave 2.) Copy the file powersave-0.11.6.ebuild to powersave-0.11.7.ebuild. 2.) Run "ebuild powersave-0.11.6.ebuild digest". This will download the powersave tarball and create a md5 hashsum over the tarball. So you will need network access for this step. 3.) Run "emerge --update world" or "emerge powersave". Both commands will upgrade your current version to 0.11.7. Final notes ~~~~~~~~~~~ This is a first draft of this little installation HOWTO. Comments are welcome. As I'm not that involved in Gentoo and lack the time I will not update or maintain this portage overlay. So if someone wants to take over the maintainership of this files and even push them into the official Gentoo portage archive I'd be glad to hand them over. One point that is still lacking is the current version of the Gentoo init script (powersave/files/powersaved.rc). It is missing the part where all the cpufreq modules and governors are probed and loaded automatically. For now you will have to add the modules to /etc/modules.autoload.d/kernel-2.x manually or copy the module loading routines from the original init script and add it to powersaved.rc. Cheers, Michael [1] http://gentoo-wiki.com/HOWTO_Installing_3rd_Party_Ebuilds [2] http://www.gentoo.org/dyn/use-index.xml
powersave_overlay.tar.bz2
Description: application/bzip
signature.asc
Description: OpenPGP digital signature
_______________________________________________ powersave-devel mailing list powersave-devel@forge.novell.com http://forge.novell.com/mailman/listinfo/powersave-devel