diff --git a/build/Common.targets b/build/Common.targets index 31f8550df1..d5ff879720 100644 --- a/build/Common.targets +++ b/build/Common.targets @@ -64,6 +64,10 @@ Targets For Tools Targets For GenerateSource *********************************************************************************************** --> + + + + @@ -89,8 +93,8 @@ Targets For Package - - + + - - - - - - - - - - - - - + + - - + + - - - - - - + + + + diff --git a/build/Google.ProtocolBuffersLite.nuspec b/build/Google.ProtocolBuffersLite.nuspec index 819eab62f1..56cf142cc3 100644 --- a/build/Google.ProtocolBuffersLite.nuspec +++ b/build/Google.ProtocolBuffersLite.nuspec @@ -41,31 +41,19 @@ Language Guide - http://code.google.com/apis/protocolbuffers/docs/proto.html + - - - - - - - - - - - - - + + - - + + - - - - - - + + + + diff --git a/build/PublishRelease.bat b/build/PublishRelease.bat deleted file mode 100644 index c6cb6f95b6..0000000000 --- a/build/PublishRelease.bat +++ /dev/null @@ -1,98 +0,0 @@ -REM @ECHO OFF -@PUSHD %~dp0 -@IF "%1" == "version" @GOTO VERSION -@IF "%1" == "build" @GOTO BUILD -@IF "%1" == "fpush" @GOTO FILEPUSH -@IF "%1" == "nupush" @GOTO NUGETPUSH -@IF "%1" == "push" @GOTO PUSH -@GOTO HELP - -:VERSION -IF NOT EXIST "..\build_temp\" MD "..\build_temp\" -hg log -l 1 --template "Revision: {rev}" > ..\build_temp\revision.txt -CMD.exe /Q /C "CD .. && lib\StampVersion.exe /major:2 /minor:4 /build:1 /revision:build_temp\revision.txt" -@TYPE ..\src\ProtocolBuffers\Properties\AssemblyInfo.cs | FIND "AssemblyFileVersion" -@ECHO. -@ECHO NEXT: Use the above version number to run "%0 build {Version}" -@ECHO. -@GOTO EXIT - -:BUILD -@IF "%2" == "" @GOTO HELP -IF EXIST "C:\Program Files\Microsoft SDKs\Windows\v7.0\Bin\sn.exe" SET WIN7SDK_DIR=C:\Program Files\Microsoft SDKs\Windows\v7.0\Bin\ - -IF NOT EXIST "..\release-key" hg clone https://bitbucket.org/rknapp/protobuf-csharp-port-keyfile ..\release-key - -MD "%2" -CMD.exe /Q /C "BuildAll.bat /verbosity:minimal "/p:AssemblyOriginatorKeyFile=%~dp0..\release-key\Google.ProtocolBuffers.snk" - -COPY /y ..\build_output\release-binaries.zip %2\protobuf-csharp-port-%2-release-binaries.zip -COPY /y ..\build_output\full-binaries.zip %2\protobuf-csharp-port-%2-full-binaries.zip - -..\lib\NuGet.exe pack Google.ProtocolBuffers.nuspec -Symbols -Version %2 -NoPackageAnalysis -OutputDirectory %2 -..\lib\NuGet.exe pack Google.ProtocolBuffersLite.nuspec -Symbols -Version %2 -NoPackageAnalysis -OutputDirectory %2 - -hg archive %2\protobuf-csharp-port-%2-source.zip - -"%WIN7SDK_DIR%sn.exe" -T ..\build_output\v2.0\Release\Google.ProtocolBuffers.dll -@ECHO. -@ECHO *********************************************************** -@ECHO IMPORTANT: Verify the above key output is: 55f7125234beb589 -@ECHO *********************************************************** -@ECHO. -@ECHO NEXT: Verify the output in %~dp0\%2 and then run "%0 push %2" -@ECHO. -@GOTO EXIT - -:PUSH -@IF "%2" == "" @GOTO HELP - -hg commit -m "version %2" -hg tag %2 -hg push -@ECHO. -@ECHO NEXT: Verify the repository state and run "%0 fpush %2 {google-code-user} {google-code-password}" -@ECHO. -@GOTO EXIT - -:FILEPUSH -@IF "%2" == "" @GOTO HELP -@IF "%3" == "" @GOTO HELP -@IF "%4" == "" @GOTO HELP -SET GOOGLEUPLOAD=python.exe googlecode_upload.py --project protobuf-csharp-port --user "%3" --password "%4" - -%GOOGLEUPLOAD% --labels Type-Source,Featured --summary "Version %2 source" %2\protobuf-csharp-port-%2-source.zip -%GOOGLEUPLOAD% --labels Type-Executable,Featured --summary "Version %2 binaries (all configurations)" %2\protobuf-csharp-port-%2-full-binaries.zip -%GOOGLEUPLOAD% --labels Type-Executable,Featured --summary "Version %2 binaries (release only)" %2\protobuf-csharp-port-%2-release-binaries.zip - -@SET GOOGLEUPLOAD= -@ECHO. -@ECHO NEXT: Verify the uploads and run "%0 nupush %2" -@ECHO. -@GOTO EXIT - -:NUGETPUSH - -..\lib\NuGet.exe push "%2\Google.ProtocolBuffers.%2.nupkg" -..\lib\NuGet.exe push "%2\Google.ProtocolBuffersLite.%2.nupkg" -..\lib\NuGet.exe push "%2\Google.ProtocolBuffers.%2.symbols.nupkg" -..\lib\NuGet.exe push "%2\Google.ProtocolBuffersLite.%2.symbols.nupkg" - -@ECHO. -@ECHO NEXT: Verify the nuget packages at http://nuget.org -@ECHO. -@GOTO EXIT - -:HELP -@ECHO. -@ECHO Available commands, run in the following order: -@ECHO 1. %0 version -@ECHO 2. %0 build {version from step 1} -@ECHO 3. %0 push {version from step 1} -@ECHO 4. %0 fpush {version from step 1} {google-code-user} {google-code-password} -@ECHO 5. %0 nupush {version from step 1} -@ECHO. -@GOTO EXIT - -:EXIT -@POPD \ No newline at end of file diff --git a/build/build.csproj b/build/build.csproj index e95137fb77..2279886a08 100644 --- a/build/build.csproj +++ b/build/build.csproj @@ -4,9 +4,10 @@ + - + @@ -39,8 +40,10 @@ $(BuildOutputDirectory)\tools\protoc.exe $(BuildOutputDirectory)\tools\protogen.exe $(LibDirectory)\NUnit\tools\nunit-console.exe + $(LibDirectory)\CsProjectProjector\CsProjectProjector.exe $(LibDirectory)\7-Zip 9.20\7za.exe - + + diff --git a/build/publish.csproj b/build/publish.csproj new file mode 100644 index 0000000000..9cb4390834 --- /dev/null +++ b/build/publish.csproj @@ -0,0 +1,182 @@ + + + + + + + + + Protocol Buffers + 2 + 4 + 1 + + + + protobuf-csharp-port- + false + + + + + + $(MSBuildProjectDirectory)\.. + $(ProjectDirectory)\build_temp + $(ProjectDirectory)\build_output + $(ProjectDirectory)\src + $(ProjectDirectory)\lib + + + $(ProjectDirectory)\release-key\Google.ProtocolBuffers.snk + + + hg.exe + C:\Python25\python.exe + $(registry:HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.0A@InstallationFolder)Bin\sn.exe + $(LibDirectory)\StampVersion.exe + $(LibDirectory)\7-Zip 9.20\7za.exe + $(LibDirectory)\NuGet.exe + $(BuildOutputDirectory)\tools\protogen.exe + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + $(VersionMajor).$(VersionMinor).$(VersionBuild).$(VersionRevision) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + $(Python) "$(MSBuildProjectDirectory)\googlecode_upload.py" --project protobuf-csharp-port --user "$(GoogleUsername)" --password "$(GooglePassword)" + + $(BuildTempDirectory)\$(PackagePrefix)$(VersionLabel)-source.zip + $(BuildTempDirectory)\$(PackagePrefix)$(VersionLabel)-release-binaries.zip + $(BuildTempDirectory)\$(PackagePrefix)$(VersionLabel)-release-symbols.zip + $(BuildTempDirectory)\$(PackagePrefix)$(VersionLabel)-full-binaries.zip + $(BuildTempDirectory)\$(PackagePrefix)$(VersionLabel)-full-symbols.zip + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/lib/NuGet.exe b/lib/NuGet.exe index c3960af621..ddc91051bc 100644 Binary files a/lib/NuGet.exe and b/lib/NuGet.exe differ diff --git a/src/ProtocolBuffers.sln b/src/ProtocolBuffers.sln index 6410347078..320834ab50 100644 --- a/src/ProtocolBuffers.sln +++ b/src/ProtocolBuffers.sln @@ -61,11 +61,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "build", "build", "{66ED1950 ..\build\build.bat = ..\build\build.bat ..\build\build.csproj = ..\build\build.csproj ..\build\BuildAll.bat = ..\build\BuildAll.bat + ..\build\GenerateProjects.bat = ..\build\GenerateProjects.bat + ..\build\PublishTool.bat = ..\build\PublishTool.bat ..\build\Common.targets = ..\build\Common.targets ..\build\GenerateSource.bat = ..\build\GenerateSource.bat ..\build\Google.ProtocolBuffers.nuspec = ..\build\Google.ProtocolBuffers.nuspec ..\build\Google.ProtocolBuffersLite.nuspec = ..\build\Google.ProtocolBuffersLite.nuspec - ..\build\PublishRelease.bat = ..\build\PublishRelease.bat + ..\build\publish.csproj = ..\build\publish.csproj ..\build\RunBenchmarks.bat = ..\build\RunBenchmarks.bat ..\build\target.csproj = ..\build\target.csproj EndProjectSection