[freenet-dev] NSIS diffs for improved wininstaller (was : freenet-java-webinstall.exe still bundled with J2RE 1.4.1_03??)

2005-11-06 Thread mazzanet
Can you resend those patches as attachments, some of the hunks fail 
(probably due to email formatting).

When I get my local copy patched I'll have a stab at it with sharp 
implements and rebuild+upload it.


Matt


Bob wrote:
> OK, here's the diffs. With wonderful timing, my boot
> drive died just as I was
> finishing up :(  I did the old stick-it-in-the-freezer
> trick and it's working
> again for now.
> 
> Anyway, because of this they're not quite perfect
> (still have the "can try and
> download JRE from snapshots" issue, not that this is
> particularly likely to crop
> up) but other than that they seem to work quite well.
> 
> I will attempt to upload the UNOFFICIAL exe's to the
> FTP mentioned upthread too
> for anyone who wants to test them.
> 
> 
> --- freenet-modern.nsi_ORIG   2005-11-05
> 00:21:30.0 +
> +++ freenet-modern.nsi2005-11-05 00:01:00.0
> +
> @@ -26,7 +26,7 @@
>  !define PRODUCT_NAME "Freenet"
>  !define WEBINSTALL  #  the default install type
>  !define BUILDDATE 20041124
> -!define JAVAINSTALLER "jre-win32-latest.exe"
> +# !define JAVAINSTALLER "jre-win32-latest.exe"
> 
>  
>  !ifdef WEBINSTALL
>   !define PRODUCT_VERSION "Webinstall"
> @@ -165,6 +165,8 @@
>   GetFullPathName /SHORT $2 $EXEDIR # same for EXEDIR
> into $2
>   GetFullPathName /SHORT $R0 $TEMP # same for TEMP
> into $R0
>  
> +# MessageBox MB_OK "Temp is $R0, Exedir is $2"
> 
> +
> 
>   # make sure the files we're downloading don't
> already exist in the temp dir:
>   SetDetailsPrint none
>   Delete "$R0\freenet-install\*.*"
> @@ -344,10 +346,10 @@
>   IfFileExists "$R0\freenet-install\seednodes.ref"
> NoDownloadSeednodes
>   # if "Don't Prompt Me" is selected the following
> message box will not appear
> and seed download will be automatic
>   # ###TODO
> - MessageBox MB_YESNO "To connect to the Freenet
> network, your Freenet node
> needs to know about at least one other Freenet
> node.$\r$\nThis is called a 'Node
> Reference' or 'seednodes.ref' file.$\r$\nDo you want
> to download 'seednodes.ref'
> from the Free Net Project's servers?$\r$\nYou may want
> to say NO if you have
> been given a .ref file by a friend,$\r$\nor if you
> have installed Freenet before
> and still have the file named seednodes.ref" IDNO
> NoDownloadSeedNodes
> - Push
> "http://freenetproject.org/snapshots/seednodes.ref;
> + MessageBox MB_YESNO "To connect to the Freenet
> network, your Freenet node
> needs to know about at least one other Freenet
> node.$\r$\nThis is called a 'Node
> Reference' or 'seednodes.ref' file.$\r$\nDo you want
> to download a compressed
> 'seednodes.ref' from the Free Net Project's
> servers?$\r$\nYou may want to say NO
> if you have been given a .ref file by a
> friend,$\r$\nor if you have installed
> Freenet before and still have the file named
> seednodes.ref" IDNO NoDownloadSeedNodes
> 
> + Push
> "http://freenetproject.org/snapshots/seednodes.zip;
> 
>   Push "$R0\freenet-install"
> - Push "seednodes.ref"
> + Push "seednodes.zip"
> 
>   Call RetryableDownload
>   StrCmp $0 "success" seedsuccess
>   MessageBox MB_YESNO "Couldn't download seednodes.ref
> - Without this file
> Freenet will not work.$\r$\nDo you want to continue
> installation anyway?  (You
> will still need to download seednodes.ref yourself)"
> IDYES NoDownloadSeedNodes
> @@ -356,6 +358,8 @@
>   seedsuccess:
>   ClearErrors
>  
> +# Should have seednodes.zip if we're here
> 
> +
> 
>   NoDownloadSeedNodes:
>  
>   StrCmp "$3" "${NUMBER_OF_DOWNLOADABLE_FILES}"
> DoneGettingFiles
> @@ -409,6 +413,28 @@
>   File update\UpdateSnapshot.exe
>   IfErrors DiskWriteError
>  
> +
> 
> +IfFileExists "$INSTDIR\seednodes.zip" unzipSeednodes
> 
> +
> 
> +# If we haven't got it for some reason, jump to error
> handler
> 
> +goto unzipSeednodesDownloadError
> 
> +
> 
> +# Bob H : We've got seednodes, unzip them
> 
> +# We must run before NodeConfig, or it will
> "helpfully" go and download the
> uncompressed seednodes.ref itself without asking!
> 
> +unzipSeednodes:
> 
> +DetailPrint "Decompressing seednodes, please wait
> ..."
> 
> + # We extract it to temp install dir first, to stop
> NodeConfig downloading
> seednodes.ref
> 
> +ZipDLL::extractall
> "$R0\freenet-install\seednodes.zip"
> "$R0\freenet-install"
> 
> + # Then copy to final install dir
> 
> +CopyFiles "$R0\freenet-install\seednodes.ref"
> "$INSTDIR"
> 
> + goto seednodesUnzipped
> 
> +
> 
> +unzipSeednodesDownloadError:
> 
> +MessageBox MB_OK "Sorry, the compressed seednodes
> 'seednodes.zip' could not be
> found.$\r$\nA seednodes file is needed for freenet to
> work.$\r$\nYou could try
> downloading seednodes manually from :$\r$\n
> http://freenetproject.org/snapshots/;
> 
> +
> 
> +seednodesUnzipped:
> 
> +
> 
> +
> 
>   # Step 3- Merge ini files
>   # Step 3a - create a default .ini file
>   IfFileExists "$INSTDIR\default.ini" 0
> NoFreenetIniDefaults
> @@ -582,6 +608,8 @@
>Delete "$INSTDIR\flaunch.ini"
>Delete "$INSTDIR\freenet.ini"
>Delete 

[freenet-dev] Re: Wininstaller NSIS diffs as attachments

2005-11-06 Thread Bob
These should now be committed to subversion.

Bob