title: Load a dynamic shared library (DLL) on Mac in C++ using CFBundleCreate
body: <p>How do I implement a function to load a dll(aka framework) on Mac OS using C++? 
  <br><code>
  void LoadFramework(const char* frameworkPath)
  {
    //frameworkPath is the absolute path of the framework
  }
  </code></p>
  
  <p><strong>Edit:</strong><br>
  When I google searched for this problem, I mostly ended up with dlopen solution to load the framework. What I am instead looking for is to use <strong>CFBundleCreate</strong> to load the framework. It seems to me that there are a bunch of methods needed to be called to construct an URL from const char * path. I found the needed code in pieces, and could not write one comprehensive solution.</p>