summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@nokia.com>2010-08-03 14:21:15 (GMT)
committerJoerg Bornemann <joerg.bornemann@nokia.com>2010-08-10 08:52:58 (GMT)
commit56e31f8ad585d8524c0d0d21d5d1f6f821fba3c2 (patch)
tree37cba11d63073763e89f4bdff6f7ed82fcebee0d /qmake
parentde6e55237263ea1b0426ffda9386cabba5739208 (diff)
downloadQt-56e31f8ad585d8524c0d0d21d5d1f6f821fba3c2.zip
Qt-56e31f8ad585d8524c0d0d21d5d1f6f821fba3c2.tar.gz
Qt-56e31f8ad585d8524c0d0d21d5d1f6f821fba3c2.tar.bz2
qmake: remove Windows CE stuff from .vcxproj generator
VS2010 does not support Windows CE. Reviewed-by: ossi
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/win32/msvc_vcproj.cpp2
-rw-r--r--qmake/generators/win32/msvc_vcxproj.cpp150
-rw-r--r--qmake/generators/win32/msvc_vcxproj.h1
3 files changed, 4 insertions, 149 deletions
diff --git a/qmake/generators/win32/msvc_vcproj.cpp b/qmake/generators/win32/msvc_vcproj.cpp
index 2f949ed..e801371 100644
--- a/qmake/generators/win32/msvc_vcproj.cpp
+++ b/qmake/generators/win32/msvc_vcproj.cpp
@@ -1260,7 +1260,6 @@ void VcprojGenerator::initTranslationFiles()
vcProject.TranslationFiles.CustomBuild = none;
}
-
void VcprojGenerator::initFormFiles()
{
vcProject.FormFiles.Name = "Form Files";
@@ -1276,7 +1275,6 @@ void VcprojGenerator::initFormFiles()
vcProject.FormFiles.CustomBuild = none;
}
-
void VcprojGenerator::initResourceFiles()
{
vcProject.ResourceFiles.Name = "Resource Files";
diff --git a/qmake/generators/win32/msvc_vcxproj.cpp b/qmake/generators/win32/msvc_vcxproj.cpp
index 3851270..d87c0e8 100644
--- a/qmake/generators/win32/msvc_vcxproj.cpp
+++ b/qmake/generators/win32/msvc_vcxproj.cpp
@@ -112,13 +112,9 @@ void VcxprojGenerator::initProject()
vcxProject.Name = unescapeFilePath(project->first("QMAKE_ORIG_TARGET"));
vcxProject.Keyword = project->first("VCPROJ_KEYWORD");
- if (project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) {
- vcxProject.PlatformName = vcxProject.Configuration.idl.TargetEnvironment;
- if ( vcxProject.Configuration.idl.TargetEnvironment.isEmpty() )
- vcxProject.PlatformName = "Win32";
- } else {
- vcxProject.PlatformName = project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")";
- }
+ vcxProject.PlatformName = vcxProject.Configuration.idl.TargetEnvironment;
+ if (vcxProject.Configuration.idl.TargetEnvironment.isEmpty())
+ vcxProject.PlatformName = "Win32";
// These are not used by Qt, but may be used by customers
vcxProject.SccProjectName = project->first("SCCPROJECTNAME");
vcxProject.SccLocalPath = project->first("SCCLOCALPATH");
@@ -179,11 +175,7 @@ void VcxprojGenerator::initConfiguration()
if (conf.Name.isEmpty())
conf.Name = isDebug ? "Debug" : "Release";
conf.ConfigurationName = conf.Name;
- if (project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) {
- conf.Name += (conf.idl.TargetEnvironment == "Win64" ? "|Win64" : "|Win32");
- } else {
- conf.Name += "|" + project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")";
- }
+ conf.Name += (conf.idl.TargetEnvironment == "Win64" ? "|Win64" : "|Win32");
conf.ATLMinimizesCRunTimeLibraryUsage = (project->first("ATLMinimizesCRunTimeLibraryUsage").isEmpty() ? _False : _True);
conf.BuildBrowserInformation = triState(temp.isEmpty() ? (short)unset : temp.toShort());
temp = project->first("CharacterSet");
@@ -250,9 +242,6 @@ void VcxprojGenerator::initConfiguration()
initCustomBuildTool();
initPreBuildEventTools();
initPostBuildEventTools();
- // Only deploy for CE projects
- if (!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH"))
- initDeploymentTool();
initPreLinkEventTools();
// Set definite values in both configurations
@@ -360,15 +349,6 @@ void VcxprojGenerator::initPostBuildEventTools()
conf.postBuild.UseInBuild = _True;
}
- QString signature = !project->isEmpty("SIGNATURE_FILE") ? var("SIGNATURE_FILE") : var("DEFAULT_SIGNATURE");
- bool useSignature = !signature.isEmpty() && !project->isActiveConfig("staticlib") &&
- !project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH");
- if(useSignature) {
- conf.postBuild.CommandLine.prepend(QLatin1String("signtool sign /F ") + signature + " \"$(TargetPath)\"\n" +
- (!conf.postBuild.CommandLine.isEmpty() ? " && " : ""));
- conf.postBuild.UseInBuild = _True;
- }
-
if(!project->values("MSVCPROJ_COPY_DLL").isEmpty()) {
if(!conf.postBuild.CommandLine.isEmpty())
conf.postBuild.CommandLine += " && ";
@@ -378,128 +358,6 @@ void VcxprojGenerator::initPostBuildEventTools()
}
}
-
-void VcxprojGenerator::initDeploymentTool()
-{
- VCXConfiguration &conf = vcxProject.Configuration;
- QString targetPath = project->values("deploy.path").join(" ");
- if (targetPath.isEmpty())
- targetPath = QString("%CSIDL_PROGRAM_FILES%\\") + project->first("TARGET");
- if (targetPath.endsWith("/") || targetPath.endsWith("\\"))
- targetPath.chop(1);
-
- // Only deploy Qt libs for shared build
- if (!project->values("QMAKE_QT_DLL").isEmpty()) {
- QStringList& arg = project->values("MSVCPROJ_LIBS");
- for (QStringList::ConstIterator it = arg.constBegin(); it != arg.constEnd(); ++it) {
- if (it->contains(project->first("QMAKE_LIBDIR"))) {
- QString dllName = *it;
-
- if (dllName.contains(QLatin1String("QAxContainer"))
- || dllName.contains(QLatin1String("qtmain"))
- || dllName.contains(QLatin1String("QtUiTools")))
- continue;
- dllName.replace(QLatin1String(".lib") , QLatin1String(".dll"));
- QFileInfo info(dllName);
- conf.deployment.AdditionalFiles += info.fileName()
- + "|" + QDir::toNativeSeparators(info.absolutePath())
- + "|" + targetPath
- + "|0;";
- }
- }
- }
-
- // C-runtime deployment
- QString runtime = project->values("QT_CE_C_RUNTIME").join(QLatin1String(" "));
- if (!runtime.isEmpty() && (runtime != QLatin1String("no"))) {
- QString runtimeVersion = QLatin1String("msvcr");
- QString mkspec = project->first("QMAKESPEC");
- // If no .qmake.cache has been found, we fallback to the original mkspec
- if (mkspec.isEmpty())
- mkspec = project->first("QMAKESPEC_ORIGINAL");
-
- if (!mkspec.isEmpty()) {
- if (mkspec.endsWith("2010"))
- runtimeVersion.append("100");
- else if (mkspec.endsWith("2008"))
- runtimeVersion.append("90");
- else
- runtimeVersion.append("80");
- if (project->isActiveConfig("debug"))
- runtimeVersion.append("d");
- runtimeVersion.append(".dll");
-
- if (runtime == "yes") {
- // Auto-find C-runtime
- QString vcInstallDir = qgetenv("VCINSTALLDIR");
- if (!vcInstallDir.isEmpty()) {
- vcInstallDir += "\\ce\\dll\\";
- vcInstallDir += project->values("CE_ARCH").join(QLatin1String(" "));
- if (!QFileInfo(vcInstallDir + QDir::separator() + runtimeVersion).exists())
- runtime.clear();
- else
- runtime = vcInstallDir;
- }
- }
- }
-
- if (!runtime.isEmpty() && runtime != QLatin1String("yes")) {
- conf.deployment.AdditionalFiles += runtimeVersion
- + "|" + QDir::toNativeSeparators(runtime)
- + "|" + targetPath
- + "|0;";
- }
- }
-
- // foreach item in DEPLOYMENT
- foreach(QString item, project->values("DEPLOYMENT")) {
- // get item.path
- QString devicePath = project->first(item + ".path");
- if (devicePath.isEmpty())
- devicePath = targetPath;
- // check if item.path is relative (! either /,\ or %)
- if (!(devicePath.at(0) == QLatin1Char('/')
- || devicePath.at(0) == QLatin1Char('\\')
- || devicePath.at(0) == QLatin1Char('%'))) {
- // create output path
- devicePath = Option::fixPathToLocalOS(QDir::cleanPath(targetPath + QLatin1Char('\\') + devicePath));
- }
- // foreach d in item.sources
- foreach(QString source, project->values(item + ".sources")) {
- QString itemDevicePath = devicePath;
- source = Option::fixPathToLocalOS(source);
- QString nameFilter;
- QFileInfo info(source);
- QString searchPath;
- if (info.isDir()) {
- nameFilter = QLatin1String("*");
- itemDevicePath += "\\" + info.fileName();
- searchPath = info.absoluteFilePath();
- } else {
- nameFilter = source.split('\\').last();
- searchPath = info.absolutePath();
- }
-
- int pathSize = searchPath.size();
- QDirIterator iterator(searchPath, QStringList() << nameFilter
- , QDir::Files | QDir::NoDotAndDotDot | QDir::NoSymLinks
- , QDirIterator::Subdirectories);
- // foreach dirIterator-entry in d
- while(iterator.hasNext()) {
- iterator.next();
- QString absoluteItemPath = Option::fixPathToLocalOS(QFileInfo(iterator.filePath()).absolutePath());
- // Identify if it is just another subdir
- int diffSize = absoluteItemPath.size() - pathSize;
- // write out rules
- conf.deployment.AdditionalFiles += iterator.fileName()
- + "|" + absoluteItemPath
- + "|" + itemDevicePath + (diffSize ? (absoluteItemPath.right(diffSize)) : QLatin1String(""))
- + "|0;";
- }
- }
- }
-}
-
void VcxprojGenerator::initPreLinkEventTools()
{
VCXConfiguration &conf = vcxProject.Configuration;
diff --git a/qmake/generators/win32/msvc_vcxproj.h b/qmake/generators/win32/msvc_vcxproj.h
index 8a183e9..efbfcb8 100644
--- a/qmake/generators/win32/msvc_vcxproj.h
+++ b/qmake/generators/win32/msvc_vcxproj.h
@@ -66,7 +66,6 @@ protected:
void initConfiguration();
void initCompilerTool();
- void initDeploymentTool();
void initLinkerTool();
void initPreLinkEventTools();
void initPostBuildEventTools();