Changeset 4ad76fa in mainline


Ignore:
Timestamp:
2023-10-19T18:51:14Z (14 months ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
master, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
972c428c
Parents:
d4643db
Message:

Improve QEMU build script

  • Install to ~/.local by default instead of system install.
  • Non-verbose tar expansion to reduce noise.
  • Configure with GTK, KVM, opengl, curses support. (By default, only VNC output is built in if headers are not

available, with no warning during configure. Now it stops
if those libraries are missing.)

  • Automatically retrieve public key for signature checking.
  • Build with -jnproc instead of -j4 (probably unnecessary, QEMU uses meson now).
  • Stop script if configure or build fails.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • contrib/qemu/build-from-scratch.sh

    rd4643db r4ad76fa  
    4242ARCHIVE_PREFIX="./S10image"
    4343BINARIES="1up-hv.bin 1up-md.bin nvram1 openboot.bin q.bin reset.bin"
     44INSTALL_PREFIX="$HOME/.local"
    4445
    4546echo "==== Downloading OpenSPARC archive ===="
     
    7778echo "==== Installing OpenSPARC binaries ===="
    7879
    79 sudo install -d /usr/local/opensparc/image
    80 sudo install -m 0444 binaries/* /usr/local/opensparc/image
     80install -d "$INSTALL_PREFIX/opensparc/image"
     81install -m 0444 binaries/* "$INSTALL_PREFIX/opensparc/image"
    8182
    8283echo "==== Obtaining QEMU sources ===="
     
    9495        fi
    9596
    96         gpg --verify ${TARBALL}.sig ${TARBALL}
     97        gpg --auto-key-retrieve --verify ${TARBALL}.sig ${TARBALL}
    9798        if [ $? -ne 0 ]; then
    9899                echo Unable to verify the signature
     
    100101        fi
    101102
    102         tar xvfj ${TARBALL}
     103        echo "==== Decompressing QEMU sources ===="
     104        tar xfj ${TARBALL}
    103105        cd ${SOURCEDIR}
    104106fi
     
    106108echo "==== Configuring QEMU ===="
    107109
    108 ./configure --target-list=i386-softmmu,x86_64-softmmu,arm-softmmu,aarch64-softmmu,ppc-softmmu,sparc64-softmmu,mips-softmmu,mipsel-softmmu --audio-drv-list=pa
     110./configure --target-list=i386-softmmu,x86_64-softmmu,arm-softmmu,aarch64-softmmu,ppc-softmmu,sparc64-softmmu,mips-softmmu,mipsel-softmmu --enable-gtk --enable-vte --enable-kvm --enable-curses --enable-opengl --enable-pa --audio-drv-list=pa --prefix="$INSTALL_PREFIX" || exit 1
    109111
    110112echo "==== Building QEMU ===="
    111113
    112 make -j 4
     114make -j`nproc` || exit 1
    113115
    114116echo "==== Installing QEMU ===="
    115117
    116 sudo make install
    117 
     118make install
Note: See TracChangeset for help on using the changeset viewer.