all pdbs are now packaged with windows
authorDavid Anderson <dvander@alliedmods.net>
Sun Oct 14 21:31:39 2007 +0000 (2007-10-14)
changeset 155895a3d8bf618d
parent 1557 eb8d17f6b271
child 1559 bb3fd890699d
all pdbs are now packaged with windows
tools/builder/ABuilder.cs
tools/builder/LinuxBuilder.cs
tools/builder/Win32Builder.cs
     1.1 --- a/tools/builder/ABuilder.cs	Sun Oct 14 20:25:57 2007 +0000
     1.2 +++ b/tools/builder/ABuilder.cs	Sun Oct 14 21:31:39 2007 +0000
     1.3 @@ -12,7 +12,7 @@
     1.4  		{
     1.5  		}
     1.6  
     1.7 -		public abstract bool BuildLibrary(Package pkg, Library lib, ref string _binName, ref string _binPath);
     1.8 +		public abstract bool BuildLibrary(Package pkg, Library lib);
     1.9  
    1.10  		public abstract string GetPawnCompilerName();
    1.11  
    1.12 @@ -168,7 +168,6 @@
    1.13  
    1.14  			/* Do libraries */
    1.15  			Library [] libs = pkg.GetLibraries();
    1.16 -			string bin = null, binpath = null;
    1.17  			for (int i=0; i<libs.Length; i++)
    1.18  			{
    1.19  				if (cfg.Platform == BasePlatform.Platform_Linux
    1.20 @@ -176,16 +175,7 @@
    1.21  				{
    1.22  					continue;
    1.23  				}
    1.24 -				if (BuildLibrary(pkg, libs[i], ref bin, ref binpath))
    1.25 -				{
    1.26 -					path = Config.PathFormat("{0}/{1}/{2}/{3}",
    1.27 -						cfg.pkg_path,
    1.28 -						pkg.GetBaseFolder(),
    1.29 -						libs[i].package_path,
    1.30 -						bin);
    1.31 -					File.Copy(binpath, path, true);
    1.32 -				}
    1.33 -				else 
    1.34 +				if (!BuildLibrary(pkg, libs[i]))
    1.35  				{
    1.36  					throw new System.Exception("Failed to compile library: " + libs[i].binary_name);
    1.37  				}
     2.1 --- a/tools/builder/LinuxBuilder.cs	Sun Oct 14 20:25:57 2007 +0000
     2.2 +++ b/tools/builder/LinuxBuilder.cs	Sun Oct 14 21:31:39 2007 +0000
     2.3 @@ -16,7 +16,7 @@
     2.4  			return "spcomp";
     2.5  		}
     2.6  
     2.7 -		public override bool BuildLibrary(Package pkg, Library lib, ref string _binName, ref string _binPath)
     2.8 +		public override bool BuildLibrary(Package pkg, Library lib)
     2.9  		{
    2.10  			ProcessStartInfo info = new ProcessStartInfo();
    2.11  
    2.12 @@ -94,8 +94,12 @@
    2.13  				return false;
    2.14  			}
    2.15  			
    2.16 -			_binName = binName;
    2.17 -			_binPath = binpath;
    2.18 +			path = Config.PathFormat("{0}/{1}/{2}/{3}",
    2.19 +				cfg.pkg_path,
    2.20 +				pkg.GetBaseFolder(),
    2.21 +				lib.package_path,
    2.22 +				binName);
    2.23 +			File.Copy(binpath, path, true);
    2.24  
    2.25  			return true;
    2.26  		}
     3.1 --- a/tools/builder/Win32Builder.cs	Sun Oct 14 20:25:57 2007 +0000
     3.2 +++ b/tools/builder/Win32Builder.cs	Sun Oct 14 21:31:39 2007 +0000
     3.3 @@ -16,7 +16,7 @@
     3.4  			return "spcomp.exe";
     3.5  		}
     3.6  
     3.7 -		public override bool BuildLibrary(Package pkg, Library lib, ref string _binName, ref string _binPath)
     3.8 +		public override bool BuildLibrary(Package pkg, Library lib)
     3.9  		{
    3.10  			ProcessStartInfo info = new ProcessStartInfo();
    3.11  
    3.12 @@ -94,8 +94,17 @@
    3.13  				return false;
    3.14  			}
    3.15  
    3.16 -			_binName = binName;
    3.17 -			_binPath = binpath;
    3.18 +			path = Config.PathFormat("{0}/{1}/{2}/{3}",
    3.19 +				cfg.pkg_path,
    3.20 +				pkg.GetBaseFolder(),
    3.21 +				lib.package_path,
    3.22 +				binName);
    3.23 +			File.Copy(binpath, path, true);
    3.24 +
    3.25 +			/* On Windows we package the .pdb files as well */
    3.26 +			binpath = binpath.Replace(".dll", ".pdb");
    3.27 +			path = path.Replace(".dll", ".pdb");
    3.28 +			File.Copy(binpath, path, true);
    3.29  
    3.30  			return true;
    3.31  		}