changeset 9358:baebf028f505

Merge with crew-stable
author Steve Borho <steve@borho.org>
date Mon, 17 Aug 2009 20:20:34 -0500
parents f7c334e810c2 (current diff) 7ee67a037dcb (diff)
children 419aa488432e
files contrib/win32/win32-build.txt
diffstat 2 files changed, 32 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/win32/mercurial.iss	Sun Aug 16 11:09:21 2009 +0900
+++ b/contrib/win32/mercurial.iss	Mon Aug 17 20:20:34 2009 -0500
@@ -1,9 +1,25 @@
 ; Script generated by the Inno Setup Script Wizard.
 ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
+
+#ifndef VERSION
+#define FileHandle
+#define FileLine
+#define VERSION = "unknown"
+#if FileHandle = FileOpen(SourcePath + "\..\..\mercurial\__version__.py")
+  #expr FileLine = FileRead(FileHandle)
+  #expr FileLine = FileRead(FileHandle)
+  #define VERSION = Copy(FileLine, Pos('"', FileLine)+1, Len(FileLine)-Pos('"', FileLine)-1)
+#endif
+#if FileHandle
+  #expr FileClose(FileHandle)
+#endif
+#pragma message "Detected Version: " + VERSION
+#endif
+
 [Setup]
 AppCopyright=Copyright 2005-2009 Matt Mackall and others
 AppName=Mercurial
-AppVerName=Mercurial snapshot
+AppVerName=Mercurial {#VERSION}
 InfoAfterFile=contrib/win32/postinstall.txt
 LicenseFile=COPYING
 ShowLanguageDialog=yes
@@ -13,10 +29,10 @@
 AppUpdatesURL=http://mercurial.selenic.com/
 AppID={{4B95A5F1-EF59-4B08-BED8-C891C46121B3}
 AppContact=mercurial@selenic.com
-OutputBaseFilename=Mercurial-snapshot
+OutputBaseFilename=Mercurial-{#VERSION}
 DefaultDirName={pf}\Mercurial
 SourceDir=..\..
-VersionInfoDescription=Mercurial distributed SCM
+VersionInfoDescription=Mercurial distributed SCM (version {#VERSION})
 VersionInfoCopyright=Copyright 2005-2009 Matt Mackall and others
 VersionInfoCompany=Matt Mackall and others
 InternalCompressLevel=max
@@ -38,8 +54,8 @@
 Source: dist\hg.exe; DestDir: {app}; AfterInstall: Touch('{app}\hg.exe.local')
 Source: dist\python*.dll; Destdir: {app}; Flags: skipifsourcedoesntexist
 Source: dist\library.zip; DestDir: {app}
-Source: dist\mfc*.dll; DestDir: {app}
-Source: dist\msvc*.dll; DestDir: {app}
+Source: dist\mfc*.dll; DestDir: {app}; Flags: skipifsourcedoesntexist
+Source: dist\msvc*.dll; DestDir: {app}; Flags: skipifsourcedoesntexist
 Source: dist\Microsoft.VC*.CRT.manifest; DestDir: {app}; Flags: skipifsourcedoesntexist
 Source: dist\Microsoft.VC*.MFC.manifest; DestDir: {app}; Flags: skipifsourcedoesntexist
 Source: dist\w9xpopen.exe; DestDir: {app}
--- a/contrib/win32/win32-build.txt	Sun Aug 16 11:09:21 2009 +0900
+++ b/contrib/win32/win32-build.txt	Mon Aug 17 20:20:34 2009 -0500
@@ -25,7 +25,10 @@
       http://gnuwin32.sourceforge.net/packages/gettext.htm
 
   Inno Setup
-      http://www.jrsoftware.org/isinfo.php
+      http://www.jrsoftware.org/isdl.php#qsp
+
+      Get and install ispack-5.3.4.exe which includes Inno Setup Processor,
+      which is necessary to package Mercurial.
 
   ISTool - optional
       http://www.istool.org/default.aspx/
@@ -94,11 +97,14 @@
 If you use ISTool, you open the C:\hg\hg-release\contrib\win32\mercurial.iss
 file and type Ctrl-F9 to compile the installer file.
 
-Otherwise you run the Inno Setup compiler.  Assuming it's on the path you run:
+Otherwise you run the Inno Setup compiler.  Assuming it's in the path
+you should execute:
 
-  iscc contrib\win32\mercurial.iss
+  iscc contrib\win32\mercurial.iss /DVERSION=foo
 
-The actual installer will be in the C:\hg\hg-release\Output directory.
+Where 'foo' is the version number you would like to see in the
+'Add/Remove Applications' tool.  The installer will be placed into
+a directory named Output/ at the root of your repository.
 
 To automate the steps above you may want to create a batchfile based on the
 following:
@@ -109,6 +115,6 @@
   cd doc
   mingw32-make RST2HTML=rst2html.bat html
   cd ..
-  iscc contrib\win32\mercurial.iss
+  iscc contrib\win32\mercurial.iss /DVERSION=snapshot
 
 and run it from the root of the hg repository (c:\hg\hg-release).