473,698 Members | 2,942 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Python 2.4.2 gcc 3.4.4 Solaris 8 build issues

Hi,
I encountered some build issues when compiling Python 2.4.4 on a Solaris 8
box using gcc 3.4.4:

1. Running configure detects that a C++-built main needs C++-linking.
Therefore, Python gets
linked with g++, creating a dependency on libstdc++.
Some research showed up a rather elaborate discussion in the
python-dev/c++-sig-archives, ending
up in a patch that replaces the --with-cxx option with a --with-cxx-main
switch and tries to set CXX
to some sensible value in the generated Makefile even if Python gets built
C-only.
(SF #1324762 Compiling and linking main() with C++ compiler, by Christoph
Ludwig; pending)

Now, I am still not 100 % sure about what I need to do. I need
C++-extensions, but I do not
want to link anything statically with Python, i.e. everything will be
dynamically imported extension
modules. I *think* I can build Python C-only, avoiding possible runtime
problems with C++-extensions that
might have been built with different C++ compilers.

Can anyony clear that up?

2. We have some stuff in non-standard locations here. To build properly, I
need to tell this
to configure (using CXX, CPPFLAGS, LD_LIBRARY_PATH ). Unfortunately, none of
this
gets communicated to the setup.py step with its find_library_fi le() stuff,
so it is also necessary to either
modify setup.py or add a setup.cfg file.

Is there some better way to do that?
(Probably the Makefile template could be changed to supply setup.py with
some appropriate
command line options for build_ext, but I do not know the autotools stuff.
Any recommendations
for some good tutorial?)

3. The test_locale test fails:
../python Lib/test/test_locale.py
'%f' % 1024 =? '1,024.000000' ... no
'%f' % 1024 == '1024.000000' != '1,024.000000'
'%f' % 102 =? '102.000000' ... yes
'%f' % -42 =? '-42.000000' ... yes
'%+f' % -42 =? '-42.000000' ... yes
'%20.f' % -42 =? ' -42' ... yes
'%+10.f' % -4200 =? ' -4,200' ... no
'%+10.f' % -4200 == ' -4200' != ' -4,200'
'%-10.f' % 4200 =? '4,200 ' ... no
'%-10.f' % 4200 == '4200 ' != '4,200 '
' '.isspace() =? True ... yes
'\xa0'.isspace( ) =? False ... no
'\xa0'.isspace( ) == True != False
'\xa1'.isspace( ) =? False ... yes
'\xc0'.isalpha( ) =? False ... no
'\xc0'.isalpha( ) == True != False
'\xc0'.isalnum( ) =? False ... no
'\xc0'.isalnum( ) == True != False
'\xc0'.isupper( ) =? False ... no
'\xc0'.isupper( ) == True != False
'\xc0'.islower( ) =? False ... yes
'\xec\xa0\xbc'. split() =? ['\xec\xa0\xbc'] ... no
'\xec\xa0\xbc'. split() == ['\xec', '\xbc'] != ['\xec\xa0\xbc']
'\xed\x95\xa0'. strip() =? '\xed\x95\xa0' ... no
'\xed\x95\xa0'. strip() == '\xed\x95' != '\xed\x95\xa0'
'\xcc\x85'.lowe r() =? '\xcc\x85' ... no
'\xcc\x85'.lowe r() == '\xec\x85' != '\xcc\x85'
'\xed\x95\xa0'. upper() =? '\xed\x95\xa0' ... no
'\xed\x95\xa0'. upper() == '\xcd\x95\xa0' != '\xed\x95\xa0'

?? Is this a known problem on Solaris?

Thanks in advance for any hints,
Holger

Der Inhalt dieser E-Mail ist vertraulich. Falls Sie nicht der angegebene
Empfänger sind oder falls diese E-Mail irrtümlich an Sie adressiertwurde ,
verständigen Sie bitte den Absender sofort und löschen Sie die E-Mail
sodann. Das unerlaubte Kopieren sowie die unbefugte Übermittlung sindnicht
gestattet. Die Sicherheit von Übermittlungen per E-Mail kann nicht
garantiert werden. Falls Sie eine Bestätigung wünschen, fordern Siebitte
den Inhalt der E-Mail als Hardcopy an.

The contents of this e-mail are confidential. If you are not the named
addressee or if this transmission has been addressed to you in error,
please notify the sender immediately and then delete this e-mail. Any
unauthorized copying and transmission is forbidden. E-Mail transmission
cannot be guaranteed to be secure. If verification is required, please
request a hard copy version.
Dec 30 '05 #1
1 1824
Holger Joukl wrote:
Now, I am still not 100 % sure about what I need to do. I need
C++-extensions, but I do not want to link anything statically with
Python, i.e. everything will be dynamically imported extension
modules. I *think* I can build Python C-only, avoiding possible
runtime problems with C++-extensions that might have been built with
different C++ compilers.

Can anyony clear that up?
On Solaris 8, yes you don't need to link Python with a C++ compiler.
This is thanks the ELF's .init section.

2. We have some stuff in non-standard locations here. To build
properly, I need to tell this to configure (using CXX, CPPFLAGS,
LD_LIBRARY_PATH ). Unfortunately, none of this > gets communicated to
the setup.py step with its find_library_fi le() stuff, so it is also
necessary to either modify setup.py or add a setup.cfg file.
Why do you say that? If you set CC before invoking configure,
it will get into Makefile, and from there into setup.py.
More generally: setup.py will take everything from Makefile,
so just check whether Makefile looks right.

As for LD_LIBRARY_PATH : If it is set when setup.py is running,
it will certainly apply. However, I really recommend to use
crle(8) instead:

crle -u -l /opt/sfw/lib

Then, your users will never have to set LD_LIBRARY_PATH
for /opt/sfw/lib.

Alternatively, set LD_RUN_PATH or pass -Wl,-R/opt/sfw/lib to
the linking compiler: this will encode the path into the
binary, so you still don't need to set LD_LIBRARY_PATH at
runtime.
?? Is this a known problem on Solaris?
It's known to me :-) I had not time to investigate it further.
Der Inhalt dieser E-Mail ist vertraulich.


So ein Quatsch. Selbst Google hat jetzt eine Kopie dieser Mail:

http://tinyurl.com/8qghw

Regards,
Martin
Dec 30 '05 #2

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

Similar topics

0
1439
by: Kurt B. Kaiser | last post by:
Patch / Bug Summary ___________________ Patches : 407 open ( +3) / 3393 closed (+17) / 3800 total (+20) Bugs : 888 open (+28) / 6145 closed (+14) / 7033 total (+42) RFE : 232 open ( +3) / 236 closed ( +1) / 468 total ( +4) New / Reopened Patches ______________________
7
3574
by: sam | last post by:
dear all, having spent the last couple of weeks getting to grips with python on windows, i am in the position of trying to make the transition to my newly arrived ultra 20. however, although there are plenty of files with idle somewhere in the title, idle.py (which i assume is the interpreter) will not open, as there is 'no installed viewer.' surely sun have not installed python only for it to unusable? i may well be completely off...
0
1606
by: Martijn de Munnik | last post by:
Hi, I'm trying to build/install pysqlite on a Solaris 10 platform. I've got Sun Studio 11 on a AMD 64 platform and got this error. I'm a python newbie and just want to install trac. I've got ActiveState python: ActivePython 2.4.3 Build 11 (ActiveState Software Inc.) based on Python 2.4.3 (#1, Apr 3 2006, 18:07:58) on sunos5 Type "help", "copyright", "credits" or "license" for more information.
4
6477
by: Martijn de Munnik | last post by:
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:
32
2847
by: siggi | last post by:
@Ben Sizer Hi Ben, in January I received your message re Pygame and Python 2.5: As a Python (and programming ) newbie allow me a - certainly naive - question:
0
1801
by: mg | last post by:
When make gets to the _ctypes section, I am getting the following in my output: building '_ctypes' extension creating build/temp.solaris-2.10-i86pc-2.5/home/ecuser/Python-2.5.1/ Modules/_ctypes creating build/temp.solaris-2.10-i86pc-2.5/home/ecuser/Python-2.5.1/ Modules/_ctypes/libffi creating build/temp.solaris-2.10-i86pc-2.5/home/ecuser/Python-2.5.1/ Modules/_ctypes/libffi/src
0
8683
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9170
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9031
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8904
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7741
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6531
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5867
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4624
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3052
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.