[Wine] How to set path to .NET runtime to use

djahma
Fri, 18 Feb 2011 18:19:16 -0000

Hi there,

I've been searching for a solution to make Mono the default runtime to be
used within wine environment, for the past 3 days now and still no success.

What am I trying to do?
So there is this windows software (AmiBroker) for which I want to create COM/OLE
objects written in C#. To achieve that, I need both COM/OLE and a .NET runtime
to work.

What I did so far
1) Starting off a clean .wine folder, I sorted many bugs and in the end I got
some objects accessible via OLE and some others not. I couldnt figure out why
since all objects seem registered in oleview.exe. Within AmiBroker too, I could
access only certain objects but not all.
2) But AmiBroker on Linux provides a tailor-made wine
setup:http://www.amibroker.org/3rdparty/Amibroker_on_Linux/html/Setup_Wine.html
, so starting from that end COM/OLE works perfectly, but .NET runtime is not
recognized/detected by wine.

What I am looking for
I need both OLE and .NET to work perfectly for what I want to do. In case 1) I
would need help to make sure COM/OLE objects are indeed callable from wine
environment. Say, how to scan OLE registered objects and re-register those
actually wrong? or something along those lines.
Or for case 2) I would need help set wine path to mono.exe. Is there a registry
value I could change to tell wine to open all .NET executables with mono or .NET
framework?

Further observations:
In case 1) Amibroker is OLE registered as Broker.Application. I can call that
object from within Amibroker formula language, but not from external jscript.
Same with WScript, it's callable from external scripts but not from within
Amibroker Formula Language.
In case 2) the only way I can use a .NET runtime to run dotnet executables
within wine is by typing the whole command, here's a ridiculously long
command I end up typing quite often:
$ wine "C:\\Program Files\\Mono-2.8.1\\bin\\mono.exe"
"C:\\Program*Files\\Toolsack*DotNet*Script*Host\\TSDotNetScriptHost.exe"
"C:\\MyProject\\Scripts\\GetChart.ns".
The same command under case 1) setup simply goes:
$ wine TSDotNetScriptHost ../../GetChart.ns

Any help on either of this 2 scenarii would be greatly appreciated [Wink]
Thanks