[Mono-list] Mono on PPC Linux quirk. Any work around?

Sean Dague sean at dague.net
Thu Jan 31 08:37:58 EST 2008


I'm working through getting OpenSim running on PPC Linux (ppc 32bit,
mono 1.2.5.1, gentoo linux), which is very close to working.  However,
there is currently at least one more issue to overcome, which seems to
be that structures are initialized differently on PPC than on x86.

At some point there is a binding layer through libsecondlife to
OpenJPEG.  It uses this structure:

        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        private struct MarshalledImage
        {
            public IntPtr encoded;             // encoded image data
            public int length;                 // encoded image length
            public int dummy; // padding for 64-bit alignment

            public IntPtr decoded;             // decoded image, contiguous components
            public int width;                  // width of decoded image
            public int height;                 // height of decoded image
            public int components;             // component count
        }

On x86 the decoded IntPtr is initialized to a value when a new
MarshalledImage is created.  On PPC (32bit) it is equal to IntPtr.Zero,
which blows up a Marshal.Copy call later.

Any ideas here on:
 * What is going on?
 * What possible fixes are?

Thanks in advance,

       -Sean

-- 
__________________________________________________________________

Sean Dague                                       Mid-Hudson Valley
sean at dague dot net                            Linux Users Group
http://dague.net                                 http://mhvlug.org

There is no silver bullet.  Plus, werewolves make better neighbors
than zombies, and they tend to keep the vampire population down.
__________________________________________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.ximian.com/pipermail/mono-list/attachments/20080131/d79bdf67/attachment.bin 


More information about the Mono-list mailing list