Skip to content

Commit ca824a9

Browse files
authored
gh-157949: Remove dead UnixWare, OpenServer and ReliantUNIX support code (#157950)
1 parent 3c1848d commit ca824a9

9 files changed

Lines changed: 9 additions & 147 deletions

File tree

‎Lib/test/test_fcntl.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def get_lockdata():
7373
fcntl.F_WRLCK, 0)
7474
elif sys.platform.startswith('gnukfreebsd'):
7575
lockdata = struct.pack('qqihhi', 0, 0, 0, fcntl.F_WRLCK, 0, 0)
76-
elif sys.platform in ['hp-uxB', 'unixware7']:
76+
elif sys.platform == 'hp-uxB':
7777
lockdata = struct.pack('hhlllii', fcntl.F_WRLCK, 0, 0, 0, 0, 0, 0)
7878
else:
7979
lockdata = struct.pack('hh'+start_len+'hh', fcntl.F_WRLCK, 0, 0, 0, 0, 0)
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Remove dead build and preprocessor code for SCO UnixWare, OpenUNIX, SCO
2+
OpenServer and ReliantUNIX.

‎Modules/_cursesmodule.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ static const char PyCursesVersion[] = "2.2";
120120
#include <langinfo.h>
121121
#endif
122122

123-
#if !defined(NCURSES_VERSION) && (defined(__sun) || defined(SCO5))
123+
#if !defined(NCURSES_VERSION) && defined(__sun)
124124
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
125125
typedef chtype attr_t; /* No attr_t type is available */
126126
#endif

‎Modules/posixmodule.c‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14146,11 +14146,6 @@ os_WSTOPSIG_impl(PyObject *module, int status)
1414614146

1414714147

1414814148
#if defined(HAVE_FSTATVFS) && defined(HAVE_SYS_STATVFS_H)
14149-
#ifdef _SCO_DS
14150-
/* SCO OpenServer 5.0 and later requires _SVID3 before it reveals the
14151-
needed definitions in sys/statvfs.h */
14152-
#define _SVID3
14153-
#endif
1415414149
#include <sys/statvfs.h>
1415514150

1415614151
#ifdef __APPLE__

‎PC/pyconfig.h‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -506,8 +506,7 @@ Py_NO_ENABLE_SHARED to find out. Also support MS_NO_COREDLL for b/w compat */
506506
/* Define if you have the putenv function. */
507507
#define HAVE_PUTENV
508508

509-
/* Define if you can safely include both <sys/select.h> and <sys/time.h>
510-
(which you can't on SCO ODT 3.0). */
509+
/* Define if you can safely include both <sys/select.h> and <sys/time.h> */
511510
/* #undef SYS_SELECT_WITH_SYS_TIME */
512511

513512
/* Define if you want build the _decimal module using a coroutine-local rather

‎Tools/build/check_capi_macros_ignored.txt‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -717,7 +717,6 @@ SSTATE_INTERNED_IMMORTAL_STATIC
717717
SSTATE_INTERNED_MORTAL
718718
SSTATE_NOT_INTERNED
719719
STDC_HEADERS
720-
STRICT_SYSV_CURSES
721720
SYS_SELECT_WITH_SYS_TIME
722721
S_IFLNK
723722
S_IFMT

‎configure‎

Lines changed: 1 addition & 63 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎configure.ac‎

Lines changed: 2 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -238,11 +238,6 @@ AH_TOP([
238238
#define Py_PYCONFIG_H
239239
])
240240
AH_BOTTOM([
241-
/* Define the macros needed if on a UnixWare 7.x system. */
242-
#if defined(__USLC__) && defined(__SCO_VERSION__)
243-
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
244-
#endif
245-
246241
#endif /*Py_PYCONFIG_H*/
247242
])
248243

@@ -377,8 +372,7 @@ then
377372
ac_sys_release=
378373
else
379374
ac_sys_system=`uname -s`
380-
if test "$ac_sys_system" = "AIX" \
381-
-o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
375+
if test "$ac_sys_system" = "AIX"; then
382376
ac_sys_release=`uname -v`
383377
else
384378
ac_sys_release=`uname -r`
@@ -1019,15 +1013,6 @@ case $ac_sys_system/$ac_sys_release in
10191013
# A lower level is defined below.
10201014
SunOS/*)
10211015
define_xopen_source=no;;
1022-
# On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
1023-
# but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
1024-
# Reconfirmed for 7.1.4 by Martin v. Loewis.
1025-
OpenUNIX/8.0.0| UnixWare/7.1.@<:@0-4@:>@)
1026-
define_xopen_source=no;;
1027-
# On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
1028-
# but used in struct sockaddr.sa_family. Reported by Tim Rice.
1029-
SCO_SV/3.2)
1030-
define_xopen_source=no;;
10311016
# On MacOS X 10.2, a bug in ncurses.h means that it craps out if
10321017
# _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which
10331018
# identifies itself as Darwin/7.*
@@ -2622,11 +2607,6 @@ then
26222607
OPT="-O3 -Wall"
26232608
;;
26242609
esac
2625-
2626-
case $ac_sys_system in
2627-
SCO_SV*) OPT="$OPT -m486 -DSCO5"
2628-
;;
2629-
esac
26302610
;;
26312611

26322612
*)
@@ -2994,10 +2974,6 @@ AS_VAR_IF([ac_cv_gcc_compat], [yes], [
29942974
esac
29952975
29962976
case $ac_sys_system in
2997-
SCO_SV*)
2998-
BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
2999-
;;
3000-
30012977
Darwin*)
30022978
# -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
30032979
# used to be here, but non-Apple gcc doesn't accept them.
@@ -3151,15 +3127,6 @@ AS_VAR_IF([ac_cv_gcc_compat], [yes], [
31513127
# end of Darwin* tests
31523128
;;
31533129
esac
3154-
], [
3155-
case $ac_sys_system in
3156-
OpenUNIX*|UnixWare*)
3157-
BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
3158-
;;
3159-
SCO_SV*)
3160-
BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
3161-
;;
3162-
esac
31633130
])
31643131

31653132
# Check for --enable-experimental-jit:
@@ -3542,13 +3509,6 @@ AC_DEFINE([_FILE_OFFSET_BITS], [64],
35423509
[This must be set to 64 on some systems to enable large file support.])
35433510
fi
35443511

3545-
# Add some code to confdefs.h so that the test for off_t works on SCO
3546-
cat >> confdefs.h <<\EOF
3547-
#if defined(SCO_DS)
3548-
#undef _OFF_T
3549-
#endif
3550-
EOF
3551-
35523512
# Type availability checks
35533513
AC_TYPE_MODE_T
35543514
AC_TYPE_OFF_T
@@ -3967,17 +3927,6 @@ then
39673927
NetBSD*|DragonFly*)
39683928
LDSHARED='$(CC) -shared'
39693929
LDCXXSHARED='$(CXX) -shared';;
3970-
OpenUNIX*|UnixWare*)
3971-
if test "$ac_cv_gcc_compat" = "yes" ; then
3972-
LDSHARED='$(CC) -shared'
3973-
LDCXXSHARED='$(CXX) -shared'
3974-
else
3975-
LDSHARED='$(CC) -G'
3976-
LDCXXSHARED='$(CXX) -G'
3977-
fi;;
3978-
SCO_SV*)
3979-
LDSHARED='$(CC) -Wl,-G,-Bexport'
3980-
LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';;
39813930
WASI*)
39823931
AS_VAR_IF([enable_wasm_dynamic_linking], [yes], [
39833932
dnl not implemented yet
@@ -4025,16 +3974,6 @@ then
40253974
]);;
40263975
FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
40273976
Haiku*) CCSHARED="-fPIC";;
4028-
OpenUNIX*|UnixWare*)
4029-
if test "$ac_cv_gcc_compat" = "yes"
4030-
then CCSHARED="-fPIC"
4031-
else CCSHARED="-KPIC"
4032-
fi;;
4033-
SCO_SV*)
4034-
if test "$ac_cv_gcc_compat" = "yes"
4035-
then CCSHARED="-fPIC"
4036-
else CCSHARED="-Kpic -belf"
4037-
fi;;
40383977
VxWorks*)
40393978
CCSHARED="-fpic -D__SO_PICABILINUX__ -ftls-model=global-dynamic"
40403979
esac
@@ -4085,9 +4024,6 @@ then
40854024
fi
40864025
fi
40874026
;;
4088-
OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
4089-
SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
4090-
ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
40914027
FreeBSD*|NetBSD*|OpenBSD*|DragonFly*)
40924028
if [[ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]]
40934029
then
@@ -6364,8 +6300,7 @@ AS_VAR_IF([ac_cv_device_macros], [yes], [
63646300

63656301
dnl no longer used, now always defined for backwards compatibility
63666302
AC_DEFINE([SYS_SELECT_WITH_SYS_TIME], [1],
6367-
[Define if you can safely include both <sys/select.h> and <sys/time.h>
6368-
(which you can't on SCO ODT 3.0).])
6303+
[Define if you can safely include both <sys/select.h> and <sys/time.h>])
63696304

63706305
# On OSF/1 V5.1, getaddrinfo is available, but a define
63716306
# for [no]getaddrinfo in netdb.h.

‎pyconfig.h.in‎

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1922,8 +1922,7 @@
19221922
/* Define to 1 if you have the ANSI C header files. */
19231923
#undef STDC_HEADERS
19241924

1925-
/* Define if you can safely include both <sys/select.h> and <sys/time.h>
1926-
(which you can't on SCO ODT 3.0). */
1925+
/* Define if you can safely include both <sys/select.h> and <sys/time.h> */
19271926
#undef SYS_SELECT_WITH_SYS_TIME
19281927

19291928
/* Custom thread stack size depending on chosen sanitizer runtimes. */
@@ -2233,10 +2232,5 @@
22332232
#undef uid_t
22342233

22352234

2236-
/* Define the macros needed if on a UnixWare 7.x system. */
2237-
#if defined(__USLC__) && defined(__SCO_VERSION__)
2238-
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
2239-
#endif
2240-
22412235
#endif /*Py_PYCONFIG_H*/
22422236

0 commit comments

Comments
 (0)