Re: [Mono-list] mono_runtime_invoke crash

2014-09-17 Thread Jonathan Chambers
Hello,

See the documentation on using 'mono_jit_exec' at
http://www.mono-project.com/docs/advanced/embedding/

Even if you are embedding and just invoking methods in a library, you need
a dummy Main method. Invoking this is the only way to setup some internals
within the runtime. I can't say this is definitely your issue, but it
sounds similar to issues I've had in the past.

Thanks,
Jonathan

On Sun, Sep 14, 2014 at 2:38 PM, tbrooks  wrote:

> Robert Jordan wrote
> > You did not show us how you're initializing the runtime.
>
> Much of this code was wrapped in a facade mechanism, here is the
> initialization code (directories are the build path + "\\lib" and "\\etc")
>
> mono_config_parse( NULL ); // Use the standard configuration...
> mono_set_dirs( GetLibDirectory().c_str(), GetConfigDirectory().c_str() );
> //
> Setup the default directories for mono use here for now the directories of
> your Mono installation
> m_Domain = mono_jit_init_version( m_AppName.c_str(), "v4.0.30319" ); //
> Init
> the JIT Engine
> m_Assembly = mono_domain_assembly_open( m_Domain,
> m_DomainAssemblyName.c_str() ); // Open the Assembly with your scripts
> m_Image = mono_assembly_get_image( m_Assembly ); // Get the Image
>
>
>
> Robert Jordan wrote
> > Under Windows you could also end up with compiling your app
> > for the Windows subsystem which doesn't have a console.
>
> There is an active console, in this case I can sometimes see output. Even
> without recompiling, sometimes it crashes and sometimes it doesn't. It
> seems
> to changed based on the execution, regardless of how many times it's called
> in that process instance.
>
> I did some more testing and now I think it's tied to the ToString()
> function. If I remove the Console.Writeline and add:
>
> string test = ID.ToString();
>
> I get the same random crashing behavior.
>
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/mono-runtime-invoke-crash-tp4663860p4663866.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] "Too many root sets" ?

2013-12-13 Thread Jonathan Chambers
Are you using app domains in you application? I believe there is a bug
where the roots registered for an app domain are not correctly unregistered
on WIndows leading to the eventual exhaustion of available roots.

- Jonathan


On Wed, Nov 13, 2013 at 11:03 AM, Rodrigo Kumpera  wrote:

> It usually means you're using too much memory on a 32bits system. Boehm
> can't reliably handle more than 500-800mb of heap without running into this.
>
>
> On Wed, Nov 13, 2013 at 8:51 AM, mickeyf  wrote:
>
>> Thanks - I fixed the bug in my own code that was getting me into this
>> situation in the first place.
>>
>> But I was actually just hoping for some insight into what "Too many root
>> sets" actually meant, in practical terms.
>>
>>
>>
>> --
>> View this message in context:
>> http://mono.1490590.n4.nabble.com/Too-many-root-sets-tp4661307p4661313.html
>> Sent from the Mono - General mailing list archive at Nabble.com.
>> ___
>> Mono-list maillist  -  Mono-list@lists.ximian.com
>> http://lists.ximian.com/mailman/listinfo/mono-list
>>
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono embedding - null pointer access violation on ves_icall_System_Reflection_Assembly_GetExecutingAssembly

2013-04-26 Thread Jonathan Chambers
I saw the same issue in an embedding case I am doing. I worked around it
ATM by not calling some C# code, but when I take time to debug/fix I'll
post it here.

Thanks,
Jonathan


On Thu, Apr 25, 2013 at 6:30 PM,  wrote:

>  Hi Rodrigo,
>
> ** **
>
> I get the same behaviour whether I attach before or after loading the mono
> runtime, and 32 or 64 bit process.
>
> I cannot figure out what I changed so much to end up in this pickle. But I
> could certainly do with a code review from someone more seasoned with mono
> embedding. My MS.NET embedding side is getting very usable, but visibly
> the Mono side has bugs I am not on top of.
>
> Happy to provide further information as needed.
>
> ** **
>
> Regards
>
> ** **
>
> *From:* Rodrigo Kumpera [mailto:kump...@gmail.com]
> *Sent:* Tuesday, 23 April 2013 12:50 AM
> *To:* Perraud, Jean-Michel (CLW, Black Mountain)
> *Cc:* Mono List
> *Subject:* Re: [Mono-list] Mono embedding - null pointer access violation
> on ves_icall_System_Reflection_Assembly_GetExecutingAssembly
>
> ** **
>
> Did you attach the thread before calling into the mono runtime?
>
> ** **
>
> On Fri, Apr 12, 2013 at 8:00 PM,  wrote:
>
> Hi,
>
> I am trying to flush out bugs in an application with Mono (3.0.6)
> embedded. Improving on the Linux front, an issue on Windows is now baffling
> me. The issue seems deep in JIT exec code but has got to be because of my
> code.
> I tried to condense the diagnosis with the (visual studio) native stack
> trace (I could not get the managed part from MonoDevelop yet). I'd highly
> appreciate the informed guess of a guru to suggest where to look to fix it.
>
> Regards.
>
> The high level call (in the R language) is like:
> callStaticMethod( "SomeNamespace.AClassName", "TheStaticMethod",
> "SomeString", "AnotherString" )
>
> The main C code for preparing the CLR method call
> MonoMethod * methodCallStaticMethod = rclr_mono_get_method(
> spTypeClrFacade, "CallStaticMethodMono", 3);
> void** static_mparams = (void**)malloc(3*sizeof(void*));
> MonoArray* methParams = create_array_object(params, paramCount);
> static_mparams[0] = create_mono_string(ns_qualified_typename);
> static_mparams[1] = create_mono_string(methodName);
> static_mparams[2] = methParams;
> result = mono_runtime_invoke (methodCallStaticMethod, NULL,
> static_mparams, &exception);
> // calling the C# method:
> // public static object CallStaticMethodMono(string typename,
> string methodName, object[] arguments)
>
> further in the stack strace, in:
> icall.c :
> ves_icall_System_Reflection_Assembly_GetExecutingAssembly (void)
> the following line returns dest as a NULL pointer, which looks like a very
> unexpected condition hence the crash.
> mono_stack_walk_no_il (get_executing, &dest);
> It seems that the root cause is in the function:
> mono_walk_stack_full:
> while (MONO_CONTEXT_GET_SP (&ctx) <
> jit_tls->end_of_stack)
> which is already false at the first iteration, hence 'dest' remains NULL.
>
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
> ** **
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Poor Mono performance

2013-03-11 Thread Jonathan Chambers
Imre,

Mono can load llvm dynamically, and if it fails to do so it outputs to
stderr. I am 99% sure the packages for Windows are not built with LLVM
support. In that case I would hope you get some output to stderr when
running?

Thanks,
Jonathan


On Mon, Mar 11, 2013 at 12:04 PM, Olajos, Imre wrote:

>  Jonathan,
>
> ** **
>
> I didn’t build the mono runtime. I just took the installable Windows
> distributable from the Mono “Download” page. Is that built with our without
> LLVM support? (And if it’s built without LLVM support, then why is the
> –llvm option offered at all?...)
>
> ** **
>
> --
> *Imre*
>
> 
>
> ** **
>
> *From:* Jonathan Chambers [mailto:jonc...@gmail.com]
> *Sent:* Saturday, March 09, 2013 6:33 PM
> *To:* Olajos, Imre
> *Cc:* mono-list@lists.ximian.com
> *Subject:* Re: [Mono-list] Poor Mono performance
>
> ** **
>
> Did you explicitly build the mono runtime with support for LLVM?
>
> ** **
>
> Thanks,
>
> Jonathan
>
> ** **
>
> On Fri, Mar 8, 2013 at 8:38 PM, imreolajos  wrote:*
> ***
>
> I ran the code through Mono without the --llvm option - made NO difference
> whatsoever. It still runs 2x slower with Mono.
>
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Poor-Mono-performance-tp4658877p4658881.html
> 
>
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
> ** **
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Poor Mono performance

2013-03-09 Thread Jonathan Chambers
Did you explicitly build the mono runtime with support for LLVM?

Thanks,
Jonathan


On Fri, Mar 8, 2013 at 8:38 PM, imreolajos  wrote:

> I ran the code through Mono without the --llvm option - made NO difference
> whatsoever. It still runs 2x slower with Mono.
>
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Poor-Mono-performance-tp4658877p4658881.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono & x64 issue

2012-10-20 Thread Jonathan Chambers
The easiest thing to do is to build the Visual Studio solution mono.sln in
mono/msvc. Build the x64 target in this case. It will produce the dynamic
library (mono-2.0.dll) and an import lib (mono-2.0.lib). A few others and
myself had the Win64 version of the runtime working pretty well. You may
run into some issues, but it should simple applications reliably.

Thanks,
Jonathan

On Tue, Oct 16, 2012 at 10:54 AM, Robert Jordan  wrote:

> On 16.10.2012 16:14, Francois Schelling wrote:
>
>> I've created a 64 bits version of my mono.lib in order to make my
>> program links correctly with mono using the following command: lib
>> /nologo /def:mono.def /out:mono64.lib /machine:x64.
>>
>
> The "official" Mono for Windows is 32-bit only, so creating
> a 64-bit import lib won't help at all.
>
> Robert
>
> __**_
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/**mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Debugging mono with VS2010

2012-08-10 Thread Jonathan Chambers
Francois,

You cannot debug managed code running in mono from within VS. You could use
MonoDevelop and the mono soft
debugger
to
debug the managed code at the same time that you are debugging the native
code in VS. If using MonoDevelop, I believe you will also need some minor
'hacks' to make it possible to debug an embedded mono. See detail in the
question here:
http://stackoverflow.com/questions/9582365/debugging-w-embedded-mono-how-to-set-breakpoints-in-c-sharp-code

Also, if you are using the soft debugger at the same time as being attached
with the native VS debugger you may run into issues with SEH exceptions
being raised internally by the soft debugger. See solution I mentioned
hereabout using
AddVectoredExceptionHandler rather than
SetUnhandledExceptionFilter.

Thanks,
Jonathan


On Fri, Aug 10, 2012 at 10:05 AM, Francois Schelling <
fschell...@square-enix-montreal.com> wrote:

> Hi,
>
> I've did a small setup to try mono and now I have a C++ program embedding
> and C# assembly.  I'm under Windows and using VS2010.
>
> So far, I'm able to launch my main app from VS, load my assembly, unload
> it, recompile it with another VS instance, and then reload the assembly on
> my main program without stopping my main program.  Now, I would like to be
> able to debug my assembly but I'm unable to do so.  I cannot attach my
> secondary VS to the process since it's not available.  On my main VS
> instance that is debugging the main program, I cannot debug the assembly,
> only the main c++ application.
>
> Anyone knows how to setup a mono debug environment with VS2010?
>
> Thanks!
> ___
> Francois Schelling
> Senior Programmer
> Square Enix Montréal
> fschell...@square-enix-montreal.com
>
>
>
>
>
>
>
> Francois
>
> __
> This email has been scanned by the MessageLabs
> __
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono compiler and specific assembly version

2012-05-30 Thread Jonathan Chambers
Yann,

In this case, I would expect that msbuild is resolving the reference paths
and passing those to the mono compiler. Look at the actual command line
being run, and ensure the references being passed to the mono compiler
actually exist. A full command line and error output might be useful.

Thanks,
Jonathan

On Wed, May 30, 2012 at 2:05 PM, Yann ROBIN  wrote:

> Thanks for taking time to answer.
>
> I'm using msbuild with specific target files that override CscToolExe
> and CscToolPath.
>
> On Wed, May 30, 2012 at 1:42 PM, Jonathan Chambers 
> wrote:
> > Yann,
> >
> > More information would be helpful. Are you trying to build a csproj using
> > xbuild? If not, how are you invoking the mono compiler?
> >
> > Thanks,
> > Jonathan
> >
> > On Wed, May 30, 2012 at 1:25 PM, Yann ROBIN  wrote:
> >>
> >> Hi !
> >> I have a question regarding mono compiler
> >> when I build a solution using .Net compiler the compiler respect the
> >> param that say "don't use specific version" of assembly but when I
> >> build using mono compiler it use specific version.
> >> The build fail saying assembly is missing but it's not ! Is there a
> >> workaround ?
> >>
> >> Thanks
> >>
> >> --
> >> Yann
> >> ___
> >> Mono-list maillist  -  Mono-list@lists.ximian.com
> >> http://lists.ximian.com/mailman/listinfo/mono-list
> >
> >
>
>
>
> --
> Yann
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ThreadStatic

2012-03-29 Thread Jonathan Chambers
Yes, it does. 

Thanks,
Jonathan


On Thursday, March 29, 2012 at 9:37 AM, wuffus wrote:

> Does MONO support the [ThreadStatic] attribute?
> 
> --
> View this message in context: 
> http://mono.1490590.n4.nabble.com/ThreadStatic-tp4515446p4515446.html
> Sent from the Mono - General mailing list archive at Nabble.com 
> (http://Nabble.com).
> ___
> Mono-list maillist - Mono-list@lists.ximian.com 
> (mailto:Mono-list@lists.ximian.com)
> http://lists.ximian.com/mailman/listinfo/mono-list
> 
> 


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Marshaling string on Windows returns Garbage??

2012-03-13 Thread Jonathan Chambers
Please post the exact code you are using, and/or file a bug with all the
details needed.

Thanks,
Jonathan

On Tue, Mar 13, 2012 at 10:09 AM, efontana  wrote:

> I tried your suggestions with the out parameter, same result, string
> returned and printed via Console.WriteLine is 
>
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Marshaling-string-on-Windows-returns-Garbage-tp4468863p4469157.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Marshaling string on Windows returns Garbage??

2012-03-13 Thread Jonathan Chambers
You could try making the argument an out parameter and seeing if that
works. If so, there must be a bug in marshaling strings as return values.
Please file a bug in that case.

//C#
void CSharp_Out_String(out string str);

and
//C++
void CSharp_Out_String(char** str)
{
 const char* testValue = "test"
 *str = CoTaskMemAlloc(strlen(testValue)+1);
 strcpy(*str, testValue);
}

Thanks,
Jonathan

On Tue, Mar 13, 2012 at 8:21 AM, efontana  wrote:

> No, it's a std::string (there an above using namespace std)
>
> FWIW: I tried even doing this:
>
> const char* testValue = "test"
> char* s = CoTaskMemAlloc(strlen(testValue)+1);
> strcpy(s, testValue);
> return s;
>
> That also returns the 8 Question Marks.
>
> Even more interesting, if I change the signature to
> IntPtr CSharp_Return_String and use Marshal.PtrToStringAnsi, the string is
> correct!!
>
> If I use the IntPtr method, the C# wrapper will have to call
> Mashal.FreeCoTaskMem to avoid
> the leak, because I'm forced to allocate the string on the C++ side since
> the string is really
> embedded in either a std::string or a Qt QString.
>
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Marshaling-string-on-Windows-returns-Garbage-tp4468863p4468951.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono not catching this, VS does

2011-11-04 Thread Jonathan Chambers
I believe there is at least one bug for this error already:

https://bugzilla.novell.com/show_bug.cgi?id=613713

Thanks,
Jonathan

On Fri, Nov 4, 2011 at 10:26 AM, Andres G. Aragoneses wrote:

>
> Please file a bug report in http://bugzilla.xamarin.com/
>
> On 11/04/2011 02:02 PM, Matt Calder wrote:
> > I don't know whether to call this a bug, but this code can result in an
> > access of the List list, without assigning to it (in the case b is
> false):
> >
> >  public static void Foo(bool b)
> >  {
> >  int i;
> >  List list;
> >  if (b && !dict.TryGetValue("foo", out list)) {
> >  dict["foo"] = new List();
> >  } else {
> >  i = list[0];
> >  }
> >
> >  }
> >
> > Visual studio flags this as a compiler error. I am using:
> >
> > $ mono --version
> > Mono JIT compiler version 2.11 ((no/7917753 Wed Mar 30 15:47:09 EDT 2011)
> > Copyright (C) 2002-2011 Novell, Inc and Contributors.
> > www.mono-project.com 
> >  TLS:   __thread
> >  SIGSEGV:   altstack
> >  Notifications: epoll
> >  Architecture:  amd64
> >  Disabled:  none
> >  Misc:  softdebug
> >  LLVM:  yes(2.8svn-mono)
> >  GC:Included Boehm (with typed GC and Parallel Mark)
> >
> >
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] RemoveDir - XBuild vs MSBuild

2011-08-03 Thread Jonathan Chambers
Mike,

This seems to be a bug. Please file this, and as a workaround try adding a
Condition attribute with an Exists check:

http://msdn.microsoft.com/en-us/library/7szfhaft.aspx

Something like:



Thanks,
Jonathan

On Wed, Aug 3, 2011 at 9:13 PM, Mike Christensen  wrote:

> I'm trying to port an MSBuild script to XBuild and running into the
> following issue:
>
> 
>
> This crashes and stops building if Imp/bin does not exist.  On
> MSBuild, it will just do nothing and ignore the command.
>
> Is this a bug?  Is there any way I can say "delete the directory if it
> exists?"
>
> Thanks!
>
> Mike
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Porting to 2.8.2 from 2.4.2.3. Socket crash

2011-01-11 Thread Jonathan Chambers
Ivan,
 Do you have a test case that can reproduce the problem?

Thanks,
Jonathan

On Tue, Jan 11, 2011 at 1:00 PM, IvanEfimov  wrote:

>
> Greeting to Mono community!
>
> We are got issues while porting from Mono 2.4.2.3 to Mono 2.8.2.
> Using own compiled Mono by means Visual Studio.
>
> Strange, but with 2.8.2 socket crash inside Socket() constructor.
>
> I have checked ves_icall_System_Net_Sockets_Socket_Socket_internal.
> This method works good. No errors inside.
>
> Ideas?
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Porting-to-2-8-2-from-2-4-2-3-Socket-crash-tp3209410p3209410.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] How to protect a mono application from reverse engineering?

2010-10-25 Thread Jonathan Chambers
Stéphane,
   You could put your performance/security critical pieces of code in
C/C++, and P/Invoke them from managed code. This will probably get you what
you want from a code obfuscation perspective, and also you might be able to
keep large amounts of your current code base.

- Jonathan

On Mon, Oct 25, 2010 at 9:08 AM, Stéphane C  wrote:

>  Hello,
> Thanks both for your answers.
>
> Actually, copy protection is not what I worry about, I know that no
> licensing system is 100% safe and I totally agree when you say that people
> will find a way to bypass them if they really invest time in it.
> What I want to protect the most is the algorithms used in the application,
> they represent many years of research and development and we don't want them
> to fall into the hands of a competitor who is just running an IL
> disassembler.
>
> Trying to reverse-engineer native code using a debugger is a real pain when
> it comes to complex operations. I'm personally convinced that it would be a
> complete waste of time on this kind of software.
> Unfortunately, from what I can tell, mono aot compiler works by generating
> a dll/so file next to the ".exe" assembly, it seems that shipping this IL
> assembly is still required to start the application. You just avoid using
> JIT compilation... or did I miss something?
>
> I'm still looking for a solution...
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Call managed from unmanaged code?

2010-08-18 Thread Jonathan Chambers
Hello Kurt,
 You can achieve this in a few ways.

1. The easiest and most portable is to marshal a delegate into a function
pointer, and then pass that pointer into native code to call back onto.

2. If you are using the embedding API, you can register internal calls with
the runtime that you can call from C#.

http://www.mono-project.com/Embedding_Mono#Exposing_C_code_to_the_CIL_universe

3.
Mono does have some support for COM Interop, but note that there is minimal
to no tool support for generating the wrapper interfaces and interop
libraries.

http://www.mono-project.com/COM_Interop

Thanks,
Jonathan

On Wed, Aug 18, 2010 at 9:27 PM,  wrote:

>  Hello, List:
>
> Is it possible to call into a managed DLL from an unmanaged C/C++
> application with the facilities within Mono? We would like to do this on the
> Mac at the moment, but we would need to do it from Suse Linux also.
>
> We are currently calling unmanaged DLL's from managed ones in our project
> and someone asked me whether we could call managed from unmanaged. Does Mono
> support something like COM-to-Net wrappers? I couldn't find a good reference
> for this in the archives.
>
> Regards;
>
> Kurt Matis
> troy, NY.
>
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] 64 Bit and GC

2009-05-08 Thread Jonathan Chambers
Hello,
 We are using 64-bit version of mono for Windows in a production
environment. There are no packages available at this point, but it should
work fine. Simply install/build the 32-bit version for Windows, and then
compile the runtime using Visual Studio. Then drop the built mono.exe/dll
into the 32-bit install. You need to checkout the mono directory from svn:

http://anonsvn.mono-project.com/viewvc/trunk/mono/

Then open the mono\msvc\mono.sln file in Visual Studio and build. There are
additional directions in mono\README.vsnet.

Thanks,
Jonathan

On Fri, May 8, 2009 at 9:09 AM, Rodrigo Kumpera  wrote:

>
>
> On Fri, May 8, 2009 at 3:46 AM, Markus Schaber  wrote:
>
>>
>> Hi, I've two small questions:
>>
>> - What is the state of 64 Bit Mono for windows? I did not find an
>> installer,
>> and the 32 bit version has memory limits...
>>
>
> There have been some work on the 64bits port, but it's not really AFAIK.
>
>
>>
>> - Whats the state of the "Fatal Error in GC" problems? I thought that Mono
>> 2.4 has a new generational garbage collector, but I still get that error
>> with some applications:
>> http://www.nabble.com/file/p23421895/Fatal_error_in_gc.jpg
>> https://bugzilla.novell.com/show_bug.cgi?id=435906 Bugzilla report 435906
>>
>
> The generational garbage collection is still in the works.
>
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] COM-Interop Problem

2009-04-27 Thread Jonathan Chambers
Hello,

Please file a bug (under Runtime at http://mono-project.com/Bugs) with a
test case.
Thanks,
Jonathan

On Mon, Apr 27, 2009 at 9:14 AM, Elmar Haneke  wrote:

> In using an COM object from within my Mono application I do get an error:
>
> ERROR:marshal.c:563:cominterop_get_interface: assertion failed: (found)
>
> The same works fine on DotNet. The Problem does arrise on Vista/32Bit
> using mono 2.4.
>
> How can it be resolved?
>
> Elmar
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ActiveX dll with mono on windows

2009-03-09 Thread Jonathan Chambers
Hello,  Visual Studio generates the Interop.cwbx.dll file from some
actual COM library using tlbimp. Interop.cwbx.dll is a managed assembly
providing the required definitions of the types in your COM library. gmcs
can compile your app referencing this library because it requires no COM
Interop to compile a managed assembly. However, once you try to run your
application you'll need the COM support that exists in the mono runtime.

Yes, you can write all the code contained in the Interop.cwbx.dll by hand if
you choose, just make sure to get it right or you'll get odd errors at
runtime.

Thanks,
Jonathan

On Mon, Mar 9, 2009 at 10:49 AM, Bartolomeo Nicolotti
wrote:

>
> Hi,
>
> sorry, but I would like to understand more precisely:
>
> I've taken the file
>
> Interop.cwbx.dll
>
> from the visual studio Project folder, I've searched and it'is only there
> on
> my pc.
>
> i've compiled with
>
>gmcs -r:Interop.cwbx.dll MyTest.cs
>
> and it works. Do you mean that without mono support COM Interop this
> wouldn't have compiled?
>
> Without the tools support and without visual studio this Interop.cwbx.dll
> can be written by hand, right?
>
> Many thanks
>
> Best regards
>
>
> Da: Jonathan Chambers 
> A:  Bartolomeo Nicolotti 
> CC: mono-list@lists.ximian.com
> Oggetto:Re: [Mono-list] ActiveX dll with mono on windows
> Data:   Mon, 9 Mar 2009 09:53:14 -0400 (14.53 CET)
>
>
> Hello,
> COM Interop in mono on windows should work the same as COM Interop on
> .Net. The tools support is not there (mono has no equivalent of tlbimp for
> example), but the runtime should be fine. If not, file a bug.
>
>
> Thanks,
> Jonathan
>
>
>
> Da: Jonathan Chambers 
> A:  Bartolomeo Nicolotti 
> CC: mono-list@lists.ximian.com
> Oggetto:Re: [Mono-list] ActiveX dll with mono on windows
> Data:   Mon, 9 Mar 2009 10:32:31 -0400 (15.32 CET)
>
>
> Hello,
>
> On Mon, Mar 9, 2009 at 10:21 AM, Bartolomeo Nicolotti <
> bnicolo...@siapcn.it>
> wrote:
> Hello,
>
>Great! Do you mean that this compiles
>
> gmcs -r:Interop.cwbx.dll MyTest.cs
>
>
> using Com Interop?
>This compiles like any normal managed application. Interop.cwbx.dll
> is just a managed assembly. COM Interop tools were used to generate that
> assembly I assume, and the runtime needs to support COM Interop in order
> for
> it to run (which mono should, unless there is a bug).
>
>
>Interop.cwbx.dll is generated by VisualStudio.
>
>Do you think that using this Interop.cwbx.dll is fine or do you
> suggest
>to use a wrapper written in mono?
>
>IBM provides us also another dll that's an assembly, but the classes
>used are different, do you think that we can keep our code as is and
> use
>a wrapper to unmanaged code or we should modify our code to use
> managed
>assembly?
>I would try your code as is first, although things being all managed
> would help with portability (for other platforms if you care about them).
>
>
>Many thanks
>
>best regards
>
>
>
> Bartolomeo Nicolotti wrote:
> >
> >
> > Da:   Justin Dearing 
> > A:Bartolomeo Nicolotti 
> > Oggetto:  Re: [Mono-list] ActiveX dll with mono on windows
> > Data: Mon, 9 Mar 2009 08:02:57 -0400 (13.02 CET)
> >
> >
> > The activeX dll is a DLL containing com.
> >
> >
> > This blog seems to indicate thats not as impossible as I thought:
> >
> >
> >
> http://jonathanchambers.blogspot.com/2007/02/three-com-interop-updates.html
> >
> >
> > Do you have the source for he activex dll? What language is it written
> in?
> > If its a VB6 dll, visual studio has a nice wizard to upgrade vb6 code to
> > vb.net.
> >
> >
> > No, I don't have the sources, it's an IBM.
> >
> > Visual Studio produces an Interp.cwbx.dll that used with
> >
> > gmcs -r:Interop.cwbx.dll MyTest.cs
> >
> > compiles! I think that's a wrapper assembly for the ActiveX dll.
> >
> > Bye
> >
> >
> > Bartolomeo Nicolotti wrote:
> >>
> >> Hi,
> >>
> >> I've sonme code written in C# with VisualStudio. I want to migrate to
> >> mono. The problem is that this code uses a .dll that's an ActiveX and
> not
> >> an assembly. Is there a way to use this dll in mono?
> >>
> >> Many thanks
> >>
> >> Best regards
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/ActiveX-dll-with-mono-on-windows-tp22411525p22413427.html
> Sent from the Mono - General mailing list archive at Nabble.com.
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ActiveX dll with mono on windows

2009-03-09 Thread Jonathan Chambers
Hello,

On Mon, Mar 9, 2009 at 10:21 AM, Bartolomeo Nicolotti
wrote:

> Hello,
>
> Great! Do you mean that this compiles
>
> gmcs -r:Interop.cwbx.dll MyTest.cs
>
> using Com Interop?

This compiles like any normal managed application. Interop.cwbx.dll is just
a managed assembly. COM Interop tools were used to generate that assembly I
assume, and the runtime needs to support COM Interop in order for it to run
(which mono should, unless there is a bug).

>
>
> Interop.cwbx.dll is generated by VisualStudio.
>
> Do you think that using this Interop.cwbx.dll is fine or do you suggest
> to use a wrapper written in mono?
>
> IBM provides us also another dll that's an assembly, but the classes
> used are different, do you think that we can keep our code as is and use
> a wrapper to unmanaged code or we should modify our code to use managed
> assembly?

I would try your code as is first, although things being all managed would
help with portability (for other platforms if you care about them).

>
>
> Many thanks
>
> best regards
>
> Il giorno lun, 09/03/2009 alle 09.53 -0400, Jonathan Chambers ha
> scritto:
> > Hello,
> >  COM Interop in mono on windows should work the same as COM
> > Interop on .Net. The tools support is not there (mono has no
> > equivalent of tlbimp for example), but the runtime should be fine. If
> > not, file a bug.
> >
> >
> > Thanks,
> > Jonathan
> >
> > On Mon, Mar 9, 2009 at 9:25 AM, Bartolomeo Nicolotti
> >  wrote:
> >
> >
> > Da: Justin Dearing 
> > A:  Bartolomeo Nicolotti 
> > Oggetto:Re: [Mono-list] ActiveX dll with mono on
> > windows
> > Data:   Mon, 9 Mar 2009 08:02:57 -0400 (13.02 CET)
> >
> >
> > The activeX dll is a DLL containing com.
> >
> >
> > This blog seems to indicate thats not as impossible as I
> > thought:
> >
> >
> >
> http://jonathanchambers.blogspot.com/2007/02/three-com-interop-updates.html
> >
> >
> > Do you have the source for he activex dll? What language is it
> > written in?
> > If its a VB6 dll, visual studio has a nice wizard to upgrade
> > vb6 code to
> > vb.net.
> >
> >
> > No, I don't have the sources, it's an IBM.
> >
> > Visual Studio produces an Interp.cwbx.dll that used with
> >
> > gmcs -r:Interop.cwbx.dll MyTest.cs
> >
> > compiles! I think that's a wrapper assembly for the ActiveX
> > dll.
> >
> > Bye
> >
> >
> > Bartolomeo Nicolotti wrote:
> > >
> > > Hi,
> > >
> > > I've sonme code written in C# with VisualStudio. I want to
> > migrate to
> > > mono. The problem is that this code uses a .dll that's an
> > ActiveX and not
> > > an assembly. Is there a way to use this dll in mono?
> > >
> > > Many thanks
> > >
> > > Best regards
> > >
> >
> > --
> >
> > View this message in context:
> >
> http://www.nabble.com/ActiveX-dll-with-mono-on-windows-tp22411525p22413057.html
> >
> > Sent from the Mono - General mailing list archive at
> > Nabble.com.
> >
> > ___
> > Mono-list maillist  -  Mono-list@lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-list
> >
> >
> >
> --
> Bartolomeo Nicolotti
> SIAP s.r.l.
> www.siapcn.it
> v.S.Albano 13 12049
> Trinità(CN) Italy
> ph:+39 0172 652553
> centralino: +39 0172 652511
> fax: +39 0172 652519
>
>
Thanks,
Jonathan
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ActiveX dll with mono on windows

2009-03-09 Thread Jonathan Chambers
Hello, COM Interop in mono on windows should work the same as COM
Interop on .Net. The tools support is not there (mono has no equivalent of
tlbimp for example), but the runtime should be fine. If not, file a bug.

Thanks,
Jonathan

On Mon, Mar 9, 2009 at 9:25 AM, Bartolomeo Nicolotti
wrote:

>
>
> Da: Justin Dearing 
> A:  Bartolomeo Nicolotti 
> Oggetto:Re: [Mono-list] ActiveX dll with mono on windows
> Data:   Mon, 9 Mar 2009 08:02:57 -0400 (13.02 CET)
>
>
> The activeX dll is a DLL containing com.
>
>
> This blog seems to indicate thats not as impossible as I thought:
>
>
> http://jonathanchambers.blogspot.com/2007/02/three-com-interop-updates.html
>
>
> Do you have the source for he activex dll? What language is it written in?
> If its a VB6 dll, visual studio has a nice wizard to upgrade vb6 code to
> vb.net.
>
>
> No, I don't have the sources, it's an IBM.
>
> Visual Studio produces an Interp.cwbx.dll that used with
>
> gmcs -r:Interop.cwbx.dll MyTest.cs
>
> compiles! I think that's a wrapper assembly for the ActiveX dll.
>
> Bye
>
>
> Bartolomeo Nicolotti wrote:
> >
> > Hi,
> >
> > I've sonme code written in C# with VisualStudio. I want to migrate to
> > mono. The problem is that this code uses a .dll that's an ActiveX and not
> > an assembly. Is there a way to use this dll in mono?
> >
> > Many thanks
> >
> > Best regards
> >
>
> --
> View this message in context:
> http://www.nabble.com/ActiveX-dll-with-mono-on-windows-tp22411525p22413057.html
> Sent from the Mono - General mailing list archive at Nabble.com.
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] how to call a mono graphical app on windows without a terminal being shown?

2008-06-07 Thread Jonathan Chambers
Alan,
  I think there were two issues. One was making sure to compile a
winexe, rather than a conolse app (you and others suggested this). The
second was that he was starting his app using a .bat file, and this also
creates a console. There were a few suggestions how to get rid of this as
well.

Thanks,
Jonathan

On Sat, Jun 7, 2008 at 9:17 PM, Alan McGovern <[EMAIL PROTECTED]>
wrote:

> While all these solutions are great and all, just compile your app with:
> -target:WINEXE. Then you won't get the console.
>
> Alan.
>
>
> On Fri, Jun 6, 2008 at 9:42 PM, Petit Eric <[EMAIL PROTECTED]> wrote:
>
>> 2008/6/6 Kornél Pál <[EMAIL PROTECTED]>:
>> > Note that if you really need a batch file without a console window and
>> > don't want to create a wrapper executable you can use a VBScript (.vbs)
>> often, me in first i disable VBS host for securyty reason
>> > file instead that is supported by XP and Vista as well.
>> you have two good solution, press Windows (super) + r and write cmd +
>> enter in the dos windows , write "start /?", you should understand.
>> The second, more beautifull is to use the registry entry, current user
>> ... Run and create a key with value : "my command line who start the
>> prog"
>> >
>> > Kornél
>> >
>> > Xavi de Blas wrote:
>> >> Hello, i'm doing it with installjammer app. It locates mono
>> >> installation reading the windows registry and then it writes in a file
>> >> where it is.
>> >>
>> >> And then the bat reads that file.
>> >>
>> >> Now that i will kill the .bat, i will put the mono path on the start
>> >> up menu and desktop icon all using the installjammer.
>> >>
>> >> if you want to see how it works (still without the bat) download
>> >> chronojump for windows:
>> >>
>> >> http://www.gnome.org/projects/chronojump/installation.html
>> >> (it's 70MB because it contains Mono)
>> >>
>> >> bye
>> >>
>> >>
>> >> 2008/6/6 Stéphane Zanoni <[EMAIL PROTECTED]>:
>> >>> Installer's don't normally know where Mono is installed, so having
>> this
>> >>> as part of a standard InstallShield deployment might be more
>> difficult.
>> >>>
>> >>> Has the idea of providing some sort of architecture specific bootstrap
>> >>> process been discussed?
>> >>>
>> >>> Stéphane
>> >>>
>> >>>>>> "Jonathan Chambers" <[EMAIL PROTECTED]> 6/6/2008 12:41 PM >>>
>> >>> Hello,
>> >>>
>> >>> Can't you make the start menu shortcut launch your app using mono?
>> >>>
>> >>> "C:\> >>> "\chronojump.exe"
>> >>>
>> >>> Thanks,
>> >>> Jonathan
>> >>>
>> >>> On Fri, Jun 6, 2008 at 2:37 PM, Xavi de Blas <[EMAIL PROTECTED]>
>> >>> wrote:
>> >>>
>> >>>> 1st thanks to all, still no success:
>> >>>>
>> >>>> -i prefer to avoid the creation of a windows c program if there's
>> >>>> another solution
>> >>>>
>> >>>> Kornél, i tried the "monow" and it's nice because the windows
>> >>> terminal
>> >>>> exist but it contains no info and can be closed. But how to close it
>> >>>> automatically?
>> >>>> I suppose that compiling as a gui app will have the same problem as
>> >>> the
>> >>>> monow
>> >>>>
>> >>>> if we don't find how to close the terminal, the best solution should
>> >>> be:
>> >>>> call mono and my app as a parameter from the desktop icon (without
>> >>> the
>> >>>> need of a .bat)
>> >>>>
>> >>>> any more ideas?
>> >>>>
>> >>>> how glade that it's included with mono on windows it's an exe that
>> >>>> calls mono? is it selfcontained?
>> >>>>
>> >>>> thanks again
>> >>>>
>> >>>> 2008/6/6 Kornél Pál <[EMAIL PROTECTED]>:
>> >>>>> Use monow.exe instead of mono.exe
>> >>>>>
>> >>>>> Kornél
>> >>>>>
>> >>>>> Xavi de Blas wrote:
>> >>>>>> Sorry for the long subject of this email, but i have the
>> >>> following
>> >>>>>> problem:
>> >>>>>>
>> >>>>>> 1.- I don't find the way to call from windows "start" menu: mono
>> >>> and
>> >>>>>> chronojump
>> >>>>>> 2.- As i don't find the way, i created a .bat, and this calls
>> >>> both
>> >>>>>> 3.- but the .bat leaves the console open all the time my app is
>> >>> open.
>> >>>>>> This is not nice, and also some users close the console and then
>> >>>>>> chronojump closes
>> >>>>>>
>> >>>>>> What is the best solution?
>> >>>>>>
>> >>>>>> Thanks
>> >>>> ___
>> >>>> Mono-list maillist  -  Mono-list@lists.ximian.com
>> >>>> http://lists.ximian.com/mailman/listinfo/mono-list
>> >>>>
>> >>
>> > ___
>> > Mono-list maillist  -  Mono-list@lists.ximian.com
>> > http://lists.ximian.com/mailman/listinfo/mono-list
>> >
>> ___
>> Mono-list maillist  -  Mono-list@lists.ximian.com
>> http://lists.ximian.com/mailman/listinfo/mono-list
>>
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] how to call a mono graphical app on windows without a terminal being shown?

2008-06-06 Thread Jonathan Chambers
Hello,

Can't you make the start menu shortcut launch your app using mono?

"C:\\chronojump.exe"

Thanks,
Jonathan

On Fri, Jun 6, 2008 at 2:37 PM, Xavi de Blas <[EMAIL PROTECTED]> wrote:

> 1st thanks to all, still no success:
>
> -i prefer to avoid the creation of a windows c program if there's
> another solution
>
> Kornél, i tried the "monow" and it's nice because the windows terminal
> exist but it contains no info and can be closed. But how to close it
> automatically?
> I suppose that compiling as a gui app will have the same problem as the
> monow
>
> if we don't find how to close the terminal, the best solution should be:
>
> call mono and my app as a parameter from the desktop icon (without the
> need of a .bat)
>
> any more ideas?
>
> how glade that it's included with mono on windows it's an exe that
> calls mono? is it selfcontained?
>
> thanks again
>
> 2008/6/6 Kornél Pál <[EMAIL PROTECTED]>:
> > Use monow.exe instead of mono.exe
> >
> > Kornél
> >
> > Xavi de Blas wrote:
> >>
> >> Sorry for the long subject of this email, but i have the following
> >> problem:
> >>
> >> 1.- I don't find the way to call from windows "start" menu: mono and
> >> chronojump
> >> 2.- As i don't find the way, i created a .bat, and this calls both
> >> 3.- but the .bat leaves the console open all the time my app is open.
> >> This is not nice, and also some users close the console and then
> >> chronojump closes
> >>
> >> What is the best solution?
> >>
> >> Thanks
> >
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Beginning Questions

2008-06-03 Thread Jonathan Chambers
Hello,
 Mono uses a few licenses for different parts. See here for the best
info: http://www.mono-project.com/License

Thanks,
Jonathan

On Tue, Jun 3, 2008 at 10:18 AM, Chris Howie <[EMAIL PROTECTED]> wrote:

> On Tue, Jun 3, 2008 at 9:55 AM, Adam Tauno Williams
> <[EMAIL PROTECTED]> wrote:
> > Yes, Mono is under the Lesser GPL.
>
> Surely you meant MIT X11?
>
> --
> Chris Howie
> http://www.chrishowie.com
> http://en.wikipedia.org/wiki/User:Crazycomputers
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono on Win32

2007-12-14 Thread Jonathan Chambers
Hello,
   It appears to be looking for libcroco-0.6.3.dll, so perhaps
librsvg-2.dll or librsvg-2-2.dll depends on it.

Thanks,
Jonathan

On Dec 14, 2007 5:54 PM, John M. Anderson <[EMAIL PROTECTED]> wrote:

>
> Windows does not use a lib prefix, try renaming the file rsvg-2.dll .
> >
> > Andreas
> >
>
>
> That doesn't seem to have helped, I wonder if its looking for something
> other than librsvg-2-2.dll and librsvg-2.dll
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] broken svn link

2007-11-10 Thread Jonathan Chambers
Hi,

 Which link are you referring to? They all seem to be working for
me. Here's the link to the svn directory containing all the VS
project: http://anonsvn.mono-project.com/viewcvs/trunk/mono/msvc/

Thanks,
Jonathan

On Nov 10, 2007 7:24 AM, Anton Hughes <[EMAIL PROTECTED]> wrote:
> Hi
>
> I am interested in developing mono using visual studio.net.
>
> I found this page - http://www.mono-project.com/Compiling_Mono_VSNET -
> however the link to the svn link to the vs.net project is not working.
>
> Does anyone have the correct link?
>
> Also, is there an official mono forum? I find forums much better than
> mailing lists.
>
> Regards
> Anton
> Send instant messages to your online friends http://au.messenger.yahoo.com
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Problems with Visual Studio 2005 compiled code

2007-08-30 Thread Jonathan Chambers
Eric,

 Your x64 output was in fact a PE+ executable. However, the Any CPU
target looks like it should have worked. Let us know.

Thanks,
Jonathan

On 8/30/07, Eric Morgan <[EMAIL PROTECTED]> wrote:
>
> Here's the dumpbin output for both the ANYCPU and x64.  Now that I look
> back, I think my ANY CPU test was still using the x64 build, so that was
> dumb.  But the x64 build didn't work, so at least that part will be helpful.
>
>
> I have not tried SVN yet, I had to do a full clean re-make of it, so it's
> taking a bit.  I will reply when I test it on whether it works or not.  For
> now, here's the results of my dumpbin (.txt attached)
>
> Thanks again!
>
> Eric Morgan
>
> On 8/30/07, Jonathan Chambers <[EMAIL PROTECTED]> wrote:
> >
> > Eric,
> >  Start up a VS cmd prompt. Then run the following on your file (both
> > built for x64 and Any CPU):
> >
> > dumpbin /HEADERS yourfile.exe
> >
> > Send me the output. It will tell us the format of the file.
> >
> > Thanks,
> > Jonathan
> >
> > On 8/30/07, Paolo Molaro < [EMAIL PROTECTED]> wrote:
> > >
> > > On 08/30/07 Jonathan Chambers wrote:
> > > >  This definitely looks like an issue with running a PE+
> > > executable
> > > > (produced if you target the x64 platform). If I try to run a PE+
> > > executable
> > > > under mono I get:
> > > >
> > > > Cannot open assembly test.exe.
> > > >
> > > > Mono currently does not support PE+, although it may in the near
> > > term as the
> > > > consensus is that is shouldn't be too hard to do. I'm guessing both
> > > times
> > > > you somehow produced a PE+ executable. Try specifically targeting
> > > x86 as the
> > > > platform and see if you application runs.
> > >
> > > I just added support for the PE+ file format in svn, at least the
> > > sample
> > > program that Jonathan kidly provided loads and runs correctly.
> > > So if the original issue was the PE+ file format, it should work now
> > > with mono from svn.
> > >
> > > lupus
> > >
> > > --
> > > -
> > > [EMAIL PROTECTED] debian/rules
> > > [EMAIL PROTECTED] Monkeys do it better
> > > ___
> > > Mono-list maillist  -  Mono-list@lists.ximian.com
> > > http://lists.ximian.com/mailman/listinfo/mono-list
> > >
> >
> >
> > ___
> > Mono-list maillist  -  Mono-list@lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-list
> >
> >
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Problems with Visual Studio 2005 compiled code

2007-08-30 Thread Jonathan Chambers
Eric,
 Start up a VS cmd prompt. Then run the following on your file (both
built for x64 and Any CPU):

dumpbin /HEADERS yourfile.exe

Send me the output. It will tell us the format of the file.

Thanks,
Jonathan

On 8/30/07, Paolo Molaro <[EMAIL PROTECTED]> wrote:
>
> On 08/30/07 Jonathan Chambers wrote:
> >  This definitely looks like an issue with running a PE+ executable
> > (produced if you target the x64 platform). If I try to run a PE+
> executable
> > under mono I get:
> >
> > Cannot open assembly test.exe.
> >
> > Mono currently does not support PE+, although it may in the near term as
> the
> > consensus is that is shouldn't be too hard to do. I'm guessing both
> times
> > you somehow produced a PE+ executable. Try specifically targeting x86 as
> the
> > platform and see if you application runs.
>
> I just added support for the PE+ file format in svn, at least the sample
> program that Jonathan kidly provided loads and runs correctly.
> So if the original issue was the PE+ file format, it should work now
> with mono from svn.
>
> lupus
>
> --
> -
> [EMAIL PROTECTED] debian/rules
> [EMAIL PROTECTED] Monkeys do it better
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Problems with Visual Studio 2005 compiled code

2007-08-30 Thread Jonathan Chambers
Eric,
 This definitely looks like an issue with running a PE+ executable
(produced if you target the x64 platform). If I try to run a PE+ executable
under mono I get:

Cannot open assembly test.exe.

Mono currently does not support PE+, although it may in the near term as the
consensus is that is shouldn't be too hard to do. I'm guessing both times
you somehow produced a PE+ executable. Try specifically targeting x86 as the
platform and see if you application runs.

Thanks,
Jonathan

On 8/30/07, Paolo Molaro <[EMAIL PROTECTED]> wrote:
>
> On 08/29/07 Eric Morgan wrote:
> > Code compiled from VS2005 does not run under mono.  It says that it
> cannot
> > open the assembly (Main executable).  The same mono version will run
> other
> > apps compiled with our old VS2003.  Is there some configuration option
> I'm
> > missing? What else can I do to troubleshoot it to at least see what's
> wrong?
> >
> > Mono-INFO: Assembly Loader probing location:
> >
> '/home/rengeo/RenegadeGeophysics/SeismicStudioLinux/SeismicStudio1.3.3/SeismicStudio.exe'.
> >
> > Mono-INFO: Unloading image
> >
> /home/rengeo/RenegadeGeophysics/SeismicStudioLinux/SeismicStudio1.3.3/SeismicStudio.exe
> > [0x7826c0].
> > Cannot open assembly
> >
> /home/rengeo/RenegadeGeophysics/SeismicStudioLinux/SeismicStudio1.3.3/SeismicStudio.exe.
>
> I guess you can't share that app with us? It looks like an issue with
> the loader: it may be over-zealous in some sanity checks it is doing.
> If you can't send the program to me (there is no need to send it to the
> list), you could try to send me just the first 4 or 8 KBs of it: it may
> be possible that would be enough to see what is going on.
> Or if you can get a binary of some other program compiled with VS2005
> that fails to load in the same way, that would work too.
>
> Thanks!
>
> lupus
>
> --
> -
> [EMAIL PROTECTED] debian/rules
> [EMAIL PROTECTED] Monkeys do it better
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Fw: Fw: Fw: Compilng 1.2.5 preview 5

2007-08-29 Thread Jonathan Chambers
g_unsetenv has been around since 2.4 according to
http://www.gtk.org/api/2.6/glib/glib-Miscellaneous-Utility-Functions.html#g-unsetenv

Thanks,
Jonathan

On 8/29/07, Jonathan Chambers <[EMAIL PROTECTED]> wrote:
>
> Do you have a very old glib? I think g_unsetenv might not be in older
> versions of glib; I think I saw something like this on windows a long time
> ago with a pre 2.4/2.6 glib.
>
> - Jonathan
>
> On 8/29/07, Jorge Bastos <[EMAIL PROTECTED]> wrote:
> >
> > ok seams it doesn't want nothing with me.
> >
> > i removed /usr/local/sbin/mono and compiled and i got:
> >
> > make[7]: Entering directory `/usr/local/src/apache/mono/mono-1.2.5/mcs'
> > /usr/local/src/apache/mono/mono- 1.2.5/mono/mini/mono: symbol lookup
> > error:
> > /usr/local/src/apache/mono/mono-1.2.5/mono/mini/mono: undefined symbol:
> > g_unsetenv
> >
> >
> >
> > - Original Message -
> > From: "Jorge Bastos" < [EMAIL PROTECTED]>
> > To: "Andreas Färber" <[EMAIL PROTECTED]>
> > Cc: 
> > Sent: Wednesday, August 29, 2007 10:01 AM
> > Subject: Re: [Mono-list] Fw: Fw: Compilng 1.2.5 preview 5
> >
> >
> > I think it was because the last mono was built on top of libc 2.5 and i
> > upgraded to libc 2.6
> > I removed the previous mono binary and im compiling again, lets see.
> > Ill give feedback in a moment.
> >
> >
> > - Original Message -
> > From: "Andreas Färber" < [EMAIL PROTECTED]>
> > To: "Jorge Bastos" <[EMAIL PROTECTED]>
> > Cc: "Mads Bondo Dydensborg" <[EMAIL PROTECTED] >; 
> > 
> > Sent: Wednesday, August 29, 2007 9:58 AM
> > Subject: Re: [Mono-list] Fw: Fw: Compilng 1.2.5 preview 5
> >
> >
> > >
> > > Am 29.08.2007 um 10:48 schrieb Jorge Bastos:
> > >
> > >> Tks for the answer, but look at this:
> > >>
> > >> /usr/local/bin/mono: symbol lookup error:
> > /usr/local/bin/mono:  undefined
> > >> symbol: g_unsetenv
> > >>
> > >> you're sugesting to download a binary download from mono's download
> > >> section
> > >> right?
> > >
> > > In order to compile a new Mono you either need no mono/mcs in PATH
> > at  all
> > > or a working mono that can be used.
> > >
> > > I have no idea why your mono spits this error, but it appears to
> > be  the
> > > already installed mono so you need to remove it either completely  or
> > keep
> > > it from being detected.
> > >
> > > If you choose to install a precompiled mono it does not matter
> > where  you
> > > download it from, either from your distribution or from mono-
> > project.com.
> > >
> > > Andreas
> > >
> >
> > ___
> > Mono-list maillist  -  Mono-list@lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-list
> >
> > ___
> > Mono-list maillist  -  Mono-list@lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-list
> >
>
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Fw: Fw: Fw: Compilng 1.2.5 preview 5

2007-08-29 Thread Jonathan Chambers
Do you have a very old glib? I think g_unsetenv might not be in older
versions of glib; I think I saw something like this on windows a long time
ago with a pre 2.4/2.6 glib.

- Jonathan

On 8/29/07, Jorge Bastos <[EMAIL PROTECTED]> wrote:
>
> ok seams it doesn't want nothing with me.
>
> i removed /usr/local/sbin/mono and compiled and i got:
>
> make[7]: Entering directory `/usr/local/src/apache/mono/mono-1.2.5/mcs'
> /usr/local/src/apache/mono/mono-1.2.5/mono/mini/mono: symbol lookup error:
> /usr/local/src/apache/mono/mono-1.2.5/mono/mini/mono: undefined symbol:
> g_unsetenv
>
>
>
> - Original Message -
> From: "Jorge Bastos" <[EMAIL PROTECTED]>
> To: "Andreas Färber" <[EMAIL PROTECTED]>
> Cc: 
> Sent: Wednesday, August 29, 2007 10:01 AM
> Subject: Re: [Mono-list] Fw: Fw: Compilng 1.2.5 preview 5
>
>
> I think it was because the last mono was built on top of libc 2.5 and i
> upgraded to libc 2.6
> I removed the previous mono binary and im compiling again, lets see.
> Ill give feedback in a moment.
>
>
> - Original Message -
> From: "Andreas Färber" <[EMAIL PROTECTED]>
> To: "Jorge Bastos" <[EMAIL PROTECTED]>
> Cc: "Mads Bondo Dydensborg" <[EMAIL PROTECTED]>; 
> Sent: Wednesday, August 29, 2007 9:58 AM
> Subject: Re: [Mono-list] Fw: Fw: Compilng 1.2.5 preview 5
>
>
> >
> > Am 29.08.2007 um 10:48 schrieb Jorge Bastos:
> >
> >> Tks for the answer, but look at this:
> >>
> >> /usr/local/bin/mono: symbol lookup error:
> /usr/local/bin/mono:  undefined
> >> symbol: g_unsetenv
> >>
> >> you're sugesting to download a binary download from mono's download
> >> section
> >> right?
> >
> > In order to compile a new Mono you either need no mono/mcs in PATH
> at  all
> > or a working mono that can be used.
> >
> > I have no idea why your mono spits this error, but it appears to be  the
> > already installed mono so you need to remove it either completely  or
> keep
> > it from being detected.
> >
> > If you choose to install a precompiled mono it does not matter
> where  you
> > download it from, either from your distribution or from mono-
> project.com.
> >
> > Andreas
> >
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] System.Media.SystemSounds not available on Windows?

2007-08-26 Thread Jonathan Chambers
Hello,

The current implementation of System.Media.SoundPlayer has an AudioDevice
backend only for Alsa at this point it seems (libasound). I'm guessing
someone needs to write a windows backend using WinMM (Windows Multi-Media)
or Direct Sound.

Thanks,
Jonathan

On 8/26/07, Xavi de Blas <[EMAIL PROTECTED]> wrote:
>
> Hello again
>
> Why this works on Mono (Linux), .NET (Windows) but not Mono (Windows) ?
>
> System.Media.SystemSounds.Question.Play();
>
> If is not implemented, Is there any workaround?
>
> Thanks
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Hang on JIT-ing fn with P/Invoke?

2007-08-09 Thread Jonathan Chambers
I haven't tried any of the code, but looking over it  here are a few
thoughts. It appears the definition of sdp_list_t may be wrong. See
http://sofia-sip.sourceforge.net/refdocs/sdp/sdp_8h-source.html . It seems
to be missing the size field:

typedef struct sdp_list_s

   sdp_list_t
;
struct sdp_list_s
{
   int  l_size
;
   sdp_list_t 

 *l_next 
;
   sdp_text_t 

 *l_text 
;
};


Also, I am not sure how things will work out having a class as the return
type of a pinvoke (sdp_list_append). It may marshal correctly, but then  I
*think* mono will try to free the memory of the unmanaged class. It might be
better to return an IntPtr and marshal it yourself.

Good luck.

- Jonathan

On 8/9/07, Andy Hume <[EMAIL PROTECTED]> wrote:
>
> Can someone try reproducing this for me.  When I run the following program
> it hangs _before_ entering the function doing a certain P/Invoke call.  If I
> comment out the sdp_list_append call it runs to completion.  It doesn't
> occur when run on the Windows mono.exe, but does in the Mono Suse vmx.  It
> needs BlueZ's libbluetooth.
>
> My best guess is that the jitter is getting stuck?  There may well be
> something wrong with the P/Invoke definitions :-,), but I'm reporting the
> hang.
>
>
> using System;
> using System.Runtime.InteropServices;
>
> class Foo2
> {
> static void Main()
> {
> Console.WriteLine("entering Main");
> fn1();
> }
> static void fn1()
> {
> Console.WriteLine("entering fn1");
> fn2();
> }
> static void fn2()
> {
> Console.WriteLine("entering fn2");
> fn3();
> }
>
> static void fn3()
> {
> Console.WriteLine("entering fn3");
> uuid_t svc_uuid = new uuid_t();
> NativeMethods.sdp_uuid16_create(svc_uuid, 0x0100);
> // With this call in place, the programs hangs apparently
> // before entering this function. 'kill -QUIT' shows
> // Main->fn1->fn2->fn2<0x>
> // Comment it out and the program runs to completion
> // (likely producing a memory error when it does so).
> /**/
> sdp_list_t search_list
> = NativeMethods.sdp_list_append(null, svc_uuid);
> //*/
> }
>
> [StructLayout(LayoutKind.Sequential)]
> class uuid_t
> {
> public byte type;
> public Guid uuid128; //?
> }
>
> [StructLayout(LayoutKind.Sequential)]
> class sdp_list_t
> {
> public sdp_list_t next;
> public IntPtr data;
> }
>
> class NativeMethods
> {
> const string BluetoothLibrary = "libbluetooth";
>
> //sdp_list_t* sdp_list_append(sdp_list_t* list, void* d);
> [DllImport(BluetoothLibrary)]
> internal static extern sdp_list_t sdp_list_append(sdp_list_t list,
> uuid_t d);
>
> //uuid_t* sdp_uuid16_create(uuid_t* uuid, uint16_t data);
> [DllImport(BluetoothLibrary)]
> internal static extern uuid_t sdp_uuid16_create(uuid_t uuid, Int16
> data);
>
> }
>
> }//class
>
>
> The stack trace at hang is the following; note no fn3.
>
> [EMAIL PROTECTED]:~/Desktop/andy> mono --debug foo2.exe
> entering fnMain
> entering fn1
> entering fn2
> Full thread dump:
>
> "" tid=0x0xb7d74ae0 this=0x0x21e10:
>   at Foo2.fn2 () <0x>
>   at Foo2.fn2 () <0x00013>
>   at Foo2.fn1 () <0x00012>
>   at Foo2.Main () <0x00012>
>   at (wrapper runtime-invoke) 
> System.Object.runtime_invoke_void(object,intptr,intptr,intptr) <0x>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Questions about Mono

2007-07-30 Thread Jonathan Chambers
Hello Marco,

 In regards to #2, COM Interop should work pretty well at this point.
You'll have to try it in your specific case. The main things that are
missing at this point are IDispatch support, and Connection Points. As long
as you are not using either of those functionalities, you should have
success AFAIK. If you have any problems, please let me know.

Also, I don't think that mono interacts well with wine, but am not sure of
the details. You should be able to google the history of that topic.

Thanks,
Jonathan

On 7/28/07, Marco Craveiro <[EMAIL PROTECTED]> wrote:
>
> hello mono-list,
>
> got a couple of questions, no luck with googling:
>
> 1) can mono support processes greater than 4 GB on linux on AMD64?
>
> 2) is it possible to access non-gui COM objects on linux via wine in
> mono? This page seems to imply the COM support is not there yet (not
> even for win32):
>
> http://www.mono-project.com/COM_Interop
>
> have things changed since then?
>
> many thanks for your time
>
> marco
> --
> A mind for ever voyaging through strange seas of thought, alone. --
> Wordsworth on Newton
>
> blog: http://mcraveiro.blogspot.com/
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Trying to port code from my MSDN Article and having trouble.

2007-07-27 Thread Jonathan Chambers
Hi Peter,
 I'm guessing you tried to compile with mcs. You need to compile with
gmcs, rather than mcs, to use 2.0 features (like generics).

Thanks,
Jonathan

On 7/27/07, Peter Kellner <[EMAIL PROTECTED]> wrote:
>
> So, a while back I wrote an MSDN article on managing asp.net 2.0
> membership with business objects.  I'm trying to port that code and
> don't quite have it all working.  My first issue was I got a Data
> Conversion error which I don't get with Microsoft's .net.  I had brought
> in the dll's directly and it was not giving me a line number.  So, I
> decided to try and compile my 3 source objects.
>
> I have a declaration like this that is giving me an error with mono:
> (using the vmware distribution).
>
>
> namespace MembershipUtilities
> {
>
> [DataObject(true)]  // This attribute allows the
> public class RoleDataObject
> {
>
>   [DataObjectMethod(DataObjectMethodType.Select, true)]
>  static public List GetRoles()
> // ERROR FROM MONO COMPILER POINTS TO THIS LINE
> {
> return GetRoles(null, false);
> }
> ...
>
> The error I get from mono develop is:  CS1518: Expected
> class,delegate,enum,interface, or struct'
>
> Can someone point out what's not good about my syntax?  It's pointing at
> the static line.  Also, when I get a runtime error, will I get the line
> of code from my asp.net app if I have debug=true set in my web.config
> and I compile the library that includes the above code with debug?
>
> Thanks,
>
> BTW, my article on converting is here:
> http://msdn2.microsoft.com/en-us/library/aa478947.aspx
>
> Peter Kellner
> http://peterkellner.net
> MVP, ASP.NET
>
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Need help with DllImport (P/Invoke) and UCS-4 unicode

2007-07-15 Thread Jonathan Chambers

Hello Christian,
I had the same problem in a different setting. I use a custom
marshaller (http://msdn2.microsoft.com/en-us/library/d3cxf9f0.aspx) for
strings in all of my pinvokes. It's pretty straightforward setting up a
custom marshaller if you follow the link above. If you need more details let
me know.

Thanks,
Jonathan

On 7/15/07, Christian Heimes <[EMAIL PROTECTED]> wrote:


Hello!

I'm working on PythonNet (http://pythonnet.sourceforge.net/). PythonNet
is an integration of the C library into .NET which allows a developer to
use .NET code inside Python or Python inside .NET. In the past few weeks
I've fixed a bunch of outstanding bugs and ported PythonNet to Python
2.5. It works pretty well on Windows.

However Linux with mono is a different story. Under Windows Python is
using a UCS-2 to store unicode but most Linux distributions (Debian,
Ubuntu and probably Redhat and SuSE) are compiling Python with UCS-4.
.NET supports only 2 byte unicode. My problem is perfectly explain at

http://www.mono-project.com/Interop_with_Native_Libraries#P.2FInvoke_Specification

One of the problematic function look like:

[DllImport(Runtime.dll, CallingConvention = CallingConvention.Cdecl,
   EntryPoint = "PyUnicodeUCS4_FromUnicode",
   ExactSpelling = true, CharSet = CharSet.Unicode)]
internal unsafe static extern IntPtr
PyUnicode_FromUnicode(string s, int size);

More functions can be found at

https://pythonnet.svn.sourceforge.net/svnroot/pythonnet/branches/clr-2.0-python-2.5-branch/src/runtime/runtime.cs

How should I solve the issue? Has Mono some generic solution for the
general issue of UCS-4 vs. UCS-2 unicode or do I have to convert the
stuff manually by wrapping every external method? If I have to convert
it manually is System.Text.Encoding.UTF32 the right module?

Christian

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] [mono-list]DLL Import errors

2007-04-20 Thread Jonathan Chambers

I may be missing something, but are you trying to PInvoke a 32-bit library
(your licensing library) from within a 64-bit mono process? I do not think
that is possible.

Thanks,
Jonathan

On 4/20/07, Jeffrey Stedfast <[EMAIL PROTECTED]> wrote:


On Wed, 2007-04-18 at 10:28 -0600, Eric Morgan wrote:
>
>
> >Frequently the problem is that the library is improperly linked; mono
> >(effectively) loads libraries using dlopen(3) with RTLD_NOW set, so
> if
> >your library depends on a symbol from another library but wasn't
> linked
> >against that library, you will get errors loading it.
> >
> >You can also use http://www.jprl.com/dltest.c to test this scenario
> (see
> >the comments for compile commands).
> >
> >If that still fails, you can reply to the mailing list with the Mono
> >output attached.
> >
> > - Jon
> >
>
> Still fails, and the output is generally the same from when I was
> using MONO_LOG_LEVEL=debug.  Here's the output from dltest:
>
> [EMAIL PROTECTED] dltest]$
> ll /home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/
> total 992
> -r-xr-xr-x  1 rengeo rengeo 339956 Apr 17 10:14 libSentinelKeys32.a
> -r-xr-xr-x  1 rengeo rengeo 315468 Feb  8 14:42 libSentinelKeys32.so
> -r-xr-xr-x  1 rengeo rengeo 328388 Apr 17 12:26 libSentinelKeysJDK.so
> [EMAIL PROTECTED]
> dltest]$ ./dltest
/home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so
> error loading library
>
`/home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so':
/home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so:
cannot open shared object file: No such file or directory
> [EMAIL PROTECTED] dltest]$
>
>
> The library is clearly there, but both mono and this dltest is saying
> that it doesn't exist.  I've tried copying the library directly into
> the folder with dltest, and it still can't find it, even though is
> literally right there.

Don't assume that it means that the file you gave it doesn't exist (I
know, it is the most reasonable assumption to make). I suspect that
Jonathan is correct, the problem is that your library depends on symbols
not found in either the application nor in the library you are trying to
load, and so dlopen() is failing - of course, this is just a guess :)

The only way to know for sure is to read the source code for dlopen()
and try to figure out what the problem is that way.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Combining JIT and interpreter

2007-03-06 Thread Jonathan Chambers

I added some updates to two of the tasks below.

On 3/6/07, Miguel de Icaza <[EMAIL PROTECTED]> wrote:


Hello,

> Any suggestions as to what these other things could be ?

Here are some:

* Implement generic code sharing (this is when the compiler
  detects that the generated code for two different
  instantiations of a generic method would have the same
  code).

* Precompilation (AOT) support for new platforms.

* Win64 port.



This is underway. There are a few issues.

* First, the runtime will need to be built with MSVC as gcc (and the rest of
the cygwin toolchain) is not ported to Win64. This means we can either drive
MSVC using the current autotools/cygwin build process, or just use VS to
build runtime. Right now, it looks much easier to just use VS so this is the
approach I am taking. I'll setup some scripts to copy files to correct
location after build so that mcs tree can be built using the MSVC built
runtime.

* As for actually porting runtime code, a few tasks I can think of or
started include generally cleaning up the vcproj files, fixing any
trucations if they exist (sizeof(long) == 4 on Win64), removing inline
assembly (64-bit MSVC does not support this), modifying the JIT to handle
the Win64 calling convention (there is only one AFAIK).

* The other big task is making sure all the dependent libraries, mainly
libgc and glib, exist on Win64. I started working on libgc (the newer
releases ship with vcproj files), but I think little work has been done in
this area. For glib, there is a currently active thread on the gtk mailing
list right now where someone else is building glib on Win64 so I'm hoping
this is done by the time I need it.


   * Complete the Mono verifier (we have tests that are failing

  in the verifier directory).

* Add XPCOM or UNO support to Mono in addition to the current
  Mainsoft COM support (coordinate with Jonathan Chambers).



* XPCOM support should be very trivial to add, at least on Win/Linux
x86/x86-64 platforms. Mainly, it just needs someone interested in this to
try it and report any problems. I spent a few hours last weekend to see if I
could use the COM Interop infrastructure to traverse the Mozilla DOM and I
could. The main issues are where XPCOM differs from MS COM, like strings and
the actual component creation mechanism.


There are other tasks here:


http://www.mono-project.com/Todo

And here:

http://www.mono-project.com/StudentProjects

Miguel.

> Thanks,
> -Aram
>
> On Mar 5, 2007, at 5:05 PM, Miguel de Icaza wrote:
>
> >
> >> I am trying to modify Mono to have the interpreter and JIT compiler
> >> run at the same time. The idea is to have some parts interpreted
> >> while others compiled. Does mono already do this ? Are there
> >> mechanisms in place for this ?
> >
> > It does not do it.
> >
> > There is no mechanism to do it.
> >
> > This seems like a lot of work, there might be better things to do that
> > would give you better bang for your buck though.
> >
> > Miguel.
>
> ___
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list