473,387 Members | 1,535 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Compile python on Solaris 64bit

Hi,

I want to compile python on my solaris 10 system (amd 64 bit).

I did the following:

../configure --prefix=/opt/64/python
make

which resulted in this error:
"Include/pyport.h", line 730: #error: "LONG_BIT definition appears wrong
for platform (bad gcc/glibc config?)."

so I edited the file and removed the error line and did a configure and
make again after a make distclean.

after a new make I get this error complaining about 32 and 64 bit.

ld: fatal: file Parser/acceler.o: wrong ELF class: ELFCLASS32

when I look to the cc statements none of my CFLAGS are passed while these
are in my environment;

CC=cc
CFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all -xlibmil
-xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
CXX=CC
CXXFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all
-xlibmil -xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
LDFLAGS=-xtarget=opteron -xarch=amd64
anybody succesfully compiled python on solaris?

thanks,
martijn

Oct 12 '06 #1
4 6463

Martijn de Munnik wrote:
Hi,

I want to compile python on my solaris 10 system (amd 64 bit).

I did the following:

./configure --prefix=/opt/64/python
make

which resulted in this error:
"Include/pyport.h", line 730: #error: "LONG_BIT definition appears wrong
for platform (bad gcc/glibc config?)."

so I edited the file and removed the error line and did a configure and
make again after a make distclean.

after a new make I get this error complaining about 32 and 64 bit.

ld: fatal: file Parser/acceler.o: wrong ELF class: ELFCLASS32

when I look to the cc statements none of my CFLAGS are passed while these
are in my environment;

CC=cc
CFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all -xlibmil
-xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
CXX=CC
CXXFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all
-xlibmil -xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
LDFLAGS=-xtarget=opteron -xarch=amd64
anybody succesfully compiled python on solaris?
I have compiled Python 2.5 successfully on 32-bit Intel platform. After
running configure, I had to manually edit the generated Makefile to add
the contents of CFLAGS.

I've had difficulties with ctypes, too. To get a successful compile, I
had to edit ffitarget.h (I think) and also use the Sun Studio Express 2
compiler suite. Or use gcc.
>
thanks,
martijn
casevh

Oct 12 '06 #2
Il Thu, 12 Oct 2006 16:46:19 +0200 (CEST), Martijn de Munnik ha scritto:
Hi,

I want to compile python on my solaris 10 system (amd 64 bit).
Just a question... AFAIK, Solaris 10 64 bit includes binaries & kernels for
both 64 bit and 32 bit machines. Which binaries are you actually using? I
think there could be some configuration mismatch between running binaries
and environment variables that could confuse the compiler.

--
Alan Franzoni <al***************@gmail.com>
-
Togli .xyz dalla mia email per contattarmi.
Rremove .xyz from my address in order to contact me.
-
GPG Key Fingerprint:
5C77 9DC3 BD5B 3A28 E7BC 921A 0255 42AA FE06 8F3E
-
Blog: http://laterradeglieroi.verdiperronchi.com
Oct 12 '06 #3
I did build Python 2.5 on a Solaris 10 Ultra 20 machine (Opteron) but
using the SUN compilers. Two changes were needed in the Makefile:
CXX=CC and CCSHARED=-KPIC.

There are a few issues which I have not investigated further (like Tcl
and ffitarget.h), but the tests pass except for 3 unexpected skips.
Other than that, Python 2.5 seems to be running fine, so far.

Also, I am using the Python 2.4 build for Solaris build from
ActiveState as well as Python 2.3.3 which is distributed with Solaris
in /usr/sfw/bin.

/Jean Brouwers
Martijn de Munnik wrote:
Hi,

I want to compile python on my solaris 10 system (amd 64 bit).

I did the following:

./configure --prefix=/opt/64/python
make

which resulted in this error:
"Include/pyport.h", line 730: #error: "LONG_BIT definition appears wrong
for platform (bad gcc/glibc config?)."

so I edited the file and removed the error line and did a configure and
make again after a make distclean.

after a new make I get this error complaining about 32 and 64 bit.

ld: fatal: file Parser/acceler.o: wrong ELF class: ELFCLASS32

when I look to the cc statements none of my CFLAGS are passed while these
are in my environment;

CC=cc
CFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all -xlibmil
-xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
CXX=CC
CXXFLAGS=-xO3 -mt -fsimple=1 -ftrap=%none -nofstore -xbuiltin=%all
-xlibmil -xlibmopt -xtarget=opteron -xarch=amd64 -xregs=no%frameptr
LDFLAGS=-xtarget=opteron -xarch=amd64
anybody succesfully compiled python on solaris?

thanks,
martijn
Oct 12 '06 #4
Martijn de Munnik schrieb:
anybody succesfully compiled python on solaris?
If that's really all you want to know: yes, I did.
It works for me on 32-bit SPARC, and 64-bit SPARC.

If you want to know more, you have to be *a lot*
more precise as to what precisely you are trying
to achieve, and how precisely it fails.

E.g.
- what Python version?
- what compiler? If gcc, what precise release?
- are you attempting to produce 32-bit binaries
or 64-bit binaries?
Regards,
Martin
Oct 12 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Markus Enders | last post by:
Hi everybody, currently we use DB2 7.1 on several Solaris machines. Now we are planning, to migrate to SUSE Linux (newest version). I wonder, if we can keep our DB2 version 7.1, or if we need to...
0
by: Zorba.GR | last post by:
IBM DB2 Connect Enterprise Edition v8.2, other IBM DB2 (32 bit, 64 bit) (MULTiOS, Windows, Linux, Solaris), IBM iSoft Commerce Suite Server Enterprise v3.2.01, IBM Tivoli Storage Resource Manager...
0
by: Gellert, Andre | last post by:
Hello, yesterday I ran into problems installing my first PostgreSQL on Solaris. My main problems consisted on missing packages, because the test system I had to use was a very small installation....
2
by: Edward Maros | last post by:
I am writing a 64bit application for Solaris 10 and am need of 64 bit binaries for the ODBC interface. What I have found so far are 32 bit libraries that work on a 64 bit platform. Because I need...
0
by: PJ Halls | last post by:
I have been finding some strange behaviour with the Oracle InstantClient 10 libraries on Solaris 10 (Sparc 9). We are running the 10g 64bit server, also on Solaris. Whilst applications built...
5
by: shobhah | last post by:
Hi, We have a complete succsssfully working product on 32bit sparc solaris machine for which compiler used is CC 5.8 Now we are migarting our product from 32 bit to 64bit sparc solaris machine....
0
by: Kurt B. Kaiser | last post by:
Patch / Bug Summary ___________________ Patches : 380 open (-36) / 3658 closed (+65) / 4038 total (+29) Bugs : 965 open ( -9) / 6555 closed (+35) / 7520 total (+26) RFE : 272 open...
6
by: Kai Rosenthal | last post by:
Hello, how can I determine the architecture (32 or 64bit) with python 2.2 on Windows or Unix (AIX, Solaris) OS, without the modul platform? Thanks for your hints, Kai
5
by: Albert-jan Roskam | last post by:
Hi, I wrote the program below to merge all xls files in a given directory into one multisheet xls file. It uses xlwt and xlrd. The xls files I use for input are generated by Spss. When I open and...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.