Commit a15b1fd2 authored by Jialin Li's avatar Jialin Li Committed by Jonas Kaufmann
Browse files

sims/external: add bmv2

To-do: Add synchronization support
parent c5977fb9
...@@ -10,3 +10,6 @@ ...@@ -10,3 +10,6 @@
[submodule "sims/external/femu"] [submodule "sims/external/femu"]
path = sims/external/femu path = sims/external/femu
url = https://github.com/simbricks/femu.git url = https://github.com/simbricks/femu.git
[submodule "sims/external/bmv2"]
path = sims/external/bmv2
url = https://github.com/simbricks/bmv2.git
...@@ -19,12 +19,17 @@ RUN apt-get update \ ...@@ -19,12 +19,17 @@ RUN apt-get update \
libboost-coroutine-dev \ libboost-coroutine-dev \
libboost-fiber-dev \ libboost-fiber-dev \
libboost-iostreams-dev \ libboost-iostreams-dev \
libboost-program-options-dev \
libelf-dev \ libelf-dev \
libglib2.0-dev \ libglib2.0-dev \
libgmp-dev \
libgoogle-perftools-dev \ libgoogle-perftools-dev \
libnanomsg-dev \
libpcap-dev \ libpcap-dev \
libpixman-1-dev \ libpixman-1-dev \
libprotobuf-dev \ libprotobuf-dev \
libssl-dev \
libtool \
locales \ locales \
ninja-build \ ninja-build \
protobuf-compiler \ protobuf-compiler \
...@@ -53,6 +58,15 @@ RUN cd /tmp \ ...@@ -53,6 +58,15 @@ RUN cd /tmp \
&& make -j`nproc` \ && make -j`nproc` \
&& make install \ && make install \
&& rm -rf /tmp/verilator && rm -rf /tmp/verilator
RUN cd /tmp \
&& git clone https://github.com/apache/thrift.git \
&& cd thrift \
&& ./bootstrap.sh \
&& ./configure \
&& make -j`nproc` \
&& make install \
&& ldconfig \
&& rm -rf /tmp/thrift
# Add non-root user for vs code devcontainer. # Add non-root user for vs code devcontainer.
ARG USERNAME=simbricks ARG USERNAME=simbricks
......
Subproject commit 7e7566532db183cf0000369f1de70939d6a8e2a7
...@@ -30,8 +30,10 @@ EXTERNAL_SIMS_DIR := $(d) ...@@ -30,8 +30,10 @@ EXTERNAL_SIMS_DIR := $(d)
$(eval $(call subdir,simics)) $(eval $(call subdir,simics))
external: $(d)gem5/ready $(d)qemu/ready $(d)ns-3/ready $(d)femu/ready external: $(d)gem5/ready $(d)qemu/ready $(d)ns-3/ready $(d)femu/ready $(d)bmv2/ready
.PHONY: external gem5-clean qemu-clean ns-3-clean femu-clean .PHONY: external gem5-clean qemu-clean ns-3-clean femu-clean bmv2-clean
$(d)gem5: $(d)gem5:
git clone https://github.com/simbricks/gem5.git $@ git clone https://github.com/simbricks/gem5.git $@
...@@ -100,6 +102,19 @@ femu-clean: ...@@ -100,6 +102,19 @@ femu-clean:
-+cd $(EXTERNAL_SIMS_DIR)femu && $(MAKE) clean -+cd $(EXTERNAL_SIMS_DIR)femu && $(MAKE) clean
rm -f $(EXTERNAL_SIMS_DIR)femu/ready rm -f $(EXTERNAL_SIMS_DIR)femu/ready
$(d)bmv2:
git clone https://github.com/simbricks/bmv2.git $@
$(d)bmv2/ready: $(d)bmv2 $(lib_netif)
+cd $< && ./autogen.sh && \
CPPFLAGS=-I$(abspath $(lib_dir)) ./configure && \
$(MAKE) -j
touch $@
bmv2-clean:
-cd $(EXTERNAL_SIMS_DIR)bmv2 && $(MAKE) clean
rm -f $(EXTERNAL_SIMS_DIR)bmv2/ready
DISTCLEAN := $(d)gem5 $(d)qemu $(d)ns-3 $(d)femu DISTCLEAN := $(d)gem5 $(d)qemu $(d)ns-3 $(d)femu
EXTERNAL_CLEAN_TASKS := gem5-clean qemu-clean ns-3-clean femu-clean EXTERNAL_CLEAN_TASKS := gem5-clean qemu-clean ns-3-clean femu-clean bmv2-clean
include mk/subdir_post.mk include mk/subdir_post.mk
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment