title: Compiling OpenCV for iOS fails - Cmake fails
body: <p>I try to compile OpenCV for ios. I get these errors all the time. I tried it with different versions of opencv, but the result is the same.</p>
  
  <p>I run this:
  python platforms/ios/build_framework.py ios_opencv_build</p>
  
  <p>I have python, cmake and g++ compilers installed. 
  Does anyone have an idea what these errors mean and what I should do to compile successfully?  </p>
  
  <pre><code>  -- Setting up iPhoneOS toolchain
      -- iPhoneOS toolchain loaded
      -- Setting up iPhoneOS toolchain
      -- iPhoneOS toolchain loaded
      -- The CXX compiler identification is Clang 5.1.0
      -- The C compiler identification is Clang 5.1.0
      -- Performing Test HAVE_CXX_FSIGNED_CHAR
      CMake Error at /opt/local/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
        get_filename_component called with incorrect number of arguments
      Call Stack (most recent call first):
        CMakeLists.txt:3 (PROJECT)
  
  
      CMake Error: Internal CMake error, TryCompile configure of cmake failed
      -- Performing Test HAVE_CXX_FSIGNED_CHAR - Failed
      -- Performing Test HAVE_C_FSIGNED_CHAR
      CMake Error at /opt/local/share/cmake-2.8/Modules/CMakeCInformation.cmake:37 (get_filename_component):
        get_filename_component called with incorrect number of arguments
      Call Stack (most recent call first):
        CMakeLists.txt:3 (PROJECT)
  
  
      CMake Error: Internal CMake error, TryCompile configure of cmake failed
      -- Performing Test HAVE_C_FSIGNED_CHAR - Failed
      -- Performing Test HAVE_CXX_W
      CMake Error at /opt/local/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
        get_filename_component called with incorrect number of arguments
      Call Stack (most recent call first):
        CMakeLists.txt:3 (PROJECT)
  ...
  </code></pre>