public inbox for gentoo-catalyst@lists.gentoo.org
 help / color / mirror / Atom feed
From: Christos Kotsi <christo.kotsi@gmail.com>
To: gentoo-catalyst@lists.gentoo.org
Cc: christo.kotsi@gmail.com
Subject: [gentoo-catalyst] [PATCH 4/6] Added some loops
Date: Wed, 12 Apr 2017 11:43:47 +0300	[thread overview]
Message-ID: <20170412084349.2017-4-christo.kotsi@gmail.com> (raw)
In-Reply-To: <20170412084349.2017-1-christo.kotsi@gmail.com>

---
 targets/support/bootloader-setup.sh | 24 +++++++++---------------
 1 file changed, 9 insertions(+), 15 deletions(-)

diff --git a/targets/support/bootloader-setup.sh b/targets/support/bootloader-setup.sh
index d9e2620..97920e7 100755
--- a/targets/support/bootloader-setup.sh
+++ b/targets/support/bootloader-setup.sh
@@ -7,8 +7,7 @@ source ${clst_shdir}/support/filesystem-functions.sh
 
 extract_cdtar $1
 extract_kernels $1/boot
-check_bootargs
-check_filesystem_type
+check_{bootargs,filesystem_type}
 
 default_append_line="root=/dev/ram0 init=/linuxrc ${cmdline_opts} ${custom_kopts} cdroot"
 [ -n "${clst_splash_theme}" ] && default_append_line="${default_append_line} splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet"
@@ -274,15 +273,13 @@ case ${clst_hostarch} in
 			echo "prompt 1" >> ${icfg}
 			echo "display boot.msg" >> ${icfg}
 			echo "F1 kernels.msg" >> ${icfg}
-			echo "F2 F2.msg" >> ${icfg}
-			echo "F3 F3.msg" >> ${icfg}
-			echo "F4 F4.msg" >> ${icfg}
-			echo "F5 F5.msg" >> ${icfg}
-			echo "F6 F6.msg" >> ${icfg}
-			echo "F7 F7.msg" >> ${icfg}
+			for k in {2..7}
+			do
+				echo "F${k} F${k}.msg" >> ${icfg}
+			done
 
 			echo "Available kernels:" > ${kmsg}
-			for i in 2 3 4 5 6 7
+			for i in {2..7}
 			do
 				cp ${clst_sharedir}/livecd/files/x86-F$i.msg \
 					$1/isolinux/F$i.msg
@@ -303,7 +300,6 @@ case ${clst_hostarch} in
 						echo "label ${x}-${y}" >> ${icfg}
 						echo "  kernel ${x}" >> ${icfg}
 						echo "  append ${default_append_line} softlevel=${y} initrd=${x}.igz vga=791" >> ${icfg}
-
 						echo >> ${icfg}
 						echo "   ${x}" >> ${kmsg}
 						echo "label ${x}-${y}-nofb" >> ${icfg}
@@ -475,11 +471,9 @@ case ${clst_hostarch} in
 		# Next, figure out what kernels were specified in the
 		# spec file, and generate the appropriate arcload conf
 		# blocks specific to each system
-		ip22="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip22" | tr "\n" " ")"
-		ip27="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip27" | tr "\n" " ")"
-		ip28="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip28" | tr "\n" " ")"
-		ip30="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip30" | tr "\n" " ")"
-		ip32="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip32" | tr "\n" " ")"
+		for l in 22 27 28 30 32; do
+			ip${l}="$(echo ${clst_boot_kernel} | tr " " "\n" | grep "ip${l}" | tr "\n" " ")"
+		done
 
 		if [ -n "${ip22}" ]; then
 			echo -e "${ip22base}" >> ${scratch}/arc.cf
-- 
2.10.2



  parent reply	other threads:[~2017-04-12  8:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-12  8:43 [gentoo-catalyst] [PATCH 1/6] Concentrated some cp commands Christos Kotsi
2017-04-12  8:43 ` [gentoo-catalyst] [PATCH 2/6] updated gitignore with patches directory Christos Kotsi
2017-04-12 19:20   ` Mike Frysinger
2017-04-12  8:43 ` [gentoo-catalyst] [PATCH 3/6] Concentrated export&delete_from_root lines Christos Kotsi
2017-04-12 19:24   ` Mike Frysinger
2017-04-12  8:43 ` Christos Kotsi [this message]
2017-04-12  8:43 ` [gentoo-catalyst] [PATCH 5/6] ln,echo and cp commands concentration Christos Kotsi
2017-04-12 19:24   ` Mike Frysinger
2017-04-12  8:43 ` [gentoo-catalyst] [PATCH 6/6] changed mkdir line for kernels/misc Christos Kotsi
2017-04-13 16:45 ` [gentoo-catalyst] [PATCH 1/6] Concentrated some cp commands Mike Frysinger

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=20170412084349.2017-4-christo.kotsi@gmail.com \
    --to=christo.kotsi@gmail.com \
    --cc=gentoo-catalyst@lists.gentoo.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox