From c032f669c28337fd7961a49046c4577b05128d29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nils=20H=C3=B6lscher?= Date: Fri, 22 Apr 2022 12:54:59 +0200 Subject: [PATCH] Better mac Setup. --- README.md | 8 ++++++++ poolhelper.sh | 14 +++++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index a30cd97..c24f4b8 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,14 @@ I am more than happy helping you install Linux on your machine. I recommend using docker and VS Code for setup. Also check out the recommended extensions in the Docker section. If you prefer to work from Linux or Mac OS X, check the Dockerfile for dependencies. +For Mac (tested in M1 Mac mini) you can also use: + +```bash +./poolhelper.sh mac +``` + +But you will need brew installed and also have to use the poolhelper script instead of the normal helper script. + Some other unrecommended Setups are at the end of this Readme. ### Setup on a Pool PC diff --git a/poolhelper.sh b/poolhelper.sh index 0b8f30d..ced57a7 100755 --- a/poolhelper.sh +++ b/poolhelper.sh @@ -44,10 +44,21 @@ buildllvm() { rm llvm-13.0.1.src.tar.xz cmake -DCMAKE_BUILD_TYPE=MinSizeRel -DLLVM_TARGETS_TO_BUILD=host llvm-13.0.1.src/ make -j 4 - export LLVM_DIR=$(pwd) + export LLVM_DIR=$(pwd) >> ~/.zshrc + export LLVM_DIR=$(pwd) >> ~/.bashrc cd .. } + +mac() { + brew install cmake make wget ninja + buildllvm + cd llvm + export LLVM_DIR=$(pwd) >> ~/.zshrc + cd .. +} + + allBenchs=( "adpcm" "bs" "bsort100" @@ -189,6 +200,7 @@ case $1 in echo "Please provide one of the following arguments:" echo " llvm Build LLVM from source" echo " llvmcontinue Contionue building llvm where you left off last time" + echo " mac Setup LLVM for mac (needs brew)" echo " clean Deletes the build folder" echo " config Creates build folder and configures build System" echo " docker Build and Run Docker container for development"