From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 3DD6A138A1F for ; Mon, 14 Apr 2014 01:16:17 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3C31DE0AC9; Mon, 14 Apr 2014 01:16:15 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id A2737E0AF4 for ; Mon, 14 Apr 2014 01:16:14 +0000 (UTC) Received: from spoonbill.gentoo.org (spoonbill.gentoo.org [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D19E833FFD7 for ; Mon, 14 Apr 2014 01:16:13 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id AA72118737 for ; Mon, 14 Apr 2014 01:16:11 +0000 (UTC) From: "Robin H. Johnson" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Robin H. Johnson" Message-ID: <1397437171.c93c617ee0f4ed3b7559208339eecfac4a49c8ec.robbat2@gentoo> Subject: [gentoo-commits] proj/genkernel:master commit in: / X-VCS-Repository: proj/genkernel X-VCS-Files: gen_initramfs.sh X-VCS-Directories: / X-VCS-Committer: robbat2 X-VCS-Committer-Name: Robin H. Johnson X-VCS-Revision: c93c617ee0f4ed3b7559208339eecfac4a49c8ec X-VCS-Branch: master Date: Mon, 14 Apr 2014 01:16:11 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 8e17513e-f27a-4d25-bf21-f170e73e42b0 X-Archives-Hash: bbe6fe7b4b0fd3a7278dc9ffe18f2d66 commit: c93c617ee0f4ed3b7559208339eecfac4a49c8ec Author: Robin H. Johnson gentoo org> AuthorDate: Mon Apr 14 00:47:38 2014 +0000 Commit: Robin H. Johnson gentoo org> CommitDate: Mon Apr 14 00:59:31 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commit;h=c93c617e Detect mknod failure. Signed-off-by: Robin H. Johnson gentoo.org> --- gen_initramfs.sh | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gen_initramfs.sh b/gen_initramfs.sh index 070dffc..d5ee5f6 100755 --- a/gen_initramfs.sh +++ b/gen_initramfs.sh @@ -89,12 +89,13 @@ append_base_layout() { echo "proc /proc proc defaults 0 0" >> ${TEMP}/initramfs-base-temp/etc/fstab cd ${TEMP}/initramfs-base-temp/dev - mknod -m 660 console c 5 1 - mknod -m 660 null c 1 3 - mknod -m 660 zero c 1 5 - mknod -m 600 tty0 c 4 0 - mknod -m 600 tty1 c 4 1 - mknod -m 600 ttyS0 c 4 64 + # TODO: this will fail as non-root + mknod -m 660 console c 5 1 || gen_die "failed to mknod" + mknod -m 660 null c 1 3 || gen_die "failed to mknod" + mknod -m 660 zero c 1 5 || gen_die "failed to mknod" + mknod -m 600 tty0 c 4 0 || gen_die "failed to mknod" + mknod -m 600 tty1 c 4 1 || gen_die "failed to mknod" + mknod -m 600 ttyS0 c 4 64 || gen_die "failed to mknod" date -u '+%Y%m%d-%H%M%S' > ${TEMP}/initramfs-base-temp/etc/build_date echo "Genkernel $GK_V" > ${TEMP}/initramfs-base-temp/etc/build_id