Old 28th March 2001, 21:55   #1
justin
Moderator Alumni
 
Join Date: Apr 2000
Location: USA
Posts: 315
OK I put 1.1z up on http://www.firehose.net/free/nsis/
(which apparently will finally get pushed to nullsoft.com).

Since I'm out of letters, I'm going to make the next version (which will soley fix bugs, no new features) 1.2.0. Yay.

For fun, here's a list of everything (in reverse-chronological order) that I've done to NSIS in the last month. The end result is a lot more functionality, and a lot less overhead (the current exe header size is 32kb, whereas it used to be about 40kb).

  • Moved licensedata into string table out of datablock
  • Removed NSIS_CONFIG_CREATESHORTCUT config option (it really didn't add much)
  • Additional exehead size optimizations (making it use global variables more instead of passing them around and copying them).
  • Made DeleteOnReboot code check for duplicates in wininit.ini on win9x.
  • Enlarged resources a bit to make more room for shit (dynamic sized resources would be nice, hmm)
  • Made install info+string table etc in datablock.
  • Made uninstall info that is written to uninstaller compressed now.
  • This makes for slightly smaller installers, typically.
  • Made install types and section names stored in string table (less overhead, less stupid static string length limitations)
  • Raised the maximum number of install types to 8 from 4 and made it a keen #define (who cares?)
  • Added DeleteFileOnReboot function to util.c
  • Added /ONREBOOT switch to Delete instruction
  • Made uninstaller delete itself after reboot
  • Updated CRC checking code for size and speed (no more seeking)
  • Updated integrity checks to check for correct length (even when CRC checking is off)
  • Made minimum post-header length of 516 bytes when CRC is enabled (in order to simplify the exehead).
  • Made cancel selected when the install is aborted.
  • Fixed a few potential bugs in libc
  • Made OLE/COM initialization better (no more open and close and open and close)
  • Reduced size even more (zlib table optimizations and such! - decompression is slower now though, but the header is 35840 bytes with all features on)
  • Removed NSIS_CONFIG_COPYFILES config option (it's small anyway)
  • Made installation logging off by default (default header size is 31744 bytes, yay!)
  • Updated uninstall system to not litter up your temporary directory with tons of nsu* files (it now only creates 26 possible files, and cleans up unused ones on uninstall)
  • Reduced size of header by 1k (40960 bytes now with all features turned on)
  • Cleaned up a lot of code/errors/etc in exehead
  • Cleaned up error/warning handling in compiler
  • Added !error and !warning
  • Added DeleteINISec and DeleteINIStr commands
  • Added jump:X mode to FindWindow
  • Made Nop instruction also work as Jump, added Jump command.
  • Made section adding more strict (you have to create all sections, none by default to make it less prone to bugs)
  • Removed a lot of section related bugs.
  • Added Abort command.
  • Added SetDetailsView.
  • Added FindWindowByTitle (uses FindWindow but with small diffs)
  • Fixed bad DeleteRegKey bug that was introduced in 1.1o.
  • Fixed a few component selector bugs. Seems to be fine now.
  • Added SectionDivider command and divider sections and all that jazz.
  • Added $\r and $\n variables (for carriage return and newline, respectively)
  • Made install.log write \r\n instead of \n.
  • Optimized header size more (it is still the same size, even though stuff was added)
  • Added optional /r switch for RMDir (removes recursive directories and deletes all files (read-only or not) from them.
  • Made Delete delete read-only files.
  • Massive changes to the way strings are handled. Strings are no longer in the data block, but instead in their own string table which is compressed with the header and stored in memory by the installer stub. This is a) faster, and b) allows us to compress the strings. Also, the static strings that the installer needs are no longer stored directly, instead "pointers" to them in the string table are stored (meaning many of the static length restrictions are gone). Doing this also simplifies much of exec.c, making the installer smaller. TODO: make all of the user messages configurable (maybe). Overall these changes produce installers that are about 1-2k smaller.
    optimized datablock_optimize
  • Changed the format of the output statistics.
  • Broke stuff (see above)
  • Added IfFileExists instruction for branching based on file/directory presence (takes wildcards, too)
  • Changed ExecuteEntry so that branching instructions (such as MessageBox and IfFileExists) can go back if necessary (oops - negative ones were broken before.)
  • Made add_data_compress and GetCompressedDataFromDataBlock use a slightly more efficient form (1 byte per block is saved, maximum file size is now 2gb instead of 4gb)
  • Created BIGTEST.NSI which tests/demonstrates nearly all of the functionality of NSIS.
  • Added Nop instruction
  • Made it possible to put comments at the end of the line (using ; or # to deliminate it) .. if you need a parameter to start with ; or #, use quotes.
  • Fixed GetCompressedDataFromDataBlockToMemory() (this was causing licenses to be truncated).
  • Made MessageBox and FindWindow strings able to use variables
  • Made last two parameters of MessageBox optional
  • Cleaned up some resources (maintained 41.5k header size even though we added some instructions etc)
  • Made it so that if the first section starts with - (or is ""), it is not shown in the section list.
  • Made it so that sections beginning with a - are treated like empty sections (and are required, and not shown).
  • Made SectionIn command additive. i.e. SectionIn 1\nSectionIn 2 adds the section to types 1 and 2.
  • Made CreateShortCut more configurable (hotkey and showmode).
  • Made integer parser take hexadecimal and octal numbers in addition to decimal.
  • Added new examples (example1.nsi, example2.nsi, waplugin.nsi, and viewhtml.nsi)
  • Reduced size of header 1.5k by removing unused portions of zlib.
  • Improved the InstlalDirRegKey logic to handle quotes in the strings better.
  • Removed winamp hack checking (use InstallDirRegKey to find the Winamp directory, in addition to $PROGRAMFILES\Winamp) ex: InstallDirRegKey HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninstall\Winamp" "UninstallString"
  • Got rid of shell.cpp, rewrote CreateShortCut in C (using lpVtbl) and included it in util.c, and inlined Shell_Free in ui.c
  • Removed time clipping on the Sleep command.
  • Made compiler give warnings for certain instances that should not be fatal but should be fixed (i.e. combining LicenseData and SilentInstall)
  • Made the install info header compressable (typically saves a few kb)
  • Made the uninstall data compressable (typically saves ~1kb)
  • Prettied up the output of statistics
  • Made the space required/available displays show KB, MB, or GB.
  • Made both exehead and compiler use the same zlib directory.
  • made nsisconf.nsi included if available (lets you configure defaults)
  • added PackEXEHeader command to let you use UPX or Petite or any other packer on the header.
    removed one extra resource from exehead to shrink installer slightly.
  • changed compression system to do one big deflate (should be slightly more efficient)
  • added SetDatablockOptimize command and made it off by default (SLOW! :)
  • made compiler print more info (compression bytes saved, etc)
  • fixed silentinstall uninstall bug

Love,

Justin
justin is offline   Reply With Quote
Old 29th March 2001, 02:30   #2
c2R
Stereotype?
(Forum King)
 
c2R's Avatar
 
Join Date: Jan 2001
Location: Ware, England
Posts: 3,511
Thanks Justin. Thats a lot of work for just one month's worth!

What I do in programs I write for work is to use a numbering system without letters - thus getting around the problem of only 26 bugfix releases...

Regards.
c2R is offline   Reply With Quote
Old 29th March 2001, 16:47   #3
Thor
Major Dude
 
Thor's Avatar
 
Join Date: May 2000
Location: Gent, Belgium (Europe)
Posts: 968
Send a message via ICQ to Thor Send a message via AIM to Thor
Cool beans Justin ! Keep it up!

Question :
you used to have this little list of todo's for "future 1.1 version" ... It's no longer there now ...
Have all those features (like DLL versions checking) been added ? Or are you still planning to do that for 1.2 releases ?
Thor is offline   Reply With Quote
Old 30th March 2001, 00:43   #4
PabUK
Major Dude
 
PabUK's Avatar
 
Join Date: Jan 2001
Location: .com/munity
Posts: 1,278
Love the constant updating!
PabUK is offline   Reply With Quote
Old 31st March 2001, 13:24   #5
RookieKiwi
Junior Member
 
Join Date: Mar 2001
Location: New Zealand
Posts: 5
Bugs introduced in 1.1z


Greetings from New Zealand!

I just love the new installer, great work Justin!

Has anybody else had problems running on Win98SE?
It installs fine, then exits with a "illegal operation" error.

I tried to activate logging via the shift key, but this no longer works. Am I missing something?

It all works fine when I compile with version 1.1j. Only problem is, 1.1j doesn't have the nice new "ifnewer" overwrite option. :-)

Anybody got any ideas?

TIA

Andrew
RookieKiwi is offline   Reply With Quote
Old 31st March 2001, 13:55   #6
PabUK
Major Dude
 
PabUK's Avatar
 
Join Date: Jan 2001
Location: .com/munity
Posts: 1,278
I have a problem like this too. Since a few version back the installer crashes on Win ME at the end, so I had to switch back to 1.1s. Maybe there is something wrong with out install scripts?
PabUK is offline   Reply With Quote
Old 1st April 2001, 02:27   #7
RookieKiwi
Junior Member
 
Join Date: Mar 2001
Location: New Zealand
Posts: 5
Bug with RegDLL on Win9x and ME


After a bit more investigation, the "illegal operation" only occurs if the RegDLL command is used in the script. It works fine on Win2K Pro, but not on Win9x or ME.

I've just confirmed that version 1.2beta also has this problem. I'll try some earlier versions and see if I can find when the problem was introduced.

RookieKiwi is offline   Reply With Quote
Old 1st April 2001, 02:42   #8
PabUK
Major Dude
 
PabUK's Avatar
 
Join Date: Jan 2001
Location: .com/munity
Posts: 1,278
If you find a fix or workaround let me know so I can upgrade to these newer versions!
PabUK is offline   Reply With Quote
Old 1st April 2001, 07:10   #9
RookieKiwi
Junior Member
 
Join Date: Mar 2001
Location: New Zealand
Posts: 5
Work around for RegDLL issue.


This seems to work fine for me...

IfFileExists "$SYSDIR\RegSvr32.exe" 0 2
ExecWait '"$SYSDIR\RegSvr32.exe /s $SYSDIR\vsStr7.ocx"'
Sleep 500

Since the $SYSDIR is where RegSvr32 is located it works on NT/2000 and Win9x. The /s is for silent registration with no popups.

Cheers

Andrew
RookieKiwi is offline   Reply With Quote
Old 1st April 2001, 13:58   #10
PabUK
Major Dude
 
PabUK's Avatar
 
Join Date: Jan 2001
Location: .com/munity
Posts: 1,278
Thanks i'll try that out! Any feedback from Justin on this issue yet?
PabUK is offline   Reply With Quote
Old 2nd April 2001, 07:33   #11
RookieKiwi
Junior Member
 
Join Date: Mar 2001
Location: New Zealand
Posts: 5
RegDLL issue fixed in 1.2


Confirming the RegDLL/Win9x problem is now fixed with version 1.2!

Thanks Justin, you're a champ!
RookieKiwi is offline   Reply With Quote
Old 2nd April 2001, 13:40   #12
PabUK
Major Dude
 
PabUK's Avatar
 
Join Date: Jan 2001
Location: .com/munity
Posts: 1,278
Just to confirm that it has fixed the problem for me too!

Thanks a lot Justin!

In support of aggressive sex with llamas, and freedom from the obligation to explain.
Pawhosting.com | Pawsoft.com | Pawdesign.com | PabUK.com
PabUK is offline   Reply With Quote
Reply
Go Back   Winamp & SHOUTcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump