Skip to content

Commit 44e58f1

Browse files
committed
Fix and improve nuget packaging
(1) Fix constants override that was wiping out the CLR2 symbol on 3.5 compiles (2) Minimize artifacts included in nuget package
1 parent 1f7ec4c commit 44e58f1

File tree

4 files changed

+22
-18
lines changed

4 files changed

+22
-18
lines changed

Clojure.nuspec

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
33
<metadata>
44
<id>Clojure</id>
5-
<version>1.5.0.0</version>
5+
<version>1.5.0.1</version>
66
<authors>Rich Hickey, Clojure</authors>
77
<requireLicenseAcceptance>false</requireLicenseAcceptance>
88
<licenseUrl>http://opensource.org/licenses/eclipse-1.0.php</licenseUrl>
@@ -12,19 +12,16 @@
1212
<tags>clojure clojureclr</tags>
1313
</metadata>
1414
<files>
15-
<file src="bin\4.0\Release\ilmerge\*" target="lib\net40" />
16-
<file src="bin\4.0\Release\Microsoft.Dynamic.*" target="lib\net40" />
17-
<file src="bin\4.0\Release\Microsoft.Scripting.*" target="lib\net40" />
15+
<file src="bin\4.0\Release\ilmerge\Clojure.dll" target="lib\net40" />
16+
<file src="bin\4.0\Release\Microsoft.Dynamic.dll" target="lib\net40" />
17+
<file src="bin\4.0\Release\Microsoft.Scripting.dll" target="lib\net40" />
1818
<file src="bin\4.0\Release\Clojure.Main.exe" target="tools\net40" />
19-
<file src="bin\4.0\Release\Clojure.Main.pdb" target="tools\net40" />
2019
<file src="bin\4.0\Release\Clojure.Compile.exe" target="tools\net40" />
21-
<file src="bin\4.0\Release\Clojure.Compile.pdb" target="tools\net40" />
22-
<file src="bin\3.5\Release\ilmerge\*" target="lib\net35" />
23-
<file src="bin\3.5\Release\Microsoft.Dynamic.*" target="lib\net35" />
24-
<file src="bin\3.5\Release\Microsoft.Scripting.*" target="lib\net35" />
20+
<file src="bin\3.5\Release\ilmerge\Clojure.dll" target="lib\net35" />
21+
<file src="bin\3.5\Release\Microsoft.Dynamic.dll" target="lib\net35" />
22+
<file src="bin\3.5\Release\Microsoft.Scripting.dll" target="lib\net35" />
23+
<file src="bin\3.5\Release\Microsoft.Scripting.Core.dll" target="lib\net35" />
2524
<file src="bin\3.5\Release\Clojure.Main.exe" target="tools\net35" />
26-
<file src="bin\3.5\Release\Clojure.Main.pdb" target="tools\net35" />
2725
<file src="bin\3.5\Release\Clojure.Compile.exe" target="tools\net35" />
28-
<file src="bin\3.5\Release\Clojure.Compile.pdb" target="tools\net35" />
2926
</files>
3027
</package>

Clojure/Clojure.Compile/Clojure.Compile.csproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,4 +135,7 @@
135135
<PostBuildEvent Condition=" '$(Runtime)' == 'Mono' ">mono "$(TargetPath)" clojure.core clojure.core.protocols clojure.main clojure.set clojure.zip clojure.walk clojure.stacktrace clojure.template clojure.test clojure.test.tap clojure.test.junit clojure.pprint clojure.clr.io clojure.repl clojure.clr.shell clojure.string clojure.data clojure.reflect</PostBuildEvent>
136136
<PostBuildEvent Condition=" '$(Runtime)' == '.Net' ">"$(TargetPath)" clojure.core clojure.core.protocols clojure.main clojure.set clojure.zip clojure.walk clojure.stacktrace clojure.template clojure.test clojure.test.tap clojure.test.junit clojure.pprint clojure.clr.io clojure.repl clojure.clr.shell clojure.string clojure.data clojure.reflect</PostBuildEvent>
137137
</PropertyGroup>
138+
<PropertyGroup>
139+
<PostBuildEvent>"$(TargetPath)" clojure.core clojure.core.protocols clojure.main clojure.set clojure.zip clojure.walk clojure.stacktrace clojure.template clojure.test clojure.test.tap clojure.test.junit clojure.pprint clojure.clr.io clojure.repl clojure.clr.shell clojure.string clojure.data clojure.reflect clojure.edn</PostBuildEvent>
140+
</PropertyGroup>
138141
</Project>

Clojure/Clojure/Clojure.csproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
<DebugType>full</DebugType>
4141
<Optimize>false</Optimize>
4242
<OutputPath>..\..\bin\3.5\Debug\</OutputPath>
43-
<DefineConstants>TRACE;DEBUG;CLR2</DefineConstants>
43+
<DefineConstants>$(PlatformSym);TRACE;DEBUG;CLR2</DefineConstants>
4444
<ErrorReport>prompt</ErrorReport>
4545
<WarningLevel>4</WarningLevel>
4646
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
@@ -50,7 +50,7 @@
5050
<DebugType>pdbonly</DebugType>
5151
<Optimize>true</Optimize>
5252
<OutputPath>..\..\bin\3.5\Release\</OutputPath>
53-
<DefineConstants>TRACE;CLR2</DefineConstants>
53+
<DefineConstants>$(PlatformSym);TRACE;CLR2</DefineConstants>
5454
<ErrorReport>prompt</ErrorReport>
5555
<WarningLevel>4</WarningLevel>
5656
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
@@ -61,7 +61,7 @@
6161
<DebugType>full</DebugType>
6262
<Optimize>false</Optimize>
6363
<OutputPath>..\..\bin\4.0\Debug\</OutputPath>
64-
<DefineConstants>TRACE;DEBUG;CODE_ANALYSIS</DefineConstants>
64+
<DefineConstants>$(PlatformSym);TRACE;DEBUG;CODE_ANALYSIS</DefineConstants>
6565
<ErrorReport>prompt</ErrorReport>
6666
<WarningLevel>4</WarningLevel>
6767
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
@@ -71,7 +71,7 @@
7171
<DebugType>pdbonly</DebugType>
7272
<Optimize>true</Optimize>
7373
<OutputPath>..\..\bin\4.0\Release\</OutputPath>
74-
<DefineConstants>TRACE</DefineConstants>
74+
<DefineConstants>$(PlatformSym);TRACE</DefineConstants>
7575
<ErrorReport>prompt</ErrorReport>
7676
<WarningLevel>4</WarningLevel>
7777
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>

Clojure/build.proj

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,12 @@
66
<cljc>Clojure.Compile.exe</cljc>
77
<clji>Clojure.Main.exe</clji>
88
<Runtime Condition=" '$(Runtime)' == '' ">.Net</Runtime>
9-
<DefineConstants Condition=" '$(Runtime)' == 'Mono' ">MONO</DefineConstants>
10-
<DefineConstants Condition=" '$(Runtime)' == '.Net' ">DOTNET</DefineConstants>
9+
<!--
10+
<DefineConstants Condition=" '$(Runtime)' == 'Mono' ">MONO</DefineConstants>
11+
<DefineConstants Condition=" '$(Runtime)' == '.Net' ">DOTNET</DefineConstants>
12+
-->
13+
<PlatformSym Condition=" '$(Runtime)' == 'Mono' ">MONO</PlatformSym>
14+
<PlatformSym Condition=" '$(Runtime)' == '.Net' ">DOTNET</PlatformSym>
1115
</PropertyGroup>
1216

1317
<!--Is there a way to avoid this duplication? This is also encoded in the project files, although relative to a different path -->
@@ -26,7 +30,7 @@
2630

2731
<Target Name="Build">
2832
<MSBuild Projects="ClojureCLR.sln"
29-
Properties="Runtime=$(Runtime);DefineConstants=$(DefineConstants)"/>
33+
Properties="Runtime=$(Runtime)"/>
3034
</Target>
3135

3236
<Target Name="CompileTest" DependsOnTargets="Build">

0 commit comments

Comments
 (0)