I try to make and get:
Makefile:81: "*** WARNING g++ minor version <7 ***"
mkdir -p obj_linux/codebase/spoa/src/
g++ -static-libgcc -static-libstdc++ -D__cplusplus=201103L -I"./src/" -I"/usr/include/" -Icodebase/argparser/src -Icodebase/seqlib/src -Icodebase/samscripts/src -Icodebase/spoa/src -O3 -fdata-sections ->ffunction-ections -c -fmessage-length=0 -ffreestanding -fopenmp -m64 ->std=c++11 -error=return-type -pthread -march=native -o obj_linux/codebase/spoa/src/alignment.o codebase/spoa/src/alignment.cpp
clang: error: unsupported option '-fopenmp'
make: *** [obj_linux/codebase/spoa/src/alignment.o] Error 1
lahmersk-iml13:racon lahmersk$ whereis g++
/usr/bin/g++
I have a home-brew install of 7.3 at /usr/local/Cellar/gcc
I tried to export PATH in .bash_profile with:
# gcc location
export PATH=/usr/local/Cellar/gcc:$PATH
My Cellar directory has:
lahmersk-iml13:Cellar lahmersk$ ls
aragorn gdbm libmpc parallel sqlite
barrnap gmp llvm prodigal tbl2asn
blast hmmer lmdb prokka xz
cmake infernal minced python3
eigen isl mpfr qt
gcc libffi openssl readline
and gcc is:
lahmersk-iml13:Cellar lahmersk$ cd gcc
lahmersk-iml13:gcc lahmersk$ ls
7.3.0
My current bash_profile is:
# Homebrew location
export PATH=/usr/local/bin:/usr/local/sbin:$PATH
# Centrifuge location
export PATH=/Users/lahmersk/centrifuge:$PATH
# Spades location
export PATH=/Users/lahmersk/SPAdes-3.11.1-Darwin/bin:$PATH
# Bowtie2 location
export PATH=/Users/lahmersk/bowtie2-2.3.4.1:$PATH
# Pilon location
export PATH=/Users/lahmersk/pilon-1.21:$PATH
# Prokka location
export PATH=/Users/lahmersk/prokka/bin:$PATH
# Barrnap location
export PATH=/Users/lahmersk/barrnap/bin:$PATH
# gcc location
export PATH=/usr/local/Cellar/gcc:$PATH
when I do sudo vi /etc/paths I get:
/usr/local/bin
/usr/bin
/bin
/usr/sbin
/sbin
I could use some assistance. What other info can I provide?
Best Answer
You shouldn't need to add the
Cellar
to your path for this. But Homebrew adds a version suffix to thegcc
commands to avoid name clashes with the standardgcc
:So the compiler you are looking for can be invoked with
g++-7
.