From 800db7730eb6d409fce3712191e3714d87a9554e Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 13:44:03 +0100 Subject: [PATCH 01/14] Add blank dnne-analyzers project --- DNNE.sln | 6 ++++++ src/dnne-analyzers/Class1.cs | 9 +++++++++ src/dnne-analyzers/dnne-analyzers.csproj | 8 ++++++++ 3 files changed, 23 insertions(+) create mode 100644 src/dnne-analyzers/Class1.cs create mode 100644 src/dnne-analyzers/dnne-analyzers.csproj diff --git a/DNNE.sln b/DNNE.sln index ecd656b..f4fe97e 100644 --- a/DNNE.sln +++ b/DNNE.sln @@ -21,6 +21,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "platform", "platform", "{95 src\platform\platform.c = src\platform\platform.c EndProjectSection EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "dnne-analyzers", "src\dnne-analyzers\dnne-analyzers.csproj", "{2A4C07AB-EAA1-4B80-8A80-BD2DB6375C35}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -47,6 +49,10 @@ Global {451402EC-4AE5-425A-9835-9D36A55E8081}.Debug|Any CPU.Build.0 = Debug|Any CPU {451402EC-4AE5-425A-9835-9D36A55E8081}.Release|Any CPU.ActiveCfg = Release|Any CPU {451402EC-4AE5-425A-9835-9D36A55E8081}.Release|Any CPU.Build.0 = Release|Any CPU + {2A4C07AB-EAA1-4B80-8A80-BD2DB6375C35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {2A4C07AB-EAA1-4B80-8A80-BD2DB6375C35}.Debug|Any CPU.Build.0 = Debug|Any CPU + {2A4C07AB-EAA1-4B80-8A80-BD2DB6375C35}.Release|Any CPU.ActiveCfg = Release|Any CPU + {2A4C07AB-EAA1-4B80-8A80-BD2DB6375C35}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/src/dnne-analyzers/Class1.cs b/src/dnne-analyzers/Class1.cs new file mode 100644 index 0000000..16eee1c --- /dev/null +++ b/src/dnne-analyzers/Class1.cs @@ -0,0 +1,9 @@ +using System; + +namespace dnne_analyzers +{ + public class Class1 + { + + } +} diff --git a/src/dnne-analyzers/dnne-analyzers.csproj b/src/dnne-analyzers/dnne-analyzers.csproj new file mode 100644 index 0000000..7f5f08b --- /dev/null +++ b/src/dnne-analyzers/dnne-analyzers.csproj @@ -0,0 +1,8 @@ + + + + netstandard2.0 + DNNE + + + From 1a62db3250b8ed1aa6f88095fa01e78d26bd2d40 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 13:51:23 +0100 Subject: [PATCH 02/14] Add Roslyn dependencies and basic setup --- src/dnne-analyzers/AnalyzerReleases.Shipped.md | 9 +++++++++ src/dnne-analyzers/AnalyzerReleases.Unshipped.md | 2 ++ src/dnne-analyzers/dnne-analyzers.csproj | 10 ++++++++++ 3 files changed, 21 insertions(+) create mode 100644 src/dnne-analyzers/AnalyzerReleases.Shipped.md create mode 100644 src/dnne-analyzers/AnalyzerReleases.Unshipped.md diff --git a/src/dnne-analyzers/AnalyzerReleases.Shipped.md b/src/dnne-analyzers/AnalyzerReleases.Shipped.md new file mode 100644 index 0000000..85c2ce9 --- /dev/null +++ b/src/dnne-analyzers/AnalyzerReleases.Shipped.md @@ -0,0 +1,9 @@ +; Shipped analyzer releases +; https://github.com/dotnet/roslyn-analyzers/blob/master/src/Microsoft.CodeAnalysis.Analyzers/ReleaseTrackingAnalyzers.Help.md + +## Release 1.0 + +### New Rules + +Rule ID | Category | Severity | Notes +--------|----------|----------|------- diff --git a/src/dnne-analyzers/AnalyzerReleases.Unshipped.md b/src/dnne-analyzers/AnalyzerReleases.Unshipped.md new file mode 100644 index 0000000..6a6dd08 --- /dev/null +++ b/src/dnne-analyzers/AnalyzerReleases.Unshipped.md @@ -0,0 +1,2 @@ +; Unshipped analyzer release +; https://github.com/dotnet/roslyn-analyzers/blob/master/src/Microsoft.CodeAnalysis.Analyzers/ReleaseTrackingAnalyzers.Help.md diff --git a/src/dnne-analyzers/dnne-analyzers.csproj b/src/dnne-analyzers/dnne-analyzers.csproj index 7f5f08b..abfac91 100644 --- a/src/dnne-analyzers/dnne-analyzers.csproj +++ b/src/dnne-analyzers/dnne-analyzers.csproj @@ -3,6 +3,16 @@ netstandard2.0 DNNE + 11.0 + + + + + + + + + From f78990cd1675239138c21287acb372eb56ffbc68 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 13:51:35 +0100 Subject: [PATCH 03/14] Add AttributesGenerator type to emit attributes --- src/dnne-analyzers/AttributesGenerator.cs | 65 +++++++++++++++++++++++ src/dnne-analyzers/Class1.cs | 9 ---- 2 files changed, 65 insertions(+), 9 deletions(-) create mode 100644 src/dnne-analyzers/AttributesGenerator.cs delete mode 100644 src/dnne-analyzers/Class1.cs diff --git a/src/dnne-analyzers/AttributesGenerator.cs b/src/dnne-analyzers/AttributesGenerator.cs new file mode 100644 index 0000000..e5ac099 --- /dev/null +++ b/src/dnne-analyzers/AttributesGenerator.cs @@ -0,0 +1,65 @@ +using Microsoft.CodeAnalysis; + +namespace DNNE; + +/// +/// A generator that generates all the necessary DNNE attributes. +/// +[Generator(LanguageNames.CSharp)] +public sealed class AttributesGenerator : IIncrementalGenerator +{ + /// + public void Initialize(IncrementalGeneratorInitializationContext context) + { + context.RegisterPostInitializationOutput(static context => + { + context.AddSource("DnneAttributes.g.cs", """ + // + #pragma warning disable + + namespace DNNE + { + /// + /// Provides C code to be defined early in the generated C header file. + /// + /// + /// This attribute is respected on an exported method declaration or on a parameter for the method. + /// The following header files will be included prior to the code being defined. + /// + /// stddef.h + /// stdint.h + /// dnne.h + /// + /// + internal sealed class C99DeclCodeAttribute : global::System.Attribute + { + /// + /// Creates a new instance with the specified parameters. + /// + /// The C code to be defined in the generated C header file. + public C99DeclCodeAttribute(string code) + { + } + } + + /// + /// Defines the C type to be used. + /// + /// + /// The level of indirection should be included in the supplied string. + /// + internal sealed class C99TypeAttribute : global::System.Attribute + { + /// + /// Creates a new instance with the specified parameters. + /// + /// The C type to be used. + public C99TypeAttribute(string code) + { + } + } + } + """); + }); + } +} diff --git a/src/dnne-analyzers/Class1.cs b/src/dnne-analyzers/Class1.cs deleted file mode 100644 index 16eee1c..0000000 --- a/src/dnne-analyzers/Class1.cs +++ /dev/null @@ -1,9 +0,0 @@ -using System; - -namespace dnne_analyzers -{ - public class Class1 - { - - } -} From 7abe0e95518810f91f689208c3c22f9fc0d886b2 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 15:56:02 +0100 Subject: [PATCH 04/14] Add DNNE.Analyzers.targets file --- src/dnne-analyzers/DNNE.Analyzers.targets | 105 ++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 src/dnne-analyzers/DNNE.Analyzers.targets diff --git a/src/dnne-analyzers/DNNE.Analyzers.targets b/src/dnne-analyzers/DNNE.Analyzers.targets new file mode 100644 index 0000000..ae0bdb5 --- /dev/null +++ b/src/dnne-analyzers/DNNE.Analyzers.targets @@ -0,0 +1,105 @@ + + + + + + <_DnneAnalyzer Include="@(Analyzer)" Condition="'%(Analyzer.NuGetPackageId)' == 'DNNE'" /> + + + + + + + + + + + + + + + @(DnneCurrentCompilerAssemblyIdentity->'%(Version)') + + + true + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + + + + + + + + true + + + + + + + From 664eb31f2992091d76c58d54c787914fde22044c Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 16:05:26 +0100 Subject: [PATCH 05/14] Wire up source generator to build setup --- src/dnne-pkg/dnne-pkg.csproj | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/dnne-pkg/dnne-pkg.csproj b/src/dnne-pkg/dnne-pkg.csproj index af2ba2b..da08f11 100644 --- a/src/dnne-pkg/dnne-pkg.csproj +++ b/src/dnne-pkg/dnne-pkg.csproj @@ -1,4 +1,4 @@ - + net6.0 @@ -37,6 +37,9 @@ + + false + TargetFramework=$(TargetFramework) false @@ -66,6 +69,7 @@ + @@ -76,6 +80,15 @@ + + + + + From 79e5e0906085ca8a7f770953faf1623a7f59ed7e Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 18:06:08 +0100 Subject: [PATCH 06/14] Use .NET 7 SDK in the CI script --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 0b95263..e2d8768 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -21,7 +21,7 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v1 with: - dotnet-version: '6.0.x' + dotnet-version: '7.0.x' include-prerelease: true - name: Build Product and Package run: dotnet build src/create_package.proj -c ${{ matrix.flavor }} @@ -51,7 +51,7 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v1 with: - dotnet-version: '6.0.x' + dotnet-version: '7.0.x' include-prerelease: true - name: Build Product and Package run: dotnet build src\create_package.proj -c ${{ matrix.flavor }} @@ -76,7 +76,7 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v1 with: - dotnet-version: '6.0.x' + dotnet-version: '7.0.x' include-prerelease: true - name: Build Product and Package run: dotnet build src/create_package.proj -c ${{ matrix.flavor }} From e72cd264d28b8049eb3bb3b8c290e37c4fc05d9a Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 18:39:05 +0100 Subject: [PATCH 07/14] Add ExportAttribute to the generated attributes --- src/dnne-analyzers/AttributesGenerator.cs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/dnne-analyzers/AttributesGenerator.cs b/src/dnne-analyzers/AttributesGenerator.cs index e5ac099..e9e61d0 100644 --- a/src/dnne-analyzers/AttributesGenerator.cs +++ b/src/dnne-analyzers/AttributesGenerator.cs @@ -19,6 +19,24 @@ public void Initialize(IncrementalGeneratorInitializationContext context) namespace DNNE { + /// + /// Defines a C export. Can be used when updating to use UnmanagedCallersOnlyAttribute would take more time. + /// + internal sealed class ExportAttribute : global::System.Attribute + { + /// + /// Creates a new instance. + /// + public ExportAttribute() + { + } + + /// + /// Gets or sets the entry point to use to produce the C export. + /// + public string EntryPoint { get; set; } + } + /// /// Provides C code to be defined early in the generated C header file. /// From 889f8c4b83655779d72ea7aa71086aa03e979ee0 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 18:39:35 +0100 Subject: [PATCH 08/14] Update unit tests, remove local attributes --- test/DNNE.UnitTests/DNNE.UnitTests.csproj | 2 +- test/ExportingAssembly/Dnne.Attributes.cs | 39 ------------------- .../ExportingAssembly.csproj | 1 - 3 files changed, 1 insertion(+), 41 deletions(-) delete mode 100644 test/ExportingAssembly/Dnne.Attributes.cs diff --git a/test/DNNE.UnitTests/DNNE.UnitTests.csproj b/test/DNNE.UnitTests/DNNE.UnitTests.csproj index aae19f3..84977f5 100644 --- a/test/DNNE.UnitTests/DNNE.UnitTests.csproj +++ b/test/DNNE.UnitTests/DNNE.UnitTests.csproj @@ -1,7 +1,7 @@ - net6.0 + net7.0 true false diff --git a/test/ExportingAssembly/Dnne.Attributes.cs b/test/ExportingAssembly/Dnne.Attributes.cs deleted file mode 100644 index 93a2750..0000000 --- a/test/ExportingAssembly/Dnne.Attributes.cs +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright 2020 Aaron R Robinson -// -// Permission is hereby granted, free of charge, to any person obtaining a copy -// of this software and associated documentation files (the "Software"), to deal -// in the Software without restriction, including without limitation the rights -// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -// copies of the Software, and to permit persons to whom the Software is furnished -// to do so, subject to the following conditions: -// -// The above copyright notice and this permission notice shall be included in all -// copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, -// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A -// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT -// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -using System; - -namespace DNNE -{ - internal class ExportAttribute : System.Attribute - { - public ExportAttribute() { } - public string EntryPoint { get; set; } - } - - internal class C99TypeAttribute : System.Attribute - { - public C99TypeAttribute(string code) { } - } - - internal class C99DeclCodeAttribute : System.Attribute - { - public C99DeclCodeAttribute(string code) { } - } -} \ No newline at end of file diff --git a/test/ExportingAssembly/ExportingAssembly.csproj b/test/ExportingAssembly/ExportingAssembly.csproj index 986be29..9e97658 100644 --- a/test/ExportingAssembly/ExportingAssembly.csproj +++ b/test/ExportingAssembly/ExportingAssembly.csproj @@ -30,7 +30,6 @@ - From ae5997599572c6b4b94b972abc886b7cac533a06 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sun, 5 Nov 2023 18:50:19 +0100 Subject: [PATCH 09/14] Reference analyzer directly in test project if needed --- test/ExportingAssembly/ExportingAssembly.csproj | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/ExportingAssembly/ExportingAssembly.csproj b/test/ExportingAssembly/ExportingAssembly.csproj index 9e97658..34fe2dd 100644 --- a/test/ExportingAssembly/ExportingAssembly.csproj +++ b/test/ExportingAssembly/ExportingAssembly.csproj @@ -40,4 +40,9 @@ + + + + + From 7d42f57b1b67d79e2654c995a98a805660a0e02e Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Mon, 6 Nov 2023 11:26:43 +0100 Subject: [PATCH 10/14] Add [AttributeUsage] to generated attributes --- src/dnne-analyzers/AttributesGenerator.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dnne-analyzers/AttributesGenerator.cs b/src/dnne-analyzers/AttributesGenerator.cs index e9e61d0..6bd0221 100644 --- a/src/dnne-analyzers/AttributesGenerator.cs +++ b/src/dnne-analyzers/AttributesGenerator.cs @@ -22,6 +22,7 @@ namespace DNNE /// /// Defines a C export. Can be used when updating to use UnmanagedCallersOnlyAttribute would take more time. /// + [global::System.AttributeUsage(global::System.AttributeTargets.Method, Inherited = false)] internal sealed class ExportAttribute : global::System.Attribute { /// @@ -49,6 +50,7 @@ public ExportAttribute() /// dnne.h /// /// + [global::System.AttributeUsage(global::System.AttributeTargets.Method | global::System.AttributeTargets.Parameter, Inherited = false)] internal sealed class C99DeclCodeAttribute : global::System.Attribute { /// @@ -66,6 +68,7 @@ public C99DeclCodeAttribute(string code) /// /// The level of indirection should be included in the supplied string. /// + [global::System.AttributeUsage(global::System.AttributeTargets.Parameter | global::System.AttributeTargets.ReturnValue, Inherited = false)] internal sealed class C99TypeAttribute : global::System.Attribute { /// From 68edb508465de703583fe4609e2aa7ab269897be Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Mon, 6 Nov 2023 11:27:37 +0100 Subject: [PATCH 11/14] Add [ExcludeFromCodeCoverage] to generated attributes --- src/dnne-analyzers/AttributesGenerator.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dnne-analyzers/AttributesGenerator.cs b/src/dnne-analyzers/AttributesGenerator.cs index 6bd0221..7ab906e 100644 --- a/src/dnne-analyzers/AttributesGenerator.cs +++ b/src/dnne-analyzers/AttributesGenerator.cs @@ -23,6 +23,7 @@ namespace DNNE /// Defines a C export. Can be used when updating to use UnmanagedCallersOnlyAttribute would take more time. /// [global::System.AttributeUsage(global::System.AttributeTargets.Method, Inherited = false)] + [global::System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] internal sealed class ExportAttribute : global::System.Attribute { /// @@ -51,6 +52,7 @@ public ExportAttribute() /// /// [global::System.AttributeUsage(global::System.AttributeTargets.Method | global::System.AttributeTargets.Parameter, Inherited = false)] + [global::System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] internal sealed class C99DeclCodeAttribute : global::System.Attribute { /// @@ -69,6 +71,7 @@ public C99DeclCodeAttribute(string code) /// The level of indirection should be included in the supplied string. /// [global::System.AttributeUsage(global::System.AttributeTargets.Parameter | global::System.AttributeTargets.ReturnValue, Inherited = false)] + [global::System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] internal sealed class C99TypeAttribute : global::System.Attribute { /// From bcb34573af558d0fad7d7a6cf2beb07c571a8795 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Mon, 6 Nov 2023 11:35:05 +0100 Subject: [PATCH 12/14] Update readme --- readme.md | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/readme.md b/readme.md index bfe4e5f..b684b3a 100644 --- a/readme.md +++ b/readme.md @@ -83,7 +83,7 @@ struct some_data }; ``` -The following attributes can be used to enable the above scenario. They must be defined by the project in order to be used - DNNE provides no assembly to reference. Refer to [`ExportingAssembly`](./test/ExportingAssembly/Dnne.Attributes.cs) for an example. +The following attributes can be used to enable the above scenario. They are automatically generated into projects referencing DNNE, because DNNE provides no assembly to reference. If your build system or IDE does not support source generators (eg. you're using an older version than VS 2022, or .NET Framework with `packages.config`), you will have to define these types yourself: ```CSharp namespace DNNE @@ -98,7 +98,8 @@ namespace DNNE /// - stdint.h /// - dnne.h /// - internal class C99DeclCodeAttribute : System.Attribute + [AttributeUsage(AttributeTargets.Method | AttributeTargets.Parameter, Inherited = false)] + internal sealed class C99DeclCodeAttribute : System.Attribute { public C99DeclCodeAttribute(string code) { } } @@ -109,7 +110,8 @@ namespace DNNE /// /// The level of indirection should be included in the supplied string. /// - internal class C99TypeAttribute : System.Attribute + [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.ReturnValue, Inherited = false)] + internal sealed class C99TypeAttribute : System.Attribute { public C99TypeAttribute(string code) { } } @@ -196,12 +198,13 @@ In addition to providing declaration code directly, users can also supply `#incl ### Experimental attribute -There are scenarios where updating `UnmanagedCallersOnlyAttribute` may take time. In order to enable independent development and experimentation, the `DNNE.ExportAttribute` is also respected. This type can be modified to suit one's needs and `dnne-gen` updated to respect those changes at source gen time. The user should define the following in their assembly. They can then modify the attribute and `dnne-gen` as needed. +There are scenarios where updating `UnmanagedCallersOnlyAttribute` may take time. In order to enable independent development and experimentation, the `DNNE.ExportAttribute` is also respected. Like other DNNE attributes, this type is also automatically generated into projects referencing the DNNE package. This type can be modified to suit one's needs (by tweaking the generated source in `dnne-analyzers`) and `dnne-gen` updated as needed to respect those changes at source gen time. ``` CSharp namespace DNNE { - internal class ExportAttribute : Attribute + [AttributeUsage(AttributeTargets.Method, Inherited = false)] + internal sealed class ExportAttribute : Attribute { public ExportAttribute() { } public string EntryPoint { get; set; } From c08760e13021e5a3ae474855af7662a82fee46a5 Mon Sep 17 00:00:00 2001 From: Aaron Robinson Date: Mon, 6 Nov 2023 06:22:17 -0800 Subject: [PATCH 13/14] Update readme.md --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index b684b3a..a17dd7a 100644 --- a/readme.md +++ b/readme.md @@ -83,7 +83,7 @@ struct some_data }; ``` -The following attributes can be used to enable the above scenario. They are automatically generated into projects referencing DNNE, because DNNE provides no assembly to reference. If your build system or IDE does not support source generators (eg. you're using an older version than VS 2022, or .NET Framework with `packages.config`), you will have to define these types yourself: +The following attributes can be used to enable the above scenario. They are automatically generated into projects referencing DNNE, because DNNE provides no assembly to reference. If your build system or IDE does not support source generators (e.g., you're using a version older than Visual Studio 2022, or .NET Framework with `packages.config`), you will have to define these types yourself: ```CSharp namespace DNNE From 84ed6d27216fa5191e65a9f448fbac4582bb8caa Mon Sep 17 00:00:00 2001 From: Aaron R Robinson Date: Mon, 6 Nov 2023 09:28:58 -0800 Subject: [PATCH 14/14] Fix pseudo package scenario. Import new targets file using DNNE.targets --- src/dnne-pkg/dnne-pkg.csproj | 13 ++++--------- src/msbuild/DNNE.targets | 2 ++ test/ExportingAssembly/ExportingAssembly.csproj | 12 +++++++----- 3 files changed, 13 insertions(+), 14 deletions(-) diff --git a/src/dnne-pkg/dnne-pkg.csproj b/src/dnne-pkg/dnne-pkg.csproj index da08f11..7f390f8 100644 --- a/src/dnne-pkg/dnne-pkg.csproj +++ b/src/dnne-pkg/dnne-pkg.csproj @@ -60,6 +60,8 @@ $(BuildDest)net472/ $(PseudoPackageRoot)tools/ $(ToolsDest)platform/ + $(PseudoPackageRoot)analyzers/ + $(AnalyzersDest)dotnet/cs @@ -74,21 +76,14 @@ + - - - - - + diff --git a/src/msbuild/DNNE.targets b/src/msbuild/DNNE.targets index 3b13ed9..ef9c09f 100644 --- a/src/msbuild/DNNE.targets +++ b/src/msbuild/DNNE.targets @@ -23,6 +23,8 @@ DNNE.targets --> + + $(DnneNativeBinaryName) diff --git a/test/ExportingAssembly/ExportingAssembly.csproj b/test/ExportingAssembly/ExportingAssembly.csproj index 34fe2dd..9d2aff5 100644 --- a/test/ExportingAssembly/ExportingAssembly.csproj +++ b/test/ExportingAssembly/ExportingAssembly.csproj @@ -4,6 +4,10 @@ $(PseudoPackage)build/DNNE.targets + + + + @@ -15,6 +19,9 @@ 1591 + + true + true true /TP @@ -40,9 +47,4 @@ - - - - -