1
0
Fork 0
mirror of git://git.code.sf.net/p/cdesktopenv/code synced 2025-03-09 15:50:02 +00:00
cde/src/cmd/INIT
Martijn Dekker 0eb857041d libast: fix memccpy(3) feature test
If you passed CC=/some/compiler, the build broke on macOS because the
cc.darwin compiler wrapper wasn't used. Among other things, this
wrapper adds a -D_lib_memccpy flag, defining _lib_memccpy as 1
during the build. That was used to override a false negative result
of the lib_memccpy feature test. This commit fixes that feature
test instead, so it correctly returns positive on macOS.

Thanks to Ryan Smith (@ryandesign) for the bug report and for the
fix to the lib_memccpy test.

src/lib/libast/features/lib:
- Fix the lib_memccpy feature test. It was checking the result of
  mmap(2) incorrectly, resulting in the test crashing on macOS.
  Failure does not return NULL, it returns MAP_FAILED which is
  usually -1.

src/cmd/INIT/cc.darwin*:
- Removed. Any other flags in these wrappers are either related to
  building dynamic libraries, which is not currently supported, or
  were determined to be unnecessary. See the GitHub issue for
  discussion. This now makes it possible to pass `CC` to use any
  compiler you like on the Mac. Notes:
  - Apple's -D_ast_int8_t=int64_t is a no-op; another AST feature
    test already defines _ast_int8_t a 64-bit integer type, even on
    32-bit systems (on which it is defined as 'long long').
  - The -search_paths_first linker flag is the default since 2010.
    But even on my museum-grade Power Mac G5 with Mac OS X 10.3
    (from 2004), it builds and runs just fine without.
  - DCLK_TCK=100 is a no-op as even that ancient Mac system already
    defines it as 100. Plus, it's not even actually used.
  If a need is found for any of these, please report this in a new
  issue so I can special-case it elsewhere in the code.

Resolves: https://github.com/ksh93/ksh/issues/373
2021-12-12 03:12:15 +01:00
..
ar.freebsd12.amd64 patches to build on freebsd 12 2020-02-24 12:58:22 -05:00
ar.ibm.risc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ar.linux.i386-64 patches to build on freebsd 12 2020-02-24 12:58:22 -05:00
C+probe Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.freebsd Build system: make SHOPT_* editable again; allow indenting Mamfiles 2021-01-22 23:39:59 +00:00
cc.hp.ia64 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.hp.pa Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.hp.pa64 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.ibm.risc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.ibm.risc.gcc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.linux INIT: add generic cc.linux wrapper 2021-04-08 04:00:09 +01:00
cc.linux.aarch64 added missed 'cc' and 'ar' scripts 2020-02-12 13:12:45 -05:00
cc.linux.i386-64 added missed 'cc' and 'ar' scripts 2020-02-12 13:12:45 -05:00
cc.linux.i386-64-icc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.linux.i386-icc Build fix for Linux i386 2021-01-31 23:47:43 +00:00
cc.linux.ia64-icc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.lynxos.i386 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.lynxos.ppc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.mvs.390 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.next.i386 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.next.m68k Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.openbsd Build system: make SHOPT_* editable again; allow indenting Mamfiles 2021-01-22 23:39:59 +00:00
cc.osf.alpha Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.pentium4 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sco.i386 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sgi.mips2 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sgi.mips3 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sgi.mips3-o32 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sgi.mips4 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sgi.mips4-n32 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.sol11.i386 Restore Solaris build after introducing 'noreturn' (re: c4f980eb) 2021-05-12 07:32:35 +02:00
cc.sol11.i386-64 Restore Solaris build after introducing 'noreturn' (re: c4f980eb) 2021-05-12 07:32:35 +02:00
cc.sol11.sparc Restore Solaris build after introducing 'noreturn' (re: c4f980eb) 2021-05-12 07:32:35 +02:00
cc.sol11.sparc-64 Restore Solaris build after introducing 'noreturn' (re: c4f980eb) 2021-05-12 07:32:35 +02:00
cc.specialize Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.unix.mc68k Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
cc.unixware.i386 typeset: Fix stack fencepost error, ISO C90 compat (#159) 2021-01-21 07:50:07 +00:00
crossexec.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
db.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
ditto.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
dl.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
execrate.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
filter.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
gdbm.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
gdbm1.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
gdbm2.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
hello.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
hosttype.tst Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
hurl.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
iconv.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
iffe.sh iffe: include OS standards macros in iffe tests by default 2021-12-07 05:25:06 +01:00
iffe.tst Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ignore.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
intl.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
ld.hp.pa Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.cygwin.i386 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.darwin Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.hp.pa Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.ibm.risc Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.lynxos Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.mvs.390 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
ldd.sgi Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
m.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
m2.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
m3.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
m4.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
m5.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
m6.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
make.probe make.probe: probe_optimize: remove -O2 2021-01-19 22:13:59 +00:00
mamake.c Update #pragmas to make clang be quiet about historic practice 2021-05-07 06:36:14 +01:00
mamake.rt Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
mamake.tst Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
Mamfile build system: do not look for nmake in $PATH 2021-05-11 01:56:22 +02:00
mamprobe.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
mkdir.sh tweak for compat with broken /bin/sh on AIX ibm.risc 2021-01-19 22:38:27 +00:00
mktest.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
mprobe.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
nsl.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
p.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
package.sh package: fix Bourne compat (re: 48e6dd98) 2021-11-17 06:09:35 +01:00
probe.win32 Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
proto.c Update #pragmas to make clang be quiet about historic practice 2021-05-07 06:36:14 +01:00
ratz.c Fix various compiler warnings and minor issues (#362) 2021-12-09 06:42:59 +01:00
regress.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
RELEASE Fix more compiler warnings, typos and other minor issues (#260) 2021-04-08 19:58:07 +01:00
release.c Update #pragmas to make clang be quiet about historic practice 2021-05-07 06:36:14 +01:00
rt.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
silent.sh Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
socket.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
w.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00
w2.c Add ksh 93u+m contributors notice to 964 copyright headers 2021-04-26 00:19:31 +01:00