message: Correct compile options for PCH
diff: @@ -72,7 +72,35 @@ FUNCTION(ADD_PRECOMPILED_HEADER _targetName _input)
  LIST(APPEND _compiler_FLAGS "-D${item}")
  ENDFOREACH(item)
  + GET_TARGET_PROPERTY(_directory_flags ${_targetName} COMPILE_OPTIONS)
  + FOREACH(item ${_directory_flags})
  + string(REGEX MATCH "RELEASE>" _regex_res "${item}")
  + string(LENGTH "${_regex_res}" _len)
  + if ((${CMAKE_BUILD_TYPE} STREQUAL "Release") AND (${_len} GREATER 0))
  + string(SUBSTRING ${item} 17 -1 _just_option)
  + string(REGEX MATCH "-[A-Za-z\-]+" _just_option ${_just_option})
  + list(APPEND _compiler_FLAGS "${_just_option}")
  + endif()
  + if (${_len} GREATER 0)
  + continue()
  + endif()
  +
  + string(REGEX MATCH "DEBUG>" _regex_res "${item}")
  + string(LENGTH "${_regex_res}" _len)
  + if ((${CMAKE_BUILD_TYPE} STREQUAL "Debug") AND (${_len} GREATER 0))
  + string(SUBSTRING ${item} 15 -1 _just_option)
  + string(REGEX MATCH "-[A-Za-z\-]+" _just_option ${_just_option})
  + list(APPEND _compiler_FLAGS "${_just_option}")
  + endif()
  + if (${_len} GREATER 0)
  + continue()
  + endif()
  +
  + list(APPEND _compiler_FLAGS "${item}")
  + ENDFOREACH(item)
  +
  SEPARATE_ARGUMENTS(_compiler_FLAGS)
  + #STRING(REPLACE ";" "\t" _compiler_FLAGS "${_compiler_FLAGS}")
  MESSAGE("${CMAKE_CXX_COMPILER} -DPCHCOMPILE ${_compiler_FLAGS} -x c++-header -o ${_output} ${_source}")
  ADD_CUSTOM_COMMAND(
  OUTPUT ${_output}
  @@ -81,5 +109,6 @@ FUNCTION(ADD_PRECOMPILED_HEADER _targetName _input)
  ADD_CUSTOM_TARGET(${_targetName}_gch DEPENDS ${_output})
  ADD_DEPENDENCIES(${_targetName} ${_targetName}_gch)
  SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS "-include ${_name} -Winvalid-pch")
  + #target_compile_options(${_targetName} PRIVATE "-include ${_name}" -Winvalid-pch)
  ENDIF(CMAKE_COMPILER_IS_GNUCXX)
  ENDFUNCTION()
  