All of lore.kernel.org
 help / color / mirror / Atom feed
From: Javier Martinez Canillas <javier@dowhile0.org>
To: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: openembedded-core@lists.openembedded.org
Subject: [PATCH v2 16/28] kernel.bbclass: use ${base_libdir} and ${sysconfdir} instead of /lib and /etc
Date: Sun,  5 Aug 2012 21:48:44 +0200	[thread overview]
Message-ID: <1344196136-7643-17-git-send-email-javier@dowhile0.org> (raw)
In-Reply-To: <1344196136-7643-1-git-send-email-javier@dowhile0.org>

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/classes/kernel.bbclass |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 1d8dff9..b434093 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -109,10 +109,10 @@ kernel_do_install() {
 	unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
 	if (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
 		oe_runmake DEPMOD=echo INSTALL_MOD_PATH="${D}" modules_install
-		rm -f "${D}/lib/modules/${KERNEL_VERSION}/modules.order"
-		rm -f "${D}/lib/modules/${KERNEL_VERSION}/modules.builtin"
-		rm "${D}/lib/modules/${KERNEL_VERSION}/build"
-		rm "${D}/lib/modules/${KERNEL_VERSION}/source"
+		rm -f "${D}${base_libdir}/modules/${KERNEL_VERSION}/modules.order"
+		rm -f "${D}${base_libdir}/modules/${KERNEL_VERSION}/modules.builtin"
+		rm "${D}${base_libdir}/modules/${KERNEL_VERSION}/build"
+		rm "${D}${base_libdir}/modules/${KERNEL_VERSION}/source"
 	else
 		bbnote "no modules to install"
 	fi
@@ -127,8 +127,8 @@ kernel_do_install() {
 	install -m 0644 .config ${D}/boot/config-${KERNEL_VERSION}
 	install -m 0644 vmlinux ${D}/boot/vmlinux-${KERNEL_VERSION}
 	[ -e Module.symvers ] && install -m 0644 Module.symvers ${D}/boot/Module.symvers-${KERNEL_VERSION}
-	install -d ${D}/etc/modules-load.d
-	install -d ${D}/etc/modprobe.d
+	install -d ${D}${sysconfdir}/modules-load.d
+	install -d ${D}${sysconfdir}/modprobe.d
 
 	#
 	# Support for external module building - create a minimal copy of the
-- 
1.7.7.6




  parent reply	other threads:[~2012-08-05 20:01 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-05 19:48 (No subject) Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 01/28] xinetd: use ${sbindir} and ${sysconfdir} instead of /usr/sbin and /etc Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 02/28] alsa-state: use ${sbindir} instead of /usr/sbin for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 03/28] lsbsetup: use ${bindir} instead of /usr/bin " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 04/28] sudo: use ${bindir} and ${sysconfdir} instead of /usr/bin and /etc Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 05/28] lsbtest: use ${bindir} instead of /usr/bin for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 06/28] cronie: use variables instead of hardcoded paths Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 07/28] useradd-example: use ${datadir} instead of /usr/share for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 08/28] ubootchart: use variables instead of hardcoded paths Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 09/28] xkeyboard-config: use ${datadir} instead of /usr/share for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 10/28] systemtap: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 11/28] lsb: use ${base_bindir} and ${sysconfdir} instead of /bin and /etc Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 12/28] mingetty: use ${base_sbindir} instead of /sbin for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 13/28] external-sourcery: use ${prefix} and ${libdir} instead of /usr and /usr/lib Javier Martinez Canillas
2012-08-05 21:34   ` Chris Larson
2012-08-05 21:53     ` Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 14/28] rpm: use ${localstatedir} and ${libdir} instead of /var " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 15/28] at: use ${base_sbindir} instead of /sbin for packaging Javier Martinez Canillas
2012-08-05 19:48 ` Javier Martinez Canillas [this message]
2012-08-06 16:14   ` [PATCH v2 16/28] kernel.bbclass: use ${base_libdir} and ${sysconfdir} instead of /lib and /etc Darren Hart
2012-08-06 17:26     ` Javier Martinez Canillas
2012-08-07 20:04     ` Khem Raj
2012-08-07 20:19       ` McClintock Matthew-B29882
2012-08-05 19:48 ` [PATCH v2 17/28] linux-firware: use ${base_libdir} instead of /lib for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 18/28] openssh: use ${localstatedir} instead of /var " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 19/28] libpam: use ${localstatedir} and ${sysconfdir} instead of /var and /etc Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 20/28] x11-common: use ${sysconfdir} instead of /etc for packaging Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 21/28] builder: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 22/28] xserver-nodm-init: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 23/28] lsbinitscripts: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 24/28] usbinit: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 25/28] qemu-config: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 26/28] rsync: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 27/28] chkconfig: " Javier Martinez Canillas
2012-08-05 19:48 ` [PATCH v2 28/28] man: " Javier Martinez Canillas
2012-08-06 14:59 ` (No subject) Richard Purdie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1344196136-7643-17-git-send-email-javier@dowhile0.org \
    --to=javier@dowhile0.org \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.