1. 14 Jul, 2016 1 commit
  2. 13 Jul, 2016 2 commits
  3. 11 Jul, 2016 1 commit
  4. 10 Jul, 2016 2 commits
  5. 08 Jul, 2016 1 commit
  6. 06 Jul, 2016 1 commit
    • Brad King's avatar
      Honor CMAKE_<LANG>_FLAGS[_<CONFIG>]_INIT set in toolchain files · a66004be
      Brad King authored
      Document these variables.
      Change our convention for setting these variables from:
          set(CMAKE_C_FLAGS_INIT "...")
          string(APPEND CMAKE_C_FLAGS_INIT " ...")
      so that any value previously set by a toolchain file will be used.
      Automate the conversion with:
          sed -i 's/set *(\(CMAKE_\(C\|CXX\|Fortran\|RC\|ASM\|${[^}]\+}\)_FLAGS\(_[^_]\+\)\?_INIT \+"\)/string(APPEND \1 /' \
            Modules/Compiler/*.cmake Modules/Platform/*.cmake
      and follow up with some manual fixes (e.g. to cases that already
      meant to append).  Also revert the automated changes to contexts
      that are not protected from running multiple times.
  7. 29 Jun, 2016 2 commits
    • Brad King's avatar
      try_compile: Add policy CMP0066 to honor CMAKE_<LANG>_FLAGS_<CONFIG> · d582c23a
      Brad King authored
      In the `try_compile` source file signature we propagate the caller's
      value of `CMAKE_<LANG>_FLAGS` into the test project.  Extend this to
      propagate `CMAKE_<LANG>_FLAGS_<CONFIG>` too instead of always using the
      default value in the test project.  This will be useful, for example, to
      allow the MSVC runtime library to be changed (e.g. `-MDd` => `-MTd`).
      However, some projects may currently depend on this not being done,
      so we need to activate the behavior using a policy.
      This change was originally made by commit v3.6.0-rc1~160^2 (try_compile:
      Honor CMAKE_<LANG>_FLAGS_<CONFIG> changes, 2016-04-11) but without the
      policy and so had to be reverted during the 3.6 release candidate cycle.
      Fixes #16174.
    • Brad King's avatar
  8. 28 Jun, 2016 2 commits
  9. 27 Jun, 2016 1 commit
    • Ben Boeckel's avatar
      ninja, rc: ignore CMAKE_NINJA_FORCE_RESPONSE_FILE for RC files · 15b3f6f0
      Ben Boeckel authored
      In commit v3.6.0-rc1~174^2 (Ninja: Honor CMAKE_NINJA_FORCE_RESPONSE_FILE
      for compile rules, 2016-04-06), Ninja learned to look for
      `CMAKE_NINJA_FORCE_RESPONSE_FILE` in the current scope or the
      environment in order to force response file usage for all compilation
      However, on Windows, the RC compiler goes through cmcldeps which does a
      `replace(output, output + ".dep.obj")` on the command line. However,
      with a response file (which we name `output + ".rsp"`), the response
      file path is replaced instead causing the compiler to (correctly)
      complain that the response file `output + ".dep.obj.rsp"` does not
      What needs to happen is for cmcldeps to look through the response file,
      replace *its* contents and place it in the `output + ".dep.obj.rsp"`
      Also add a test which actually compiles an RC file into a library and
      executable for all generators on Windows and additionally test
      `CMAKE_NINJA_FORCE_RESPONSE_FILE` for Ninja generators...
  10. 22 Jun, 2016 1 commit
  11. 20 Jun, 2016 3 commits
  12. 18 Jun, 2016 1 commit
  13. 17 Jun, 2016 2 commits
    • Alex Turbov's avatar
      cmake: Add an option to control what files needs to be traced · e63151ff
      Alex Turbov authored
      Even in relatively small projects using `--trace` (and `--trace-expand`)
      may produce a lot of output.  When developing a custom module usually
      one is interested in output of only a few particular modules.
      Add a `--trace-source=<file>` option to enable tracing only a subset of
      source files.  The final output would be only from requested modules,
      ignoring anything else not matched to given filename(s).
    • Bill Hoffman's avatar
      Add options to run `ldd -u -r` as a "link-what-you-use" tool · 96242f80
      Bill Hoffman authored
      Create a LINK_WHAT_YOU_USE target property and corresponding
      CMAKE_LINK_WHAT_YOU_USE variable to enable this behavior.
      Extend link commands by running `ldd -u -r` to detect shared
      libraries that are linked but not needed.
  14. 14 Jun, 2016 1 commit
  15. 13 Jun, 2016 1 commit
  16. 12 Jun, 2016 1 commit
    • Stephen Kelly's avatar
      cmake: Issue message independent of cmMakefile definition · 0a4af073
      Stephen Kelly authored
      The makefile is only used when called by the cmMessageCommand, so inline
      the use of it there.  It otherwise creates an undesirable dependency on
      cmMakefile for issuing messages in the cmake instance, a violation of
      the Interface Segregation Principle.
      This also makes it more explicit that the variable definitions only
      affect the message() command.  If an AUTHOR_WARNING is issued for any
      other reason, it is not affected.  To affect that, it is necessary to
      set the cache variable instead of the regular variable.
      This is an unfortunate interface quirk, but one which can't be fixed
      easily now.
  17. 10 Jun, 2016 3 commits
  18. 09 Jun, 2016 1 commit
  19. 08 Jun, 2016 2 commits
  20. 07 Jun, 2016 4 commits
  21. 06 Jun, 2016 1 commit
  22. 03 Jun, 2016 1 commit
  23. 02 Jun, 2016 2 commits
    • Brad King's avatar
      Fix crash on $<TARGET_PROPERTY:...,LOCATION> genex (#16134) · f500a784
      Brad King authored
      Policy CMP0026 deprecated the LOCATION property, and we have long
      provided a $<TARGET_FILE:...> generator expression.  However, if
      a project tries to use $<TARGET_PROPERTY:...,LOCATION> we should
      at least not crash.
      The compatibility implementation of the LOCATION property uses
      cmGlobalGenerator::CreateGenerationObjects to create the structures
      needed to evaluate the property before generation starts.  The
      implementation assumed that accessing the property could only be done
      during configuration (via the typical get_property command use case).
      The $<TARGET_PROPERTY:...,LOCATION> genex causes the LOCATION property
      to be accessed during generation.  Calling CreateGenerationObjects
      during generation blows away all the objects currently being used for
      generation and is not safe.  Add a condition to call it only when
      configuration is not finished.
    • Matthäus Chajdas's avatar
      FindOpenCL: Add an imported target · b66d4739
      Matthäus Chajdas authored
  24. 26 May, 2016 2 commits
    • Daniel Pfeifer's avatar
      Remove redundant c_str() calls. · 1b2bb933
      Daniel Pfeifer authored
      Run clang-tidy's readability-redundant-string-cstr checker.
      Ignore findings in kwsys.
    • Daniel Pfeifer's avatar
      Pass arguments that are not modified as const&. · 618fb23f
      Daniel Pfeifer authored
      Use clang-tidy's performance-unnecessary-value-param checker to find
      value parameter declarations of expensive to copy types that are not
      modified inside the function.  Ignore findings in kwsys.
      After applying the fix-its, manually change `const T&` to `T const&`.
  25. 25 May, 2016 1 commit
    • Brad King's avatar
      try_compile: Optionally forward custom platform variables to test project · d256ba07
      Brad King authored
      Add a `CMAKE_TRY_COMPILE_PLATFORM_VARIABLES` variable to specify a list
      of custom variables to be forwarded to a `try_compile` test project.
      This will be useful for platform information modules or toolchain files
      to forward some platform-specific set of variables from the host project
      (perhaps set in its cache) to the test project so that it can build the
      same way.