Skip to content

Commit bb199c5

Browse files
committed
Merge bug21967 into default
2 parents b68ac2c + 6f70e91 commit bb199c5

File tree

3 files changed

+49
-15
lines changed

3 files changed

+49
-15
lines changed

Dist-dotnet-2.0.props.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@
22
<Project ToolsVersion="3.5" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<PropertyGroup>
44
<PropTargetFramework>v2.0</PropTargetFramework>
5+
<PropUsingMono>@USINGMONO@</PropUsingMono>
6+
<PropLaunchExe Condition="'$(PropUsingMono)' == 'true'">mono </PropLaunchExe>
57
<PropAssemblyVersion>@VERSION@</PropAssemblyVersion>
68
<PropKeyfile>$(MSBuildProjectDirectory)\..\..\..\@KEYFILE@</PropKeyfile>
79
</PropertyGroup>
810
</Project>
11+

Dist-dotnet-3.0.props.in

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22
<Project ToolsVersion="3.5" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<PropertyGroup>
44
<PropTargetFramework>v3.0</PropTargetFramework>
5-
<PropBuildWcf>true</PropBuildWcf>
5+
<PropUsingMono>@USINGMONO@</PropUsingMono>
6+
<PropLaunchExe Condition="'$(PropUsingMono)' == 'true'">mono </PropLaunchExe>
7+
<PropBuildWcf Condition="'$(PropUsingMono)' != 'true'">true</PropBuildWcf>
68
<PropAssemblyVersion>@VERSION@</PropAssemblyVersion>
79
<PropKeyfile>$(MSBuildProjectDirectory)\..\..\..\@KEYFILE@</PropKeyfile>
810
</PropertyGroup>
911
</Project>
12+

dist.sh

Lines changed: 42 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,23 @@ CYGWIN=nontsec
6969
### Overrideable vars
7070
test "$KEYFILE" || KEYFILE=rabbit-mock.snk
7171
test "$RABBIT_VSN" || RABBIT_VSN=0.0.0
72-
test "$MSBUILD" || MSBUILD=msbuild.exe
7372
test "$WEB_URL" || WEB_URL=http://stage.rabbitmq.com/
7473
test "$UNOFFICIAL_RELEASE" || UNOFFICIAL_RELEASE=
74+
test "$MONO_DIST" || MONO_DIST=
7575

7676
### Other, general vars
7777
NAME=rabbitmq-dotnet-client
7878
NAME_VSN=$NAME-$RABBIT_VSN
7979
RELEASE_DIR=releases/$NAME/v$RABBIT_VSN
80+
if [ "$MONO_DIST" ] ; then
81+
INCLUDE_WCF=true
82+
MSBUILD=xbuild
83+
DOTNET_PROGRAM_PREPEND="mono"
84+
else
85+
INCLUDE_WCF=true
86+
MSBUILD=msbuild.exe
87+
DOTNET_PROGRAM_PREPEND=
88+
fi
8089

8190

8291
function main {
@@ -117,7 +126,7 @@ function dist-zips {
117126
dist-target-framework dotnet-2.0
118127
### HTML documentation for the .NET 2.0 library dist
119128
gendoc-dist \
120-
projects/client/RabbitMQ.Client/build/bin/RabbitMQ.Client.xml \
129+
build/bin/RabbitMQ.Client.xml \
121130
$NAME_VSN-client-htmldoc.zip \
122131
"/suppress:RabbitMQ.Client.Framing.v0_8 \
123132
/suppress:RabbitMQ.Client.Framing.v0_8qpid \
@@ -127,17 +136,23 @@ function dist-zips {
127136
/suppress:RabbitMQ.Client.Framing.Impl.v0_9 \
128137
/suppress:RabbitMQ.Client.Impl \
129138
/suppress:RabbitMQ.Client.Apigen.Attributes" \
130-
$NAME_VSN-tmp-xmldoc.zip
139+
$NAME_VSN-tmp-xmldoc.zip \
140+
projects/client/RabbitMQ.Client \
141+
../../..
131142

132143
### .NET 3.0 library (bin), examples (src and bin), WCF bindings library (bin)
133-
### and WCF examples (src) dist
144+
### and WCF examples (src) dist (WCF built only if MONO_DIST is undefined)
134145
dist-target-framework dotnet-3.0
135-
### HTML documentation for the WCF bindings library dist
136-
gendoc-dist \
137-
projects/wcf/RabbitMQ.ServiceModel/build/bin/RabbitMQ.ServiceModel.xml \
138-
$NAME_VSN-wcf-htmldoc.zip \
139-
"" \
140-
""
146+
if [ -z "$MONO_DIST" ]; then
147+
### HTML documentation for the WCF bindings library dist
148+
gendoc-dist \
149+
build/bin/RabbitMQ.ServiceModel.xml \
150+
$NAME_VSN-wcf-htmldoc.zip \
151+
"" \
152+
"" \
153+
projects/wcf/RabbitMQ.ServiceModel \
154+
../../..
155+
fi
141156
}
142157

143158

@@ -187,7 +202,7 @@ function src-dist {
187202
function dist-target-framework {
188203
TARGET_FRAMEWORK="$1"
189204
BUILD_WCF=
190-
test "$TARGET_FRAMEWORK" == "dotnet-3.0" && BUILD_WCF="true"
205+
test "$TARGET_FRAMEWORK" == "dotnet-3.0" && test -z "$MONO_DIST" && BUILD_WCF="true"
191206

192207
### Make sure we can use MSBuild.Community.Tasks.dll (it might be from a
193208
### remote location)
@@ -235,8 +250,14 @@ function dist-target-framework {
235250
}
236251

237252
function gen-props {
253+
if [ "$MONO_DIST" ]; then
254+
USING_MONO="true"
255+
else
256+
USING_MONO="false"
257+
fi
238258
sed -e "s:@VERSION@:$RABBIT_VSN:g" \
239259
-e "s:@KEYFILE@:$KEYFILE:g" \
260+
-e "s:@USINGMONO@:$USING_MONO:g" \
240261
< $1 > $2
241262
}
242263

@@ -246,19 +267,25 @@ function gendoc-dist {
246267
EXTRA_NDOCPROC_ARGS="$3"
247268
### If this is an empty string, the intermediate xml output will not be saved in a zip
248269
ZIP_TMP_XML_DOC_FILENAME="$4"
270+
PROJECT_DIR="$5"
271+
RELATIVE_DIR="$6"
249272

250273
mkdir -p tmp/gendoc/xml tmp/gendoc/html
251274

252275
### Make sure we can use ndocproc (it might be from a remote location)
253276
chmod +x lib/ndocproc-bin/bin/ndocproc.exe
254277

278+
cd $PROJECT_DIR
279+
255280
### Generate XMLs with ndocproc
256-
lib/ndocproc-bin/bin/ndocproc.exe \
281+
$DOTNET_PROGRAM_PREPEND $RELATIVE_DIR/lib/ndocproc-bin/bin/ndocproc.exe \
257282
/nosubtypes \
258283
$EXTRA_NDOCPROC_ARGS \
259-
tmp/gendoc/xml \
284+
$RELATIVE_DIR/tmp/gendoc/xml \
260285
$XML_SOURCE_FILE \
261-
docs/namespaces.xml
286+
$RELATIVE_DIR/docs/namespaces.xml
287+
288+
cd $RELATIVE_DIR
262289

263290
### Zip ndocproc's output
264291
if [ "$ZIP_TMP_XML_DOC_FILENAME" ]; then
@@ -297,3 +324,4 @@ function genhtml {
297324

298325

299326
main $@
327+

0 commit comments

Comments
 (0)