Skip to content
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

<PropertyGroup>
<TargetFrameworks>netcoreapp1.0</TargetFrameworks>
<RuntimeIdentifiers>win7-x86</RuntimeIdentifiers>
<OutputType>Exe</OutputType>
<AssemblyOriginatorKeyFile>test.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
Expand All @@ -19,7 +18,6 @@
</PropertyGroup>

<PropertyGroup Condition="'$(TargetFramework)' == 'net46'">
<RuntimeIdentifier>win7-x86</RuntimeIdentifier>
<PublicSign>false</PublicSign>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,10 @@
<OutputType>Exe</OutputType>
<TargetFramework>net46</TargetFramework>
</PropertyGroup>
<PropertyGroup Condition="'$(UseNativeCode)' == 'true'">
<DefineConstants>$(DefineConstants);USE_NATIVE_CODE</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="'$(UseNativeCode)' == 'true'">
<PackageReference Include="Libuv" Version="1.9.1" />
</ItemGroup>
</Project>
33 changes: 30 additions & 3 deletions TestAssets/TestProjects/DesktopMinusRid/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,41 @@
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.InteropServices;

namespace TestApp
{
public class Program
class Program
{
public static void Main(string[] args)
static void Main()
{
// Prevent libuv on path from interfering with test
Environment.SetEnvironmentVariable("PATH", "");

#if USE_NATIVE_CODE
try
{
uv_loop_size();
Console.WriteLine($"Native code was used ({GetCurrentAssemblyProcessorArchitecture()})");
}
catch (DllNotFoundException)
{
Console.WriteLine($"Native code failed ({GetCurrentAssemblyProcessorArchitecture()})");
}
#else
Console.WriteLine($"Native code was not used ({GetCurrentAssemblyProcessorArchitecture()})");
#endif
}

#if USE_NATIVE_CODE
[DllImport("libuv", CallingConvention = CallingConvention.Cdecl)]
static extern int uv_loop_size();
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like the test might eventually break if the Libuv and Kestrel packages get updated to support AnyCPU .NET Framework deployments by deploying both x86 and x64 versions of the native library and Kestrel dynamically chooses which one to load.

I'm not suggesting you change this now, just pointing it out.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would only happen if my libuv package ref was upgraded, which is unexpected and I'd be happy to have tests fail in that case.

#endif

static ProcessorArchitecture GetCurrentAssemblyProcessorArchitecture()
{
return AssemblyName.GetAssemblyName(typeof(Program).Assembly.Location).ProcessorArchitecture;
}
}
}
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.cs.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Nečekaná závislost {0} bez čísla verze.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>Hodnota RuntimeIdentifier musí být nastavena pro spustitelné soubory .NET Frameworku. Můžete použít hodnotu RuntimeIdentifier=win7-x86 nebo RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Před zpracováním prostředků je potřeba nakonfigurovat preprocesor prostředků.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.de.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Unerwartete Abhängigkeit "{0}" ohne Versionsnummer.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>"RuntimeIdentifier" muss für ausführbare .NETFramework-Dateien festgelegt werden. Verwenden Sie ggf. "RuntimeIdentifier=win7-x86" oder "RuntimeIdentifier=win7-x64".</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Der Ressourcenpräprozessor muss konfiguriert werden, bevor Ressourcen verarbeitet werden.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.es.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Dependencia '{0}' sin número de versión no esperada.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>RuntimeIdentifier debe establecerse para archivos ejecutables de .NET Framework. Considere usar RuntimeIdentifier=win7-x86 o RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Debe configurarse el preprocesador de recursos antes de que se procesen los recursos.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.fr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Dépendance '{0}' sans numéro de version inattendue.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>RuntimeIdentifier doit être défini pour les exécutables .NET Framework. Considérez RuntimeIdentifier=win7-x86 ou RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Le préprocesseur de composants doit être configuré avant que les composants ne soient traités.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.it.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>La dipendenza '{0}' è imprevista e non ha numero di versione.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>Per gli eseguibili di .NET Framework è necessario impostare RuntimeIdentifier. Provare a specificare RuntimeIdentifier=win7-x86 o RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Prima di elaborare le risorse, è necessario configurare il preprocessore di risorse.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.ja.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>バージョン番号のない予期しない依存関係 '{0}' です。</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>.NETFramework 実行可能ファイルの RuntimeIdentifier を設定する必要があります。RuntimeIdentifier=win7-x86 または RuntimeIdentifier=win7-x64 を検討してください。</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>資産を処理する前に、資産プリプロセッサを構成する必要があります。</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.ko.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>버전 번호가 없는 예기치 않은 종속성 '{0}'입니다.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>.NET Framework 실행 파일에는 RuntimeIdentifier를 설정해야 합니다. RuntimeIdentifier=win7-x86 또는 RuntimeIdentifier=win7-x64를 사용해 보세요.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>자산을 처리하려면 먼저 자산 전처리기를 구성해야 합니다.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.pl.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Nieoczekiwana zależność „{0}” bez numeru wersji.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>Element RuntimeIdentifier musi być ustawiony dla plików wykonywalnych programu .NETFramework. Rozważ element RuntimeIdentifier=win7-x86 lub RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Preprocesor zasobów musi być skonfigurowany przed przetworzeniem zasobów.</value>
</data>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Dependência inesperada '{0}' sem número de versão.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>O RuntimeIdentifier deve ser definido para executáveis .NETFramework. Considere o RuntimeIdentifier=win7-x86 ou RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>O pré-processador de ativos deve ser configurado antes de os ativos serem processados.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Unexpected dependency '{0}' with no version number.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Asset preprocessor must be configured before assets are processed.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.ru.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Непредвиденная зависимость "{0}" без номера версии.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>RuntimeIdentifier необходимо задать для исполняемых файлов .NETFramework. Рекомендуется RuntimeIdentifier=win7-x86 или RuntimeIdentifier=win7-x64.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Препроцессор ресурсов необходимо настроить перед обработкой ресурсов.</value>
</data>
Expand Down
3 changes: 0 additions & 3 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/Strings.tr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>Sürüm numarası olmayan, beklenmeyen bağımlılık: '{0}'.</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>.NETFramework yürütülebilir dosyaları için RuntimeIdentifier ayarlanmalıdır. RuntimeIdentifier=win7-x86 veya RuntimeIdentifier=win7-x64 ayarlanabilir.</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>Varlıkların işlenebilmesi için varlık ön işlemcisi yapılandırılmalıdır.</value>
</data>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>不具有版本号的意外依赖项“{0}”。</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>必须为 .NETFramework 可执行文件设置 RuntimeIdentifier。请考虑 RuntimeIdentifier=win7-x86 或 RuntimeIdentifier=win7-x64。</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>必须在处理资产之前配置资产预处理器。</value>
</data>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,6 @@
<data name="UnexpectedDependencyWithNoVersionNumber" xml:space="preserve">
<value>未預期的相依性 '{0}',沒有版本號碼。</value>
</data>
<data name="RuntimeIdentifierMustBeSetForNETFramework" xml:space="preserve">
<value>必須為 .NETFramework 可執行檔設定 RuntimeIdentifier。請考慮使用 RuntimeIdentifier=win7-x86 或 RuntimeIdentifier=win7-x64。</value>
</data>
<data name="AssetPreprocessorMustBeConfigured" xml:space="preserve">
<value>必須設定資產前置處理器,才能處理資產。</value>
</data>
Expand Down
11 changes: 3 additions & 8 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/xlf/Strings.cs.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<note />
</trans-unit>
<trans-unit id="NoCompatibleTargetFramework">
<source>Project '{0}' has no target framework compatible with '{1}'.</source>
<target state="translated">Cílová platforma projektu {0} není kompatibilní s {1}.</target>
<note />
<source>Project '{0}' targets '{2}'. It cannot be referenced by a project that targets '{1}'.</source>
<target state="needs-review-translation">Cílová platforma projektu {0} není kompatibilní s {1}.</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidFrameworkName">
<source>Invalid framework name: '{0}'.</source>
Expand Down Expand Up @@ -98,11 +98,6 @@
<target state="translated">Nečekaná závislost {0} bez čísla verze.</target>
<note />
</trans-unit>
<trans-unit id="RuntimeIdentifierMustBeSetForNETFramework">
<source>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</source>
<target state="translated">Hodnota RuntimeIdentifier musí být nastavena pro spustitelné soubory .NET Frameworku. Můžete použít hodnotu RuntimeIdentifier=win7-x86 nebo RuntimeIdentifier=win7-x64.</target>
<note />
</trans-unit>
<trans-unit id="AssetPreprocessorMustBeConfigured">
<source>Asset preprocessor must be configured before assets are processed.</source>
<target state="translated">Před zpracováním prostředků je potřeba nakonfigurovat preprocesor prostředků.</target>
Expand Down
11 changes: 3 additions & 8 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/xlf/Strings.de.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<note />
</trans-unit>
<trans-unit id="NoCompatibleTargetFramework">
<source>Project '{0}' has no target framework compatible with '{1}'.</source>
<target state="translated">Für das Projekt "{0}" ist kein mit "{1}" kompatibles Framework vorhanden.</target>
<note />
<source>Project '{0}' targets '{2}'. It cannot be referenced by a project that targets '{1}'.</source>
<target state="needs-review-translation">Für das Projekt "{0}" ist kein mit "{1}" kompatibles Framework vorhanden.</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidFrameworkName">
<source>Invalid framework name: '{0}'.</source>
Expand Down Expand Up @@ -98,11 +98,6 @@
<target state="translated">Unerwartete Abhängigkeit "{0}" ohne Versionsnummer.</target>
<note />
</trans-unit>
<trans-unit id="RuntimeIdentifierMustBeSetForNETFramework">
<source>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</source>
<target state="translated">"RuntimeIdentifier" muss für ausführbare .NETFramework-Dateien festgelegt werden. Verwenden Sie ggf. "RuntimeIdentifier=win7-x86" oder "RuntimeIdentifier=win7-x64".</target>
<note />
</trans-unit>
<trans-unit id="AssetPreprocessorMustBeConfigured">
<source>Asset preprocessor must be configured before assets are processed.</source>
<target state="translated">Der Ressourcenpräprozessor muss konfiguriert werden, bevor Ressourcen verarbeitet werden.</target>
Expand Down
11 changes: 3 additions & 8 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/xlf/Strings.es.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<note />
</trans-unit>
<trans-unit id="NoCompatibleTargetFramework">
<source>Project '{0}' has no target framework compatible with '{1}'.</source>
<target state="translated">El proyecto '{0}' no tiene una plataforma de destino compatible con '{1}'.</target>
<note />
<source>Project '{0}' targets '{2}'. It cannot be referenced by a project that targets '{1}'.</source>
<target state="needs-review-translation">El proyecto '{0}' no tiene una plataforma de destino compatible con '{1}'.</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidFrameworkName">
<source>Invalid framework name: '{0}'.</source>
Expand Down Expand Up @@ -98,11 +98,6 @@
<target state="translated">Dependencia '{0}' sin número de versión no esperada.</target>
<note />
</trans-unit>
<trans-unit id="RuntimeIdentifierMustBeSetForNETFramework">
<source>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</source>
<target state="translated">RuntimeIdentifier debe establecerse para archivos ejecutables de .NET Framework. Considere usar RuntimeIdentifier=win7-x86 o RuntimeIdentifier=win7-x64.</target>
<note />
</trans-unit>
<trans-unit id="AssetPreprocessorMustBeConfigured">
<source>Asset preprocessor must be configured before assets are processed.</source>
<target state="translated">Debe configurarse el preprocesador de recursos antes de que se procesen los recursos.</target>
Expand Down
11 changes: 3 additions & 8 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/xlf/Strings.fr.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<note />
</trans-unit>
<trans-unit id="NoCompatibleTargetFramework">
<source>Project '{0}' has no target framework compatible with '{1}'.</source>
<target state="translated">Le projet '{0}' n'a aucun framework cible compatible avec '{1}'.</target>
<note />
<source>Project '{0}' targets '{2}'. It cannot be referenced by a project that targets '{1}'.</source>
<target state="needs-review-translation">Le projet '{0}' n'a aucun framework cible compatible avec '{1}'.</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidFrameworkName">
<source>Invalid framework name: '{0}'.</source>
Expand Down Expand Up @@ -98,11 +98,6 @@
<target state="translated">Dépendance '{0}' sans numéro de version inattendue.</target>
<note />
</trans-unit>
<trans-unit id="RuntimeIdentifierMustBeSetForNETFramework">
<source>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</source>
<target state="translated">RuntimeIdentifier doit être défini pour les exécutables .NET Framework. Considérez RuntimeIdentifier=win7-x86 ou RuntimeIdentifier=win7-x64.</target>
<note />
</trans-unit>
<trans-unit id="AssetPreprocessorMustBeConfigured">
<source>Asset preprocessor must be configured before assets are processed.</source>
<target state="translated">Le préprocesseur de composants doit être configuré avant que les composants ne soient traités.</target>
Expand Down
11 changes: 3 additions & 8 deletions src/Tasks/Microsoft.NET.Build.Tasks/Resources/xlf/Strings.it.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<note />
</trans-unit>
<trans-unit id="NoCompatibleTargetFramework">
<source>Project '{0}' has no target framework compatible with '{1}'.</source>
<target state="translated">Per il progetto '{0}' non esiste alcun framework di destinazione compatibile con '{1}'.</target>
<note />
<source>Project '{0}' targets '{2}'. It cannot be referenced by a project that targets '{1}'.</source>
<target state="needs-review-translation">Per il progetto '{0}' non esiste alcun framework di destinazione compatibile con '{1}'.</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidFrameworkName">
<source>Invalid framework name: '{0}'.</source>
Expand Down Expand Up @@ -98,11 +98,6 @@
<target state="translated">La dipendenza '{0}' è imprevista e non ha numero di versione.</target>
<note />
</trans-unit>
<trans-unit id="RuntimeIdentifierMustBeSetForNETFramework">
<source>RuntimeIdentifier must be set for .NETFramework executables. Consider RuntimeIdentifier=win7-x86 or RuntimeIdentifier=win7-x64.</source>
<target state="translated">Per gli eseguibili di .NET Framework è necessario impostare RuntimeIdentifier. Provare a specificare RuntimeIdentifier=win7-x86 o RuntimeIdentifier=win7-x64.</target>
<note />
</trans-unit>
<trans-unit id="AssetPreprocessorMustBeConfigured">
<source>Asset preprocessor must be configured before assets are processed.</source>
<target state="translated">Prima di elaborare le risorse, è necessario configurare il preprocessore di risorse.</target>
Expand Down
Loading