From 3397f67c54dd4cd740298217befc95c4a1f05777 Mon Sep 17 00:00:00 2001 From: Bili Dong Date: Mon, 27 Jan 2025 08:05:17 -0800 Subject: [PATCH] Update dependency install script Signed-off-by: Bili Dong --- .../ubuntu_install_mlir_requirements.sh | 26 +++++++++++++------ 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/build_tools/ubuntu_install_mlir_requirements.sh b/build_tools/ubuntu_install_mlir_requirements.sh index c5b8c3d..ba8839a 100755 --- a/build_tools/ubuntu_install_mlir_requirements.sh +++ b/build_tools/ubuntu_install_mlir_requirements.sh @@ -1,11 +1,7 @@ #!/usr/bin/env bash -# -# Reference: -# - https://mlir.llvm.org/getting_started/ -# - https://llvm.org/docs/GettingStarted.html#requirements - set -ex +# Install common build tools sudo apt-get update sudo apt-get install -y \ build-essential \ @@ -13,10 +9,24 @@ sudo apt-get install -y \ clang \ lld \ ninja-build \ + pkg-config \ python-is-python3 \ python3 \ - python3-pip \ - zlib1g-dev - + python3-pip pip install --upgrade \ cmake + +# Install additional LLVM & MLIR dependencies +# https://llvm.org/docs/GettingStarted.html#requirements +# https://mlir.llvm.org/getting_started/ +sudo apt-get install -y \ + zlib1g-dev + +# Install additional P4C dependencies +# https://github.com/p4lang/p4c/blob/main/README.md#ubuntu-dependencies +sudo apt-get install -y \ + bison \ + flex \ + libboost-dev \ + libboost-iostreams-dev \ + libfl-dev