Skip to content

Commit c0569b3

Browse files
V3.11 fork (#141)
* Update nuspec to preperly reflect 4.6._2_ requirement. * Improve license call out. * Git ignore build pre-processing directory * Fix OutDir/OutputPath handling. Was double-copying in web projects. * Rev to preview2
1 parent 0155ac4 commit c0569b3

5 files changed

Lines changed: 18 additions & 21 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,5 @@ PublishProfiles/
1313
.build/
1414
.testPublish/
1515
msbuild.*
16+
src/packages/**/*.pp/
1617
src/**/tools/Roslyn*/

src/Packages/Microsoft.CodeDom.Providers.DotNetCompilerPlatform/Microsoft.CodeDom.Providers.DotNetCompilerPlatform.nuproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,16 @@
3030
<Destination>tasks</Destination>
3131
</NuGetContent>
3232
<NuGetContent Include="Content\config.install.xdt">
33-
<Destination>content\net46\app.config.install.xdt</Destination>
33+
<Destination>content\net462\app.config.install.xdt</Destination>
3434
</NuGetContent>
3535
<NuGetContent Include="Content\config.install.xdt">
36-
<Destination>content\net46\web.config.install.xdt</Destination>
36+
<Destination>content\net462\web.config.install.xdt</Destination>
3737
</NuGetContent>
3838
<NuGetContent Include="Content\config.uninstall.xdt">
39-
<Destination>content\net46\app.config.uninstall.xdt</Destination>
39+
<Destination>content\net462\app.config.uninstall.xdt</Destination>
4040
</NuGetContent>
4141
<NuGetContent Include="Content\config.uninstall.xdt">
42-
<Destination>content\net46\web.config.uninstall.xdt</Destination>
42+
<Destination>content\net462\web.config.uninstall.xdt</Destination>
4343
</NuGetContent>
4444
<NuGetContent Include="Content\config.install.xdt">
4545
<Destination>content\net472\app.config.install.xdt</Destination>
@@ -57,10 +57,10 @@
5757
<Destination>build\net472</Destination>
5858
</NuGetContent>
5959
<NuGetContent Include="build\*">
60-
<Destination>build\net46</Destination>
60+
<Destination>build\net462</Destination>
6161
</NuGetContent>
6262
<NuGetContent Include="build\net46\*">
63-
<Destination>build\net46</Destination>
63+
<Destination>build\net462</Destination>
6464
</NuGetContent>
6565
<NuGetContent Include="build\net472\*">
6666
<Destination>build\net472</Destination>

src/Packages/Microsoft.CodeDom.Providers.DotNetCompilerPlatform/Microsoft.CodeDom.Providers.DotNetCompilerPlatform.nuspec

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
<projectUrl>https://github.com/aspnet/RoslynCodeDomProvider</projectUrl>
1717
<iconUrl>http://go.microsoft.com/fwlink/?LinkID=288859</iconUrl>
1818
<licenseUrl>https://licenses.nuget.org/MIT</licenseUrl>
19+
<license type="expression">MIT</license>
1920
<requireLicenseAcceptance>true</requireLicenseAcceptance>
2021
<tags>Roslyn CodeDOM Compiler CSharp VB.Net ASP.NET</tags>
2122
</metadata>

src/Packages/Microsoft.CodeDom.Providers.DotNetCompilerPlatform/build/Microsoft.CodeDom.Providers.DotNetCompilerPlatform.targets

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<Import Project="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.Extensions.targets"/>
33

44
<PropertyGroup>
5-
<RoslynCopyToOutDir>true</RoslynCopyToOutDir>
5+
<RoslynCopyToOutDir Condition="$(RoslynCopyToOutDir) == ''">true</RoslynCopyToOutDir>
66
</PropertyGroup>
77

88
<Target Name="SetRoslynCompilerFiles" DependsOnTargets="LocateRoslynCompilerFiles">
@@ -18,35 +18,30 @@
1818
<ItemGroup>
1919
<FilesForPackagingFromProject Include="@(RoslynCompilerFiles)">
2020
<DestinationRelativePath>bin\roslyn\%(RecursiveDir)%(Filename)%(Extension)</DestinationRelativePath>
21+
<DestinationRelativePath Condition=" '$(WebProjectOutputDir)' == '' ">roslyn\%(RecursiveDir)%(Filename)%(Extension)</DestinationRelativePath>
2122
<FromTarget>IncludeRoslynCompilerFilesToFilesForPackagingFromProject</FromTarget>
2223
<Category>Run</Category>
2324
</FilesForPackagingFromProject>
2425
</ItemGroup>
2526
</Target>
2627

2728
<Target Name="LocateRoslynToolsDestinationFolder" Condition=" '$(RoslynToolsDestinationFolder)' == '' ">
28-
<!-- Choose one of WebProjectOutputDir or OutputPath -->
29+
<!-- Choose one of WebProjectOutputDir or OutDir or OutputPath (in that order of preference) -->
30+
<!-- OutDir and OutputPath are confusing... but usually they are the same. When they differ
31+
it's likely because somebody is mucking with some intermediate details, but the ultimate
32+
output destination should be OutDir. For non-web projects. So use that if it exists. -->
2933
<PropertyGroup>
3034
<RoslynToolsDestinationFolder>$(WebProjectOutputDir)\bin\roslyn</RoslynToolsDestinationFolder>
31-
<RoslynToolsDestinationFolder Condition=" '$(WebProjectOutputDir)' == '' ">$(OutputPath)\roslyn</RoslynToolsDestinationFolder>
32-
</PropertyGroup>
33-
34-
<!-- But when OutDir is specified there as well -->
35-
<PropertyGroup Condition="'$(OutDir)' != ''">
36-
<RoslynToolsOutDirFolder>$(OutDir)\bin\roslyn</RoslynToolsOutDirFolder>
37-
<RoslynToolsOutDirFolder Condition=" '$(WebProjectOutputDir)' == '' ">$(OutDir)\roslyn</RoslynToolsOutDirFolder>
35+
<RoslynToolsDestinationFolder Condition=" '$(WebProjectOutputDir)' == '' ">$(OutDir)\roslyn</RoslynToolsDestinationFolder>
36+
<RoslynToolsDestinationFolder Condition=" '$(WebProjectOutputDir)' == '' AND '$(OutDir)' == '' ">$(OutputPath)\roslyn</RoslynToolsDestinationFolder>
3837
</PropertyGroup>
3938
</Target>
4039

41-
<Target Name="CopyRoslynCompilerFilesToOutputDirectory" AfterTargets="CopyFilesToOutputDirectory" DependsOnTargets="LocateRoslynToolsDestinationFolder;SetRoslynCompilerFiles">
40+
<Target Name="CopyRoslynCompilerFilesToOutputDirectory" AfterTargets="CopyFilesToOutputDirectory" DependsOnTargets="LocateRoslynToolsDestinationFolder;SetRoslynCompilerFiles" Condition="$(RoslynCopyToOutDir) == 'true'">
4241
<Copy SourceFiles="@(RoslynCompilerFiles)" DestinationFolder="$(RoslynToolsDestinationFolder)" ContinueOnError="true" SkipUnchangedFiles="true" Retries="0" />
4342
<ItemGroup Condition="'$(MSBuildLastTaskResult)' == 'True'" >
4443
<FileWrites Include="$(RoslynToolsDestinationFolder)\*" />
4544
</ItemGroup>
46-
<Copy SourceFiles="@(RoslynCompilerFiles)" DestinationFolder="$(RoslynToolsOutDirFolder)" Condition="'$(RoslynToolsOutDirFolder)' != '$(RoslynToolsDestinationFolder)'" ContinueOnError="true" SkipUnchangedFiles="true" Retries="0" />
47-
<ItemGroup Condition="'$(RoslynToolsOutDirFolder)' != '$(RoslynToolsDestinationFolder)' AND '$(MSBuildLastTaskResult)' == 'True'" >
48-
<FileWrites Include="$(RoslynToolsOutDirFolder)\*" />
49-
</ItemGroup>
5045
</Target>
5146

5247
<Target Name="CheckIfShouldKillVBCSCompiler" DependsOnTargets="LocateRoslynCompilerFiles;LocateRoslynToolsDestinationFolder">

tools/RoslynCodeProvider.settings.targets

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
<!-- Configurable properties-->
1111

1212
<PropertyGroup>
13-
<BuildQuality Condition="'$(BuildQuality)' == ''">preview1</BuildQuality>
13+
<BuildQuality Condition="'$(BuildQuality)' == ''">preview2</BuildQuality>
1414
<VersionStartYear>2022</VersionStartYear>
1515
<VersionMajor>3</VersionMajor>
1616
<VersionMinor>11</VersionMinor>

0 commit comments

Comments
 (0)