Old 8th July 2003, 03:00   #1
test
Junior Member
 
Join Date: Dec 2002
Posts: 12
Bde?

G'Day Group,

Does any of you have a script template to install (and hopefully configure) the Borland Database Engine from NSIS?

Thanks a million !
test is offline   Reply With Quote
Old 8th July 2003, 09:50   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
It doesn't seem like Borland helps their developers to do it. They only have a MSI merge module (can anybody say monopoly? ). If you can find something that explains how to get it working with another installer I can help you convert it to NSIS script.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 8th July 2003, 15:14   #3
MoNKi
Senior Member
 
Join Date: Aug 2002
Location: Spain
Posts: 112
I have found some information on how to install BDE using Inno, you only need to convert the script to use it in NSIS, but i don't know if i can post the url here.
MoNKi is offline   Reply With Quote
Old 8th July 2003, 15:26   #4
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
InnoSetup is open source too, I don't think there should be any problem. I personally wouldn't mind if it was the other way around.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 8th July 2003, 15:30   #5
MoNKi
Senior Member
 
Join Date: Aug 2002
Location: Spain
Posts: 112
Ok kichik, here is the url:

http://www.jrsoftware.org/ishowto.phtml?a=bde

It uses a program to create aliases, maybe someboy can make a nsis plugin for it.
MoNKi is offline   Reply With Quote
Old 8th July 2003, 15:40   #6
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Well according to this page you have a file called BDEINST.CAB located in Program Files\Common Files\Borland Shared\BDE. Extract BDEINST.DLL from this file and use:

code:
GetTempFileName $0
File /oname=$0 C:\Path\To\Extracted\BDEINST.DLL
RegDLL $0



As for the aliases DLL, you'd need Delphi or Borland C++ Builder to build it. Both of which I don't have. You can either use the EXE in there (if the license permits it) or find someone with Delphi or Borland C++ Builder to create the DLL for you. It's possible that you can use BDE in Visual C++ too but I'm afraid I don't know how. If you know it, please share

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 9th July 2003, 02:12   #7
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
I do have delphi and could try to create a dll for this purpose, however i am not sure how to interface delphi dll's to NSIS plugin.

[edit]I downloaded the AddAlias program from the specified link and it is a free program for any use.[/edit]

Vytautas

Last edited by Vytautas; 9th July 2003 at 03:52.
Vytautas is offline   Reply With Quote
Old 9th July 2003, 04:38   #8
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Just a few questions about the plugin system:
1. Would it need to return a a value to indicate if the task was performed succesfully.
2. What calling convention does the NSIS plugin system use.
3. After having a look at the AddAlias program it looks like the plugin will have to take 3 string (PChar) arguments. How do you transfer arguments between NSIS and the plugin?

Vytautas
Vytautas is offline   Reply With Quote
Old 9th July 2003, 12:11   #9
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
There's an example Delphi plug-in in Contrib\ExDLL. It answers everything you've asked.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 9th July 2003, 12:18   #10
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Thanks, I'll try to convert the AddAlias program into a plugin dll.

Vytautas
Vytautas is offline   Reply With Quote
Old 16th July 2003, 12:22   #11
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Sorry about the delay, had some problems with the programming computer.

Attached is the BDE Alias Plugin. I will create an achive page for this ASAP.

Vytautas

BTW How do I attach a file to the archive page?

PS If you would like the delphi source code for the plugin please contact me.
Attached Files
File Type: zip bdealias.zip (35.5 KB, 542 views)
Vytautas is offline   Reply With Quote
Old 16th July 2003, 12:27   #12
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
To upload files to the Archive you need admin privileges. You can send it to me, attach it here or upload it to somewhere I can download it and I'll upload it for you.

If you're already creating an archive page for this plug-in, how about including all of the required data to install BDE?

BTW, The standard with plug-ins is to get the arguments on the stack, not through the variables $0, $1, etc.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th July 2003, 12:34   #13
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
I tried setting the data through the stack however I kept getting this error after the plugin command: 'the exception unknown software eception (0x0eedfade) ocurred in the application at location 0x77e8f142'.

After removing the variable transfer from the stack the error disapeared, so I think there might be some incompatibility between delphi 7 and NSIS.

Vytautas
Vytautas is offline   Reply With Quote
Old 16th July 2003, 12:42   #14
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Does the example work?

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th July 2003, 12:49   #15
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
If you mean the exDLL example then yes it did work, although it only got one variable of the stack, if that makes any difference?

Vytautas
Vytautas is offline   Reply With Quote
Old 16th July 2003, 12:52   #16
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
The example only pops one value so it only gets one value. If the example works then there is probably something wrong with your code. If you upload/send me the related code part I can try to help you with it.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 16th July 2003, 12:56   #17
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Thanks kichik i'll post the code tomorrow as the 'original' source code is at work.

Vytautas
Vytautas is offline   Reply With Quote
Old 17th July 2003, 09:21   #18
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Once again thanks kichik, I had deleted the original source code and only had a hard copy, so I descided to recreate the plugin using the stack from scratch and it worked. Now I think the problem was caused by me trying to convert PChar into delphi string or something similar. Attached is the new version of the plugin, if you could appach it to my archive page that would be greatly appreciated.

Vytautas
Attached Files
File Type: zip bdealias.zip (35.3 KB, 410 views)
Vytautas is offline   Reply With Quote
Old 17th July 2003, 11:19   #19
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Done.

http://nsis.sourceforge.net/archive/...e=bdealias.zip

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 23rd July 2003, 00:07   #20
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Installer Error

I tried the compiled version of the BDE Installer program and for me it generates this error when installing BDE. See attached image of the error message. At first I thought it might be just a problem with the dll file however it works fine when using regsvr32, outside of NSIS.

Vytautas
Vytautas is offline   Reply With Quote
Old 23rd July 2003, 00:11   #21
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Lets try this again.

Vytautas
Attached Images
File Type: jpg bdeerror.jpg (46.7 KB, 681 views)
Vytautas is offline   Reply With Quote
Old 23rd July 2003, 12:03   #22
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Let me take a wild guess... You're running Windows 9x and it works when you use RegDLL /NOUNLOAD. Am I correct?

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 23rd July 2003, 12:37   #23
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Well no, I tried this on Win98, Win2k & WinXP with same results. When I tried using /NOUNLOAD switch the dialog in the dll did not show at all, i.e. it did not run. Am I using the switch correctly?
code:
GetTempFileName $0
File /oname=$0 BDEINST.DLL
RegDLL $0 /NOUNLOAD



Vytautas
Vytautas is offline   Reply With Quote
Old 23rd July 2003, 12:37   #24
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
No, the other way around. RegDLL /NOUNLOAD $0.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 23rd July 2003, 12:52   #25
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Same result. BTW I'm using MUI and newest CSV, from 30 seconds ago, if that makes any difference.

Vytautas
Vytautas is offline   Reply With Quote
Old 23rd July 2003, 16:26   #26
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
A little confusion... Use:

CallInstDLL dllname.dll /NOUNLOAD DllRegisterServer

But on second thought, if the first wasn't right then the whole thing isn't right. Ramon is working on it right now, more examples would be nice.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 24th July 2003, 00:36   #27
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Thanks that seemed to work, no error message, will test further to make sure though. So is it better to use "CallInstDLL dllname.dll /NOUNLOAD DllRegisterServer" command instead of "regdll"?

Vytautas
Vytautas is offline   Reply With Quote
Old 24th July 2003, 03:07   #28
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Do I need to 'unload' the dll after it is finished, it all works great in win2k but when i use win98se it install with no problems and the installer continues and displays the nsis finish page however the bde installation progress windows does not close down until nsis instoler is closed. Is there anything I can do to rectify this?

Vytautas

PS what examples do you need?
Vytautas is offline   Reply With Quote
Old 24th July 2003, 04:15   #29
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Just in case it is possible with NSIS

After reading the info on the INNO Site I believe that this is not possible but knowing that NSIS is more powerfull I thought I'll ask anyway.

1) Is it possible to change the dir BDE is installed in from within the script, i.e. modify the dialog box in the BDE Installer.
2) Is it possible to programatically click 'next' in the message box that pops up when installing BDE.

Vytautas
Vytautas is offline   Reply With Quote
Old 25th July 2003, 14:39   #30
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Just one more question: Is there a way to tell if the user canceled the BDE Installation and/or disable the cancel button. Using WinSpy++ I figgured out the name of the dialog and that it was made in delphi just not sure how to firstly find and then modify these elements.

Vytautas
Vytautas is offline   Reply With Quote
Old 25th July 2003, 17:10   #31
ramon18
NSIS Dev
 
ramon18's Avatar
 
Join Date: Apr 2003
Location: Portugal
Posts: 110
Not easy, I think that is good idea forget it, try to check the return value

nsExec::ExecToLog ...
pop $0 -> check if this value is different when you cancel or when setup finish with success.

good luck,
Ramon
ramon18 is offline   Reply With Quote
Old 25th July 2003, 23:19   #32
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
ramon18 how would I use "CallInstDLL dllname.dll /NOUNLOAD DllRegisterServer" with nsExec plugin?

Vytautas
Vytautas is offline   Reply With Quote
Old 26th July 2003, 00:29   #33
MoNKi
Senior Member
 
Join Date: Aug 2002
Location: Spain
Posts: 112
I have found this, a program that checks if bde is installed or not (with delphi source code) and a wise setup script. Is better than nothing.
http://ibinstall.defined.net/dl_bdeinfo.htm

And more info about bde installation:
http://www.bdesupport.com/deploy.htm
MoNKi is offline   Reply With Quote
Old 8th September 2003, 03:03   #34
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
The problem with the BDE installation dll appears to be fixed in the latest CSV version. Thanks to all the devs for making NSIS as bug free as possible.

Vytautas
Vytautas is offline   Reply With Quote
Old 17th December 2003, 23:36   #35
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Could someone upload this update to the AddAlias Plugin. Now it allows to specify other parameters when adding an alias such as the user name.

Vytautas
Attached Files
File Type: zip bdealias-0.3.zip (35.3 KB, 413 views)
Vytautas is offline   Reply With Quote
Old 17th December 2003, 23:38   #36
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
SF shell servers doesn't seem to like me at the moment. Status page says it's ok, but I can't connect

I'll try again tomorrow.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 18th December 2003, 05:02   #37
cchian
Member
 
Join Date: Apr 2001
Posts: 73
Will this also work for 16-bit BDE?
cchian is offline   Reply With Quote
Old 18th December 2003, 05:41   #38
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Not sure since I do not have a 16-bit version. Just try it on your system with a test script and then check using BDE Admin to see if the Alias was created or not.

Vytautas
Vytautas is offline   Reply With Quote
Old 18th December 2003, 12:01   #39
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Uploaded.

BTW, how did you get it to not use MSVCRT.dll or did compile with something else than MinGW?

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 18th December 2003, 12:05   #40
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Well actually this plugin was made with Delphi, no need for MSVCRT.dll

Vytautas
Vytautas 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