netgui68
2009-Jan-22 15:21 UTC
[Wine] Application will only run when executed from its directory
Hi everyone! I am running Wine 1.0 on Linux Mint 5.1. I have a custom developed program that was designed in Delphi using the Borland Database library that will only run correctly if executed from the directory it is contained in. It will not run from the start menu nor will it run from a launcher that I have built on the Desktop. I figure it has to be something with the path referencing. I have scoured the internet and tried many suggestions, however none of which have solved the problem. To be more specific, it seems like the program is unable to find the Borland files. The path to the application is: .wine/drive_c/Scan The path to the Borland dll's, odbc drives, and other shared libraries is: .wine/drive_c/Program Files/Common Files/Borland Shared/BDE/ My main desire is to be able to launch this program from a launcher that I can create on the Desktop, eventually I would like to make this universally accessible to all users. Your help and suggestions would be most appreciated. Thank you!
Austin English
2009-Jan-22 15:25 UTC
[Wine] Application will only run when executed from its directory
On Thu, Jan 22, 2009 at 9:21 AM, netgui68 <wineforum-user at winehq.org> wrote:> Hi everyone! I am running Wine 1.0 on Linux Mint 5.1. I have a custom developed program that was designed in Delphi using the Borland Database library that will only run correctly if executed from the directory it is contained in. It will not run from the start menu nor will it run from a launcher that I have built on the Desktop. I figure it has to be something with the path referencing. I have scoured the internet and tried many suggestions, however none of which have solved the problem. > > To be more specific, it seems like the program is unable to find the Borland files. > > The path to the application is: .wine/drive_c/Scan > The path to the Borland dll's, odbc drives, and other shared libraries is: > .wine/drive_c/Program Files/Common Files/Borland Shared/BDE/ > > My main desire is to be able to launch this program from a launcher that I can create on the Desktop, eventually I would like to make this universally accessible to all users. Your help and suggestions would be most appreciated. > > Thank you! > > > > > >Does using: $ wine "C:\Scan\program.exe" work? -- -Austin
netgui68
2009-Jan-22 16:00 UTC
[Wine] Re: Application will only run when executed from its directory
Does using: $ wine "C:\Scan\program.exe" work? ---------------------------Answer------------------------------ It runs but not correctly, I receive all kinds of errors about not being able to build table files and such...If I go to the start menu and tell wine to let me browse the C:\ drive and execute the application there...it works flawlessly. Trying to execute it from any other place gives me errors.
Austin English
2009-Jan-22 16:03 UTC
[Wine] Application will only run when executed from its directory
On Thu, Jan 22, 2009 at 10:00 AM, netgui68 <wineforum-user at winehq.org> wrote:> Does using: > $ wine "C:\Scan\program.exe" > work? > > ---------------------------Answer------------------------------ > > It runs but not correctly, I receive all kinds of errors about not being able to build table files and such...If I go to the start menu and tell wine to let me browse the C:\ drive and execute the application there...it works flawlessly. Trying to execute it from any other place gives me errors. > > > > > >Many programs rely on being run from their current directory, Delphi was well known for that. If your window manager supports it, you can tell it to run from that directory, then use the full path. Should work then. -- -Austin
netgui68
2009-Jan-22 16:16 UTC
[Wine] Re: Application will only run when executed from its directory
Many programs rely on being run from their current directory, Delphi was well known for that. If your window manager supports it, you can tell it to run from that directory, then use the full path. Should work then. -- -Austin -----------Answer--------------------------------- The window launcher does not give me that option and most importantly I am trying to build this to work for novice users...they need the link on the Desktop to click or they will be lost. Thanks for your suggestions.
Vincent Povirk
2009-Jan-22 17:12 UTC
[Wine] Application will only run when executed from its directory
Short of writing a shell script, the easiest way to start an executable file in its directory is to run $ wine start /unix ".wine/drive_c/Scan/program.exe" When invoked this way, wine will try to start the file the same as if it were double-clicked in windows explorer. It will start from the path containing the exe and invoke it with its full dos path. This is the way file browsers invoke Wine. If that worked, this should also work. The drawback is that you cannot pass arguments to the executable this way; for that you would need a shell script. Vincent Povirk
netgui68
2009-Jan-22 19:35 UTC
[Wine] Re: Application will only run when executed from its directory
That command structure worked perfectly. This issue is resolved. Strangely enough I had tried a similar command found on the net, I guess the syntax was incorrect. Again..thank you very much for your help.