aboutsummaryrefslogtreecommitdiff
path: root/emulators/qemu-cheri
diff options
context:
space:
mode:
authorBrooks Davis <brooks@FreeBSD.org>2020-03-27 16:11:53 +0000
committerBrooks Davis <brooks@FreeBSD.org>2020-03-27 16:11:53 +0000
commit4d4d3ba6f18ea579b5f2078f9a711983fa14aec7 (patch)
tree9071a49b35ea0a1871bf61c23a0d62dda9bb3427 /emulators/qemu-cheri
parent38eecc963d97d83a7ec535743042f887a62974e6 (diff)
downloadports-4d4d3ba6f18ea579b5f2078f9a711983fa14aec7.tar.gz
ports-4d4d3ba6f18ea579b5f2078f9a711983fa14aec7.zip
Update qemu-cheri and llvm-cheri to recent snapshots.
In qemu-cheri: * Fix build with llvm10 [0] * Remove the 256-bit capability version * Add CHERI RISC-V PR: 244768 [0] Submitted by: dim [0] Sponsored by: DARPA
Notes
Notes: svn path=/head/; revision=529267
Diffstat (limited to 'emulators/qemu-cheri')
-rw-r--r--emulators/qemu-cheri/Makefile10
-rw-r--r--emulators/qemu-cheri/Makefile.snapshot5
-rw-r--r--emulators/qemu-cheri/distinfo8
-rw-r--r--emulators/qemu-cheri/files/gen-Makefile.snapshot.sh3
-rw-r--r--emulators/qemu-cheri/files/patch-configure52
5 files changed, 69 insertions, 9 deletions
diff --git a/emulators/qemu-cheri/Makefile b/emulators/qemu-cheri/Makefile
index d80adfece3e1..c0960305bf3e 100644
--- a/emulators/qemu-cheri/Makefile
+++ b/emulators/qemu-cheri/Makefile
@@ -2,7 +2,7 @@
PORTNAME= qemu
PORTVERSION= 0.d${SNAPDATE}
-PORTREVISION= 1
+PORTREVISION= 0
CATEGORIES= emulators devel
PKGNAMESUFFIX= -cheri
@@ -21,6 +21,7 @@ LICENSE= GPLv2
USE_GITHUB= yes
GH_TUPLE= CTSRD-CHERI:qemu:${QEMU_COMMIT} \
+ CTSRD-CHERI:dtc:${DTC_COMMIT}:dtc/dtc \
CTSRD-CHERI:libslirp:${LIBSLIRP_COMMIT}:libslirp/slirp \
qemu:keycodemapdb:6b3d716:qemu/ui/keycodemapdb \
@@ -37,13 +38,14 @@ OPTIONS_DEFINE= DOCS
.include "Makefile.snapshot"
CONFIGURE_ARGS+= \
- --target-list=cheri128-softmmu,cheri128magic-softmmu,cheri256-softmmu \
+ --target-list=cheri128-softmmu,cheri128magic-softmmu,riscv64cheri-softmmu \
--disable-curl \
--disable-git-update \
--disable-gtk \
--disable-linux-user \
--disable-linux-aio \
--disable-kvm \
+ --disable-opengl \
--disable-vnc-png \
--disable-sdl \
--disable-vte \
@@ -57,12 +59,12 @@ QEMU_SYSTEM_CHERI?= qemu-system${PKGNAMESUFFIX}
PLIST= /dev/null
PLIST_FILES= bin/qemu-system-cheri128 \
bin/qemu-system-cheri128magic \
- bin/qemu-system-cheri256
+ bin/qemu-system-riscv64cheri
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/cheri128-softmmu/qemu-system-cheri128 \
${WRKSRC}/cheri128magic-softmmu/qemu-system-cheri128magic \
- ${WRKSRC}/cheri256-softmmu/qemu-system-cheri256 \
+ ${WRKSRC}/riscv64cheri-softmmu/qemu-system-riscv64cheri \
${STAGEDIR}${PREFIX}/bin/
.include <bsd.port.mk>
diff --git a/emulators/qemu-cheri/Makefile.snapshot b/emulators/qemu-cheri/Makefile.snapshot
index 3158b2ac671e..7f1dd9e181f7 100644
--- a/emulators/qemu-cheri/Makefile.snapshot
+++ b/emulators/qemu-cheri/Makefile.snapshot
@@ -4,7 +4,8 @@
#
# Generated by: files/gen-Makefile.snapshot.sh.
#
-SNAPDATE= 20191209
+SNAPDATE= 20200327
-QEMU_COMMIT= 74235a2879944724c88ad8b400170b8e2b0a6147
+QEMU_COMMIT= 0a323821042c36e21ea80e58b9545dfc3b0cb8ef
LIBSLIRP_COMMIT= 6651ba26c4e94f64d6448a2db4991269ce553bd9
+DTC_COMMIT= 87a656ae5ff96c4903e68eb2f999532a3b98e3a7
diff --git a/emulators/qemu-cheri/distinfo b/emulators/qemu-cheri/distinfo
index 07a2f43a8158..e438e02246ee 100644
--- a/emulators/qemu-cheri/distinfo
+++ b/emulators/qemu-cheri/distinfo
@@ -1,6 +1,8 @@
-TIMESTAMP = 1576015343
-SHA256 (CTSRD-CHERI-qemu-0.d20191209-74235a2879944724c88ad8b400170b8e2b0a6147_GH0.tar.gz) = facff8aca23b47d443dad98fa6ece3971636cf0a7d2fb79eaadbff5ddb4bf348
-SIZE (CTSRD-CHERI-qemu-0.d20191209-74235a2879944724c88ad8b400170b8e2b0a6147_GH0.tar.gz) = 29444613
+TIMESTAMP = 1585324588
+SHA256 (CTSRD-CHERI-qemu-0.d20200327-0a323821042c36e21ea80e58b9545dfc3b0cb8ef_GH0.tar.gz) = ba74e4192d02ec6a5c6f72a3ee42ea4113d4719692d98a590ef9968759492fbf
+SIZE (CTSRD-CHERI-qemu-0.d20200327-0a323821042c36e21ea80e58b9545dfc3b0cb8ef_GH0.tar.gz) = 29937048
+SHA256 (CTSRD-CHERI-dtc-87a656ae5ff96c4903e68eb2f999532a3b98e3a7_GH0.tar.gz) = 9dd7b32701106948f380acdd5d91391031b3d56e9fa84e8a49d469f50bdb2ddf
+SIZE (CTSRD-CHERI-dtc-87a656ae5ff96c4903e68eb2f999532a3b98e3a7_GH0.tar.gz) = 200509
SHA256 (CTSRD-CHERI-libslirp-6651ba26c4e94f64d6448a2db4991269ce553bd9_GH0.tar.gz) = aaffa33addd3aec53b5def83c4735275c9f501425bb0d8706494a7724875d8a6
SIZE (CTSRD-CHERI-libslirp-6651ba26c4e94f64d6448a2db4991269ce553bd9_GH0.tar.gz) = 121465
SHA256 (qemu-keycodemapdb-6b3d716_GH0.tar.gz) = c9d3412510aac999865d01aaa14b1fa8dc0385db55c5cf6c4d95d160bd0eaee9
diff --git a/emulators/qemu-cheri/files/gen-Makefile.snapshot.sh b/emulators/qemu-cheri/files/gen-Makefile.snapshot.sh
index 065b9baba2d9..adcc52488be0 100644
--- a/emulators/qemu-cheri/files/gen-Makefile.snapshot.sh
+++ b/emulators/qemu-cheri/files/gen-Makefile.snapshot.sh
@@ -33,6 +33,8 @@ query_repo qemu qemu-cheri
QEMU_COMMIT=$SHA
query_repo libslirp
LIBSLIRP_COMMIT=$SHA
+query_repo dtc
+DTC_COMMIT=$SHA
cat <<EOF > Makefile.snapshot
# \$FreeBSD\$
@@ -45,6 +47,7 @@ SNAPDATE= ${MAX_DATE}
QEMU_COMMIT= ${QEMU_COMMIT}
LIBSLIRP_COMMIT= ${LIBSLIRP_COMMIT}
+DTC_COMMIT= ${DTC_COMMIT}
EOF
rm -f $tmpfile
diff --git a/emulators/qemu-cheri/files/patch-configure b/emulators/qemu-cheri/files/patch-configure
new file mode 100644
index 000000000000..8f19f7d642cd
--- /dev/null
+++ b/emulators/qemu-cheri/files/patch-configure
@@ -0,0 +1,52 @@
+--- configure.orig 2019-12-09 17:14:11 UTC
++++ configure
+@@ -6358,27 +6358,30 @@ if ( [ "$linux_user" = yes ] || [ "$bsd_user" = yes ]
+ cat > $TMPC <<EOF
+ int main(void) { return 0; }
+ EOF
+- textseg_ldflags="-Wl,-Ttext-segment=$textseg_addr"
++ textseg_ldflags="-Wl,--image-base=$textseg_addr"
+ if ! compile_prog "" "$textseg_ldflags"; then
+- # In case ld does not support -Ttext-segment, edit the default linker
+- # script via sed to set the .text start addr. This is needed on FreeBSD
+- # at least.
+- if ! $ld --verbose >/dev/null 2>&1; then
+- error_exit \
+- "We need to link the QEMU user mode binaries at a" \
+- "specific text address. Unfortunately your linker" \
+- "doesn't support either the -Ttext-segment option or" \
+- "printing the default linker script with --verbose." \
+- "If you don't want the user mode binaries, pass the" \
+- "--disable-user option to configure."
+- fi
++ textseg_ldflags="-Wl,-Ttext-segment=$textseg_addr"
++ if ! compile_prog "" "$textseg_ldflags"; then
++ # In case ld does not support -Ttext-segment, edit the default linker
++ # script via sed to set the .text start addr. This is needed on FreeBSD
++ # at least.
++ if ! $ld --verbose >/dev/null 2>&1; then
++ error_exit \
++ "We need to link the QEMU user mode binaries at a" \
++ "specific text address. Unfortunately your linker" \
++ "doesn't support either the -Ttext-segment option or" \
++ "printing the default linker script with --verbose." \
++ "If you don't want the user mode binaries, pass the" \
++ "--disable-user option to configure."
++ fi
+
+- $ld --verbose | sed \
+- -e '1,/==================================================/d' \
+- -e '/==================================================/,$d' \
+- -e "s/[.] = [0-9a-fx]* [+] SIZEOF_HEADERS/. = $textseg_addr + SIZEOF_HEADERS/" \
+- -e "s/__executable_start = [0-9a-fx]*/__executable_start = $textseg_addr/" > config-host.ld
+- textseg_ldflags="-Wl,-T../config-host.ld"
++ $ld --verbose | sed \
++ -e '1,/==================================================/d' \
++ -e '/==================================================/,$d' \
++ -e "s/[.] = [0-9a-fx]* [+] SIZEOF_HEADERS/. = $textseg_addr + SIZEOF_HEADERS/" \
++ -e "s/__executable_start = [0-9a-fx]*/__executable_start = $textseg_addr/" > config-host.ld
++ textseg_ldflags="-Wl,-T../config-host.ld"
++ fi
+ fi
+ fi
+ fi