mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-10-04 04:03:22 +03:00
cmcldeps: prefer the /TC flag
The /TC flag causes all source files to be processed as C source files. We know that there is only one, so this is safe.
This commit is contained in:
1 parent
47092d3e80
commit
70e268da3e
1 file changed
+1
-6
+1
-6
@@ -279,12 +279,7 @@ int main()
|
||||
clrest = replace(clrest, "/fo", "/out:");
|
||||
clrest = replace(clrest, objfile, objfile + ".dep.obj ");
|
||||
|
||||
// rc: src\x\x.rc -> cl: /Tc src\x\x.rc
|
||||
if (srcfile.find(' ') != std::string::npos)
|
||||
srcfile = "\"" + srcfile + "\"";
|
||||
clrest = replace(clrest, srcfile, "/Tc " + srcfile);
|
||||
|
||||
cl = "\"" + cl + "\" /P /DRC_INVOKED ";
|
||||
cl = "\"" + cl + "\" /P /DRC_INVOKED /TC ";
|
||||
|
||||
// call cl in object dir so the .i is generated there
|
||||
std::string objdir;
|
||||
|
||||
Reference in new issue
Block a user