[genproj] Simplify strong name key handling
authorAlexander Köplinger <alex.koeplinger@outlook.com>
Mon, 7 Aug 2017 15:54:30 +0000 (17:54 +0200)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Mon, 7 Aug 2017 20:10:58 +0000 (22:10 +0200)
It doesn't need to be in a separate PropertyGroup.

msvc/scripts/csproj.tmpl
msvc/scripts/genproj.cs

index 1b2e850e5e3330287beaf5c14cbcf1efaf54ff79..b43ad7901c12614d27dcc78e061ff40e49b41dd2 100644 (file)
@@ -25,8 +25,8 @@
     <AssemblyName>@ASSEMBLYNAME@</AssemblyName>\r
     <TargetFrameworkVersion>v@FX_VERSION</TargetFrameworkVersion>\r
     <FileAlignment>512</FileAlignment>\r
+@SIGNATURE@\r
   </PropertyGroup>\r
-  @SIGNATURE@\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
index 378d1c00db7210c098bc3bd9b84f275633f77e4b..c60bc5397ce28ad027f8856df3061ebfad69d4f6 100644 (file)
@@ -915,13 +915,10 @@ class MsbuildGenerator {
                string strongNameSection = "";
                if (StrongNameKeyFile != null){
                        strongNameSection = String.Format (
-                               "  <PropertyGroup>" + NewLine +
                                "    <SignAssembly>true</SignAssembly>" + NewLine +
                                "{1}" +
-                               "  </PropertyGroup>" + NewLine +
-                               "  <PropertyGroup>" + NewLine +
-                               "    <AssemblyOriginatorKeyFile>{0}</AssemblyOriginatorKeyFile>" + NewLine +
-                               "  </PropertyGroup>", StrongNameKeyFile, StrongNameDelaySign ? "    <DelaySign>true</DelaySign>" + NewLine : "");
+                               "    <AssemblyOriginatorKeyFile>{0}</AssemblyOriginatorKeyFile>",
+                               StrongNameKeyFile, StrongNameDelaySign ? "    <DelaySign>true</DelaySign>" + NewLine : "");
                }
                Csproj.output = template.
                        Replace ("@OUTPUTTYPE@", Target == Target.Library ? "Library" : "Exe").