Archive: Library.nsh


Library.nsh
Hi all I am having this problem with my install script.

This is the error:


!define: "LIBRARY_VERSION_HIGH" already defined!
!include: error in script: "C:\Program Files\NSIS\Contrib\Library\LibraryLocal\LibraryLocal.nsh" on line 1
Error in macro InstallLib on macroline 84
Error in script "C:\Temp\iRing\iRing2.nsi" on line 319 -- aborting creation process


I have nsis 2.0 installed and I recently downloaded the development Snapshot and copied those files over my nsis 2.0 install so that I could use the installlib function.

Here is my script, it is a little messy as I am just learning how to use it(sorry if it is long).

This is the script:

[snip, attached below]

The error and the script do not match. Line 319 contains a comment. Please attach scripts next time, it's very hard to read it this way.


script from original message


Does it work with the attached Library.nsh?


First off, my appologies for inserting the script instead of attaching it. kichik thanks for the replies!

Now, I downloaded the library.nsh and put it into the include folder. When I tried compling the script I get a different error now:


!define: "LIBRARY_DEFINE_UPGRADE_LABEL" already defined!
Error in macro InstallLib on macroline 150
Error in script "C:\Temp\iRing\iRing2.nsi" on line 208 -- aborting creation process


There are no variables like that in my script. So I suspect that it is located in the library.nsh file but I am probably wrong. If this helps, before I added the sections called "-Install Common Components" and "-un.Install Common Components". The script worked well.

OK, I found something interesting. I commented out the sections "-Install Common Components" and "-un.Install Common Components". I compiled the script again and it stopped on this line with the error:

Error:


!define: "LIBRARY_DEFINE_UPGRADE_LABEL" already defined!
Error in macro InstallLib on macroline 150
Error in script "C:\Temp\iRing\iRing2.nsi" on line 175 -- aborting creation process




The line:

!insertmacro InstallLib TLB $ALREADY_INSTALLED REBOOT_PROTECTED "iRing\vb6sp6Runtimes\stdole2.tlb" "$SYSDIR\stdole2.tlb" "$SYSDIR"


So I commented out the above line and it compiled. Could it be having a problem with the *.tlb file?

It's probably not just one line, but a combination of some.

I've fixed the LIBRARY_DEFINE_UPGRADE_LABEL error. If you're still having problems with it, attach the entire script and paste the error so I can see exactly which lines cause this.


It worked. You're awesome! This has got to be one of the best installers around!