473,395 Members | 1,474 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,395 software developers and data experts.

Python 2.4.2 make failure in posixmodule on OSX 10.4.3

Hi All-

I'm trying to build Python 2.4.2 on OSX 10.4.3 (gcc ver. 3.3 apple
build 1495) and have the following error when running 'make':

gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp
-mno-fused-madd -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I.
-I./Include -DPy_BUILD_CORE -c ./Modules/posixmodule.c -o
Modules/posixmodule.o
Modules/posixmodule.c: In function `posix_lchown':
Modules/posixmodule.c:1353: warning: implicit declaration of function
`lchown'
Modules/posixmodule.c:5999:25: sys/statvfs.h: No such file or directory
Modules/posixmodule.c: At top level:
Modules/posixmodule.c:6002: error: parameter `st' has incomplete type
Modules/posixmodule.c: In function `posix_fstatvfs':
Modules/posixmodule.c:6048: error: storage size of `st' isn't known
Modules/posixmodule.c:6053: warning: implicit declaration of function
`fstatvfs'
Modules/posixmodule.c:6048: warning: unused variable `st'
Modules/posixmodule.c:6064:25: sys/statvfs.h: No such file or directory
Modules/posixmodule.c: In function `posix_statvfs':
Modules/posixmodule.c:6075: error: storage size of `st' isn't known
Modules/posixmodule.c:6079: warning: implicit declaration of function
`statvfs'
Modules/posixmodule.c:6075: warning: unused variable `st'
make: *** [Modules/posixmodule.o] Error 1

'make clean' hasn't helped, and I ran configure with
'--disable-toolbox-glue'.

I need to build it from source because I have a program with a long
running worker thread that I think will benefit from using Evan Jones'
memory management patch (http://evanjones.ca/python-memory-part2.html).
Note that I haven't applied the diff yet; this is just the reason I
need to build from source.

Couldn't find anything on this in the group already, or the main Python
site, or in any of the docs with the distribution.
Any suggestions on how I can remedy this?

Dec 6 '05 #1
6 1563
smurphus wrote:
Any suggestions on how I can remedy this?


It would be good if you could try to understand and to
analyse these error messages; your message does not
indicate whether you have knowledge of the C language
and could analyse them or not.

For example, it is very puzzling that there is no
declaration of lchown. Can you find a declaration
for this function (there must be one, somewhere
in /usr/include)? Why is it not used?

Regards,
Martin
Dec 6 '05 #2
Thanks for the reply, Martin.

I know a bit of C. I thought maybe I was missing something simple,
since I don't have an exotic system configuration.

Re: lchown
the file posixmodule.c in Python does include <sys/types.h> and I have
that header where it should be, i.e. /usr/include/sys/types.h so I
don't know why it tells me lchown is implicitly defined after the
include.

The next error with statvfs.h perhaps makes more sense. I do not have
/usr/include/sys/statvfs.h on my system, and the statement #include
<sys/statvfs.h> is in an include guard, #if defined(HAVE_FSTATVFS). I
assume that's not being detected properly by the configure script?

I hope that information is of some use. Not sure where to go from
here.

Thanks.

Dec 6 '05 #3
I just re-ran the configure script.

It reports:
checking for lchown... yes
checking for fstatvfs... yes

??

Dec 6 '05 #4
configure also reports
checking for statvfs... yes

Dec 6 '05 #5
smurphus wrote:
I hope that information is of some use. Not sure where to go from
here.


Please try
gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp
-mno-fused-madd -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I.
-I./Include -DPy_BUILD_CORE -c ./Modules/posixmodule.c -o
Modules/posixmodule.o --save-temps

and inspect the resulting posixmodule.i. I would expect that
it *doesn't* have the prototype for lchown.

I'm surprised though that you were suggesting (without
actually saying) that the prototype for lchown is in
sys/types.h in your system. I would have expected it in
unistd.h. Still can't check my Mac right now.

Re fstatvfs: can you verify that your system has the
fvstatvfs function? Is there a prototype declared anywhere?

Looking at

http://www.hmug.org/man/3/statvfs.php

suggests that OS X / Darwin does indeed have sys/statvfs.h.
So if you don't have it, something is broken with your
compiler setup.

Regards,
Martin
Dec 6 '05 #6
Yes, it looks like I was missing the necessary headers. Once I
replaced them, it has been smooth sailing.

Thank you for your assitance, Martin.

Dec 7 '05 #7

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

Similar topics

3
by: Phil Frost | last post by:
Greetings all. I'm attempting to embed a python interpreter at a very low level in an OS I am writing. Currently I'm stuck with build issues. Firstly, as there is no working C compiler in our OS, I...
1
by: chads | last post by:
I was wondering if there is a current implementation or plan to implement the wait4 function (BSD style) into Python. If not, how do I go about requesting consideration for inclusion in the...
5
by: Heuguette Bostic | last post by:
I am attempting to compile Python 2-3.4 on Tru64 UNIX V4.0F. Whenever Iissue the make command, the following errors are output: -pthread -ieee -std -Olimit 1500 -DNDEBUG -O -I. -I./Include...
1
by: Jerald | last post by:
Running python 2.3.4 on valgrind (a tool like purify which checks the use of uninitialized memory, etc), gives a lot of errors. See below. jfj@cluster:~/> python -V Python 2.3.4...
5
by: mrstephengross | last post by:
Ok, I'm working on building python 2.4.2 on cygwin. I *think* it's version 3.0 or 3.1 (is there a quick way to find out what version of cygwin is running within a shell?) Anyway, it appears to...
1
by: mrstephengross | last post by:
I'm working on building python 2.4.2 with the mingw compiler (on cygwin). It runs into problems with Modules/posixmodule.c, because the mingw compiler does *not* provide complex process management...
66
by: Srijit Kumar Bhadra | last post by:
Is there any specific reason for not using MinGW to build the official distribution of Python for Win32? A quick Google search did not reveal the answer to my question. If a link is available,...
1
by: Justin Johnson | last post by:
Hello, I'm trying to build Python 2.5.0 on AIX 5.3 using IBM's compiler (VisualAge C++ Professional / C for AIX Compiler, Version 6). I run configure and make, but makes fails with undefined...
0
by: zhouyangpku | last post by:
Dear friends: I'm trying to install python on irix 6, the lab server. It fail at ' make ' procedure for Modules/posixmodule.c. I've just configured the prefix for my own path and no other option...
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: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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...

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.