-
Bug
-
Resolution: Out of scope
-
P3: Somewhat important
-
4.7.3, 4.7.4, 4.8.0
-
None
-
Windows XP/Visual Studio 2005/Qt 4.7.3|4.7.4
Windows 7/Visual Studio 2010 prof/Qt 4.7.3|4.7.4|4.8.0
using target-renaming between debug and release like this
!debug_and_release|build_pass {
CONFIG(debug, debug|release)
}
breaks project-dependencies for msvc-projects
a small test-project is appended
for fixing this i use the following patch:
patch msvc_vcproj.cpp (4.8.0)
--- d:\qt\4.8.0.org\qmake\generators\win32\msvc_vcproj.cpp 2011-12-08 07:06:02.000000000 +0100 +++ d:\qt\4.8.0\qmake\generators\win32\msvc_vcproj.cpp 2012-01-09 22:34:38.000000000 +0100 @@ -431,11 +431,30 @@ QString profile = tmp; if(!profile.endsWith(Option::dir_sep)) profile += Option::dir_sep; profile += fi.baseName() + Option::pro_ext; subdirs.append(profile); } else { - QMakeProject tmp_proj; + //initialize the base + QString build = "Release"; + QMap<QString, QStringList> basevars; + if(!project->isEmpty(build + ".CONFIG")) + basevars["CONFIG"] += project->values(build + ".CONFIG"); + basevars["CONFIG"] += build; + basevars["CONFIG"] += "build_pass"; + basevars["BUILD_PASS"] = QStringList(build); + QStringList buildname = project->values(build + ".name"); + basevars["BUILD_NAME"] = (buildname.isEmpty() ? QStringList(build) : buildname); + QMakeProject tmp_proj(project->properties(), basevars); + const QStringList old_after_user_config = Option::after_user_configs; + const QStringList old_user_config = Option::user_configs; + Option::after_user_configs += basevars["CONFIG"]; + Option::user_configs += basevars["CONFIG"]; QString dir = fi.path(), fn = fi.fileName(); if(!dir.isEmpty()) { if(!qmake_setpwd(dir)) fprintf(stderr, "Cannot find directory: %s\n", dir.toLatin1().constData());