This is an archive of the discontinued LLVM Phabricator instance.

[OpenMP][OMPD] Fix compile error when OMPD is not supported
ClosedPublic

Authored by mnadeem on Sep 20 2021, 6:06 PM.

Details

Summary

I am getting compilation errors after https://reviews.llvm.org/D100182

Error:

In file included from .../openmp/libompd/src/TargetValue.cpp:13:
 .../openmp/libompd/src/TargetValue.h:13:10: fatal error: 'omp-tools.h' file not found
 #include "omp-tools.h"

Looks like the file omp-tools.h is guarded like this:

if(${LIBOMP_OMPT_SUPPORT})
  configure_file(${LIBOMP_INC_DIR}/omp-tools.h.var omp-tools.h @ONLY)
endif()

Not familiar with the build system but here is an attempt to fix the issue.

Diff Detail

Event Timeline

mnadeem created this revision.Sep 20 2021, 6:06 PM
mnadeem requested review of this revision.Sep 20 2021, 6:06 PM
Herald added a project: Restricted Project. · View Herald Transcript
mnadeem added inline comments.Sep 20 2021, 6:12 PM
openmp/runtime/CMakeLists.txt
335

used here to set LIBOMP_OMPD_SUPPORT

Vigneshbalu accepted this revision.Sep 20 2021, 8:06 PM
This revision is now accepted and ready to land.Sep 20 2021, 8:06 PM