aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Yu <tlyu@mit.edu>2007-03-30 20:54:10 +0000
committerTom Yu <tlyu@mit.edu>2007-03-30 20:54:10 +0000
commit4cfb3f3f9a55f984c34716e4de9fb0cabb052dd6 (patch)
treeadb583484e35eb13dbd6f399f13642f6dd4fe8e1
parent8990ab30ec5a5f8a4022708283e7e59450bfbf48 (diff)
downloadkrb5-4cfb3f3f9a55f984c34716e4de9fb0cabb052dd6.zip
krb5-4cfb3f3f9a55f984c34716e4de9fb0cabb052dd6.tar.gz
krb5-4cfb3f3f9a55f984c34716e4de9fb0cabb052dd6.tar.bz2
pull up r19297 from trunk
r19297@cathode-dark-space: kpkoch | 2007-03-28 14:43:11 -0400 Target_Version: 1.6.1 Ticket: 5490 Tags: pullup Pull product version information from kerberos.ver. Change site-local.wxi/.nsi to site-local-tagged.wxi/.nsi. Add tags such as %VERSION-MAJOR% which are substituted by the build script. NB: to build the installers directly, the build script must be run at least once to generate site-local.wxi/.nsi. Write DEBUG, RELEASE, BETA defines to site-local.nsi, based on build setting & values from kerberos.ver. Add more tag substitutions to file copy and the config file, to provide a way to generate names like kfw-3-2-0-DEBUG.exe programatically. ticket: 5490 git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-6@19355 dc483132-0cff-0310-8789-dd5450dbe970
-rw-r--r--src/windows/build/BKWconfig.xml15
-rw-r--r--src/windows/build/bkw.pl196
-rw-r--r--src/windows/build/copyfiles.pl6
-rw-r--r--src/windows/installer/nsis/site-local-tagged.nsi13
-rw-r--r--src/windows/installer/nsis/site-local.nsi13
-rw-r--r--src/windows/installer/wix/site-local-tagged.wxi (renamed from src/windows/installer/wix/site-local.wxi)202
6 files changed, 276 insertions, 169 deletions
diff --git a/src/windows/build/BKWconfig.xml b/src/windows/build/BKWconfig.xml
index 7c536da..2893944 100644
--- a/src/windows/build/BKWconfig.xml
+++ b/src/windows/build/BKWconfig.xml
@@ -29,10 +29,8 @@
<FetchSources>
<Config>
<CVSROOT name=":kserver:cvs.mit.edu:/cvs/pismere" />
- <SVNURL name="svn.mit.edu" /> <!-- NB: No protocol or slashes!! -->
- <KERBEROS_ID name="kpkoch" />
- <KRB_PLINK name="plink.exe" /> <!-- Path to a kerberized plink, needed for svn. -->
- <!-- NB: Path separators must be doubled backslashes. EG: C:\\WINDOWS\\PLINK.EXE -->
+ <SVNURL name="svn.mit.edu" /> <!-- NB: No protocol or slashes!! -->
+ <USERNAME name="" /> <!-- Needed for svn/plink. Override from command line -->
</Config>
</FetchSources>
<Make>
@@ -73,13 +71,18 @@
</CopyList>
</PrePackage>
<Package>
+ <Config>
+ <Paths>
+ <Versions path="pismere/athena/include/kerberos.ver" /> <!-- Relative to <src>. -->
+ </Paths>
+ </Config>
<MSI></MSI>
<NSIS></NSIS> <!-- NB: Most config is done in site-local.nsi. -->
<!-- Theoretically, writing site-local.nsi from xml settings could be done, but isn't. -->
</Package>
<PostPackage>
<Config> <!-- This config info will be copied into each CopyList in PostPackage. -->
- <FileStem name="kfw-3-2-0" /> <!-- <FileStem> will be substituted for %filestem%. -->
+ <FileStem name="kfw-%VERSION_MAJOR%-%VERSION_MINOR%-%VERSION_PATCH%" /> <!-- <FileStem> will be substituted for %filestem%. -->
</Config>
<Zips>
<Zip dummy="foo" /> <!-- To force desired XML::Simple behavior -->
@@ -142,7 +145,7 @@
<File name="msi-deployment-guide.txt" from="staging\install\wix\" to="" />
<File name="netidmgr_userdoc.pdf" from="staging\doc" to="." />
<File name="kfw.msi" from="staging\install\wix\" to="" newname="%filestem%.msi" />
- <File name="MITKerberosForWindows.exe" from="staging\install\nsis" to="" newname="%filestem%.exe" />
+ <File name="MITKerberosForWindows%-DEBUG%.exe" from="staging\install\nsis" to="" newname="%filestem%%-DEBUG%.exe" />
</Files>
</CopyList>
</PostPackage>
diff --git a/src/windows/build/bkw.pl b/src/windows/build/bkw.pl
index 5460ffa..8279879 100644
--- a/src/windows/build/bkw.pl
+++ b/src/windows/build/bkw.pl
@@ -38,23 +38,23 @@ Usage: $0 (-f --config) config-file [options] NMAKE-options
Options:
/help /? usage information (what you now see).
- /config path Path to config file.
- /srcdir dir Source directory to use. Should contain
+ /config /c path Path to config file.
+ /srcdir /r dir Source directory to use. Should contain
pismere/athena. If cvstag or svntag is null,
the directory should be prepopulated.
- /outdir dir Directory to be created where build results will go
+ /outdir /o dir Directory to be created where build results will go
/repository checkout | co \\ What repository action to take.
update | up ) Options are to checkout, update or
skip / take no action [skip].
- /kerberos_id id kerberos id used to access svn if checking out.
- /cvstag tag \\ If non-empty, the tag is appended to cvs and svn
- /svntag tag / commands to select the rev to fetch.
- /debug Do debug make instead of release make.
+ /username /u name username used to access svn if checking out.
+ /cvstag /c tag \\ If non-empty, the tag is appended to cvs and svn
+ /svntag /s tag / commands to select the rev to fetch.
+ /debug /d Do debug make instead of release make.
/nomake Skip make step.
/clean Build clean target.
/nopackage Skip packaging step.
- /verbose Debug mode - verbose output.
- /logfile path Where to write output. If omitted, ...
+ /verbose /v Debug mode - verbose output.
+ /logfile /l path Where to write output. If omitted, ...
Other:
NMAKE-options any options you want to pass to NMAKE, which can be:
(note: /nologo is always used)
@@ -91,9 +91,9 @@ sub main {
'config|f:s',
'logfile|l:s',
'repository:s',
- 'kerberos_id:s',
- 'verbose',
- 'vverbose',
+ 'username|u:s',
+ 'verbose|v',
+ 'vverbose|vv',
'nomake',
'clean',
'nopackage',
@@ -114,7 +114,7 @@ sub main {
}
# List of programs which must be in PATH:
- my @required_list = ('sed', 'awk', 'which', 'cat', 'rm', 'cvs', 'svn', 'doxygen', 'hhc', 'candle', 'light', 'makensis', 'nmake');
+ my @required_list = ('sed', 'awk', 'which', 'cat', 'rm', 'cvs', 'svn', 'doxygen', 'hhc', 'candle', 'light', 'makensis', 'nmake', 'plink');
my $requirements_met = 1;
my $first_missing = 0;
my $error_list = "";
@@ -167,7 +167,7 @@ sub main {
$switches[0]->{debug}->{value} = $OPT->{debug} if exists $OPT->{debug};
$switches[0]->{clean}->{value} = 1 if exists $OPT->{clean};
$switches[0]->{repository}->{value} = $OPT->{repository} if exists $OPT->{repository};
- $fetch[0]->{KERBEROS_ID}->{name} = $OPT->{kerberos_id} if exists $OPT->{kerberos_id};
+ $fetch[0]->{USERNAME}->{name} = $OPT->{username} if exists $OPT->{username};
$switches[0]->{nomake}->{value} = 1 if exists $OPT->{nomake};
$switches[0]->{nopackage}->{value} = 1 if exists $OPT->{nopackage};
$switches[0]->{verbose}->{value} = $OPT->{verbose} if exists $OPT->{verbose};
@@ -211,20 +211,28 @@ sub main {
my $wd = $src."\\pismere";
- if ($rverb =~ /checkout/) {
- if (-d $wd) {
- print "\n\nHEADS UP!!\n\n";
- print "/REPOSITORY CHECKOUT will cause everything under $wd to be deleted.\n";
- print "If this is not what you intended, here's your chance to bail out!\n\n\n";
- print "Are you sure you want to remove everything under $wd? ";
- my $char = getc;
- if (! ($char =~ /y/i)) {die "Info -- operation aborted by user."}
- !system("rm -rf $wd/*") or die "Fatal -- Couldn't clean $wd.";
- !system("rmdir $wd") or die "Fatal -- Couldn't remove $wd.";
+ if (! ($rverb =~ /skip/)) {
+ local $len = 0;
+ if (exists $fetch[0]->{USERNAME}->{name}) {
+ $len = length $fetch[0]->{USERNAME}->{name};
+ }
+ if ($len < 1) {
+ die "Fatal -- you won't get far accessing the repository without specifying a username.";
}
- if (! -d $src) {mkdir $src or die "Fatal -- Couldn't create $src.";}
- if (! -d $wd) {mkdir $wd or die "Fatal -- Couldn't create $wd.";}
- if (! -d "$wd//CVS") {mkdir "$wd//CVS" or die "Fatal -- Couldn't create $wd\\CVS.";}
+ }
+
+ if ($rverb =~ /checkout/) {
+ print "\n\nHEADS UP!!\n\n";
+ print "/REPOSITORY CHECKOUT will cause everything under $wd to be deleted.\n";
+ print "If this is not what you intended, here's your chance to bail out!\n\n\n";
+ print "Are you sure you want to remove everything under $wd? ";
+ my $char = getc;
+ if (! ($char =~ /y/i)) {die "Info -- operation aborted by user."}
+ !system("rm -rf $wd/*") or die "Fatal -- Couldn't clean $wd.";
+ !system("rmdir $wd") or die "Fatal -- Couldn't remove $wd.";
+# !system("attrib -h -r $wd\\* /s /d") or die "Fatal -- Couldn't clear read-only attributes.";
+# !system("del /s /q $wd\\*.*") or die "Fatal -- Couldn't clean files from $wd.";
+# !system("rm -rf $wd\\*.*") or die "Fatal -- Couldn't clean directories from $wd.";
}
# Begin logging:
@@ -243,8 +251,8 @@ sub main {
# Set up cvs environment variables:
$ENV{CVSROOT} = $fetch[0]->{CVSROOT}->{name};
- chdir($src) or die "Fatal -- couldn't chdir to $src\n";
- print "Info -- chdir to ".`cd`."\n" if ($verbose);
+ chdir($src) or die "Fatal -- couldn't chdir to $src\n";
+ print "Info -- chdir to ".`cd`."\n" if ($verbose);
my $krb5dir = $wd."\\athena\\auth\\krb5";
my $cvscmdroot = "cvs $rverb";
@@ -261,28 +269,26 @@ sub main {
$cvscmd = $cvscmdroot." ".$module;
$cvscmd .= " ".$tags[0]->{cvs}->{value} if ($tags[0]->{cvs}->{value});
if ($verbose) {print "Info -- cvs command: $cvscmd\n";}
- !system($cvscmd) or die "Fatal -- command \"$cvscmd\" failed; return code $?\n";
+ !system($cvscmd) or die "Fatal -- command \"$cvscmd\" failed; return code $?\n";
}
}
else { ## Update.
$cvscmd = $cvscmdroot;
$cvscmd .= " ".$tags[0]->{cvs}->{value} if ($tags[0]->{cvs}->{value});
if ($verbose) {print "Info -- cvs command: $cvscmd\n";}
- !system($cvscmd) or die "Fatal -- command \"$cvscmd\" failed; return code $?\n";
+ !system($cvscmd) or die "Fatal -- command \"$cvscmd\" failed; return code $?\n";
}
- # Set up svn environment variables:
- my $dblback_plink = $fetch[0]->{KRB_PLINK}->{name};
- $dblback_plink =~ s/\\/\\\\/g;
- $ENV{SVN_SSH} = $dblback_plink;
+ # Set up svn environment variable:
+ $ENV{SVN_SSH} = "plink.exe";
# If the directory structure doesn't exist, many cd commands will fail.
- mkdir($krb5dir);
- chdir($krb5dir) or die "Fatal -- couldn't chdir to $krb5dir\n";
+ if (! -d $krb5dir) {mkdir($krb5dir) or die "Fatal -- Couldn't create $krb5dir";}
+ chdir($krb5dir) or die "Fatal -- Couldn't chdir to $krb5dir";
print "Info -- chdir to ".`cd`."\n" if ($verbose);
my $svncmd = "svn $rverb ";
if ($rverb =~ /checkout/) { # Append the rest of the checkout command:
chdir("..");
- $svncmd .= "svn+ssh://".$fetch[0]->{KERBEROS_ID}->{name}."@".$fetch[0]->{SVNURL}->{name}."/krb5/trunk krb5";
+ $svncmd .= "svn+ssh://".$fetch[0]->{USERNAME}->{name}."@".$fetch[0]->{SVNURL}->{name}."/krb5/trunk krb5";
}
if ($tags[0]->{svn}->{value}) {$svncmd .= " ".$tags[0]->{svn}->{value};} # Add any specific tag
if ($verbose) {print "Info -- svn command: $svncmd\n";}
@@ -292,6 +298,7 @@ sub main {
}
##-- End repository action.
+##++ Make action:
if ( (!$switches[0]->{nomake}->{value}) ) {
if ($verbose) {print "Info -- *** Begin preparing for build.\n";}
@@ -368,9 +375,65 @@ sub main {
if ($verbose) {print "Info -- *** End build".$buildtext."\n";}
} ## End make conditional.
else {print "Info -- *** Skipping build.\n" if ($verbose);}
+##-- Make action.
if (!$switches[0]->{nopackage}->{value}) { ## If /clean, this switch will have been cleared.
if ($verbose) {print "Info -- *** Begin prepackage.\n";}
+
+ # We read in the version information to be able to update the site-local files in the install build areas:
+ local $version_path = $config->{Stages}->{Package}->{Config}->{Paths}->{Versions}->{path};
+ open(DAT, "$src/$version_path") or die "Could not open $version_path.";
+ @raw = <DAT>;
+ close DAT;
+ foreach $line (@raw) {
+ chomp $line;
+ if ($line =~ /#define/) { # Process #define lines:
+ $line =~ s/#define//; # Remove #define token
+ $line =~ s/^\s+//; # and leading & trailing whitespace
+ $line =~ s/\s+$//;
+ local @qr = split("\"", $line); # Try splitting with quotes
+ if (exists $qr[1]) {
+ $qr[0] =~ s/^\s+//; # Clean up whitespace
+ $qr[0] =~ s/\s+$//;
+ $config->{Versions}->{$qr[0]} = $qr[1]; # Save string
+ }
+ else { # No quotes, so
+ local @ar = split(" ", $line); # split with space
+ $ar[0] =~ s/^\s+//; # Clean up whitespace
+ $ar[0] =~ s/\s+$//;
+ $config->{Versions}->{$ar[0]} = $ar[1]; # and save numeric value
+ }
+ }
+ }
+
+ # Check that the versions we will need for site-local have been defined:
+ my @required_versions = ('VER_PROD_MAJOR', 'VER_PROD_MINOR', 'VER_PROD_REV',
+ 'VER_PROD_MAJOR_STR', 'VER_PROD_MINOR_STR', 'VER_PROD_REV_STR',
+ 'VER_PRODUCTNAME_STR');
+ my $requirements_met = 1;
+ my $first_missing = 0;
+ my $error_list = "";
+ foreach my $required (@required_versions) {
+ if (! exists $config->{Versions}->{$required}) {
+ $requirements_met = 0;
+ if (!$first_missing) {
+ $first_missing = 1;
+ $error_list = "Fatal -- The following version(s) are not defined in $src/$version_path.\n";
+ }
+ $error_list .= "$required\n";
+ }
+ }
+ if (!$requirements_met) {
+ print $error_list;
+ exit(0);
+ }
+ # Apply any of these tags to filestem:
+ my $filestem = $config->{Stages}->{PostPackage}->{Config}->{FileStem}->{name};
+ $filestem =~ s/%VERSION_MAJOR%/$config->{Versions}->{'VER_PROD_MAJOR_STR'}/;
+ $filestem =~ s/%VERSION_MINOR%/$config->{Versions}->{'VER_PROD_MINOR_STR'}/;
+ $filestem =~ s/%VERSION_PATCH%/$config->{Versions}->{'VER_PROD_REV_STR'}/;
+ $config->{Stages}->{PostPackage}->{Config}->{FileStem}->{name} = $filestem;
+
# The build results are copied to a staging area, where the packager expects to find them.
# We put the staging area in the fixed area .../pismere/staging.
my $prepackage = $config->{Stages}->{PrePackage};
@@ -383,24 +446,54 @@ sub main {
# Force Where From and To are relative to:
$prepackage->{CopyList}->{Config}->{From}->{root} = "$src\\pismere\\athena";
$prepackage->{CopyList}->{Config}->{To}->{root} = "$src\\pismere\\staging";
- copyFiles($prepackage->{CopyList}, $config); ## Copy any files
+ copyFiles($prepackage->{CopyList}, $config); ## Copy any files [this step takes a while]
chdir("staging\\install\\wix") or die "Fatal -- Couldn't cd to $wd\\staging\\install\\wix";
- print "Info -- chdir to ".`cd`."\n" if ($verbose);
# Correct errors in files.wxi:
!system("sed 's/WorkingDirectory=\"\\[dirbin\\]\"/WorkingDirectory=\"dirbin\"/g' files.wxi > a.tmp") or die "Fatal -- Couldn't modify files.wxi.";
!system("mv a.tmp files.wxi") or die "Fatal -- Couldn't update files.wxi.";
- # Update paths in site-local.wxi:
- my $dblback_originalDir = $originalDir;
- $dblback_originalDir =~ s/\\/\\\\/g;
- !system("sed -f $dblback_originalDir\\site-local.sed site-local.wxi > b.tmp") or die "Fatal -- Couldn't modify site-local.wxi.";
- my $hexback_wd = $wd;
- $hexback_wd =~ s/\\/\\\\\\\\\\\\/g;
- !system("sed 's/%%TARGETDIR%%/$hexback_wd\\\\\\staging\\\\\\/' b.tmp > c.tmp") or die "Fatal -- Couldn't modify site-local.wxi temporary file.";
- !system("sed 's/%%CONFIGDIR%%/$hexback_wd\\\\\\staging\\\\\\sample\\\\\\/' c.tmp > d.tmp") or die "Fatal -- Couldn't modify site-local.wxi temporary file.";
- !system("mv d.tmp site-local.wxi") or die "Fatal -- Couldn't replace site-local.wxi.";
-
+ # Make sed script to run on the site-local configuration files:
+ local $tmpfile = "site-local.sed" ;
+ system("del $tmpfile");
+ # Basic substitutions:
+ local $dblback_staging = "$wd\\staging";
+ $dblback_staging =~ s/\\/\\\\/g;
+ !system("echo s/%TARGETDIR%/$dblback_staging/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ local $dblback_sample = "$wd\\staging\\sample";
+ $dblback_sample =~ s/\\/\\\\/g;
+ !system("echo s/%CONFIGDIR-WIX%/$dblback_sample/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo s/%CONFIGDIR-NSI%/$dblback_staging/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo s/%VERSION_MAJOR%/$config->{Versions}->{'VER_PROD_MAJOR_STR'}/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo s/%VERSION_MINOR%/$config->{Versions}->{'VER_PROD_MINOR_STR'}/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo s/%VERSION_PATCH%/$config->{Versions}->{'VER_PROD_REV_STR'}/ >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ # Strip out some defines so they can be replaced: [used for site-local.nsi]
+ !system("echo /\^!define\.\*RELEASE\.\*\$/d >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo /\^!define\.\*DEBUG\.\*\$/d >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+ !system("echo /\^!define\.\*BETA\.\*\$/d >> $tmpfile") or die "Fatal -- Couldn't modify $tmpfile.";
+
+ # Run the script on site-local.wxi:
+ !system("sed -f $tmpfile site-local-tagged.wxi > site-local.wxi") or die "Fatal -- Couldn't modify site-local.wxi.";
+
+ # Now update site-local.nsi:
+ chdir "..\\nsis";
+ print "Info -- chdir to ".`cd`."\n" if ($verbose);
+ local $tmpfile = "site-local.sed" ;
+ !system("sed -f ..\\wix\\$tmpfile site-local-tagged.nsi > b.tmp") or die "Fatal -- Couldn't modify site-local.wxi.";
+ # Add DEBUG or RELEASE:
+ if ($switches[0]->{debug}->{value}) { ## debug build
+ !system("echo !define DEBUG >> b.tmp") or die "Fatal -- Couldn't modify b.tmp.";
+ }
+ else { ## release build
+ !system("echo !define RELEASE >> b.tmp") or die "Fatal -- Couldn't modify b.tmp.";
+ !system("echo !define NO_DEBUG >> b.tmp") or die "Fatal -- Couldn't modify b.tmp.";
+ }
+ # Add BETA if present:
+ if ( exists $config->{Versions}->{'BETA_STR'}) {
+ !system("echo !define BETA $config->{Versions}->{'BETA_STR'} >> b.tmp") or die "Fatal -- Couldn't modify b.tmp.";
+ }
+ !system("mv -f b.tmp site-local.nsi") or die "Fatal -- Couldn't replace site-local.nsi.";
+
if ($verbose) {print "Info -- *** End prepackage.\n";}
if ($verbose) {print "Info -- *** Begin package.\n";}
@@ -428,7 +521,6 @@ sub main {
$config->{Stages}->{PostPackage}->{CopyList}->{Config}->{From}->{root} = "$src\\pismere"; ## Used after zips are made.
$config->{Stages}->{PostPackage}->{CopyList}->{Config}->{To}->{root} = "$src\\$toRoot\\ziptemp";
- my $filestem = $config->{Stages}->{PostPackage}->{Config}->{FileStem}->{name};
local $i = 0;
while ($zipsXML->{Zip}[$i]) {
@@ -473,7 +565,7 @@ sub main {
# Prune any unwanted files or directories from the directory we're about to zip:
if (exists $zip->{Prunes}) {
- # Use Unix find instead of Windows find. Save PATH so we can restore it when we're3 done:
+ # Use Unix find instead of Windows find. Save PATH so we can restore it when we're done:
my $savedPATH = $ENV{PATH};
$ENV{PATH} = $config->{CommandLine}->{Directories}->{unixfind}->{path}.";".$savedPATH;
my $prunes = $zip->{Prunes};
diff --git a/src/windows/build/copyfiles.pl b/src/windows/build/copyfiles.pl
index a6b4ede..5e4200b 100644
--- a/src/windows/build/copyfiles.pl
+++ b/src/windows/build/copyfiles.pl
@@ -82,6 +82,12 @@ sub copyFiles {
$from =~ s/%filestem%/$FileStemFragment/g;
$to =~ s/%filestem%/$FileStemFragment/g;
}
+ # %-DEBUG% substitution:
+ local $DebugFragment = ($switches[0]->{debug}->{value}) ? "-DEBUG" : "";
+if ($from =~ /\-DEBUG/) {print "\n$from ... \n";}
+ $from =~ s/%\-DEBUG%/$DebugFragment/g;
+ $to =~ s/%\-DEBUG%/$DebugFragment/g;
+if ($from =~ /DEBUG/) {print "\n$from ... \n";}
$to =~ s/\*.*//; ## Truncate to path before any wildcard
my $bCopyOK = 1;
diff --git a/src/windows/installer/nsis/site-local-tagged.nsi b/src/windows/installer/nsis/site-local-tagged.nsi
new file mode 100644
index 0000000..26ad541
--- /dev/null
+++ b/src/windows/installer/nsis/site-local-tagged.nsi
@@ -0,0 +1,13 @@
+!define KFW_TARGETDIR %TARGETDIR%
+!define KFW_CONFIG_DIR %CONFIGDIR-NSI%
+!define KFW_MAJORVERSION %VERSION_MAJOR%
+!define KFW_MINORVERSION %VERSION_MINOR%
+!define KFW_PATCHLEVEL %VERSION_PATCH%
+!define CL_1310
+
+!define RELEASE
+!define NOT_DEBUG
+!define BETA 1
+!define SAMPLE_CONFIG_REALM "ATHENA.MIT.EDU"
+!define HTTP_CONFIG_URL "[Obtain a URL from your Kerberos administrator]"
+
diff --git a/src/windows/installer/nsis/site-local.nsi b/src/windows/installer/nsis/site-local.nsi
deleted file mode 100644
index 15c8620..0000000
--- a/src/windows/installer/nsis/site-local.nsi
+++ /dev/null
@@ -1,13 +0,0 @@
-!define KFW_TARGETDIR c:\projects\autobuild\pismere\staging
-!define KFW_CONFIG_DIR "c:\projects\autobuild\pismere\staging"
-!define KFW_MAJORVERSION 3
-!define KFW_MINORVERSION 2
-!define KFW_PATCHLEVEL 0
-!define CL_1310
-
-!define RELEASE
-!define NOT_DEBUG
-!define BETA 1
-!define SAMPLE_CONFIG_REALM "ATHENA.MIT.EDU"
-!define HTTP_CONFIG_URL "[Obtain a URL from your Kerberos administrator]"
-
diff --git a/src/windows/installer/wix/site-local.wxi b/src/windows/installer/wix/site-local-tagged.wxi
index ce31bd9..2b48e50 100644
--- a/src/windows/installer/wix/site-local.wxi
+++ b/src/windows/installer/wix/site-local-tagged.wxi
@@ -1,99 +1,105 @@
-<?xml version="1.0" encoding="utf-8"?>
-<Include xmlns="http://schemas.microsoft.com/wix/2003/01/wi">
-
- <!-- User configurable options -->
-
- <!-- TargetDir should point to build target directory and must end with
- a backslash. If not specified, assume we are in TargetDir\install -->
-
- <?define TargetDir="c:\temp\kfw\kfw-3.2.0-alpha\"?>
-
- <!-- ConfigDir should point to directory containing configuration files
- (krb5.ini, krb.con, krbrealm.con) to be bundled with the installer.
- The directory name should end with a backslash. -->
-
- <?define ConfigDir="C:\Projects\Autobuild\pismere\staging\sample\"?>
-
- <!-- VersionMajor, VersionMinor and VersionPatch must all be specified, or
- none should be specified (in which case, the defaults will be
- selected below. -->
-
- <!-- version defs go here -->
-
- <!-- BuildLang is the language code for the installation. If you are
- changing this, you should also change the ProductCode below. -->
- <?ifndef BuildLang?>
- <?define BuildLang="1033"?>
- <?endif?>
-
- <!-- ProductCode is an uppercase GUID. Each release should have its
- own ProductCode. If one is not defined, we generate a random one. -->
- <?ifndef ProductCode?>
- <?define ProductCode="????????-????-????-????-????????????"?>
- <?endif?>
-
- <!-- DefaultRealm, is your default realm. Must be uppercase -->
- <?define DefaultRealm="ATHENA.MIT.EDU"?>
-
- <!-- One of the following must be defined and must correspond to the
- version of compiler used for building Kerberos for Windows -->
-
- <!-- <?define CL1200?> -->
- <!-- <?define CL1300?> -->
- <?define CL1310?>
- <!-- <?define CL1400?> -->
-
- <!-- At most one of the following could be defined and must correspond
- to the type of build performed. -->
- <!-- <?define Debug?> -->
- <?define Release?>
-
- <!-- We are including debug symbols anyway. Undefine this for a leaner
- installer without debug syms. -->
- <?define DebugSyms?>
-
- <!-- Optional defines -->
- <?define Beta="1"?> <!-- Numeric Beta identifier -->
- <!-- <?define OldHelp?> --> <!-- Specifies the use of the old leash32.hlp file
- instead of the new leash32.chm file -->
-
-
- <!-- End of user configurable options -->
-
- <!-- Assert that required options are defined, or select defaults if
- they weren't -->
-
- <?ifndef TargetDir?>
- <?define TargetDir="$(sys.SOURCEFILEDIR)..\"?>
- <?endif?>
-
- <?ifndef ConfigDir?>
- <?define ConfigDir="$(env.SystemRoot)\"?>
- <?endif?>
-
- <?ifndef VersionMajor?>
- <?define VersionMajor="3"?>
- <?define VersionMinor="2"?>
- <?define VersionPatch="0"?>
- <?else?>
- <?if Not ($(var.VersionMinor) And $(var.VersionPatch))?>
- <?error VersionMajor, VersionMinor and VersionPatch should be specified together?>
- <?endif?>
- <?endif?>
-
- <?ifndef ProductCode?>
- <?error Must define ProductCode?>
- <?endif?>
-
- <?ifndef BuildLang?>
- <?error Must define BuildLang?>
- <?endif?>
-
- <!-- DefaultRealm. Must be uppercase. -->
- <?ifndef DefaultRealm?>
- <?error Must define DefaultRealm?>
- <?endif?>
-
- <!-- The build makefile defines 'Date' and 'Time' which are strings that
- identify the time at which the build was performed. -->
+<?xml version="1.0" encoding="utf-8"?>
+<Include xmlns="http://schemas.microsoft.com/wix/2003/01/wi">
+
+ <!-- User configurable options -->
+
+ <!-- Items enclosed in double percent marks will be substituted by
+ the build script. -->
+
+ <!-- TargetDir should point to build target directory and must end with
+ a backslash. If not specified, assume we are in TargetDir\install -->
+
+ <?define TargetDir="%TARGETDIR%\"?>
+
+ <!-- ConfigDir should point to directory containing configuration files
+ (krb5.ini, krb.con, krbrealm.con) to be bundled with the installer.
+ The directory name should end with a backslash. -->
+
+ <?define ConfigDir="%CONFIGDIR-WIX%\"?>
+
+ <!-- VersionMajor, VersionMinor and VersionPatch must all be specified, or
+ none should be specified (in which case, the defaults will be
+ selected below. -->
+
+ <!-- version defs go here -->
+ <?define VersionMajor="%VERSION_MAJOR%"?>
+ <?define VersionMinor="%VERSION_MINOR%"?>
+ <?define VersionPatch="%VERSION_PATCH%"?>
+
+ <!-- BuildLang is the language code for the installation. If you are
+ changing this, you should also change the ProductCode below. -->
+ <?ifndef BuildLang?>
+ <?define BuildLang="1033"?>
+ <?endif?>
+
+ <!-- ProductCode is an uppercase GUID. Each release should have its
+ own ProductCode. If one is not defined, we generate a random one. -->
+ <?ifndef ProductCode?>
+ <?define ProductCode="????????-????-????-????-????????????"?>
+ <?endif?>
+
+ <!-- DefaultRealm, is your default realm. Must be uppercase -->
+ <?define DefaultRealm="ATHENA.MIT.EDU"?>
+
+ <!-- One of the following must be defined and must correspond to the
+ version of compiler used for building Kerberos for Windows -->
+
+ <!-- <?define CL1200?> -->
+ <!-- <?define CL1300?> -->
+ <?define CL1310?>
+ <!-- <?define CL1400?> -->
+
+ <!-- At most one of the following could be defined and must correspond
+ to the type of build performed. -->
+ <!-- <?define Debug?> -->
+ <?define Release?>
+
+ <!-- We are including debug symbols anyway. Undefine this for a leaner
+ installer without debug syms. -->
+ <?define DebugSyms?>
+
+ <!-- Optional defines -->
+ <?define Beta="1"?> <!-- Numeric Beta identifier -->
+ <!-- <?define OldHelp?> --> <!-- Specifies the use of the old leash32.hlp file
+ instead of the new leash32.chm file -->
+
+
+ <!-- End of user configurable options -->
+
+ <!-- Assert that required options are defined, or select defaults if
+ they weren't -->
+
+ <?ifndef TargetDir?>
+ <?define TargetDir="$(sys.SOURCEFILEDIR)..\"?>
+ <?endif?>
+
+ <?ifndef ConfigDir?>
+ <?define ConfigDir="$(env.SystemRoot)\"?>
+ <?endif?>
+
+ <?ifndef VersionMajor?>
+ <?define VersionMajor="3"?>
+ <?define VersionMinor="2"?>
+ <?define VersionPatch="0"?>
+ <?else?>
+ <?if Not ($(var.VersionMinor) And $(var.VersionPatch))?>
+ <?error VersionMajor, VersionMinor and VersionPatch should be specified together?>
+ <?endif?>
+ <?endif?>
+
+ <?ifndef ProductCode?>
+ <?error Must define ProductCode?>
+ <?endif?>
+
+ <?ifndef BuildLang?>
+ <?error Must define BuildLang?>
+ <?endif?>
+
+ <!-- DefaultRealm. Must be uppercase. -->
+ <?ifndef DefaultRealm?>
+ <?error Must define DefaultRealm?>
+ <?endif?>
+
+ <!-- The build makefile defines 'Date' and 'Time' which are strings that
+ identify the time at which the build was performed. -->
</Include> \ No newline at end of file