Merge pull request #2151 from dotnet/brthor/remove-oob-commands
Remove OOB Commands and Pdbs from stage2
This commit is contained in:
commit
164a235a20
4 changed files with 24 additions and 10 deletions
|
@ -20,9 +20,7 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
|
|
||||||
public static readonly string[] BinariesForCoreHost = new[]
|
public static readonly string[] BinariesForCoreHost = new[]
|
||||||
{
|
{
|
||||||
"csi",
|
"csc"
|
||||||
"csc",
|
|
||||||
"vbc"
|
|
||||||
};
|
};
|
||||||
|
|
||||||
public static readonly string[] ProjectsToPublish = new[]
|
public static readonly string[] ProjectsToPublish = new[]
|
||||||
|
@ -32,7 +30,7 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
|
|
||||||
public static readonly string[] FilesToClean = new[]
|
public static readonly string[] FilesToClean = new[]
|
||||||
{
|
{
|
||||||
"README.md"
|
"vbc.exe"
|
||||||
};
|
};
|
||||||
|
|
||||||
public static readonly string[] ProjectsToPack = new[]
|
public static readonly string[] ProjectsToPack = new[]
|
||||||
|
@ -250,9 +248,13 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
|
|
||||||
CopySharedHost(Dirs.Stage1);
|
CopySharedHost(Dirs.Stage1);
|
||||||
PublishSharedFramework(c, Dirs.Stage1, DotNetCli.Stage0);
|
PublishSharedFramework(c, Dirs.Stage1, DotNetCli.Stage0);
|
||||||
return CompileCliSdk(c,
|
var result = CompileCliSdk(c,
|
||||||
dotnet: DotNetCli.Stage0,
|
dotnet: DotNetCli.Stage0,
|
||||||
outputDir: Dirs.Stage1);
|
outputDir: Dirs.Stage1);
|
||||||
|
|
||||||
|
CleanOutputDir(Path.Combine(Dirs.Stage1, "sdk"));
|
||||||
|
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
[Target]
|
[Target]
|
||||||
|
@ -299,9 +301,17 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CleanOutputDir(Path.Combine(Dirs.Stage2, "sdk"));
|
||||||
|
|
||||||
return c.Success();
|
return c.Success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static void CleanOutputDir(string directory)
|
||||||
|
{
|
||||||
|
FS.RmFilesInDirRecursive(directory, "vbc.exe");
|
||||||
|
FS.RmFilesInDirRecursive(directory, "*.pdb");
|
||||||
|
}
|
||||||
|
|
||||||
private static void CopySharedHost(string outputDir)
|
private static void CopySharedHost(string outputDir)
|
||||||
{
|
{
|
||||||
// corehost will be renamed to dotnet at some point and then this can be removed.
|
// corehost will be renamed to dotnet at some point and then this can be removed.
|
||||||
|
|
|
@ -34,6 +34,15 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void RmFilesInDirRecursive(string dir, string filePattern)
|
||||||
|
{
|
||||||
|
var files = Directory.EnumerateFiles(dir, filePattern, SearchOption.AllDirectories);
|
||||||
|
foreach (var file in files)
|
||||||
|
{
|
||||||
|
FS.Rm(file);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public static void Chmod(string file, string mode, bool recursive = false)
|
public static void Chmod(string file, string mode, bool recursive = false)
|
||||||
{
|
{
|
||||||
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
||||||
|
|
|
@ -10,8 +10,6 @@
|
||||||
},
|
},
|
||||||
"Microsoft.CodeAnalysis.CSharp": "1.3.0-beta1-20160321-04",
|
"Microsoft.CodeAnalysis.CSharp": "1.3.0-beta1-20160321-04",
|
||||||
"Microsoft.Net.Compilers.netcore": "1.3.0-beta1-20160321-04",
|
"Microsoft.Net.Compilers.netcore": "1.3.0-beta1-20160321-04",
|
||||||
"Microsoft.Net.CSharp.Interactive.netcore": "1.3.0-beta1-20160321-04",
|
|
||||||
"Microsoft.FSharp.Compiler.netcore": "1.0.0-alpha-160318",
|
|
||||||
"Microsoft.DiaSymReader.Native": "1.3.3"
|
"Microsoft.DiaSymReader.Native": "1.3.3"
|
||||||
},
|
},
|
||||||
"frameworks": {
|
"frameworks": {
|
||||||
|
|
|
@ -108,14 +108,11 @@ namespace Microsoft.DotNet.Cli
|
||||||
{
|
{
|
||||||
["build"] = BuildCommand.Run,
|
["build"] = BuildCommand.Run,
|
||||||
["compile-csc"] = CompileCscCommand.Run,
|
["compile-csc"] = CompileCscCommand.Run,
|
||||||
["compile-fsc"] = CompileFscCommand.Run,
|
|
||||||
["compile-native"] = CompileNativeCommand.Run,
|
|
||||||
["help"] = HelpCommand.Run,
|
["help"] = HelpCommand.Run,
|
||||||
["new"] = NewCommand.Run,
|
["new"] = NewCommand.Run,
|
||||||
["pack"] = PackCommand.Run,
|
["pack"] = PackCommand.Run,
|
||||||
["projectmodel-server"] = ProjectModelServerCommand.Run,
|
["projectmodel-server"] = ProjectModelServerCommand.Run,
|
||||||
["publish"] = PublishCommand.Run,
|
["publish"] = PublishCommand.Run,
|
||||||
["repl"] = ReplCommand.Run,
|
|
||||||
["restore"] = RestoreCommand.Run,
|
["restore"] = RestoreCommand.Run,
|
||||||
["run"] = RunCommand.Run,
|
["run"] = RunCommand.Run,
|
||||||
["test"] = TestCommand.Run
|
["test"] = TestCommand.Run
|
||||||
|
|
Loading…
Add table
Reference in a new issue