You've already forked linux-packaging-mono
Imported Upstream version 5.0.0.42
Former-commit-id: fd56571888259555122d8a0f58c68838229cea2b
This commit is contained in:
parent
1190d13a04
commit
6bdd276d05
@@ -51,9 +51,10 @@ namespace Mono.XBuild.CommandLine {
|
||||
Project project;
|
||||
ConsoleReportPrinter printer;
|
||||
|
||||
#pragma warning disable 169
|
||||
// this does nothing but adds strong reference to Microsoft.Build.Tasks*.dll that we need to load consistently.
|
||||
Microsoft.Build.Tasks.Copy dummy;
|
||||
|
||||
#pragma warning restore
|
||||
public static void Main (string[] args)
|
||||
{
|
||||
MainClass mc = new MainClass ();
|
||||
@@ -74,12 +75,20 @@ namespace Mono.XBuild.CommandLine {
|
||||
bool show_stacktrace = false;
|
||||
|
||||
try {
|
||||
parameters.ParseArguments (args);
|
||||
try {
|
||||
parameters.ParseArguments (args);
|
||||
} catch {
|
||||
ShowDeprecationNotice ();
|
||||
throw;
|
||||
}
|
||||
|
||||
show_stacktrace = (parameters.LoggerVerbosity == LoggerVerbosity.Detailed ||
|
||||
parameters.LoggerVerbosity == LoggerVerbosity.Diagnostic);
|
||||
|
||||
if (!parameters.NoLogo)
|
||||
if (!parameters.NoLogo) {
|
||||
ShowDeprecationNotice ();
|
||||
ErrorUtilities.ShowVersion (false);
|
||||
}
|
||||
|
||||
engine = Engine.GlobalEngine;
|
||||
if (!String.IsNullOrEmpty (parameters.ToolsVersion)) {
|
||||
@@ -164,6 +173,15 @@ namespace Mono.XBuild.CommandLine {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void ShowDeprecationNotice ()
|
||||
{
|
||||
Console.ForegroundColor = ConsoleColor.DarkRed;
|
||||
Console.WriteLine ();
|
||||
Console.WriteLine (">>>> xbuild tool is deprecated and will be removed in future updates, use msbuild instead <<<<");
|
||||
Console.WriteLine ();
|
||||
Console.ResetColor ();
|
||||
}
|
||||
}
|
||||
|
||||
// code from mcs/report.cs
|
||||
|
||||
@@ -77,6 +77,8 @@ install-frameworks:
|
||||
$(INSTALL_DATA) frameworks/net_4.6.xml $(DESTDIR)$(NETFRAMEWORK_DIR)/v4.6/RedistList/FrameworkList.xml
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(NETFRAMEWORK_DIR)/v4.6.1/RedistList
|
||||
$(INSTALL_DATA) frameworks/net_4.6.1.xml $(DESTDIR)$(NETFRAMEWORK_DIR)/v4.6.1/RedistList/FrameworkList.xml
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(NETFRAMEWORK_DIR)/v4.6.2/RedistList
|
||||
$(INSTALL_DATA) frameworks/net_4.6.2.xml $(DESTDIR)$(NETFRAMEWORK_DIR)/v4.6.2/RedistList/FrameworkList.xml
|
||||
|
||||
install-pcl-targets:
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(PORTABLE_TARGETS_DIR)
|
||||
@@ -131,6 +133,7 @@ install-pcl5-framework:
|
||||
EXTRA_DISTFILES = \
|
||||
data/xbuild.rsp \
|
||||
data/xbuild.exe.config.in \
|
||||
data/xbuild.exe.config_test.in \
|
||||
data/Microsoft.Build.xsd \
|
||||
data/2.0/Microsoft.Common.tasks \
|
||||
data/3.5/Microsoft.Common.tasks \
|
||||
@@ -161,6 +164,7 @@ EXTRA_DISTFILES = \
|
||||
frameworks/net_4.5.2.xml \
|
||||
frameworks/net_4.6.xml \
|
||||
frameworks/net_4.6.1.xml \
|
||||
frameworks/net_4.6.2.xml \
|
||||
targets/Microsoft.WebApplication.targets \
|
||||
$(NUGET_BUILDTASKS_REPO_DIR)/src/Microsoft.NuGet.Build.Tasks/ImportBeforeAfter/Microsoft.NuGet.ImportBefore.props \
|
||||
$(NUGET_BUILDTASKS_REPO_DIR)/src/Microsoft.NuGet.Build.Tasks/ImportBeforeAfter/Microsoft.NuGet.ImportAfter.targets \
|
||||
|
||||
@@ -151,7 +151,7 @@
|
||||
Condition="'$(TargetFrameworkIdentifier)' == '' or '$(TargetFrameworkIdentifier)' == '.NETFramework'"
|
||||
DependsOnTargets="$(GetFrameworkPathsDependsOn)">
|
||||
<GetFrameworkPath>
|
||||
<Output Condition="'$(TargetFrameworkVersion)' == 'v4.5' or '$(TargetFrameworkVersion)' == 'v4.5.1' or '$(TargetFrameworkVersion)' == 'v4.5.2' or '$(TargetFrameworkVersion)' == 'v4.6' or '$(TargetFrameworkVersion)' == 'v4.6.1'"
|
||||
<Output Condition="'$(TargetFrameworkVersion)' == 'v4.5' or '$(TargetFrameworkVersion)' == 'v4.5.1' or '$(TargetFrameworkVersion)' == 'v4.5.2' or '$(TargetFrameworkVersion)' == 'v4.6' or '$(TargetFrameworkVersion)' == 'v4.6.1' or '$(TargetFrameworkVersion)' == 'v4.6.2'"
|
||||
TaskParameter="FrameworkVersion45Path"
|
||||
ItemName="_CombinedTargetFrameworkDirectoriesItem"/>
|
||||
<Output Condition="'$(TargetFrameworkVersion)' == 'v4.0'"
|
||||
@@ -172,7 +172,7 @@
|
||||
</CreateProperty>
|
||||
|
||||
<Warning Text="TargetFrameworkVersion '$(TargetFrameworkVersion)' not supported by this toolset (ToolsVersion: $(MSBuildToolsVersion))."
|
||||
Condition="'$(TargetFrameworkVersion)' != 'v4.6.1' and '$(TargetFrameworkVersion)' != 'v4.6' and '$(TargetFrameworkVersion)' != 'v4.5.2' and '$(TargetFrameworkVersion)' != 'v4.5.1' and '$(TargetFrameworkVersion)' != 'v4.5' and '$(TargetFrameworkVersion)' != 'v4.0' and '$(TargetFrameworkVersion)' != 'v3.5' and '$(TargetFrameworkVersion)' != 'v3.0' and '$(TargetFrameworkVersion)' != 'v2.0'"/>
|
||||
Condition="'$(TargetFrameworkVersion)' != 'v4.6.2' and '$(TargetFrameworkVersion)' != 'v4.6.1' and '$(TargetFrameworkVersion)' != 'v4.6' and '$(TargetFrameworkVersion)' != 'v4.5.2' and '$(TargetFrameworkVersion)' != 'v4.5.1' and '$(TargetFrameworkVersion)' != 'v4.5' and '$(TargetFrameworkVersion)' != 'v4.0' and '$(TargetFrameworkVersion)' != 'v3.5' and '$(TargetFrameworkVersion)' != 'v3.0' and '$(TargetFrameworkVersion)' != 'v2.0'"/>
|
||||
</Target>
|
||||
|
||||
<PropertyGroup>
|
||||
|
||||
11
mcs/tools/xbuild/data/xbuild.exe.config_test.in
Normal file
11
mcs/tools/xbuild/data/xbuild.exe.config_test.in
Normal file
@@ -0,0 +1,11 @@
|
||||
<generatePublisherEvidence enabled="false" />
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Build.Framework" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="@ASM_VERSION@" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Build.Engine" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="@ASM_VERSION@" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
3
mcs/tools/xbuild/frameworks/net_4.6.2.xml
Normal file
3
mcs/tools/xbuild/frameworks/net_4.6.2.xml
Normal file
@@ -0,0 +1,3 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FileList Name=".NET Framework 4.6.2" TargetFrameworkDirectory="..\..\..\..\4.5">
|
||||
</FileList>
|
||||
@@ -9,7 +9,7 @@ export XBUILD_FRAMEWORK_FOLDERS_PATH= $(topdir)/class/Microsoft.Build/xbuild-tes
|
||||
ifeq (4.0, $(FRAMEWORK_VERSION))
|
||||
NO_TEST=true
|
||||
else
|
||||
test-local: copy-targets $(test_lib).config
|
||||
test-local: copy-targets Test/test-config-file-$(PROFILE)
|
||||
clean-local: clean-targets clean-test-config
|
||||
endif
|
||||
|
||||
@@ -17,11 +17,11 @@ xbuild-net4-fail:
|
||||
@echo "The net_4_0 profile contains reference assemblies only and cannot be installed/tested as an xbuild toolset"
|
||||
@exit 1
|
||||
|
||||
$(test_lib).config: $(XBUILD_DATA_DIR)/xbuild.exe.config.in
|
||||
sed -e 's/@ASM_VERSION@/$(XBUILD_ASSEMBLY_VERSION)/g' $(XBUILD_DATA_DIR)/xbuild.exe.config.in > $(test_lib).config
|
||||
Test/test-config-file-$(PROFILE): $(XBUILD_DATA_DIR)/xbuild.exe.config_test.in
|
||||
sed -e 's/@ASM_VERSION@/$(XBUILD_ASSEMBLY_VERSION)/g' $(XBUILD_DATA_DIR)/xbuild.exe.config_test.in > Test/test-config-file-$(PROFILE)
|
||||
|
||||
clean-test-config:
|
||||
rm -f $(test_lib).config
|
||||
rm -f Test/test-config-file-$(PROFILE)
|
||||
|
||||
copy-targets: copy-targets-$(XBUILD_VERSION)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user