From e28cbf3ddebc45a7b94e33df0c671d767e1ff7ad Mon Sep 17 00:00:00 2001 From: Paul Vaduva Date: Tue, 21 Mar 2017 15:36:46 +0100 Subject: aarch64: Fix missing qemu-aarch64-static in chroot During recent rework, we lost the explicit copy of qemu-aarch64-static from docker to chroot; so when trying to execute AArch64 binaries inside chroot, no emulator was present to handle it. This change brings back (inside chroot) the missing emulator binary. JIRA: YARDSTICK-595 Change-Id: I146e2eeec2e9452a0db36f0bf0a466a8affc2005 Signed-off-by: Paul Vaduva (cherry picked from commit 742ee6f3249a6204a351fe02c1334c9b14213e51) --- tools/ubuntu-server-cloudimg-modify.sh | 10 ++-------- tools/yardstick-img-modify | 6 +++--- 2 files changed, 5 insertions(+), 11 deletions(-) (limited to 'tools') diff --git a/tools/ubuntu-server-cloudimg-modify.sh b/tools/ubuntu-server-cloudimg-modify.sh index bffd83a7b..0316ecea6 100755 --- a/tools/ubuntu-server-cloudimg-modify.sh +++ b/tools/ubuntu-server-cloudimg-modify.sh @@ -93,14 +93,8 @@ else fi make --directory "${CLONE_DEST}/UnixBench/" -if [ "${YARD_IMG_ARCH}" = "arm64" ]; then - wget https://github.com/beefyamoeba5/ramspeed/archive/master.zip - unzip master.zip && rm master.zip - mkdir "${CLONE_DEST}/RAMspeed" - mv ramspeed-master/* "${CLONE_DEST}/RAMspeed/" -else - git clone https://github.com/beefyamoeba5/ramspeed.git "${CLONE_DEST}/RAMspeed" -fi +git clone https://github.com/beefyamoeba5/ramspeed.git "${CLONE_DEST}/RAMspeed" + cd "${CLONE_DEST}/RAMspeed/ramspeed-2.6.0" mkdir temp bash build.sh diff --git a/tools/yardstick-img-modify b/tools/yardstick-img-modify index 658717c71..2bb1ad447 100755 --- a/tools/yardstick-img-modify +++ b/tools/yardstick-img-modify @@ -104,9 +104,6 @@ download() { # mount image setup() { # qemu-img resize $raw_imgfile +5GB - if [ "${YARD_IMG_ARCH}" = "arm64" ]; then - echo -e "d\nn\np\n1\n\n\nw" | parted -l $raw_imgfile - fi mkdir -p $mountdir loopdevice=$(kpartx -l $raw_imgfile | head -1 | cut -f1 -d ' ') @@ -129,6 +126,9 @@ setup() { cp $(which "qemu-aarch64-static") "$mountdir/usr/bin" fi cp $cmd $mountdir/$(basename $cmd) + if [ "${YARD_IMG_ARCH}" = "arm64" ]; then + cp /usr/bin/qemu-aarch64-static $mountdir/usr/bin + fi } # modify image running a script using in a chrooted environment -- cgit 1.2.3-korg