Skip to content

Commit

Permalink
Merge pull request #17 from debbiemarkslab/fix/12/compilation
Browse files Browse the repository at this point in the history
Switch `make all-mac-openmp` to `clang`
  • Loading branch information
aaronkollasch authored Jan 20, 2023
2 parents 905011f + a73ad83 commit 2c854cb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,16 @@ plmc requires no external libraries, but can optionally be accelerated with Open

make all-openmp

On macOS, OpenMP requires that an external version of GCC be installed rather than `clang`. Precompiled binaries of GCC are available [here](http://hpc.sourceforge.net/) or can be downloaded through package managers like homebrew or macports.
**Multicore, macOS**. To install OpenMP through homebrew and compile with `clang`:

brew install libomp
make all-mac-openmp

**Single core, Linux**. To compile with `gcc`:

make all

**Single core, Mac OS X**. To compile with `clang`:
**Single core, macOS**. To compile with `clang`:

make all-mac

Expand Down
2 changes: 1 addition & 1 deletion makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ all-mac32:
# If using homebrew for openMP (libomp)
all-mac-openmp: LIBOMP_PREFIX=$(shell brew --prefix libomp)
all-mac-openmp:
$(CC) $(SOURCES) -o bin/plmc -Xpreprocessor -fopenmp $(GCCFLAGS) -lomp -L$(LIBOMP_PREFIX)/lib/ -I$(LIBOMP_PREFIX)/include/
clang $(SOURCES) -o bin/plmc -Xpreprocessor -fopenmp $(CLANGFLAGS) -lomp -L$(LIBOMP_PREFIX)/lib/ -I$(LIBOMP_PREFIX)/include/

clean:
rm -rf bin/*

0 comments on commit 2c854cb

Please sign in to comment.