Hi list,
I'm trying to generate with CMake 2.8.1 on Windows XP a VS6 project which
compiles a resource (OK ... I know VS6 is really old, but the company I'm
working for is still using it ;-)). It works pretty well with Debug, Release
and RelWithDebInfo. But with the MinSizeRel profile I got an error from VS6. In
the generated dsp file I found the following line:
# ADD RSC REL
I think the bug is in cmLocalVisualStudio6Generator.cxx. There are some string
replacements. The replacement for the compile definitions for MinSizeRel seems
to be incomplete (COMPILE_DEFINITIONS_MINSIZE instead of
COMPILE_DEFINITIONS_MINSIZEREL). So the REL remains after the replacement. Here
is a diff with the patch to solve this (I don't know if it's allowed to send
mails with attachments to the mailinglist, so I insert the diff as plain text
in the mail body):
diff -ru cmake-2.8.1/Source/cmLocalVisualStudio6Generator.cxx
cmake-2.8.1.patched/Source/cmLocalVisualStudio6Generator.cxx
--- Source/cmLocalVisualStudio6Generator.cxx 2010-03-16 13:10:20.000000000
+0100
+++ Source/cmLocalVisualStudio6Generator.cxx.patched 2010-05-10
11:07:09.281250000 +0200
@@ -1629,7 +1629,7 @@
flagsRelease.c_str());
cmSystemTools::ReplaceString(line, "CMAKE_CXX_FLAGS", flags.c_str());
- cmSystemTools::ReplaceString(line, "COMPILE_DEFINITIONS_MINSIZE",
+ cmSystemTools::ReplaceString(line, "COMPILE_DEFINITIONS_MINSIZEREL",
minsizeDefines.c_str());
cmSystemTools::ReplaceString(line, "COMPILE_DEFINITIONS_DEBUG",
debugDefines.c_str());
After applying this patch to CMake 2.8.1, resource compilation works for me
with all profiles.
Bye,
Michael
--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01
_______________________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake