From f1977643b64be997a6badf7f1602debdb02518d7 Mon Sep 17 00:00:00 2001 From: Maryanne Wachter Date: Fri, 1 Oct 2021 13:41:41 -0700 Subject: [PATCH] Added build instructions for MacOS --- README.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/README.md b/README.md index a28b3a58df..e0985cc5d6 100644 --- a/README.md +++ b/README.md @@ -136,6 +136,34 @@ If all worked out correctly you can now use IfcOpenShell. See the examples below **6)** Install the project if wanted: $ sudo make install + +### Installing on MacOS Using Homebrew + +**1)** Install all dependencies using [Homebrew](https://brew.sh/) + +```{shell} +$ brew install boost swig cmake ftgl cgal gmp libaec opencascade +``` + +**2)** Clone the git repo and its submodules +```{shell} +$ git clone --recurse-submodules https://github.com/IfcOpenShell/IfcOpenShell.git +``` +**3)** Build IfcOpenShell with flags for Homebrew dependencies (```/usr/local/```) +```{shell} +$ cd /path/to/IfcOpenShell +$ mkdir build && cd build +$ cmake ../cmake -DOCC_LIBRARY_DIR=/usr/local/lib/ \ + -DOCC_INCLUDE_DIR=/usr/local/include/opencascade/ \ + -DCOLLADA_SUPPORT=0 \ + -DCGAL_INCLUDE_DIR=/usr/local/include/ \ + -DGMP_LIBRARY_DIR=/usr/local/lib/ \ + -DMPFR_LIBRARY_DIR=/usr/local/lib/ + +$ make -j -lboost_options +``` + +Note: Make sure to compile using XCode, rather than a ```brew``` installed C/C++ compiler. Installing IfcOpenShell with Conda ----------------------------------