| OLD | NEW |
| 1 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | 1 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. |
| 2 # Distributed under the terms of the GNU General Public License v2 | 2 # Distributed under the terms of the GNU General Public License v2 |
| 3 | 3 |
| 4 EAPI=2 | 4 EAPI=2 |
| 5 | 5 |
| 6 inherit cros-debug cros-workon toolchain-funcs | 6 inherit cros-debug cros-workon toolchain-funcs |
| 7 | 7 |
| 8 DESCRIPTION="Power Manager for Chromium OS" | 8 DESCRIPTION="Power Manager for Chromium OS" |
| 9 HOMEPAGE="http://src.chromium.org" | 9 HOMEPAGE="http://src.chromium.org" |
| 10 LICENSE="BSD" | 10 LICENSE="BSD" |
| 11 SLOT="0" | 11 SLOT="0" |
| 12 IUSE="-new_power_button test -lockvt -touchui" | 12 IUSE="-new_power_button test -lockvt -touchui -nocrit" |
| 13 KEYWORDS="~amd64 ~arm ~x86" | 13 KEYWORDS="~amd64 ~arm ~x86" |
| 14 | 14 |
| 15 RDEPEND="chromeos-base/libcros | 15 RDEPEND="chromeos-base/libcros |
| 16 chromeos-base/metrics | 16 chromeos-base/metrics |
| 17 dev-cpp/gflags | 17 dev-cpp/gflags |
| 18 dev-cpp/glog | 18 dev-cpp/glog |
| 19 x11-base/xorg-server | 19 x11-base/xorg-server |
| 20 x11-libs/gtk+ | 20 x11-libs/gtk+ |
| 21 x11-libs/libX11 | 21 x11-libs/libX11 |
| 22 x11-libs/libXext" | 22 x11-libs/libXext" |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 sed -i -e "/NAME=/s/=.*/=${LIGHT_SENSOR_NAME:-tsl2563}/" \ | 115 sed -i -e "/NAME=/s/=.*/=${LIGHT_SENSOR_NAME:-tsl2563}/" \ |
| 116 -e "/BUS=/s/=.*/=${LIGHT_SENSOR_BUS:-2}/" \ | 116 -e "/BUS=/s/=.*/=${LIGHT_SENSOR_BUS:-2}/" \ |
| 117 -e "/ADDRESS=/s/=.*/=${LIGHT_SENSOR_ADDRESS:-0x29}/" \ | 117 -e "/ADDRESS=/s/=.*/=${LIGHT_SENSOR_ADDRESS:-0x29}/" \ |
| 118 "${D}/lib/udev/light-sensor-install.sh" | 118 "${D}/lib/udev/light-sensor-install.sh" |
| 119 fi | 119 fi |
| 120 | 120 |
| 121 # Install light sensor udev rules | 121 # Install light sensor udev rules |
| 122 insinto "/etc/udev/rules.d" | 122 insinto "/etc/udev/rules.d" |
| 123 doins "${S}/99-light-sensor.rules" | 123 doins "${S}/99-light-sensor.rules" |
| 124 | 124 |
| 125 # Nocrit disables low battery suspend percent by setting it to 0 |
| 126 if use nocrit; then |
| 127 crit="usr/share/power_manager/low_battery_suspend_percent" |
| 128 if [ ! -e "${D}/${crit}" ]; then |
| 129 die "low_battery_suspend_percent config file missing" |
| 130 fi |
| 131 echo "0" > "${D}/${crit}" |
| 132 fi |
| 133 |
| 125 if use touchui; then | 134 if use touchui; then |
| 126 if [ ! -e "${D}/usr/share/power_manager/use_lid" ]; then | 135 if [ ! -e "${D}/usr/share/power_manager/use_lid" ]; then |
| 127 die "use_lid config file missing" | 136 die "use_lid config file missing" |
| 128 fi | 137 fi |
| 129 echo "0" > "${D}/usr/share/power_manager/use_lid" | 138 echo "0" > "${D}/usr/share/power_manager/use_lid" |
| 130 fi | 139 fi |
| 131 } | 140 } |
| OLD | NEW |