1. 27 Jun, 2016 2 commits
    • 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.
      Fixes #16167.
  2. 26 Jun, 2015 2 commits
    • Brad King's avatar
      VS: Add /machine: flag to Librarian tool (#11240) · 806609c7
      Brad King authored
      If a Windows resource (.rc) source file is included in a STATIC library,
      the VS "link" tool will process the compiled ".res" file and needs to know
      the target architecture.  Without it, we may get a LNK4068 warning and
      possibly a LNK1112 error.  Add /machine: to the default static library
      flags to give the link tool the information it needs.