diff --git a/lib/Driver/ToolChains/Clang.cpp b/lib/Driver/ToolChains/Clang.cpp
index 292cf72b56..d8c6327080 100644
--- a/tools/clang/lib/Driver/ToolChains/Clang.cpp
+++ b/tools/clang/lib/Driver/ToolChains/Clang.cpp
@@ -3229,6 +3229,8 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
     case Driver::OMPRT_OMP:
     case Driver::OMPRT_IOMP5:
       // Clang can generate useful OpenMP code for these two runtime libraries.
+      // Automatically find MacPorts' omp.h
+      CmdArgs.push_back("-I@@PREFIX@@/include/libomp");
       CmdArgs.push_back("-fopenmp");
 
       // If no option regarding the use of TLS in OpenMP codegeneration is
diff -u a/tools/clang/lib/Driver/ToolChains/CommonArgs.cpp.orig b/tools/clang/lib/Driver/ToolChains/CommonArgs.cpp
--- a/tools/clang/lib/Driver/ToolChains/CommonArgs.cpp.orig	2020-04-19 11:47:05.000000000 -0700
+++ b/tools/clang/lib/Driver/ToolChains/CommonArgs.cpp	2020-04-19 11:48:11.000000000 -0700
@@ -521,12 +521,18 @@
 
   switch (RTKind) {
   case Driver::OMPRT_OMP:
+    // Automatically find MacPorts' libomp
+    CmdArgs.push_back("-L@@PREFIX@@/lib/libomp");
     CmdArgs.push_back("-lomp");
     break;
   case Driver::OMPRT_GOMP:
+    // Automatically find MacPorts' libomp
+    CmdArgs.push_back("-L@@PREFIX@@/lib/libomp");
     CmdArgs.push_back("-lgomp");
     break;
   case Driver::OMPRT_IOMP5:
+    // Automatically find MacPorts' libomp
+    CmdArgs.push_back("-L@@PREFIX@@/lib/libomp");
     CmdArgs.push_back("-liomp5");
     break;
   case Driver::OMPRT_Unknown:
