[Wine] Passing arguments from the command line to apps on Mac OS X (Darwine and CrossOver)

James McKenzie jjmckenzie51 at earthlink.net
Mon Oct 13 22:09:32 CDT 2008

Yarden Katz wrote:
> Hi all,
> There's a Windows application I've been running (called "WinBUGS.exe") on an
> intel Mac OS X (ver. 10.5.5) using both Darwine and CrossOver Pro. My
> application runs fine under Darwine and also under CrossOver. However, in
> spite of being able to run these applications using either platform from the
> command line, I still cannot pass arguments to the application. What I want
> to do is simply invoke the application from the command line and pass it an
> argument.
> >From the command line, I am able to use "open WinBUGS.exe" to run my
> application. If I try to open the application and pass it the command "/PAR
> script.txt", it does not work:
> $ open WinBUGS.exe '/PAR script.txt'
> The file /PAR script.txt does not exist.
If you are calling this from the terminal you will have to offset the
command with the grave accent, which is the key to the left of the
number 1 key like this:

wine `WinBUGS.exe '/PAR script.txt'`

However,  if you are using Darwine, start Winehelper and use the menu to
start your application.  This allows you to specify parameters.

Also, you should not be invoking the open command as far as I know.
> I looked at my DISPLAY variable to see if I can correct the second error:
> $ echo $DISPLAY
> /tmp/launch-UTIOMG/:0
> I tried this setting:
> $ export DISPLAY=:0.0
> :0.0
variable to :0.0 nor should you be changing it.  This will break the
security features embedded with the version of X11 supported by Apple.

Suggestiion:  Get and use the MacOSXForge XQuartz.  This fixes several
problems with Apple's very broken X11 server.  You will have to apply
fixes with each and every update to MacOSX until all of the fixes found
by the XQuartz team are integrated into Apple's X11.  Also please be
aware that any program that calls OpenGL 1.3 calls will NOT work with
Apple's and XQuartz's X11 until XQuartz 2.4 is released.

James McKenzie

More information about the wine-users mailing list