Author: ankit
Date: 2007-05-29 09:29:35 -0400 (Tue, 29 May 2007)
New Revision: 78119
Modified:
trunk/monodevelop/Extras/MonoDevelop.Autotools/ChangeLog
trunk/monodevelop/Extras/MonoDevelop.Autotools/SimpleProjectMakefileHandler.cs
Log:
* SimpleProjectMakefileHandler.cs (Deploy): GetDeployFiles can return
duplicates, ignore them. Update code for change in GetProjectConfig.
(GetProjectConfig): Look for project's config in ParentCombine's
configs.
Modified: trunk/monodevelop/Extras/MonoDevelop.Autotools/ChangeLog
===================================================================
--- trunk/monodevelop/Extras/MonoDevelop.Autotools/ChangeLog 2007-05-29
13:03:45 UTC (rev 78118)
+++ trunk/monodevelop/Extras/MonoDevelop.Autotools/ChangeLog 2007-05-29
13:29:35 UTC (rev 78119)
@@ -1,5 +1,12 @@
2007-05-29 Ankit Jain <[EMAIL PROTECTED]>
+ * SimpleProjectMakefileHandler.cs (Deploy): GetDeployFiles can return
+ duplicates, ignore them. Update code for change in GetProjectConfig.
+ (GetProjectConfig): Look for project's config in ParentCombine's
+ configs.
+
+2007-05-29 Ankit Jain <[EMAIL PROTECTED]>
+
* SimpleProjectMakefileHandler.cs (Deploy): Enumerate solution level
configs, and use the corresponding project config for emitting
Makefile.am
(GetProjectConfig): New.
Modified:
trunk/monodevelop/Extras/MonoDevelop.Autotools/SimpleProjectMakefileHandler.cs
===================================================================
---
trunk/monodevelop/Extras/MonoDevelop.Autotools/SimpleProjectMakefileHandler.cs
2007-05-29 13:03:45 UTC (rev 78118)
+++
trunk/monodevelop/Extras/MonoDevelop.Autotools/SimpleProjectMakefileHandler.cs
2007-05-29 13:29:35 UTC (rev 78119)
@@ -21,6 +21,7 @@
using System;
using System.IO;
using System.Collections;
+using System.Collections.Generic;
using System.Reflection;
using System.Text;
@@ -187,6 +188,7 @@
// Handle files to be deployed
Hashtable deployDirs = new Hashtable ();
Hashtable deployFileVars = new Hashtable ();
+ Dictionary<string, DeployFile>
uniqueDeployFiles = new Dictionary<string, DeployFile> ();
StringBuilder deployFileCopy = new
StringBuilder ();
ArrayList builtFiles = new ArrayList ();
@@ -195,6 +197,12 @@
if (dfile.SourcePath ==
project.GetOutputFileName ())
continue;
+ // GetDeployFiles can return
duplicates, ignore them
+ string key = dfile.SourcePath +
dfile.RelativeTargetPath;
+ if (uniqueDeployFiles.ContainsKey (key))
+ continue;
+ uniqueDeployFiles [key] = dfile;
+
string fname = null;
string deployVar = GetDeployVar
(deployFileVars, Path.GetFileName (dfile.RelativeTargetPath));
@@ -269,7 +277,7 @@
StringBuilder conf_vars = new StringBuilder ();
foreach (CombineConfiguration combineConfig in
project.RootCombine.Configurations)
{
- DotNetProjectConfiguration config =
GetProjectConfig (combineConfig, project) as DotNetProjectConfiguration;
+ DotNetProjectConfiguration config =
GetProjectConfig (combineConfig.Name, project) as DotNetProjectConfiguration;
if (config == null)
continue;
@@ -316,7 +324,7 @@
{
Project refp =
GetProjectFromName ( reference.Reference, project );
-
DotNetProjectConfiguration dnpc = GetProjectConfig (combineConfig, refp) as
DotNetProjectConfiguration;
+
DotNetProjectConfiguration dnpc = GetProjectConfig (combineConfig.Name, refp)
as DotNetProjectConfiguration;
if ( dnpc == null )
throw new
Exception ( GettextCatalog.GetString
("Could not add reference to project '{0}'", refp.Name) );
@@ -366,9 +374,13 @@
return makefile;
}
- // Gets the Project config corresponding to the @combineConfig
for a project (@entry)
- IConfiguration GetProjectConfig (CombineConfiguration
combineConfig, CombineEntry entry)
+ // Get the Project config corresponding to its @parentConfig
+ IConfiguration GetProjectConfig (string parentConfig,
CombineEntry entry)
{
+ CombineConfiguration combineConfig =
entry.ParentCombine.Configurations [parentConfig] as CombineConfiguration;
+ if (combineConfig == null)
+ return null;
+
foreach (CombineConfigurationEntry cce in
combineConfig.Entries) {
if (cce.Entry == entry)
return entry.Configurations
[cce.ConfigurationName];
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches