Solaris 64 bit compilation

Holden Caulfield phoebe_1 at att.net
Sat Sep 21 10:27:10 EDT 2002


Please see insert. I apoligize for not providing all the info, as I
did not have
access to the machine.

martin at v.loewis.de (Martin v. Loewis) wrote in message news:<m3sn03k44m.fsf at mira.informatik.hu-berlin.de>...
> phoebe_1 at att.net (Holden Caulfield) writes:
> 
> >  This is my first attempt at compiling Python v2.2.1 in *64bit* mode 
> > on a Solaris 5.9 system. I am using the Sun Compiler (the latest I do not
> > remember the version). I am migrating a few of my apps (all developed on
> > 64bit platforms) to Solaris, so I *need* the 64bit mode.
> 
> 
> I can't follow your conclusion - if you migrate applications which
> have been developed on 64-bit platforms, there is no inherent need to
> compile them as 64-bit binaries on Solaris 9.
> 

Ok, What I have is Python C-Extensions that I wrote for a third party
vendors
software. Unfortunately, they have decided to ship *only* 64 bit
libraries for
Solaris. So, you see I need to build python in that mode.

> > But, it is failing miserably. It compiles *fine* in 32bit mode (the default),
> > but it does me no good. As some of the extensions library that I have are
> > 64bit. Before, I start hacking I thought I would give a query here and see
> > if anyone had any success?
> 
> It compiles fine for me, with SunPRO 6U1.

What I have is :
cc: Sun WorkShop 6 update 1 C 5.2 2000/09/11
Like I said, it compiles fine for the default mode, which is creating
32bit
extensions,modules. Like I said before, I *need* to have it in 64-bit
objects,
modules,extensions etc.

> 
> > 
> > Here are my preliminary results:
> > - Flags used "-xarch=v9 -xcode=pic32".
> > The first thing I get is the bail-out in "pyport.h":
> >  Where the #LONG_BITS != (8 * sizeof(LONG)) fails!!!
> 
> Please try to report failures carefully. It does not say sizeof(LONG),
> instead, it says SIZEOF_LONG. Which gives rise to the question: What
> value does SIZEOF_LONG have, in pyconfig.h?
> 
cc -c -DNDEBUG -g -Xc xarch=v9 -xcode=pic32 -I. -I./Include
-DHAVE_CONFIG_H  -o Modules/p
ython.o Modules/python.c
"./Include/pyport.h", line 480: #error: "LONG_BIT definition appears
wrong for platform (bad gcc/glibc config?)."


> > So, I commented it out, first to proceed and see what happens. Most of them
> > compiled fine except, I got some serious errors in the:
> > fileobject.c file probably related to the LP64 model.
> > 
> > I will try to add more info, when I get around to it.
> 
> More info would be required if you want help. Start with reporting the
> error messages as the compiler produces them, instead of interpreting
> them, and reporting your interpretation.
> 

So after commenting it out, here is what I get.

cc -c -DNDEBUG -g -Xc xarch=v9 -xcode=pic32 -I. -I./Include
-DHAVE_CONFIG_H  -o Objects/f
ileobject.o Objects/fileobject.c
"Objects/fileobject.c", line 282: argument #2 is incompatible with
prototype:
        prototype: long : "/usr/include/iso/stdio_iso.h", line 209
        argument : union  {double _d, array[2] of int _l}
"Objects/fileobject.c", line 325: return value type mismatch
"Objects/fileobject.c", line 355: assignment type mismatch:
        union  {double _d, array[2] of int _l} "=" long
"Objects/fileobject.c", line 393: assignment type mismatch:
        union  {double _d, array[2] of int _l} "=" long
"Objects/fileobject.c", line 407: operands have incompatible types:
         union  {double _d, array[2] of int _l} "==" int
"Objects/fileobject.c", line 462: operands have incompatible types:
         union  {double _d, array[2] of int _l} "==" int
"Objects/fileobject.c", line 468: argument #1 is incompatible with
prototype:
        prototype: long : "./Include/intobject.h", line 37
        argument : union  {double _d, array[2] of int _l}
"Objects/fileobject.c", line 548: argument #2 is incompatible with
prototype:
        prototype: union  {double _d, array[2] of int _l} :
"/usr/include/unistd.h", line
 341
        argument : long
"Objects/fileobject.c", line 550: operands have incompatible types:
         union  {double _d, array[2] of int _l} ">=" int
"Objects/fileobject.c", line 551: assignment type mismatch:
        union  {double _d, array[2] of int _l} "=" long
"Objects/fileobject.c", line 553: operands have incompatible types:
         union  {double _d, array[2] of int _l} "<" int
"Objects/fileobject.c", line 555: operands have incompatible types:
         union  {double _d, array[2] of int _l} ">" union  {double _d,
array[2] of int _l
}
"Objects/fileobject.c", line 555: operands have incompatible types:
         union  {double _d, array[2] of int _l} ">=" int
"Objects/fileobject.c", line 556: operands have incompatible types:
         unsigned int "+" union  {double _d, array[2] of int _l}
"Objects/fileobject.c", line 556: operands have incompatible types:
         unsigned int "-" union  {double _d, array[2] of int _l}
"Objects/fileobject.c", line 1173: cannot recover from previous errors
cc: acomp failed for Objects/fileobject.c
*** Error code 2
make: Fatal error: Command failed for target `Objects/fileobject.o'

> Regards,
> Martin



More information about the Python-list mailing list