Patchwork [v2,02/28] alsa-state: use ${sbindir} instead of /usr/sbin for packaging

login
register
mail settings
Submitter Javier Martinez Canillas
Date Aug. 5, 2012, 7:48 p.m.
Message ID <1344196136-7643-3-git-send-email-javier@dowhile0.org>
Download mbox | patch
Permalink /patch/33903/
State Accepted
Commit 72fd0993d8643d7ca52d954d65395585fdf34b03
Headers show

Comments

Javier Martinez Canillas - Aug. 5, 2012, 7:48 p.m.
It is considered good practice to use the build system provided
variables instead of directly specify hardcoded paths.

Signed-off-by: Javier Martinez Canillas <javier@dowhile0.org>
---
 meta/recipes-bsp/alsa-state/alsa-state.bb |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

Patch

diff --git a/meta/recipes-bsp/alsa-state/alsa-state.bb b/meta/recipes-bsp/alsa-state/alsa-state.bb
index 83c9faa..a9cc04c 100644
--- a/meta/recipes-bsp/alsa-state/alsa-state.bb
+++ b/meta/recipes-bsp/alsa-state/alsa-state.bb
@@ -10,7 +10,7 @@  sound state at system boot and save it at system shut down."
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
 PV = "0.2.0"
-PR = "r2"
+PR = "r3"
 
 SRC_URI = "\
   file://asound.conf \
@@ -46,9 +46,9 @@  FILES_alsa-states = "${localstatedir}/lib/alsa/*.state"
 pkg_postinst_${PN}() {
 	if test -z "$D"
 	then
-		if test -x /usr/sbin/alsactl
+		if test -x ${sbindir}/alsactl
 		then
-			/usr/sbin/alsactl -f ${localstatedir}/lib/alsa/asound.state restore
+			${sbindir}/alsactl -f ${localstatedir}/lib/alsa/asound.state restore
 		fi
 		# INITSCRIPT_PARAMS changed, so remove the old and
 		# install the new setting.