Skip to content

Commit

Permalink
Merge with upstream/dev
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnoKing committed Feb 23, 2024
2 parents ff34ceb + 9a6050c commit bf06132
Show file tree
Hide file tree
Showing 25 changed files with 7,680 additions and 7,069 deletions.
10 changes: 9 additions & 1 deletion NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,18 @@ This documents significant changes in the dev branch of ksh 93u+m.
For full details, see the git log at: https://github.com/ksh93/ksh
Uppercase BUG_* IDs are shell bug IDs as used by the Modernish shell library.

2024-02-16:
2024-02-22:

- Fixed a crash that occurred when starting ksh with no TERM variable in the
environment (e.g., in single user mode on NetBSD and DragonFlyBSD).

- Fixed two integer overflows that could occur when using TMOUT.

2024-02-17:

- Fixed a crash that could occur when using 'typeset -T' typed variables
in a virtual subshell.

2024-02-11:

- Added SHOPT_PRINTF_LEGACY compile-time option for compatibility with
Expand Down
8 changes: 4 additions & 4 deletions bin/package
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ command=${0##*/}
case $(getopts '[-][123:xyz]' opt --xyz 2>/dev/null; echo 0$opt) in
0123) USAGE=$'
[-?
@(#)$Id: '$command$' (ksh 93u+m) 2024-02-12 $
@(#)$Id: '$command$' (ksh 93u+m) 2024-02-17 $
]
[-author?Glenn Fowler <[email protected]>]
[-author?Contributors to https://github.com/ksh93/ksh]
Expand Down Expand Up @@ -360,7 +360,7 @@ ifs=${IFS-'
'}
lo=
make=
makeflags='-K'
makeflags=''
nl="
"
noexec=
Expand Down Expand Up @@ -579,7 +579,7 @@ SEE ALSO
pkgadd(1), pkgmk(1), rpm(1), sh(1), tar(1), optget(3)

IMPLEMENTATION
version package (ksh 93u+m) 2024-02-12
version package (ksh 93u+m) 2024-02-17
author Glenn Fowler <[email protected]>
author Contributors to https://github.com/ksh93/ksh
copyright (c) 1994-2012 AT&T Intellectual Property
Expand Down Expand Up @@ -692,7 +692,7 @@ do case $i in
VPATH=*)eval USER_$n='$'v
;;
'debug=1')
makeflags="$makeflags --debug-symbols"
makeflags="$makeflags --debug-symbols -e"
;;
'strip=1')
makeflags="$makeflags --strip-symbols"
Expand Down
12 changes: 5 additions & 7 deletions src/Mamfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
note *
note * This build file is in the Make Abstract Machine (MAM) language. It was
note * first generated by nmake, but in the ksh 93u+m distribution we maintain
note * it manually because nmake had too many problems to keep using. The
note * Mamfiles are processed by mamake (src/cmd/INIT/mamake.c); we added
note * indentation to improve readability. The language is documented in
note * src/cmd/INIT/README-mamake.md.
note * This build script is in an extended Make Abstract Machine (MAM)
note * language. Documentation is at: src/cmd/INIT/README-mamake.md
note *
setv MAMAKE_STRICT

setv MAMAKE_STRICT 2

make test virtual
make test_announce virtual
exec - : testing KornShell $KSH_VERSION :
Expand Down
149 changes: 42 additions & 107 deletions src/cmd/INIT/Mamfile
Original file line number Diff line number Diff line change
@@ -1,98 +1,48 @@
note *
note * This build file is in the Make Abstract Machine (MAM) language. It was
note * first generated by nmake, but in the ksh 93u+m distribution we maintain
note * it manually because nmake had too many problems to keep using. The
note * Mamfiles are processed by mamake (src/cmd/INIT/mamake.c); we added
note * indentation to improve readability. The language is documented in
note * src/cmd/INIT/README-mamake.md.
note * This build script is in an extended Make Abstract Machine (MAM)
note * language. Documentation is at: src/cmd/INIT/README-mamake.md
note *
setv MAMAKE_STRICT

setv MAMAKE_STRICT 2
setv INSTALLROOT ../../..
setv PACKAGEROOT ../../../../..
setv CC cc
setv mam_cc_FLAGS
setv CCFLAGS ${-debug-symbols?1?${mam_cc_DEBUG} -D_BLD_DEBUG?${mam_cc_OPTIMIZE}?}
setv CCLDFLAGS ${-strip-symbols?1?${mam_cc_LD_STRIP}??}
setv LDFLAGS

note *
note * initialization for the build system
note *

make install virtual
make iffe
prev iffe.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make mktest
prev mktest.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make regress
prev regress.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make crossexec
prev crossexec.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make mkreq
prev mkreq.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make mkreq-maplib
prev mkreq-maplib.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make mprobe
prev mprobe.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make probe
make probe.sh
prev C+probe
prev make.probe
exec - cat ${^} > ${@}
loop DIR bin include/ast lib/lib lib/probe/C/make lib/probe/C/pp lib/probe/C/mam
make ${INSTALLROOT}/${DIR}
exec - mkdir -p ${@}
done
exec - cp ${<} ${@} && chmod u+w,+x ${@}
done
make ${INSTALLROOT}/bin
exec - mkdir -p ${@}
done
make ${INSTALLROOT}/bin/iffe
prev iffe
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/bin/mkreq
prev mkreq
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/bin/mktest
prev mktest
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/bin/regress
prev regress
exec - cp -f ${<} ${@}
done
make ${PACKAGEROOT}/bin
exec - mkdir -p ${PACKAGEROOT}/bin
done
make ${INSTALLROOT}/bin/crossexec
prev crossexec
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/bin/proto
note *
note * proto(1) has been removed, but install a backward compatibility stub
note * that allows old Mamfiles containing proto commands to keep working.
note *
prev proto.sh
exec - cp ${<} ${@} && chmod u+w,+x ${@}

note *
note * install helper scripts
note *

make probe.sh
prev C+probe
prev make.probe
exec - cat ${^} > ${@}
done
loop SCRIPT probe iffe mktest regress crossexec mkreq mkreq-maplib mprobe proto
make ${INSTALLROOT}/bin/${SCRIPT}
make ${SCRIPT}
prev ${@}.sh
exec - cp ${<} ${@} && ${STDCHMOD} u+w,+x ${@}
done
exec - cp -f ${<} ${@}
done
done

note *
note * ksh93 function search on PATH
note * ksh93 builtin command library -lcmd
note * ksh93 ld library path search on PATH
note *

make ${INSTALLROOT}/bin/.paths
exec - if test ! -f ${INSTALLROOT}/bin/.paths -o -w ${INSTALLROOT}/bin/.paths
exec - then N='
Expand Down Expand Up @@ -225,25 +175,15 @@ make install virtual
exec - esac
exec - fi
done

note *
note * probe initialization
note *
make ${INSTALLROOT}/lib/probe/C
exec - mkdir -p ${@}
done

make ${INSTALLROOT}/lib/probe/C/probe
prev C+probe
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/lib/probe/C/make
exec - mkdir -p ${@}
done
make ${INSTALLROOT}/lib/probe/C/pp
exec - mkdir -p ${@}
done
make ${INSTALLROOT}/lib/probe/C/mam
exec - mkdir -p ${@}
done
make ${INSTALLROOT}/lib/probe/C/mam/probe
prev mprobe
exec - cp -f ${<} ${@}
Expand All @@ -256,12 +196,6 @@ make install virtual
prev probe
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/include/ast
exec - mkdir -p ${@}
done
make ${INSTALLROOT}/lib/lib
exec - mkdir -p ${@}
done
note *
note * check if -ldl is required
note *
Expand All @@ -274,8 +208,8 @@ make install virtual
make ${INSTALLROOT}/lib/lib/dl
make dl.req
prev dl.c
exec - mkreq-maplib ${CC} : dl : ${^} : dl
prev mkreq-maplib
exec - mkreq-maplib ${CC} : dl : dl.c : dl
done
exec - cp -f ${<} ${@}
done
Expand All @@ -285,17 +219,17 @@ make install virtual
make ${INSTALLROOT}/lib/lib/iconv
make iconv.req
prev iconv.c
exec - mkreq-maplib ${CC} : iconv : ${^} : iconv
prev mkreq-maplib
exec - mkreq-maplib ${CC} : iconv : iconv.c : iconv
done
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/lib/lib/w
make w.req
prev w.c
prev w2.c
exec - mkreq-maplib ${CC} : w : ${^} : w
prev mkreq-maplib
exec - mkreq-maplib ${CC} : w : w.c w2.c : w
done
exec - cp -f ${<} ${@}
done
Expand All @@ -305,8 +239,8 @@ make install virtual
make ${INSTALLROOT}/lib/lib/intl
make intl.req
prev intl.c
exec - mkreq-maplib ${CC} : intl : ${^} : intl
prev mkreq-maplib
exec - mkreq-maplib ${CC} : intl : intl.c : intl
done
exec - cp -f ${<} ${@}
done
Expand All @@ -318,16 +252,16 @@ make install virtual
prev m4.c
prev m5.c
prev m6.c
exec - mkreq-maplib ${CC} : m : ${^} : m
prev mkreq-maplib
exec - mkreq-maplib ${CC} : m : m.c m2.c m3.c m4.c m5.c m6.c : m
done
exec - cp -f ${<} ${@}
done
make ${INSTALLROOT}/lib/lib/nsl
make nsl.req
prev nsl.c
exec - mkreq-maplib ${CC} : nsl : ${^} : nsl
prev mkreq-maplib
exec - mkreq-maplib ${CC} : nsl : nsl.c : nsl
done
exec - cp -f ${<} ${@}
done
Expand All @@ -341,8 +275,8 @@ make install virtual
make socket.req
prev socket.c
prev nsl.c
exec - mkreq-maplib ${CC} : socket : ${^} : socket
prev mkreq-maplib
exec - mkreq-maplib ${CC} : socket : socket.c nsl.c : socket
done
exec - cp -f ${<} ${@}
done
Expand All @@ -364,20 +298,21 @@ make install virtual
prev gdbm.c
prev gdbm1.c
prev gdbm2.c
exec - mkreq-maplib ${CC} : dbm : ${^} : db gdbm_compat gdbm ndbm dbm
prev mkreq-maplib
exec - mkreq-maplib ${CC} : dbm : db.c gdbm.c gdbm1.c gdbm2.c : db gdbm_compat gdbm ndbm dbm
done
exec - cp -f ${<} ${@}
done
done install

make test dontcare virtual
make test.iffe virtual
prev iffe.tst
exec - regress ${<} iffe
exec - regress iffe.tst iffe
done
make test.mamake virtual
prev mamake.tst
exec - : testing non-libast mamake at $PWD/mamake :
exec - regress ${<} mamake
exec - regress mamake.tst mamake
done
done test
Loading

0 comments on commit bf06132

Please sign in to comment.