1. 29 Jan, 2019 2 commits
    • chuck cranor's avatar
      CrayPrgEnv/ParseImplicitIncludes: simplify for new implict include parser · eaf53158
      chuck cranor authored
      Remove now redundant implicit parser code from CrayPrgEnv.cmake, as
      this function is now supported in the general cmake code
      (e.g. Modules/CMakeParseImplicit{Include,Link}Info.cmake).
      This simplifies __CrayPrgEnv_setup() to take only one arg (${lang})
      and allows us to remove a level of inclusion as
      CrayPrgEnv-${lang}.cmake is now compiler independent we
      do not need the CrayPrgEnv-${compiler}-${lang} files any more.
    • chuck cranor's avatar
      ParseImplicitIncludeInfo: add SunPro Fortran and PGI compiler, Cray fix · ef8f2376
      chuck cranor authored
      Add implicit include parser for PGI compiler ID.  PGI verbose output
      for CXX differs from C and Fortran, so CXX is broken out into its own
      case.  The C and Fortran compilers take "-YI,path" and "-Mnostdinc" to
      change or disable the builtin include path.  The last arg on the command
      line appears to override previous args (e.g. "-YI,path1 -YI,path2" will
      set the path to "path2" ... the previous "-YI,path1" gets undone).
      The CXX compiler verbose output reports with "-I" rather than "-stdinc"
      for the built in path.  In addition with CXX "-Mnostdinc" does not
      completely zero the include path (e.g. "#include <stdio.h>" still works
      with "-Mnostdinc"... "-I/usr/include" still shows up in the verbose output).
      Minor adjustments to get the SunPro parser to handle Fortran as well.
      Fixes for Cray compiler support (Modules/Compiler/Cray-{C,CXX}.cmake):
      The *_COMPILE_OPTION flags contain options like "-h c99,gnu" ...
      these options need to be in double quotes (they are currently not).
      Otherwise, cmake treats them as lists and tries to run the compiler
      with "-h;c99,gnu" and fails when it is "Detecting C compile features"...
      Also, the Cray-CXX.cmake contains "__compiler_cray(C)" instead of
      "__compiler_cray(CXX)" -- this error prevents the correct VERBOSE
      flags for CXX from being defined which prevents the implicit include
      parser from running.
      Add additional test cases for PGI and SunPro Fortran to the
      Tests/RunCMake/ParseImplicitIncludeInfo area.
  2. 25 Jan, 2019 1 commit
  3. 21 Jan, 2019 1 commit
    • Brad King's avatar
      CMakeDetermineCompilerABI: pass verbose flag during compilation · c765ae49
      Brad King authored
      Default to the same flag that is used for verbose link information, but
      provide another internal platform information variable to use a
      compilation-specific variant.  Populate it for CUDA where we use a
      different compiler for compilation and linking and therefore need
      different flags.
      Co-Author: Chuck Cranor <chuck@ece.cmu.edu>
  4. 16 Jan, 2019 4 commits
    • Fred Baksik's avatar
      GHS: Add Compiler ID detection · 72e0c115
      Fred Baksik authored
      -- Detect GHS compiler and version
         Detect ARCHITECTURE_ID for PPC / ARM / 86 targets
         Detect PLATFORM_ID for Integrity and Integrity178 platforms
         Using defines specified in the documents for the compilers: 201416 PPC / 201754 ARM / 201714 86
      -- Fallback C/CXX compiler ID to GHS if not otherwise detected and using GHS MULTI generator
         Works around issue with some GHS compilers not setting __ghs__ compiler define
      -- Tweak Compiler ID checking so major id of 002017 is not replaced with 217
      -- Prefer try_compile() library targets when testing for working GHS compilers
      -- Avoid CMake errors if reading past end of file for checking if file is PE executable
    • Fred Baksik's avatar
      GHS: Use the correct compiler flags for CMAKE_BUILD_TYPE · 702121c5
      Fred Baksik authored
      -- Do not use CMAKE_C_FLAGS_RELEASE flags when CMAKE_BUILD_TYPE is empty
         if CMAKE_BUILD_TYPE was not set the generator would use Release settings
         this does not match the documented behavior of CMAKE_BUILD_TYPE
      -- CMAKE_C_FLAGS_<CONFIG> not used when -kernel is present
         Fixes issue where CMAKE_C_FLAGS_<CONFIG> is ignored when -kernel option is present as a compiler option
         When the -kernel option is added to an executable it uses a different set of language flags
         This does not occur -kernel=<type> is used or if it is added as part of a link flag
         The variables CMAKE_<LANG>_GHS_KERNEL_FLAGS_<CONFIG> are removed
         NOTE: By default this only added the flag -ldebug which links in the debugger library.
      -- Separate compiler options by newlines
    • Fred Baksik's avatar
      GHS: Update the link line processing · 595932c4
      Fred Baksik authored
      -- add missing executable linker libs from:
      -- add missed transitive link libraries
      -- add skipped library linker options
      -- The linker expects -l../relative/path/to/lib.a to be relative to the top-level project
         Because there can be multiple top-level projects convert the path to an absolute path to target
    • Fred Baksik's avatar
      GHS: Place build system outputs per target output directives · 2ed2d6b4
      Fred Baksik authored
      -- Set output and object file locations
      -- Suffixes are no longer being forced but will now follow the target properties
         By default GHS tools have no suffix for executable files so
         CMAKE_EXECUTABLE_SUFFIX was changed to meet this behavior
      -- Remove #if 0 blocked out code; it has been replaced.
         Forcing the -relprog option has been removed from non-kernel executable targets.
         The default value of this option (if it is even available) is determined by the
         tool-chain for the specified target and platform (Some tool-chains default to
         -locatedprogram).  The use of -relprog can have unexpected results as it cannot
         always produce a fully relocated executable.
      -- Clarify use of CMAKE_BUILD_TYPE to control build configuration
  5. 15 Jan, 2019 1 commit
  6. 10 Jan, 2019 1 commit
    • Rob Boehne's avatar
      XL: Move '-bE' flag earlier so it can be overridden · 74720a29
      Rob Boehne authored
      By default, we generate an export list for a shared library and pass
      that file on the link line.  The problem was that it could not be
      overridden by a target when a specific export file is being used.
      Multiple `-bE` flags on the link are overridden by subsequent `-bE`
      flags, so only the last one is used.
      Fixes: #13282
  7. 19 Dec, 2018 1 commit
  8. 03 Dec, 2018 1 commit
  9. 11 Nov, 2018 1 commit
  10. 08 Nov, 2018 1 commit
  11. 29 Oct, 2018 2 commits
  12. 05 Oct, 2018 1 commit
  13. 10 Sep, 2018 1 commit
  14. 28 Aug, 2018 1 commit
    • Sebastian Holtermann's avatar
      Sebastian Holtermann authored
      AUTOMOC used to fail to generate ``moc_predefs.h`` when ``ccache`` was used
      as a compiler starter by e.g. configuring a project with the environment
      variable CXX="ccache g++".
      The reason was that ``CMAKE_<LANG>_COMPILER_ARG1`` wasn't respected in the
      definition of ``CMAKE_<LANG>_COMPILER_PREDEFINES_COMMAND`` for various
      compilers.  This is fixed by this patch.
      Fixes #17275.
  15. 24 Aug, 2018 1 commit
  16. 01 Aug, 2018 2 commits
  17. 12 Jul, 2018 1 commit
  18. 11 Jul, 2018 1 commit
    • Cristian Adam's avatar
      QNX: Fix autogen compiler predefines detection · e014df76
      Cristian Adam authored
      In commit v3.12.0-rc1~20^2 (Move GNU COMPILER_PREDEFINES_COMMAND from
      Platform to Compiler, 2018-06-01), `Compiler/GNU.cmake` introduced the
      `-dM` flag, which requires `-Wp` prefix for the QNX compiler wrapper.
  19. 06 Jun, 2018 1 commit
  20. 04 Jun, 2018 2 commits
    • Brad King's avatar
      Features: Add special case to disable relaxed constexpr for Intel 18 · f719a13c
      Brad King authored
      Intel compilers define `__cpp_constexpr` to `200704` even in C++14 mode.
      This indicates that the `cxx_relaxed_constexpr` feature is not
      available.  However, Intel 17 and above document support for it.  In
      commit v3.8.0~9^2 (Features: Update features for Intel C++ 17.0.2 on
      UNIX, 2017-03-31) we added a special check for this case.  Intel 17 and
      19 work.  However, Intel 18 does not seem to work and fails our test
      case.  Add a special case to disable the feature for Intel 18.
    • Arnaud Gelas's avatar
      TI: Add support for C language standards · 9e27881b
      Arnaud Gelas authored
      Set C90 and C99 compile options for TI compiler.
      Fixes: #18061
  21. 01 Jun, 2018 1 commit
    • Sebastian Holtermann's avatar
      Move GNU COMPILER_PREDEFINES_COMMAND from Platform to Compiler · caa138c1
      Sebastian Holtermann authored
      Moves `CMAKE_${lang}_COMPILER_PREDEFINES_COMMAND` from linux specific
      [Modules/Platform/Linux-GNU.cmake](Modules/Platform/Linux-GNU.cmake) to
      This enables compiler predefines generation (in AUTOMOC) on all
      platforms that run gcc (and clang).
  22. 23 Apr, 2018 1 commit
  23. 17 Apr, 2018 1 commit
  24. 11 Apr, 2018 4 commits
  25. 02 Apr, 2018 1 commit
    • Brad King's avatar
      Android: Do not pass non-existent Clang -std flags · 12e6796b
      Brad King authored
      Android NDK r16b comes with
        Android clang version 5.0.300080  (based on LLVM 5.0.300080)
      Although it claims version 5, it does not support the `-std=c++17`
      or `-std=c++2a` flags that upstream Clang does.
      Android NDK r17-beta1 comes with
        Android (4639204 based on r316199) clang version 6.0.1
      that does have the flags.
  26. 29 Mar, 2018 1 commit
    • Brad King's avatar
      Features: Record C features for MSVC · a53cf690
      Brad King authored
      The MSVC C compiler has no notion of C language standards or flags.
      Tell CMake to assume that all language standards are available.
      Record available C language features depending on the version of
      the compiler.
      Fixes: #17858
  27. 27 Mar, 2018 4 commits