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 0F492198005 for ; Sun, 10 Mar 2013 14:50:07 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A3AD7E0205; Sun, 10 Mar 2013 14:50:05 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 2038BE0205 for ; Sun, 10 Mar 2013 14:50:05 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id E8F2333BE52 for ; Sun, 10 Mar 2013 14:50:02 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 52259E4079 for ; Sun, 10 Mar 2013 14:50:01 +0000 (UTC) From: "Anthony G. Basile" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anthony G. Basile" Message-ID: <1362926957.36072be59c421023ffb0ae53c6b12a44f3b5aa4c.blueness@gentoo> Subject: [gentoo-commits] proj/releng:master commit in: tools-uclibc/ X-VCS-Repository: proj/releng X-VCS-Files: tools-uclibc/run-mipsel3.sh tools-uclibc/stage1-mipsel3-uclibc-hardened.conf.template tools-uclibc/stage1-mipsel3-uclibc-vanilla.conf.template tools-uclibc/stage2-mipsel3-uclibc-hardened.conf.template tools-uclibc/stage2-mipsel3-uclibc-vanilla.conf.template tools-uclibc/stage3-mipsel3-uclibc-hardened.conf.template tools-uclibc/stage3-mipsel3-uclibc-vanilla.conf.template X-VCS-Directories: tools-uclibc/ X-VCS-Committer: blueness X-VCS-Committer-Name: Anthony G. Basile X-VCS-Revision: 36072be59c421023ffb0ae53c6b12a44f3b5aa4c X-VCS-Branch: master Date: Sun, 10 Mar 2013 14:50:01 +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: c775afcd-14e6-4871-8aeb-2375a08e2d76 X-Archives-Hash: fb23431d30b1e35fdd336c6ee9f38a93 commit: 36072be59c421023ffb0ae53c6b12a44f3b5aa4c Author: Anthony G. Basile gentoo org> AuthorDate: Sun Mar 10 14:49:12 2013 +0000 Commit: Anthony G. Basile gentoo org> CommitDate: Sun Mar 10 14:49:17 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/releng.git;a=commit;h=36072be5 tools-uclibc: add build scripts for mipsel3 uclibc --- tools-uclibc/run-mipsel3.sh | 129 ++++++++++++++++++++ .../stage1-mipsel3-uclibc-hardened.conf.template | 9 ++ .../stage1-mipsel3-uclibc-vanilla.conf.template | 9 ++ .../stage2-mipsel3-uclibc-hardened.conf.template | 9 ++ .../stage2-mipsel3-uclibc-vanilla.conf.template | 9 ++ .../stage3-mipsel3-uclibc-hardened.conf.template | 8 ++ .../stage3-mipsel3-uclibc-vanilla.conf.template | 8 ++ 7 files changed, 181 insertions(+), 0 deletions(-) diff --git a/tools-uclibc/run-mipsel3.sh b/tools-uclibc/run-mipsel3.sh new file mode 100644 index 0000000..7b398e2 --- /dev/null +++ b/tools-uclibc/run-mipsel3.sh @@ -0,0 +1,129 @@ +#!/bin/bash + +# +# Usage: ./run-mipsel3.sh +# where +# = "", it will actually do the runs +# = "test", it will just pretend +# + +source /etc/catalyst/catalyst.conf + +mydate=`date +%Y%m%d` + +prepare_confs() { + local arch=$1 + local flavor=$2 + + for s in 1 2 3; do + cat stage${s}-${arch}-uclibc-${flavor}.conf.template | \ + sed -e "s:\(^version_stamp.*$\):\1-${mydate}:" \ + -e "s:MyCatalyst:$(pwd):" > stage${s}-${arch}-uclibc-${flavor}.conf + done +} + +banner() { +cat << EOF | tee -a zzz.log > stage$1-$2-uclibc-$3.log + +************************************************************************ +* stage$1-$2-uclibc-$3 +************************************************************************" + +EOF +} + + +do_stages() { + local arch=$1 + local flavor=$2 + local pretend=$3 + + for s in 1 2 3; do + local tgpath="${storedir}/builds/${flavor}/${arch}" + local target="stage${s}-${arch}-uclibc-${flavor}-${mydate}.tar.bz2" + local tglink="stage${s}-${arch}-uclibc-${flavor}.tar.bz2" + + if [[ ! -f "${tgpath}/${tglink}" ]]; then + touch stage${s}-${arch}-uclibc-${flavor}.log + echo "!!! ${target} at ${tgpath} doesn't exit" \ + | tee -a zzz.log \ + > stage${s}-${arch}-uclibc-${flavor}.err + return 1 + fi + + if [[ "x${pretend}" != "xtest" ]]; then + banner ${s} ${arch} ${flavor} + catalyst -f stage${s}-${arch}-uclibc-${flavor}.conf \ + | tee -a zzz.log \ + > stage${s}-${arch}-uclibc-${flavor}.log \ + 2> stage${s}-${arch}-uclibc-${flavor}.err + else + touch stage${s}-${arch}-uclibc-${flavor}.log + touch stage${s}-${arch}-uclibc-${flavor}.err + touch "${tgpath}/${target}" + echo "PRETEND: catalyst -f stage${s}-${arch}-uclibc-${flavor}.conf \ " + echo "PRETEND: > stage${s}-${arch}-uclibc-${flavor}.log \ " + echo "PRETEND: 2> stage${s}-${arch}-uclibc-${flavor}.err" + fi + + if [[ -f "${tgpath}/${target}" ]]; then + rm -f "${tgpath}/${tglink}" + ln -s ${target} "${tgpath}/${tglink}" + else + echo "!!! ${target} was not generated" \ + | tee -a zzz.log \ + >stage${s}-${arch}-uclibc-${flavor}.err + return 1 + fi + done + + return 0 +} + + +# +# approximate timings: +# +# catalyst -s current 3 minutes +# catalyst -f stage1 130 minutes +# + +main() { + local pretend=$1 + + >zzz.log + + if [[ "x${pretend}" != "xtest" ]]; then + catalyst -s current | tee -a zzz.log >snapshot.log 2>snapshot.err + else + >snapshot.log + >snapshot.err + echo "PRETEND: catalyst -s current > snapshot.log 2> snapshot.err" + fi + + for arch in mipsel3; do + for flavor in hardened vanilla; do + prepare_confs ${arch} ${flavor} + done + done + + for arch in mipsel3; do + for flavor in hardened vanilla; do + do_stages ${arch} ${flavor} ${pretend} + ret=$? + if [[ $? == 1 ]]; then + echo "FAILURE at ${arch} ${flavor} ${pretend} " | tee zzz.log + return 1 + fi + done + done + + if [[ "x${pretend}" == "xtest" ]]; then + tree /var/tmp/catalyst/builds + echo + echo "!!! Run fixup.sh to clean up!" + echo + fi +} + +main $1 & diff --git a/tools-uclibc/stage1-mipsel3-uclibc-hardened.conf.template b/tools-uclibc/stage1-mipsel3-uclibc-hardened.conf.template new file mode 100644 index 0000000..5c5574f --- /dev/null +++ b/tools-uclibc/stage1-mipsel3-uclibc-hardened.conf.template @@ -0,0 +1,9 @@ +subarch: mipsel3 +target: stage1 +version_stamp: uclibc-hardened +rel_type: hardened/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: hardened/mipsel3/stage3-mipsel3-uclibc-hardened +chost: mips-gentoo-linux-uclibc +portage_confdir: MyCatalyst/portage.mips.hardened diff --git a/tools-uclibc/stage1-mipsel3-uclibc-vanilla.conf.template b/tools-uclibc/stage1-mipsel3-uclibc-vanilla.conf.template new file mode 100644 index 0000000..20a15c2 --- /dev/null +++ b/tools-uclibc/stage1-mipsel3-uclibc-vanilla.conf.template @@ -0,0 +1,9 @@ +subarch: mipsel3 +target: stage1 +version_stamp: uclibc-vanilla +rel_type: vanilla/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: vanilla/mipsel3/stage3-mipsel3-uclibc-vanilla +chost: mips-gentoo-linux-uclibc +portage_confdir: MyCatalyst/portage.mips.vanilla diff --git a/tools-uclibc/stage2-mipsel3-uclibc-hardened.conf.template b/tools-uclibc/stage2-mipsel3-uclibc-hardened.conf.template new file mode 100644 index 0000000..02f225c --- /dev/null +++ b/tools-uclibc/stage2-mipsel3-uclibc-hardened.conf.template @@ -0,0 +1,9 @@ +subarch: mipsel3 +target: stage2 +version_stamp: uclibc-hardened +rel_type: hardened/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: hardened/mipsel3/stage1-mipsel3-uclibc-hardened +chost: mips-gentoo-linux-uclibc +portage_confdir: MyCatalyst/portage.mips.hardened diff --git a/tools-uclibc/stage2-mipsel3-uclibc-vanilla.conf.template b/tools-uclibc/stage2-mipsel3-uclibc-vanilla.conf.template new file mode 100644 index 0000000..bd6a261 --- /dev/null +++ b/tools-uclibc/stage2-mipsel3-uclibc-vanilla.conf.template @@ -0,0 +1,9 @@ +subarch: mipsel3 +target: stage2 +version_stamp: uclibc-vanilla +rel_type: vanilla/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: vanilla/mipsel3/stage1-mipsel3-uclibc-vanilla +chost: mips-gentoo-linux-uclibc +portage_confdir: MyCatalyst/portage.mips.vanilla diff --git a/tools-uclibc/stage3-mipsel3-uclibc-hardened.conf.template b/tools-uclibc/stage3-mipsel3-uclibc-hardened.conf.template new file mode 100644 index 0000000..0808712 --- /dev/null +++ b/tools-uclibc/stage3-mipsel3-uclibc-hardened.conf.template @@ -0,0 +1,8 @@ +subarch: mipsel3 +target: stage3 +version_stamp: uclibc-hardened +rel_type: hardened/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: hardened/mipsel3/stage2-mipsel3-uclibc-hardened +portage_confdir: MyCatalyst/portage.mips.hardened diff --git a/tools-uclibc/stage3-mipsel3-uclibc-vanilla.conf.template b/tools-uclibc/stage3-mipsel3-uclibc-vanilla.conf.template new file mode 100644 index 0000000..7067d9e --- /dev/null +++ b/tools-uclibc/stage3-mipsel3-uclibc-vanilla.conf.template @@ -0,0 +1,8 @@ +subarch: mipsel3 +target: stage3 +version_stamp: uclibc-vanilla +rel_type: vanilla/mipsel3 +profile: hardened/linux/uclibc/mips/mipsel +snapshot: current +source_subpath: vanilla/mipsel3/stage2-mipsel3-uclibc-vanilla +portage_confdir: MyCatalyst/portage.mips.vanilla