-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·26 lines (19 loc) · 985 Bytes
/
build.sh
File metadata and controls
executable file
·26 lines (19 loc) · 985 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/env bash
git clone https://github.com/qemu/qemu && cd qemu
git checkout v5.1.0
# Apply a patch as a workaround to fix Qemu Sphinx-related problem
git apply ../fix_qemu_sphinx_warning.patch
# Now tweak the build options for Linux target OS. We maintain a patch
# for that purpose.
git apply ../tweak_linux_config_options.patch
echo 'Successfully applied the required patches. Configuring now...'
# Most importantly, note '--static'
mkdir build-riscv64 && cd build-riscv64
../configure --target-list=riscv64-softmmu --static --audio-drv-list="" --disable-vnc
echo "Successfully configured. Building now..."
# On my machine, configuration step did not collect all the dependencies
# required to build Qemu. So manually appending them here, even if they
# are present already.
sudo apt install libblkid-dev libselinux1-dev uuid-dev libmount-dev
awk -F '=' -i inplace '{ if ($1 == "GIO_LIBS") { print $0 " -lblkid -luuid" } else { print $0 } }' config-host.mak
make -j4