Commit Graph

281 Commits

Author SHA1 Message Date
Jack Jansen 418c3b1e26 OSX tests used specific version numbers to test for new features and
used the default Darwin/* for the old code. Reversed those tests so
that compatibility code is in a switch leg with a specific version and
newer systems take the default leg.

This should allow Python to build on OSX 10.1.1 (which jumps from Darwin/1.4
to Darwin/5.1 due to a new numbering scheme).
2001-11-14 10:59:57 +00:00
Martin v. Löwis c010b6d9e0 Add sys/types.h and stdio.h into getaddrinfo test, based on itojun's message
in http://mail.python.org/pipermail/python-dev/2001-November/018473.html
2001-11-09 17:50:52 +00:00
Jack Jansen 666b1e7e2f Link the core with CoreServices, not with Carbon, and don't use any Carbon
routines. As of 10.1 using Carbon will crash Python if no window server is
available (ssh connection, console mode, MacOSX Server). This fixes bug
#466907.

A result of this mod is that the default 8bit encoding on OSX is now ASCII,
for the time being. Also, the extension modules that need the Carbon
framework now explicitly include it in setup.py.
2001-10-31 12:11:48 +00:00
Martin v. Löwis eb9b103296 Check for HP/UX curses problems. Define _XOPEN_SOURCE_EXTENDED and
STRICT_SYSV_CURSES when compiling curses module on HP/UX. Generalize
access to _flags on systems where WINDOW is opaque. Fixes bugs
#432497, #422265, and the curses parts of #467145 and #473150.
2001-10-24 17:10:49 +00:00
Martin v. Löwis 861a65bc2f Include netdb.h to detect getaddrinfo. Work around problem with getaddrinfo
not properly processing numeric IPv4 addresses. Fixes V5.1 part of #472675.
2001-10-24 14:36:00 +00:00
Neil Schemenauer af5567f734 install on HP-UX does not support the -d option. Using the install-sh instead.
This fixes SF bug: [ #473491 ] "install -d" doesn't work on HP-UX.
2001-10-21 22:32:04 +00:00
Guido van Rossum 67b2659046 Patch from SF bug #473150: configure weaknesses on HP-UX (Michael Piotrowski)
1. configure doesn't handle HP-UX release numbers
    (e.g., B.11.00), resulting in MACHDEP = "hpuxB".

    2. After checking for wchar.h, configure doesn't
    include it when checking the size of wchar_t.

    (Python 2.2b1 on HP-UX 11.00)
2001-10-20 14:21:45 +00:00
Guido van Rossum c524d952da SF patch #460805 by Chris Gonnerman: Support for unsetenv()
This adds unsetenv to posix, and uses it in the __delitem__ method of
os.environ.

(XXX Should we change the preferred name for putenv to setenv, for
consistency?)
2001-10-19 01:31:59 +00:00
Guido van Rossum 98bf58f1c6 SF patch #462296: Add attributes to os.stat results; by Nick Mathewson.
This is a big one, touching lots of files.  Some of the platforms
aren't tested yet.  Briefly, this changes the return value of the
os/posix functions stat(), fstat(), statvfs(), fstatvfs(), and the
time functions localtime(), gmtime(), and strptime() from tuples into
pseudo-sequences.  When accessed as a sequence, they behave exactly as
before.  But they also have attributes like st_mtime or tm_year.  The
stat return value, moreover, has a few platform-specific attributes
that are not available through the sequence interface (because
everybody expects the sequence to have a fixed length, these couldn't
be added there).  If your platform's struct stat doesn't define
st_blksize, st_blocks or st_rdev, they won't be accessible from Python
either.

(Still missing is a documentation update.)
2001-10-18 20:34:25 +00:00
Guido van Rossum a6535fd40b Shut up warnings for setgroups() on Linux -- you have to #include
<grp.h> it seems.  This requires yet another configure test.
2001-10-18 19:44:10 +00:00
Martin v. Löwis b7da67a873 Use CXX in LINKCC if CXX is used to build main() and the system requires
to link a C++ main using the C++ compiler. Fixes #472007.
2001-10-18 15:35:38 +00:00
Martin v. Löwis 61c5edf6fc Expose setgroups. Fixes feature request #468116. 2001-10-18 04:06:00 +00:00
Martin v. Löwis 69c0ff3836 Do not define _POSIX_THREADS if unistd.h defines it.
Check for pthread_sigmask before using it. Fixes remaining problem in #470781.
2001-10-15 14:34:42 +00:00
Martin v. Löwis a5f73f9bab Check whether pthreads are available without any options before checking
that -Kpthread is supported. Fixes #470781.
Port to autoconf 2.52.
2001-10-15 08:06:29 +00:00
Martin v. Löwis 6953233a35 Check for term.h and include it on non-ncurses system to get a declaration
for tigetstr.
2001-10-13 09:12:41 +00:00
Martin v. Löwis 8158b5ad09 Provide explicit program when trying to link pthread_create.
Contributed by Albert Chin in discussion of bug #210665.
2001-10-08 13:17:28 +00:00
Martin v. Löwis 25ae43b184 Support OpenUNIX like UnixWare. 2001-10-07 08:39:18 +00:00
Martin v. Löwis 260aecc83d Use AC_TRY_RUN for checking for -Kpthread. 2001-10-07 08:14:41 +00:00
Martin v. Löwis 244edc8985 Add chroot call. Implements feature #459267. 2001-10-04 22:44:26 +00:00
Martin v. Löwis 0daad598d0 Patch #462122: add readline startup and pre_event hooks. 2001-09-30 21:09:59 +00:00
Guido van Rossum ce608b02a6 Fix SF bug 419062: building pbs on AIX 4.3.2
Apply patch from "china@thewrittenword.com" to put the correct
location for ld_so_aix in BLDSHARED.
2001-09-28 15:59:38 +00:00
Guido van Rossum 3065c94f37 Add cross-compilation defaults to most AC_TRY_RUN values. The
supplied values are the most "normal" or "common" values found for
recent 32 bit machines.  This now seems to work to build Python 2.2
for the ARM processor used on the iPAQ.
2001-09-17 04:03:14 +00:00
Jack Jansen 127e56e5e8 When frameworks are not enabled don't put an empty target in the Makefile.
Older make's can apparently choke on this.
2001-09-11 14:41:54 +00:00
Martin v. Löwis 5b718fc8a3 Use $(CC) -G to link shared libraries on Solaris. 2001-09-10 15:34:42 +00:00
Guido van Rossum d0b69eceb4 Improve threading on Solaris, according to SF patch #460269, submitted
by bbrox@bbrox.org / lionel.ulmer@free.fr.

This adds a configure check and if all goes well turns on the
PTHREAD_SCOPE_SYSTEM thread attribute for new threads.

This should remove the need to add tiny sleeps at the start of threads
to allow other threads to be scheduled.
2001-09-10 14:10:54 +00:00
Guido van Rossum 810cc51d5f This time (I hope) I've fixed largefile
support on Linux (and Solaris, I expect) for real.
The necessary symbols are defined once and for all,
under the assumption that they won't harm elsewhere.
2001-09-09 23:51:39 +00:00
Jack Jansen a3891ea46c (Slightly modified) patch by Steve Spicklemire to make Python build
out of the box on OSX 10.1. Untested by me (except for not having adverse
effects on 10.0.4) but it looks good, for now. Eventually we should not
trigger on the darwin version but test for something, but until I have
the time to install 10.1 myself I have no clue what to test on.

It would be nice if this got in to the 2.2a3 distribution.
2001-09-07 14:25:12 +00:00
Guido van Rossum 98935bff0a SF bug #427073: DLINCLDIR defined incorrectly (Skip Montanaro).
I don't know what difference it makes, but '/' indeed makes less sense
as an include dir than '.', so I'm changing the default.  Just so I
can close the bug. ;-)
2001-09-05 19:13:16 +00:00
Guido van Rossum b855216099 Changes to automatically enable large file support on some systems.
I believe this works on Linux (tested both on a system with large file
support and one without it), and it may work on Solaris 2.7.

The changes are twofold:

(1) The configure script now boldly tries to set the two symbols that
    are recommended (for Solaris and Linux), and then tries a test
    script that does some simple seeking without writing.

(2) The _portable_{fseek,ftell} functions are a little more systematic
    in how they try the different large file support options: first
    try fseeko/ftello, but only if off_t is large; then try
    fseek64/ftell64; then try hacking with fgetpos/fsetpos.

I'm keeping my fingers crossed.  The meaning of the
HAVE_LARGEFILE_SUPPORT macro is not at all clear.

I'll see if I can get it to work on Windows as well.
2001-09-05 14:58:11 +00:00
Martin v. Löwis 36546db750 Patch #455231: Support ELF properly on OpenBSD. 2001-09-05 14:24:43 +00:00
Martin v. Löwis 703ad705c3 Use -fPIC instead of -fpic for gcc on HP/UX. Fixes bug #433234. 2001-09-05 08:36:52 +00:00
Martin v. Löwis a5f8bb57e0 Check for RFC 2553 API. Fixes bug #454493. 2001-09-05 08:22:34 +00:00
Neil Schemenauer 9c63e6d682 Always compile gcmodule. 2001-08-29 23:44:38 +00:00
Martin v. Löwis 339d0f720e Patch #445762: Support --disable-unicode
- Do not compile unicodeobject, unicodectype, and unicodedata if Unicode is disabled
- check for Py_USING_UNICODE in all places that use Unicode functions
- disables unicode literals, and the builtin functions
- add the types.StringTypes list
- remove Unicode literals from most tests.
2001-08-17 18:39:25 +00:00
Martin v. Löwis f95dd0a298 Fix portability problems with glibc 2.0, as reported in #449157. 2001-08-15 17:14:33 +00:00
Jack Jansen 591cbede56 MacOSX: if we're building without --enable-toolbox-glue don't attempt to
include _PyMac_Error. Also don't try to include __dummy: it needs Foundation
and I think (not 100% sure) that this isn't part of naked Darwin.
2001-08-15 13:55:15 +00:00
Jack Jansen b6e9cad34c Lots of changes in the framework support:
- Made framework builds work for MacOSX. The configure arg is now
  "--enable-framework".
- Added an install target frameworkinstall which installs the framework.
- Ripped out Next/OpenStep support, which was broken anyway.
- Made the MacOSX toolbox glue dependant on a --enable-toolbox-glue
  configure arg. This should make naked darwin build work again (untested).

A few targets have been added to Makefile.pre.in, and on inspection they
look harmless to non-MacOSX machines, but it is worth checking.

Closes bug #420601 and patch #450350.
2001-08-15 01:26:28 +00:00
Martin v. Löwis 1ba3fd5d51 Autotest for netpacket/packet.h, as it is not available on all Linux versions.
Depend AF_PACKET on HAVE_NETPACKET_PACKET_H. Fixes #449157
2001-08-10 20:29:40 +00:00
Martin v. Löwis 9b75dca192 Expose nl_langinfo through locale where available. 2001-08-10 13:58:50 +00:00
Martin v. Löwis a2ac60277c Move IPv6 test further down so that usage of -lnsl has been tested.
Recognize Solaris IPv6 by checking /etc/netconfig.
2001-08-09 11:40:14 +00:00
Martin v. Löwis 1d5ecb7cfa Patch #433537: Cache ac_cv_bad_static_forward.
Also move up AC_AIX and AC_MINIX further up.
2001-08-09 10:29:44 +00:00
Jack Jansen 9a66b6d470 Various fixes to streamline build process on Mac OS X:
- Give a warning if you're on a case-insensitive filesystem and have
  not specified --with-suffix.
- Don't require --with-dyld, it is now default for OSX/Darwin (suggested
  by Martin v. Loewis)
- Don't define _POSIX_THREADS on Darwin, it's done by standard headers already
  (fix by Tony Lownds)
- Don't use the Mac subtree anymore, the routines relevant to OSX/Darwin
  have moved to a new file Python/mactoolboxglue.c.
2001-08-08 13:56:14 +00:00
Thomas Wouters b0db85ac19 Remove redundant check for 'getaddrinfo' (it's already checked the block
before.)
2001-08-08 10:39:03 +00:00
Martin v. Löwis 864e9ffb14 Auto-detect hstrerror. Raise socket.herror in PyH_Error. Register the three
exception classes in the module dictionary.
2001-08-04 22:32:03 +00:00
Jack Jansen ca06bc6423 - On OSX add -no-cpp-precomp to OPT. The user still has to manually specify
the --with-suffix=.exe, but it seems that that is also true for cygwin
  (or not? should I automatically set it?)
- Got --with-next-framework to build on OSX. This is only the build bit,
  the install still has to be done manually. Moreover, the Python build order
  isn't really suited to frameworks (where you want to do 'build lib',
  'install lib and framework', 'link executable against installed framework'
  in that order).
2001-08-03 15:32:23 +00:00
Martin v. Löwis 4f1cd8bdcb Patch #411138: Rename config.h to pyconfig.h. Closes bug #231774. 2001-07-26 13:41:06 +00:00
Martin v. Löwis 784d3df09f Allow usage of gcc on OSF/1; this reverts rev 1.23 of configure.in,
and fixes bug #438786.
2001-07-25 07:30:35 +00:00
Martin v. Löwis 791bfda2b3 Autocheck for snprintf, and use sprintf if it is not available.
Remove declaration of h_errno, since it is supposedly declared in netdb.h.
Changes proposed by itojun.
2001-07-24 06:33:08 +00:00
Martin v. Löwis 9db2f571c3 Instead of accessing ss_family, cast sockaddr_storage to sockaddr and access sa_family. 2001-07-23 01:30:10 +00:00
Andrew M. Kuchling 5a3e4cb0a2 Patch #429442 from Jason Tishler: Corrects sys.platform and
distutils.util.get_platform() problems caused by the cruft contained
    in Cygwin's uname -s.
2001-07-20 19:29:04 +00:00