diff options
author | lbsa71 | 2009-02-17 16:15:29 +0000 |
---|---|---|
committer | lbsa71 | 2009-02-17 16:15:29 +0000 |
commit | 55d89b73edbfc12da6f6ec11c6f1aa429a7e7a40 (patch) | |
tree | b9087194c8859a6a27caf6d5363d686e597f8207 /Prebuild/src/Core/Targets/VS2005Target.cs | |
parent | * Apply http://opensimulator.org/mantis/view.php?id=3178 (diff) | |
download | opensim-SC_OLD-55d89b73edbfc12da6f6ec11c6f1aa429a7e7a40.zip opensim-SC_OLD-55d89b73edbfc12da6f6ec11c6f1aa429a7e7a40.tar.gz opensim-SC_OLD-55d89b73edbfc12da6f6ec11c6f1aa429a7e7a40.tar.bz2 opensim-SC_OLD-55d89b73edbfc12da6f6ec11c6f1aa429a7e7a40.tar.xz |
* fixed 'path' reference attribute for Nant and VS2008 targets.
Diffstat (limited to '')
-rw-r--r-- | Prebuild/src/Core/Targets/VS2005Target.cs | 30 |
1 files changed, 26 insertions, 4 deletions
diff --git a/Prebuild/src/Core/Targets/VS2005Target.cs b/Prebuild/src/Core/Targets/VS2005Target.cs index 8e09711..5b7ad07 100644 --- a/Prebuild/src/Core/Targets/VS2005Target.cs +++ b/Prebuild/src/Core/Targets/VS2005Target.cs | |||
@@ -364,6 +364,21 @@ namespace Prebuild.Core.Targets | |||
364 | return ret; | 364 | return ret; |
365 | } | 365 | } |
366 | 366 | ||
367 | private static bool ExtensionSpecified(string refName) | ||
368 | { | ||
369 | return refName.EndsWith(".dll") || refName.EndsWith(".exe"); | ||
370 | } | ||
371 | |||
372 | private static string GetProjectExtension(ProjectNode project) | ||
373 | { | ||
374 | string extension = ".dll"; | ||
375 | if (project.Type == ProjectType.Exe) | ||
376 | { | ||
377 | extension = ".exe"; | ||
378 | } | ||
379 | return extension; | ||
380 | } | ||
381 | |||
367 | private void WriteProject(SolutionNode solution, ProjectNode project) | 382 | private void WriteProject(SolutionNode solution, ProjectNode project) |
368 | { | 383 | { |
369 | if (!tools.ContainsKey(project.Language)) | 384 | if (!tools.ContainsKey(project.Language)) |
@@ -474,14 +489,21 @@ namespace Prebuild.Core.Targets | |||
474 | ps.WriteLine("\" >"); | 489 | ps.WriteLine("\" >"); |
475 | 490 | ||
476 | string path; | 491 | string path; |
477 | 492 | ||
478 | if (refr.Name.EndsWith(".dll", StringComparison.InvariantCultureIgnoreCase)) | 493 | if (String.IsNullOrEmpty(refr.Path)) |
479 | { | 494 | { |
480 | path = Helper.NormalizePath(Path.Combine( refPath, refr.Name), '\\'); | 495 | if ( ExtensionSpecified( refr.Name ) ) |
496 | { | ||
497 | path = Helper.NormalizePath(Path.Combine(refPath, refr.Name), '\\'); | ||
498 | } | ||
499 | else | ||
500 | { | ||
501 | path = refr.Name + ".dll"; | ||
502 | } | ||
481 | } | 503 | } |
482 | else | 504 | else |
483 | { | 505 | { |
484 | path = refr.Name + ".dll"; | 506 | path = refr.Path; |
485 | } | 507 | } |
486 | 508 | ||
487 | // TODO: Allow reference to *.exe files | 509 | // TODO: Allow reference to *.exe files |