Skip to content

Commit

Permalink
Fix of issue 4051: Nuget.targets broken on mono xbuild
Browse files Browse the repository at this point in the history
- Don't use property functions on mono xbuild since they are not supported.
- Also, replace <Choose> since again, it's not well supported on mono xbuild.
  • Loading branch information
feiling committed Mar 4, 2014
1 parent 89edd98 commit 3fc9e44
Showing 1 changed file with 6 additions and 13 deletions.
19 changes: 6 additions & 13 deletions src/Build/NuGet.targets
Original file line number Diff line number Diff line change
Expand Up @@ -36,21 +36,14 @@
</PropertyGroup>

<PropertyGroup>
<PackagesProjectConfig>$(MSBuildProjectDirectory)\packages.$(MSBuildProjectName.Replace(' ', '_')).config</PackagesProjectConfig>
<PackagesProjectConfig Condition=" '$(OS)' == 'Windows_NT'">$(MSBuildProjectDirectory)\packages.$(MSBuildProjectName.Replace(' ', '_')).config</PackagesProjectConfig>
<PackagesProjectConfig Condition=" '$(OS)' != 'Windows_NT'">$(MSBuildProjectDirectory)\packages.$(MSBuildProjectName).config</PackagesProjectConfig>
</PropertyGroup>

<Choose>
<When Condition="Exists('$(PackagesProjectConfig)')">
<PropertyGroup>
<PackagesConfig>$(PackagesProjectConfig)</PackagesConfig>
</PropertyGroup>
</When>
<When Condition="Exists('$(MSBuildProjectDirectory)\packages.config')">
<PropertyGroup>
<PackagesConfig>$(MSBuildProjectDirectory)\packages.config</PackagesConfig>
</PropertyGroup>
</When>
</Choose>
<PropertyGroup>
<PackagesConfig Condition="Exists('$(PackagesProjectConfig)')">$(PackagesProjectConfig)</PackagesConfig>
<PackagesConfig Condition="Exists('$(MSBuildProjectDirectory)\packages.config')">$(MSBuildProjectDirectory)\packages.config</PackagesConfig>
</PropertyGroup>

<PropertyGroup>
<!-- NuGet command -->
Expand Down

0 comments on commit 3fc9e44

Please sign in to comment.