v1.17
This commit is contained in:
parent
e33d0f4fb5
commit
a57f4666c2
258
aq.sh
258
aq.sh
@ -19,10 +19,10 @@
|
||||
# aixiao@aixiao.me.
|
||||
#
|
||||
|
||||
#set -x
|
||||
path() {
|
||||
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
}
|
||||
|
||||
init() {
|
||||
initdate
|
||||
check_os
|
||||
@ -30,6 +30,7 @@ init() {
|
||||
check_root
|
||||
PWD=$(pwd)
|
||||
SRC=$PWD/AQ
|
||||
LOG=$(pwd)/AQ/LOG
|
||||
QEMU_PREFIX=/data/local/aixiao.qemu
|
||||
QEMU_VERSION="2.8.0"
|
||||
QEMU_VERSION="2.8.1.1"
|
||||
@ -47,6 +48,8 @@ init() {
|
||||
QEMU_VERSION="2.11.1"
|
||||
QEMU_VERSION="2.12.0-rc4"
|
||||
QEMU_VERSION="2.12.0"
|
||||
QEMU_VERSION="3.0.0"
|
||||
QEMU_VERSION="4.0.0-rc2"
|
||||
QEMU_VERSION=${qemu_version:-"$QEMU_VERSION"}
|
||||
check_qemu_version $QEMU_VERSION
|
||||
QEMU_TAR_SRC=${PWD}/AQ/qemu-${QEMU_VERSION}.tar.xz
|
||||
@ -55,97 +58,54 @@ init() {
|
||||
QEMU_SRC_DIR=${PWD}/AQ/qemu-${QEMU_VERSION}
|
||||
QEMU_GIT_SRC_DIR=${PWD}/AQ/qemu
|
||||
QEMU_CONFIGURE_2_8_0="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu \
|
||||
--static \
|
||||
|
||||
--enable-docs --enable-guest-agent \
|
||||
|
||||
--enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png --enable-fdt --enable-bluez --enable-kvm --enable-colo --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-bzip2 \
|
||||
|
||||
--enable-coroutine-pool --enable-tpm --disable-libssh2 --enable-replication \
|
||||
--disable-libiscsi --disable-libnfs --disable-libusb --disable-smartcard --disable-usb-redir --disable-glusterfs --disable-seccomp \
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu --static --enable-docs --enable-guest-agent --enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png --enable-fdt --enable-bluez --enable-kvm --enable-colo --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-bzip2 --enable-coroutine-pool --enable-tpm --disable-libssh2 --enable-replication --disable-libiscsi --disable-libnfs --disable-libusb --disable-smartcard --disable-usb-redir --disable-glusterfs --disable-seccomp
|
||||
"
|
||||
QEMU_CONFIGURE_2_8_1_1="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu \
|
||||
--static \
|
||||
|
||||
--enable-docs --enable-guest-agent \
|
||||
|
||||
--enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png \
|
||||
--enable-fdt --enable-bluez --enable-kvm --enable-colo --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-bzip2 \
|
||||
|
||||
--enable-coroutine-pool --enable-tpm --disable-libssh2 --enable-replication \
|
||||
--disable-libiscsi --disable-libnfs --disable-libusb --disable-smartcard --disable-usb-redir --disable-glusterfs --disable-seccomp \
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu --static --enable-docs --enable-guest-agent --enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png --enable-fdt --enable-bluez --enable-kvm --enable-colo --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-bzip2 --enable-coroutine-pool --enable-tpm --disable-libssh2 --enable-replication --disable-libiscsi --disable-libnfs --disable-libusb --disable-smartcard --disable-usb-redir --disable-glusterfs --disable-seccomp
|
||||
"
|
||||
QEMU_CONFIGURE_2_10_0_RC0="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu \
|
||||
--static \
|
||||
|
||||
--enable-docs \
|
||||
--enable-guest-agent \
|
||||
|
||||
--disable-sdl --disable-gtk --disable-vte --disable-curses --disable-cocoa \
|
||||
--enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png --disable-virtfs --enable-fdt --enable-bluez --enable-kvm --disable-hax \
|
||||
--enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --enable-bzip2 \
|
||||
|
||||
--enable-coroutine-pool --disable-glusterfs --enable-tpm --enable-libssh2 --enable-replication --enable-vhost-vsock --enable-xfsctl --enable-tools \
|
||||
--enable-crypto-afalg \
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu --static --enable-docs --enable-guest-agent --disable-sdl --disable-gtk --disable-vte --disable-curses --disable-cocoa --enable-gcrypt --enable-vnc --enable-vnc-jpeg --enable-vnc-png --disable-virtfs --enable-fdt --enable-bluez --enable-kvm --disable-hax --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --enable-bzip2 --enable-coroutine-pool --disable-glusterfs --enable-tpm --enable-libssh2 --enable-replication --enable-vhost-vsock --enable-xfsctl --enable-tools --enable-crypto-afalg
|
||||
"
|
||||
QEMU_CONFIGURE_2_10_0_RC2="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu \
|
||||
--static \
|
||||
|
||||
--enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse \
|
||||
|
||||
--disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa \
|
||||
--enable-virtfs --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax \
|
||||
--disable-rdma --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard \
|
||||
--disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy \
|
||||
--enable-bzip2 \
|
||||
|
||||
--disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl \
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs \
|
||||
--enable-crypto-afalg --enable-vhost-user\
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu --static --enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse --disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa --enable-virtfs --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax --disable-rdma --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 --disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl --disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user
|
||||
"
|
||||
QEMU_CONFIGURE_2_11_0_RC0="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu \
|
||||
--static \
|
||||
--enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse \
|
||||
|
||||
--disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa \
|
||||
--enable-virtfs --enable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax \
|
||||
--disable-rdma --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard \
|
||||
--disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 \
|
||||
|
||||
--disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl \
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone\
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu --static --enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse --disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa --enable-virtfs --enable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax --disable-rdma --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 --disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl --disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone
|
||||
"
|
||||
QEMU_CONFIGURE_2_11_1="
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu \
|
||||
--static \
|
||||
--enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse \
|
||||
|
||||
--disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa \
|
||||
--enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax \
|
||||
--disable-rdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard \
|
||||
--disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 \
|
||||
|
||||
--disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl \
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone \
|
||||
./configure --prefix=${QEMU_PREFIX} --target-list=arm-linux-user,arm-softmmu,i386-linux-user,i386-softmmu --static --enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse --disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa --enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-fdt --enable-bluez --enable-kvm --disable-hax --disable-rdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 --disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl --disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone
|
||||
"
|
||||
QEMU_CONFIGURE_2_12_0_RC4="
|
||||
./configure --prefix=${QEMU_PREFIX}\
|
||||
--static\
|
||||
--enable-malloc-trim\
|
||||
./configure --prefix=${QEMU_PREFIX} --static --enable-malloc-trim --enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse --disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa --enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-membarrier --enable-fdt --enable-bluez --enable-kvm --disable-hax --disable-hvf --disable-whpx --disable-rdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-vhost-crypto --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard --disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 --disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --enable-libxml2 --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl --disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone
|
||||
"
|
||||
|
||||
QEMU_CONFIGURE_3_0_0="
|
||||
./configure --prefix=${QEMU_PREFIX} --static --enable-malloc-trim\
|
||||
--enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse\
|
||||
--disable-gnutls --disable-nettle --enable-gcrypt --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa\
|
||||
--enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-membarrier --enable-fdt --enable-bluez --enable-kvm --disable-hax\
|
||||
--disable-hvf --disable-whpx\
|
||||
--disable-rdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-vhost-crypto --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard\
|
||||
--enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-membarrier --enable-fdt --enable-bluez --enable-kvm --disable-hax
|
||||
--disable-hvf --disable-whpx --disable-rdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-vhost-crypto --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard\
|
||||
--disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2\
|
||||
--disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --disable-libssh2 --disable-numa --enable-libxml2 --disable-tcmalloc --disable-jemalloc --enable-replication --enable-vhost-vsock --disable-opengl\
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone\
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-crypto-afalg --enable-vhost-user --enable-capstone --disable-capstone
|
||||
"
|
||||
|
||||
ALSA_PREFIX="/data/local/alsa"
|
||||
QEMU_CONFIGURE_4_0_0_RC2="
|
||||
./configure --prefix=${QEMU_PREFIX}\
|
||||
--static --audio-drv-list=alsa --extra-ldflags=-L${ALSA_PREFIX}/lib\
|
||||
--enable-malloc-trim\
|
||||
--enable-system --enable-user --disable-bsd-user --enable-docs --enable-guest-agent --disable-guest-agent-msi --disable-pie --disable-modules --enable-debug-tcg --disable-debug-info --disable-sparse\
|
||||
--disable-gnutls --disable-nettle --enable-gcrypt --disable-auth-pam --disable-sdl --disable-gtk --disable-vte --disable-curses --enable-iconv --enable-vnc --disable-vnc-sasl --enable-vnc-jpeg --enable-vnc-png --disable-cocoa\
|
||||
--enable-virtfs --disable-mpath --disable-xen --disable-xen-pci-passthrough --disable-brlapi --disable-curl --enable-membarrier --enable-fdt --enable-bluez --enable-kvm --disable-hax\
|
||||
--disable-hvf --disable-whpx\
|
||||
--disable-rdma --disable-pvrdma --enable-vde --disable-netmap --enable-linux-aio --enable-cap-ng --enable-attr --enable-vhost-net --enable-vhost-vsock --enable-vhost-scsi --enable-vhost-crypto --enable-vhost-kernel --enable-vhost-user --disable-spice --disable-rbd --enable-libiscsi --disable-libnfs --disable-smartcard\
|
||||
--disable-libusb --enable-live-block-migration --disable-usb-redir --disable-lzo --disable-snappy --enable-bzip2 --disable-lzfse\
|
||||
--disable-seccomp --enable-coroutine-pool --disable-glusterfs --enable-tpm --enable-libssh2 --disable-numa --enable-libxml2 --disable-tcmalloc --disable-jemalloc --disable-avx2 --enable-replication --disable-opengl\
|
||||
--disable-virglrenderer --enable-xfsctl --enable-qom-cast-debug --enable-tools --disable-vxhs --enable-bochs --enable-cloop --enable-dmg --enable-qcow1 --enable-vdi --enable-vvfat --enable-qed --enable-parallels --enable-sheepdog --enable-crypto-afalg --enable-capstone --enable-debug-mutex --disable-libpmem\
|
||||
"
|
||||
|
||||
|
||||
QEMU_CONFIGURE_2_10_0_RC1=$QEMU_CONFIGURE_2_10_0_RC0
|
||||
QEMU_CONFIGURE_2_10_0_RC2=$QEMU_CONFIGURE_2_10_0_RC2
|
||||
QEMU_CONFIGURE_2_10_0_RC3=$QEMU_CONFIGURE_2_10_0_RC2
|
||||
@ -160,7 +120,10 @@ init() {
|
||||
QEMU_CONFIGURE_2_11_1=$QEMU_CONFIGURE_2_11_1
|
||||
QEMU_CONFIGURE_2_12_0_RC4=$QEMU_CONFIGURE_2_12_0_RC4
|
||||
QEMU_CONFIGURE_2_12_0=$QEMU_CONFIGURE_2_12_0_RC4
|
||||
QEMU_CONFIGURE_GIT=$QEMU_CONFIGURE_2_12_0_RC4
|
||||
QEMU_CONFIGURE_3_0_0=$QEMU_CONFIGURE_3_0_0
|
||||
QEMU_CONFIGURE_4_0_0_RC2=$QEMU_CONFIGURE_4_0_0_RC2
|
||||
QEMU_CONFIGURE_GIT=$QEMU_CONFIGURE_3_0_0
|
||||
|
||||
MAKE_J="$(grep -c ^processor /proc/cpuinfo | grep -E '^[1-9]+[0-9]*$' || echo 1)" ; test $MAKE_J != "1" && make_j=$((MAKE_J - 1)) || make_j=$MAKE_J
|
||||
MAKE_J="-j${make_j}"
|
||||
pkg_install $OS
|
||||
@ -171,26 +134,94 @@ init() {
|
||||
fi
|
||||
src_download
|
||||
tar_extract
|
||||
if test "${QEMU_VERSION}" = "4.0.0-rc2"; then
|
||||
build_alsa-lib;
|
||||
fi
|
||||
install qemu
|
||||
}
|
||||
|
||||
function check_alsa() {
|
||||
case $1 in
|
||||
"4.0.0-rc2") build_alsa-lib; ;;
|
||||
esac
|
||||
}
|
||||
|
||||
function build_alsa-lib() {
|
||||
ALSA_VERSION="1.1.8";
|
||||
ALSA_TAR_SRC="${SRC}/alsa-lib-${ALSA_VERSION}.tar.bz2";
|
||||
ALSA_TAR_SRC_USR="ftp://ftp.alsa-project.org/pub/lib/alsa-lib-${ALSA_VERSION}.tar.bz2";
|
||||
ALSA_SRC_DIR=${SRC}/alsa-lib-${ALSA_VERSION};
|
||||
|
||||
ALSA_CONFIGURE_1_1_8="
|
||||
./configure --prefix=${ALSA_PREFIX} --enable-static=yes --disable-shared
|
||||
"
|
||||
|
||||
if ! test -f ${ALSA_TAR_SRC} ; then
|
||||
echo -n "Download ALSA-LIB ${ALSA_VERSION} "
|
||||
bg_wait wget -q -T 120 -O ${ALSA_TAR_SRC}_tmp ${ALSA_TAR_SRC_USR}
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" || ! test -f ${ALSA_TAR_SRC}_tmp ; then
|
||||
echo -ne fail\\n
|
||||
test -f ${ALSA_TAR_SRC}_tmp && rm -f ${ALSA_TAR_SRC}_tmp && exit 3
|
||||
else
|
||||
echo -ne done\\n
|
||||
mv ${ALSA_TAR_SRC}_tmp ${ALSA_TAR_SRC}
|
||||
fi
|
||||
fi
|
||||
if ! test -d ${ALSA_SRC_DIR}; then
|
||||
echo -n +Extract ALSA ....
|
||||
tar -axf ${ALSA_TAR_SRC} -C ${SRC} >> ${BGEXEC_LOG_STATUS_FILE} 2>&1
|
||||
if ! test -d ${ALSA_SRC_DIR} ; then
|
||||
echo -ne \\b\\b\\b\\bfail\\n
|
||||
exit 3
|
||||
else
|
||||
echo -ne \\b\\b\\b\\bdone\\n
|
||||
fi
|
||||
fi
|
||||
|
||||
cd ${ALSA_SRC_DIR};
|
||||
echo -n "Configure ALSA "
|
||||
bg_wait $ALSA_CONFIGURE_1_1_8
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) = "0" && test -f ${ALSA_SRC_DIR}/Makefile ; then
|
||||
echo -ne done\\n
|
||||
else
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
|
||||
make $MAKE_J >> $LOG 2>&1 &
|
||||
echo -n Make ALSA\ ;wait_pid $!
|
||||
if test -x $ALSA_SRC_DIR/aserver/aserver ; then
|
||||
echo -ne done\\n
|
||||
else
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
make install >> $LOG 2>&1 &
|
||||
echo -n Make install ALSA\ ;wait_pid $!
|
||||
if test -x $ALSA_PREFIX/bin/aserver ; then
|
||||
echo -ne done\\n
|
||||
else
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
initdate() {
|
||||
init_date=`date +%s`
|
||||
}
|
||||
|
||||
helloworld() {
|
||||
cat <<HELLOWORLD
|
||||
cat <<EOF
|
||||
-----------------------------
|
||||
Web: AIXIAO.ME
|
||||
AQ: $VER for $OS $vvv
|
||||
Qq: 1225803134
|
||||
Qq: 1605227279
|
||||
Qemail: 1225803134@qq.com
|
||||
Qemail: 1605227279@qq.com
|
||||
Author: aixiao@aixiao.me
|
||||
Android Qemu
|
||||
-----------------------------
|
||||
HELLOWORLD
|
||||
EOF
|
||||
}
|
||||
|
||||
check_os() {
|
||||
@ -222,6 +253,7 @@ check_os() {
|
||||
test "$arch" = "x86_64" && arch=x64
|
||||
test "$arch" = "armv7l" && arch=arm
|
||||
test "$arch" = "armv6l" && arch=arm
|
||||
test "$arch" = "aarch64" && arch=arm;
|
||||
case $vvv in
|
||||
"8")
|
||||
:
|
||||
@ -240,13 +272,13 @@ check_os() {
|
||||
"9")
|
||||
case $arch in
|
||||
"arm")
|
||||
APT1="libbz2-dev libxml2-dev liblzma-dev"
|
||||
APT1="libbz2-dev libxml2-dev liblzma-dev flex bison texinfo perl python-sphinx"
|
||||
;;
|
||||
"x86")
|
||||
APT1="libbz2-dev libxml2-dev liblzma-dev"
|
||||
;;
|
||||
"x64")
|
||||
APT1="libbz2-dev libxml2-dev liblzma-dev"
|
||||
APT1="libbz2-dev libxml2-dev liblzma-dev flex bison texinfo perl python-sphinx"
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
@ -302,6 +334,8 @@ check_qemu_version() {
|
||||
"2.11.1") : ;;
|
||||
"2.12.0-rc4") : ;;
|
||||
"2.12.0") : ;;
|
||||
"3.0.0") : ;;
|
||||
"4.0.0-rc2") : ;;
|
||||
*) echo -ne The QEMU $QEMU_VERSION version does not support configure\\n ; exit 3 ;;
|
||||
esac
|
||||
}
|
||||
@ -339,18 +373,22 @@ wait_pid() {
|
||||
done
|
||||
}
|
||||
|
||||
function TEE() {
|
||||
$@ | tee -a $LOG
|
||||
}
|
||||
|
||||
pkg_install() {
|
||||
case $1 in
|
||||
debian)
|
||||
echo -n "Debian apt update "
|
||||
bg_wait apt-get update
|
||||
bg_wait TEE apt-get update
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n
|
||||
else
|
||||
echo -ne done\\n
|
||||
fi
|
||||
echo -n "Debian apt install "
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait apt-get -qqy --force-yes install build-essential git-core $APT
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait TEE apt-get -qqy --force-yes install build-essential git-core $APT
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n-----------------------------\\n
|
||||
exit 3
|
||||
@ -358,7 +396,7 @@ pkg_install() {
|
||||
echo -ne done\\n
|
||||
fi
|
||||
echo -n "Debian apt build-dep "
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait apt-get -qqy --force-yes build-dep qemu-system
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait TEE apt-get -qqy --force-yes build-dep qemu-system
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n-----------------------------\\n
|
||||
exit 3
|
||||
@ -367,14 +405,14 @@ pkg_install() {
|
||||
;;
|
||||
ubuntu)
|
||||
echo -n "Ubuntu apt update "
|
||||
bg_wait apt-get update
|
||||
bg_wait TEE apt-get update
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n
|
||||
else
|
||||
echo -ne done\\n
|
||||
fi
|
||||
echo -n "Ubuntu apt install "
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait apt-get -qqy --force-yes install build-essential git $APT
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait TEE apt-get -qqy --force-yes install build-essential git $APT
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n-----------------------------\\n
|
||||
exit 3
|
||||
@ -382,7 +420,7 @@ pkg_install() {
|
||||
echo -ne done\\n
|
||||
fi
|
||||
echo -n "Ubuntu apt build-dep "
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait apt-get -qqy --force-yes build-dep qemu-system
|
||||
DEBIAN_FRONTEND=noninteractive bg_wait TEE apt-get -qqy --force-yes build-dep qemu-system
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n-----------------------------\\n
|
||||
exit 3
|
||||
@ -396,7 +434,7 @@ pkg_install() {
|
||||
src_download() {
|
||||
if ! test -f ${QEMU_TAR_SRC} ; then
|
||||
echo -n "Download QEMU ${QEMU_VERSION} "
|
||||
bg_wait wget -q -T 120 -O ${QEMU_TAR_SRC}_tmp ${QEMU_TAR_SRC_USR}
|
||||
bg_wait TEE wget -q -T 120 -O ${QEMU_TAR_SRC}_tmp ${QEMU_TAR_SRC_USR}
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" || ! test -f ${QEMU_TAR_SRC}_tmp ; then
|
||||
echo -ne fail\\n
|
||||
test -f ${QEMU_TAR_SRC}_tmp && rm -f ${QEMU_TAR_SRC}_tmp && exit 3
|
||||
@ -448,18 +486,18 @@ git_clone() {
|
||||
if ! test -d $QEMU_GIT_SRC_DIR ; then
|
||||
echo -n "GIT PULL QEMU "
|
||||
cd $SRC
|
||||
bg_wait git clone git://git.qemu-project.org/qemu.git
|
||||
bg_wait TEE git clone git://git.qemu-project.org/qemu.git
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" || ! test -d $QEMU_GIT_SRC_DIR ; then
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
cd $QEMU_GIT_SRC_DIR
|
||||
bg_wait git submodule init
|
||||
bg_wait TEE git submodule init
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" ; then
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
bg_wait git submodule update --recursive
|
||||
bg_wait TEE git submodule update --recursive
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) != "0" || ! test -f $QEMU_GIT_SRC_DIR/configure ; then
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
@ -502,6 +540,8 @@ configure() {
|
||||
"2.11.1") ${QEMU_CONFIGURE_2_11_1} ;;
|
||||
"2.12.0-rc4") ${QEMU_CONFIGURE_2_12_0_RC4} ;;
|
||||
"2.12.0") ${QEMU_CONFIGURE_2_12_0_RC4} ;;
|
||||
"3.0.0") ${QEMU_CONFIGURE_3_0_0} ;;
|
||||
"4.0.0-rc2") ${QEMU_CONFIGURE_4_0_0_RC2} ;;
|
||||
esac
|
||||
;;
|
||||
qemu-git)
|
||||
@ -515,7 +555,7 @@ install() {
|
||||
qemu)
|
||||
cd $QEMU_SRC_DIR
|
||||
echo -n "Configure QEMU "
|
||||
bg_wait configure $1 $QEMU_VERSION
|
||||
bg_wait TEE configure $1 $QEMU_VERSION
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) = "0" && test -f $QEMU_SRC_DIR/Makefile ; then
|
||||
echo -ne done\\n
|
||||
else
|
||||
@ -531,7 +571,8 @@ install() {
|
||||
else
|
||||
echo -ne done\\n
|
||||
fi
|
||||
make $MAKE_J >> $BGEXEC_LOG_STATUS_FILE 2>&1 &
|
||||
: make $MAKE_J >> $BGEXEC_LOG_STATUS_FILE 2>&1 &
|
||||
make $MAKE_J >> $LOG 2>&1 &
|
||||
echo -n Make QEMU\ ;wait_pid $!
|
||||
if test -x $QEMU_SRC_DIR/arm-softmmu/qemu-system-arm ; then
|
||||
echo -ne done\\n
|
||||
@ -539,7 +580,8 @@ install() {
|
||||
echo -ne fail\\n
|
||||
exit 3
|
||||
fi
|
||||
make install >> $BGEXEC_LOG_STATUS_FILE 2>&1 &
|
||||
: make install >> $BGEXEC_LOG_STATUS_FILE 2>&1 &
|
||||
make install >> $LOG 2>&1 &
|
||||
echo -n Make install QEMU\ ;wait_pid $!
|
||||
if test -x $QEMU_PREFIX/bin/qemu-system-arm ; then
|
||||
echo -ne done\\n
|
||||
@ -551,7 +593,7 @@ install() {
|
||||
qemu-git)
|
||||
cd $QEMU_GIT_SRC_DIR
|
||||
echo -n "Configure QEMU "
|
||||
bg_wait configure $1
|
||||
bg_wait TEE configure $1
|
||||
if test $(cat $BGEXEC_EXIT_STATUS_FILE) = "0" && test -f $QEMU_GIT_SRC_DIR/Makefile ; then
|
||||
echo -ne done\\n
|
||||
else
|
||||
@ -597,19 +639,24 @@ init_exec() {
|
||||
---------------------------
|
||||
AQ
|
||||
Android Qemu
|
||||
Qq: 1225803134
|
||||
Qq: 1605227279
|
||||
Qemail: 1225803134@qq.com
|
||||
Qemail: 1605227279@qq.com
|
||||
Author: aixiao@aixiao.me
|
||||
---------------------------
|
||||
-x
|
||||
print debug.
|
||||
---------------------------
|
||||
--prefix=
|
||||
Installation directory.
|
||||
---------------------------
|
||||
--qemuversion=
|
||||
Qemu Version.
|
||||
---------------------------
|
||||
--gitqemu
|
||||
Clone source code from GIT repository.
|
||||
---------------------------
|
||||
--help
|
||||
print help.
|
||||
---------------------------
|
||||
HELP
|
||||
exit 3
|
||||
@ -625,8 +672,20 @@ HELP
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
while getopts :x x; do
|
||||
case ${x} in
|
||||
x)
|
||||
debug=x;
|
||||
shift $((OPTIND-1));
|
||||
;;
|
||||
esac
|
||||
|
||||
done
|
||||
test "${debug}" = "x" && set -x;
|
||||
|
||||
path
|
||||
VER=1.15
|
||||
VER=1.17
|
||||
for((i=1;i<=$#;i++)); do
|
||||
ini_cfg=${!i}
|
||||
ini_cfg_a=`echo $ini_cfg | sed -r s/^-?-?.*=//`
|
||||
@ -636,3 +695,4 @@ done
|
||||
init $@
|
||||
exit
|
||||
aixiao@aixiao.me.
|
||||
201904061843
|
||||
|
Loading…
Reference in New Issue
Block a user