facebook / infer

A static analyzer for Java, C, C++, and Objective-C
http://fbinfer.com/
MIT License
14.92k stars 2.01k forks source link

Infer - clang plugin OCaml - Issue #1810

Closed mantejl closed 7 months ago

mantejl commented 8 months ago

I am trying to build Infer using the documentation given, but I am coming across this issue everytime I try to build. Not sure what the error is, I have tried changing the script and make file.

Infer version: not yet available, as infer is not building

OS Version: Ventura 13.0.1

Command: ./build-infer.sh clang

Output:

initializing opam... looking if switch 4.14.0+flambda exists in this list: 4.14.0+flambda verdict: yes

installing infer dependencies; this can take up to 30 minutes... Nothing to do. preparing build...

skcho commented 8 months ago

Looking at the failed command, CXX is suspicious to include some flags. Could you check how it has been set in config.status. For example, for me it is like,

S["CXXFLAGS"]="-g -O2"
S["CXX"]="clang++"

If CXX is including -std=gnu++11, I think it is better to set under CXXFLAGS.

mantejl commented 8 months ago

Just checked the config.status file, and this is what showed up for me:

S["CXXFLAGS"]="-g -O2" S["CXX"]="clang++ -std=gnu++11"

samuelchen2015 commented 7 months ago

I ran into the same issue? any idea? build with os 13 and xcode14