title: Why output saved in cmake-build-debug
body: <p>I have a C++ project and I want to access some data I have saved in folder <code>images</code>. 
  I have tried from <code>calibration.cpp</code> to do: </p>
  
  <pre><code>std::string path = "images/*.jpg";
  cv::glob(path, images);
  </code></pre>
  
  <p>But it gave me an error of not detecting the directory. In order to determine in which directory the execution was looking at I created a dummy text file and save it to see where it got saved.
  It gets saved in <strong>cmake-build-debug</strong> , which is a folder created automatically when building the CMakeLists.txt in CLion. Then if I put my <code>images</code> folder in <strong>cmake-build-debug</strong> it gets seen but I want to have the images folder in parent directory.</p>
  
  <ul>
  <li>How can I set the current directory to look for files from there?</li>
  </ul>
  
  <p>My project looks like:</p>
  
  <pre><code>Camera Motion
  -- cmake-build-debug
  ----     ...
  -- images
  ---- image1.png
  -- CMakeLists.txt
  -- calibration.cpp
  </code></pre>
  
  <pre><code># CMakeLists.txt
  cmake_minimum_required(VERSION 3.15)
  project(CameraMotion)
  
  set(CMAKE_CXX_STANDARD 14)
  
  find_package( OpenCV REQUIRED )
  include_directories(${OpenCV_INCLUDE_DIRS})
  
  add_executable(CameraMotion calibration.cpp)
  target_link_libraries(CameraMotion ${OpenCV_LIBS})
  
  </code></pre>
  
  <pre><code># calibration.cpp
  #include &lt;iostream&gt;
  
  int main()
  {
      std::ofstream myfile;
      myfile.open("output.txt");
      myfile &lt;&lt; "output\n";
      myfile.close();
      std::string path = "images/*.jpg";
  
      cv::glob(path, images);
  }
  </code></pre>
  
  <p>When I run the project in CLion it says:</p>
  
  <pre><code>====================[ Build | CameraMotion | Debug ]============================
  /Applications/CLion.app/Contents/bin/cmake/mac/bin/cmake --build /Users/hectoresteban/CLionProjects/CameraMotion/cmake-build-debug --target CameraMotion -- -j 4
  [100%] Built target CameraMotion
  </code></pre>