llvm / llvm-project

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
http://llvm.org
Other
29.13k stars 12.01k forks source link

link stub library if OpenMP is disabled? #30554

Open Trass3r opened 7 years ago

Trass3r commented 7 years ago
Bugzilla Link 31206
Version unspecified
OS Windows NT
CC @hahnjo,@hfinkel

Extended Description

To fix linker errors like: error LNK2019: unresolved external symbol omp_get_max_threads referenced

Tested with http://llvm.org/builds/ installer based on r284979.

hahnjo commented 7 years ago

The information here is really scarce... If I understand you correctly, you want the compiler to always link in a stubs library to get the OpenMP API? If -fopenmp is not supplied, it's enough to simply link in -lomp