From 0069a6e084d9843ec1f0c7ddb87e8b3bd7009477 Mon Sep 17 00:00:00 2001 From: Chase Date: Wed, 22 Jul 2020 20:32:47 -0500 Subject: [PATCH 01/43] dtksh: remove old ksh from repo --- cde/programs/dtksh/ksh93/Imakefile | 73 - cde/programs/dtksh/ksh93/ship/README | 154 - .../dtksh/ksh93/ship/ksh93/930519/UNCRATED | 0 .../dtksh/ksh93/ship/ksh93/930519/base | 0 .../dtksh/ksh93/ship/ksh93/930519/copyright | 5 - .../dtksh/ksh93/ship/ksh93/930519/items | 1 - .../dtksh/ksh93/ship/ksh93/930519/owner | 1 - .../dtksh/ksh93/ship/ksh93/950619/UNCRATED | 0 .../dtksh/ksh93/ship/ksh93/950619/base | 0 .../dtksh/ksh93/ship/ksh93/950619/copyright | 5 - .../dtksh/ksh93/ship/ksh93/950619/items | 1 - .../dtksh/ksh93/ship/ksh93/950619/owner | 1 - .../dtksh/ksh93/ship/ksh93/950807/UNCRATED | 0 .../dtksh/ksh93/ship/ksh93/950807/base | 0 .../dtksh/ksh93/ship/ksh93/950807/copyright | 5 - .../dtksh/ksh93/ship/ksh93/950807/items | 1 - .../dtksh/ksh93/ship/ksh93/950807/message | 32 - .../dtksh/ksh93/ship/ksh93/950807/owner | 1 - .../dtksh/ksh93/ship/ksh93/950807/promo | 146 - .../dtksh/ksh93/ship/ksh93/950807/report | 5 - .../dtksh/ksh93/ship/lib0ast/950509/UNCRATED | 0 .../dtksh/ksh93/ship/lib0ast/950509/base | 0 .../dtksh/ksh93/ship/lib0ast/950509/copyright | 5 - .../dtksh/ksh93/ship/lib0ast/950509/items | 0 .../dtksh/ksh93/ship/lib0ast/950509/owner | 0 .../dtksh/ksh93/ship/lib0ast/950811/UNCRATED | 0 .../dtksh/ksh93/ship/lib0ast/950811/base | 0 .../dtksh/ksh93/ship/lib0ast/950811/copyright | 6 - .../dtksh/ksh93/ship/lib0ast/950811/items | 0 .../dtksh/ksh93/ship/lib0ast/950811/owner | 1 - .../dtksh/ksh93/ship/libAST/930519/UNCRATED | 0 .../dtksh/ksh93/ship/libAST/930519/base | 0 .../dtksh/ksh93/ship/libAST/930519/copyright | 5 - .../dtksh/ksh93/ship/libAST/930519/items | 0 .../dtksh/ksh93/ship/libAST/930519/owner | 1 - .../dtksh/ksh93/ship/libast/930716/UNCRATED | 0 .../dtksh/ksh93/ship/libast/930716/base | 0 .../dtksh/ksh93/ship/libast/930716/copyright | 5 - .../dtksh/ksh93/ship/libast/930716/items | 1 - .../dtksh/ksh93/ship/libast/930716/owner | 1 - .../dtksh/ksh93/ship/libast/950620/UNCRATED | 0 .../dtksh/ksh93/ship/libast/950620/base | 0 .../dtksh/ksh93/ship/libast/950620/copyright | 5 - .../dtksh/ksh93/ship/libast/950620/items | 1 - .../dtksh/ksh93/ship/libast/950620/owner | 1 - .../dtksh/ksh93/ship/libast/950811/UNCRATED | 0 .../dtksh/ksh93/ship/libast/950811/base | 0 .../dtksh/ksh93/ship/libast/950811/copyright | 6 - .../dtksh/ksh93/ship/libast/950811/items | 1 - .../dtksh/ksh93/ship/libast/950811/owner | 1 - .../dtksh/ksh93/ship/libcmd/930527/UNCRATED | 0 .../dtksh/ksh93/ship/libcmd/930527/base | 0 .../dtksh/ksh93/ship/libcmd/930527/copyright | 5 - .../dtksh/ksh93/ship/libcmd/930527/items | 1 - .../dtksh/ksh93/ship/libcmd/930527/owner | 1 - .../dtksh/ksh93/ship/libcmd/950620/UNCRATED | 0 .../dtksh/ksh93/ship/libcmd/950620/base | 0 .../dtksh/ksh93/ship/libcmd/950620/copyright | 5 - .../dtksh/ksh93/ship/libcmd/950620/items | 1 - .../dtksh/ksh93/ship/libcmd/950620/owner | 1 - .../dtksh/ksh93/ship/libcmd/950811/UNCRATED | 0 .../dtksh/ksh93/ship/libcmd/950811/base | 0 .../dtksh/ksh93/ship/libcmd/950811/copyright | 6 - .../dtksh/ksh93/ship/libcmd/950811/items | 1 - .../dtksh/ksh93/ship/libcmd/950811/owner | 1 - .../ksh93/ship/libodelta/930125/UNCRATED | 0 .../dtksh/ksh93/ship/libodelta/930125/base | 0 .../ksh93/ship/libodelta/930125/copyright | 5 - .../dtksh/ksh93/ship/libodelta/930125/items | 1 - .../dtksh/ksh93/ship/libodelta/930125/owner | 1 - .../ksh93/ship/libodelta/950509/UNCRATED | 0 .../dtksh/ksh93/ship/libodelta/950509/base | 0 .../ksh93/ship/libodelta/950509/copyright | 5 - .../dtksh/ksh93/ship/libodelta/950509/items | 1 - .../dtksh/ksh93/ship/libodelta/950509/owner | 1 - .../ksh93/ship/libodelta/950811/UNCRATED | 0 .../dtksh/ksh93/ship/libodelta/950811/base | 0 .../ksh93/ship/libodelta/950811/copyright | 6 - .../dtksh/ksh93/ship/libodelta/950811/items | 1 - .../dtksh/ksh93/ship/libodelta/950811/owner | 1 - .../ksh93/ship/libvdelta/950509/UNCRATED | 0 .../dtksh/ksh93/ship/libvdelta/950509/base | 0 .../ksh93/ship/libvdelta/950509/copyright | 0 .../dtksh/ksh93/ship/libvdelta/950509/items | 1 - .../dtksh/ksh93/ship/libvdelta/950509/owner | 0 .../ksh93/ship/libvdelta/950811/UNCRATED | 0 .../dtksh/ksh93/ship/libvdelta/950811/base | 0 .../ksh93/ship/libvdelta/950811/copyright | 6 - .../dtksh/ksh93/ship/libvdelta/950811/items | 1 - .../dtksh/ksh93/ship/libvdelta/950811/owner | 1 - .../dtksh/ksh93/ship/pax/930716/UNCRATED | 0 cde/programs/dtksh/ksh93/ship/pax/930716/base | 0 .../dtksh/ksh93/ship/pax/930716/copyright | 5 - .../dtksh/ksh93/ship/pax/930716/items | 1 - .../dtksh/ksh93/ship/pax/930716/owner | 1 - .../dtksh/ksh93/ship/pax/950620/UNCRATED | 0 cde/programs/dtksh/ksh93/ship/pax/950620/base | 0 .../dtksh/ksh93/ship/pax/950620/copyright | 5 - .../dtksh/ksh93/ship/pax/950620/items | 1 - .../dtksh/ksh93/ship/pax/950620/owner | 1 - .../dtksh/ksh93/ship/pax/950811/UNCRATED | 0 cde/programs/dtksh/ksh93/ship/pax/950811/base | 0 .../dtksh/ksh93/ship/pax/950811/copyright | 6 - .../dtksh/ksh93/ship/pax/950811/items | 1 - .../dtksh/ksh93/ship/pax/950811/owner | 1 - .../dtksh/ksh93/ship/pax/950811/promo | 48 - cde/programs/dtksh/ksh93/ship/shipfeature.sh | 1131 --- cde/programs/dtksh/ksh93/ship/shipiffe.sh | 1419 ---- cde/programs/dtksh/ksh93/ship/shipin | 1787 ----- cde/programs/dtksh/ksh93/ship/shipop.c | 280 - cde/programs/dtksh/ksh93/ship/shipout | 1908 ----- cde/programs/dtksh/ksh93/ship/shipproto.c | 5024 ------------- cde/programs/dtksh/ksh93/src/Makefile | 2 - cde/programs/dtksh/ksh93/src/cmd/Makefile | 2 - .../dtksh/ksh93/src/cmd/ksh93/COMPATIBILITY | 95 - .../dtksh/ksh93/src/cmd/ksh93/Makefile | 85 - .../dtksh/ksh93/src/cmd/ksh93/Mamfile | 1113 --- .../dtksh/ksh93/src/cmd/ksh93/OBSOLETE | 152 - .../dtksh/ksh93/src/cmd/ksh93/OPTIONS | 19 - cde/programs/dtksh/ksh93/src/cmd/ksh93/PROMO | 147 - cde/programs/dtksh/ksh93/src/cmd/ksh93/README | 178 - .../dtksh/ksh93/src/cmd/ksh93/RELEASE | 422 -- .../dtksh/ksh93/src/cmd/ksh93/RELEASEa | 214 - .../dtksh/ksh93/src/cmd/ksh93/bltins/alarm.c | 333 - .../dtksh/ksh93/src/cmd/ksh93/bltins/cd_pwd.c | 277 - .../dtksh/ksh93/src/cmd/ksh93/bltins/cflow.c | 169 - .../ksh93/src/cmd/ksh93/bltins/getconf.c | 197 - .../ksh93/src/cmd/ksh93/bltins/getopts.c | 200 - .../dtksh/ksh93/src/cmd/ksh93/bltins/hist.c | 324 - .../dtksh/ksh93/src/cmd/ksh93/bltins/misc.c | 561 -- .../dtksh/ksh93/src/cmd/ksh93/bltins/print.c | 630 -- .../dtksh/ksh93/src/cmd/ksh93/bltins/read.c | 488 -- .../dtksh/ksh93/src/cmd/ksh93/bltins/sleep.c | 234 - .../dtksh/ksh93/src/cmd/ksh93/bltins/test.c | 601 -- .../dtksh/ksh93/src/cmd/ksh93/bltins/trap.c | 391 - .../ksh93/src/cmd/ksh93/bltins/typeset.c | 1158 --- .../dtksh/ksh93/src/cmd/ksh93/bltins/ulimit.c | 263 - .../dtksh/ksh93/src/cmd/ksh93/bltins/umask.c | 159 - .../dtksh/ksh93/src/cmd/ksh93/bltins/whence.c | 303 - .../dtksh/ksh93/src/cmd/ksh93/builtins.mm | 625 -- .../dtksh/ksh93/src/cmd/ksh93/data/aliases.c | 131 - .../dtksh/ksh93/src/cmd/ksh93/data/builtins.c | 276 - .../dtksh/ksh93/src/cmd/ksh93/data/config.c | 289 - .../dtksh/ksh93/src/cmd/ksh93/data/keywords.c | 134 - .../ksh93/src/cmd/ksh93/data/lexstates.c | 477 -- .../dtksh/ksh93/src/cmd/ksh93/data/limits.c | 124 - .../dtksh/ksh93/src/cmd/ksh93/data/msg.c | 251 - .../dtksh/ksh93/src/cmd/ksh93/data/options.c | 158 - .../dtksh/ksh93/src/cmd/ksh93/data/signals.c | 323 - .../dtksh/ksh93/src/cmd/ksh93/data/strdata.c | 187 - .../dtksh/ksh93/src/cmd/ksh93/data/testops.c | 129 - .../ksh93/src/cmd/ksh93/data/variables.c | 173 - .../ksh93/src/cmd/ksh93/edit/completion.c | 392 -- .../dtksh/ksh93/src/cmd/ksh93/edit/edit.c | 1281 ---- .../dtksh/ksh93/src/cmd/ksh93/edit/emacs.c | 1370 ---- .../dtksh/ksh93/src/cmd/ksh93/edit/history.c | 1128 --- .../dtksh/ksh93/src/cmd/ksh93/edit/vi.c | 2551 ------- .../dtksh/ksh93/src/cmd/ksh93/feature/cmds | 1 - .../dtksh/ksh93/src/cmd/ksh93/feature/dynamic | 17 - .../dtksh/ksh93/src/cmd/ksh93/feature/externs | 3 - .../dtksh/ksh93/src/cmd/ksh93/feature/locale | 21 - .../ksh93/src/cmd/ksh93/feature/options.sh | 63 - .../dtksh/ksh93/src/cmd/ksh93/feature/poll | 34 - .../dtksh/ksh93/src/cmd/ksh93/feature/rlimits | 2 - .../dtksh/ksh93/src/cmd/ksh93/feature/setjmp | 15 - .../ksh93/src/cmd/ksh93/feature/sigfeatures | 28 - .../dtksh/ksh93/src/cmd/ksh93/feature/time | 8 - .../dtksh/ksh93/src/cmd/ksh93/feature/ttys | 3 - .../dtksh/ksh93/src/cmd/ksh93/features/cmds | 1 - .../ksh93/src/cmd/ksh93/features/dynamic | 17 - .../ksh93/src/cmd/ksh93/features/externs | 3 - .../dtksh/ksh93/src/cmd/ksh93/features/locale | 21 - .../ksh93/src/cmd/ksh93/features/options.sh | 77 - .../dtksh/ksh93/src/cmd/ksh93/features/poll | 34 - .../ksh93/src/cmd/ksh93/features/rlimits | 2 - .../dtksh/ksh93/src/cmd/ksh93/features/setjmp | 18 - .../ksh93/src/cmd/ksh93/features/sigfeatures | 28 - .../dtksh/ksh93/src/cmd/ksh93/features/time | 8 - .../dtksh/ksh93/src/cmd/ksh93/features/ttys | 3 - .../dtksh/ksh93/src/cmd/ksh93/grep.mm | 50 - .../ksh93/src/cmd/ksh93/include/argnod.h | 216 - .../ksh93/src/cmd/ksh93/include/builtins.h | 267 - .../dtksh/ksh93/src/cmd/ksh93/include/defs.h | 253 - .../dtksh/ksh93/src/cmd/ksh93/include/edit.h | 263 - .../dtksh/ksh93/src/cmd/ksh93/include/fault.h | 184 - .../dtksh/ksh93/src/cmd/ksh93/include/fcin.h | 133 - .../ksh93/src/cmd/ksh93/include/history.h | 151 - .../dtksh/ksh93/src/cmd/ksh93/include/io.h | 160 - .../dtksh/ksh93/src/cmd/ksh93/include/jobs.h | 226 - .../ksh93/src/cmd/ksh93/include/lexstates.h | 188 - .../dtksh/ksh93/src/cmd/ksh93/include/name.h | 226 - .../ksh93/src/cmd/ksh93/include/national.h | 138 - .../dtksh/ksh93/src/cmd/ksh93/include/nval.h | 280 - .../dtksh/ksh93/src/cmd/ksh93/include/path.h | 175 - .../dtksh/ksh93/src/cmd/ksh93/include/shell.h | 243 - .../dtksh/ksh93/src/cmd/ksh93/include/shlex.h | 206 - .../ksh93/src/cmd/ksh93/include/shnodes.h | 280 - .../ksh93/src/cmd/ksh93/include/shtable.h | 142 - .../ksh93/src/cmd/ksh93/include/streval.h | 192 - .../ksh93/src/cmd/ksh93/include/terminal.h | 281 - .../dtksh/ksh93/src/cmd/ksh93/include/test.h | 143 - .../ksh93/src/cmd/ksh93/include/timeout.h | 60 - .../ksh93/src/cmd/ksh93/include/ulimit.h | 174 - .../ksh93/src/cmd/ksh93/include/variables.h | 176 - cde/programs/dtksh/ksh93/src/cmd/ksh93/ksh.mk | 933 --- .../dtksh/ksh93/src/cmd/ksh93/mamexec | 307 - .../dtksh/ksh93/src/cmd/ksh93/mamstate.c | 101 - cde/programs/dtksh/ksh93/src/cmd/ksh93/nval.3 | 433 -- cde/programs/dtksh/ksh93/src/cmd/ksh93/sh.1 | 6272 ----------------- .../dtksh/ksh93/src/cmd/ksh93/sh.memo | 3248 --------- .../dtksh/ksh93/src/cmd/ksh93/sh/args.c | 582 -- .../dtksh/ksh93/src/cmd/ksh93/sh/arith.c | 217 - .../dtksh/ksh93/src/cmd/ksh93/sh/array.c | 547 -- .../dtksh/ksh93/src/cmd/ksh93/sh/defs.c | 90 - .../dtksh/ksh93/src/cmd/ksh93/sh/deparse.c | 602 -- .../dtksh/ksh93/src/cmd/ksh93/sh/dlopen.c | 248 - .../dtksh/ksh93/src/cmd/ksh93/sh/expand.c | 598 -- .../dtksh/ksh93/src/cmd/ksh93/sh/fault.c | 524 -- .../dtksh/ksh93/src/cmd/ksh93/sh/fcin.c | 189 - .../dtksh/ksh93/src/cmd/ksh93/sh/init.c | 1396 ---- .../dtksh/ksh93/src/cmd/ksh93/sh/io.c | 1438 ---- .../dtksh/ksh93/src/cmd/ksh93/sh/jobs.c | 1474 ---- .../dtksh/ksh93/src/cmd/ksh93/sh/lex.c | 1984 ------ .../dtksh/ksh93/src/cmd/ksh93/sh/macro.c | 1654 ----- .../dtksh/ksh93/src/cmd/ksh93/sh/main.c | 685 -- .../dtksh/ksh93/src/cmd/ksh93/sh/name.c | 1802 ----- .../dtksh/ksh93/src/cmd/ksh93/sh/parse.c | 1480 ---- .../dtksh/ksh93/src/cmd/ksh93/sh/path.c | 946 --- .../dtksh/ksh93/src/cmd/ksh93/sh/shcomp.c | 179 - .../dtksh/ksh93/src/cmd/ksh93/sh/streval.c | 597 -- .../dtksh/ksh93/src/cmd/ksh93/sh/string.c | 331 - .../dtksh/ksh93/src/cmd/ksh93/sh/subshell.c | 402 -- .../dtksh/ksh93/src/cmd/ksh93/sh/suid_exec.c | 531 -- .../dtksh/ksh93/src/cmd/ksh93/sh/tdump.c | 285 - .../dtksh/ksh93/src/cmd/ksh93/sh/timers.c | 299 - .../dtksh/ksh93/src/cmd/ksh93/sh/trestore.c | 364 - .../dtksh/ksh93/src/cmd/ksh93/sh/userinit.c | 103 - .../dtksh/ksh93/src/cmd/ksh93/sh/vfork.c | 165 - .../dtksh/ksh93/src/cmd/ksh93/sh/waitevent.c | 106 - .../dtksh/ksh93/src/cmd/ksh93/sh/xec.c | 1941 ----- .../dtksh/ksh93/src/cmd/ksh93/tests/alias.sh | 54 - .../dtksh/ksh93/src/cmd/ksh93/tests/arith.sh | 100 - .../dtksh/ksh93/src/cmd/ksh93/tests/arrays.sh | 201 - .../ksh93/src/cmd/ksh93/tests/attributes.sh | 88 - .../dtksh/ksh93/src/cmd/ksh93/tests/basic.sh | 183 - .../ksh93/src/cmd/ksh93/tests/bracket.sh | 159 - .../ksh93/src/cmd/ksh93/tests/builtins.sh | 143 - .../dtksh/ksh93/src/cmd/ksh93/tests/case.sh | 35 - .../dtksh/ksh93/src/cmd/ksh93/tests/comvar.sh | 39 - .../ksh93/src/cmd/ksh93/tests/coprocess.sh | 88 - .../dtksh/ksh93/src/cmd/ksh93/tests/exit.sh | 32 - .../ksh93/src/cmd/ksh93/tests/functions.sh | 136 - .../dtksh/ksh93/src/cmd/ksh93/tests/grep.sh | 84 - .../ksh93/src/cmd/ksh93/tests/heredoc.sh | 81 - .../dtksh/ksh93/src/cmd/ksh93/tests/io.sh | 45 - .../ksh93/src/cmd/ksh93/tests/nameref.sh | 101 - .../ksh93/src/cmd/ksh93/tests/options.sh | 25 - .../ksh93/src/cmd/ksh93/tests/quoting.sh | 234 - .../dtksh/ksh93/src/cmd/ksh93/tests/return.sh | 156 - .../dtksh/ksh93/src/cmd/ksh93/tests/select.sh | 44 - .../dtksh/ksh93/src/cmd/ksh93/tests/shtests | 20 - .../ksh93/src/cmd/ksh93/tests/substring.sh | 140 - .../dtksh/ksh93/src/cmd/ksh93/tests/tilde.sh | 52 - .../ksh93/src/cmd/ksh93/tests/variables.sh | 186 - cde/programs/dtksh/ksh93/src/cmd/pax/HISTORY | 26 - cde/programs/dtksh/ksh93/src/cmd/pax/Makefile | 22 - cde/programs/dtksh/ksh93/src/cmd/pax/Mamfile | 344 - cde/programs/dtksh/ksh93/src/cmd/pax/RELEASE | 111 - cde/programs/dtksh/ksh93/src/cmd/pax/bax.1 | 97 - cde/programs/dtksh/ksh93/src/cmd/pax/bax.sh | 121 - cde/programs/dtksh/ksh93/src/cmd/pax/bio.c | 983 --- cde/programs/dtksh/ksh93/src/cmd/pax/cia.fmt | 3 - .../dtksh/ksh93/src/cmd/pax/ciadb.fmt | 7 - .../dtksh/ksh93/src/cmd/pax/convert.c | 256 - cde/programs/dtksh/ksh93/src/cmd/pax/copy.c | 974 --- cde/programs/dtksh/ksh93/src/cmd/pax/cpio.sh | 118 - cde/programs/dtksh/ksh93/src/cmd/pax/delta.c | 1145 --- .../dtksh/ksh93/src/cmd/pax/fgetline.c | 169 - cde/programs/dtksh/ksh93/src/cmd/pax/file.c | 1073 --- cde/programs/dtksh/ksh93/src/cmd/pax/format.c | 2298 ------ cde/programs/dtksh/ksh93/src/cmd/pax/misc.c | 678 -- cde/programs/dtksh/ksh93/src/cmd/pax/nocom.c | 437 -- .../dtksh/ksh93/src/cmd/pax/options.h | 205 - cde/programs/dtksh/ksh93/src/cmd/pax/pax.1 | 685 -- .../dtksh/ksh93/src/cmd/pax/pax.1.posix | 339 - cde/programs/dtksh/ksh93/src/cmd/pax/pax.c | 1890 ----- cde/programs/dtksh/ksh93/src/cmd/pax/pax.h | 893 --- cde/programs/dtksh/ksh93/src/cmd/pax/ppar.fmt | 2 - cde/programs/dtksh/ksh93/src/cmd/pax/stubs.c | 115 - cde/programs/dtksh/ksh93/src/cmd/pax/tar.sh | 88 - cde/programs/dtksh/ksh93/src/lib/Makefile | 2 - .../dtksh/ksh93/src/lib/lib0ast/C.probe | 522 -- .../dtksh/ksh93/src/lib/lib0ast/Makefile | 35 - .../dtksh/ksh93/src/lib/lib0ast/Mamfile | 186 - .../dtksh/ksh93/src/lib/lib0ast/PROBE.mk | 14 - .../dtksh/ksh93/src/lib/lib0ast/RELEASE | 13 - .../dtksh/ksh93/src/lib/lib0ast/hostinfo.sh | 474 -- .../dtksh/ksh93/src/lib/lib0ast/hosttype.tst | 5 - .../dtksh/ksh93/src/lib/libAST/C.probe | 417 -- .../dtksh/ksh93/src/lib/libAST/Makefile | 31 - .../dtksh/ksh93/src/lib/libAST/Mamfile | 128 - .../dtksh/ksh93/src/lib/libAST/PROBE.mk | 14 - .../dtksh/ksh93/src/lib/libast/Makefile | 171 - .../dtksh/ksh93/src/lib/libast/Mamfile | 3393 --------- .../dtksh/ksh93/src/lib/libast/README | 96 - .../dtksh/ksh93/src/lib/libast/RELEASE | 109 - .../dtksh/ksh93/src/lib/libast/comp/atexit.c | 174 - .../dtksh/ksh93/src/lib/libast/comp/conf.sh | 843 --- .../dtksh/ksh93/src/lib/libast/comp/conf.tab | 314 - .../dtksh/ksh93/src/lib/libast/comp/dup2.c | 114 - .../dtksh/ksh93/src/lib/libast/comp/errno.c | 109 - .../dtksh/ksh93/src/lib/libast/comp/execve.c | 133 - .../dtksh/ksh93/src/lib/libast/comp/fcntl.c | 163 - .../ksh93/src/lib/libast/comp/getgroups.c | 142 - .../dtksh/ksh93/src/lib/libast/comp/getpgrp.c | 98 - .../dtksh/ksh93/src/lib/libast/comp/getwd.c | 100 - .../dtksh/ksh93/src/lib/libast/comp/killpg.c | 108 - .../dtksh/ksh93/src/lib/libast/comp/link.c | 111 - .../dtksh/ksh93/src/lib/libast/comp/lstat.c | 108 - .../dtksh/ksh93/src/lib/libast/comp/memccpy.c | 119 - .../dtksh/ksh93/src/lib/libast/comp/memchr.c | 117 - .../dtksh/ksh93/src/lib/libast/comp/memcmp.c | 113 - .../dtksh/ksh93/src/lib/libast/comp/memcpy.c | 127 - .../dtksh/ksh93/src/lib/libast/comp/memmove.c | 121 - .../dtksh/ksh93/src/lib/libast/comp/memset.c | 110 - .../dtksh/ksh93/src/lib/libast/comp/mkdir.c | 130 - .../dtksh/ksh93/src/lib/libast/comp/mkfifo.c | 114 - .../dtksh/ksh93/src/lib/libast/comp/mknod.c | 112 - .../dtksh/ksh93/src/lib/libast/comp/mktemp.c | 127 - .../dtksh/ksh93/src/lib/libast/comp/mount.c | 113 - .../dtksh/ksh93/src/lib/libast/comp/open.c | 184 - .../ksh93/src/lib/libast/comp/pathconf.c | 189 - .../ksh93/src/lib/libast/comp/readlink.c | 117 - .../dtksh/ksh93/src/lib/libast/comp/remove.c | 108 - .../dtksh/ksh93/src/lib/libast/comp/rename.c | 123 - .../dtksh/ksh93/src/lib/libast/comp/rmdir.c | 134 - .../ksh93/src/lib/libast/comp/setlocale.c | 157 - .../dtksh/ksh93/src/lib/libast/comp/setpgid.c | 148 - .../dtksh/ksh93/src/lib/libast/comp/setsid.c | 158 - .../ksh93/src/lib/libast/comp/sigsetmask.c | 118 - .../ksh93/src/lib/libast/comp/sigunblock.c | 131 - .../dtksh/ksh93/src/lib/libast/comp/spawnve.c | 106 - .../ksh93/src/lib/libast/comp/spawnveg.c | 248 - .../dtksh/ksh93/src/lib/libast/comp/statvfs.c | 215 - .../dtksh/ksh93/src/lib/libast/comp/strchr.c | 124 - .../dtksh/ksh93/src/lib/libast/comp/strrchr.c | 127 - .../dtksh/ksh93/src/lib/libast/comp/strtod.c | 126 - .../dtksh/ksh93/src/lib/libast/comp/strtol.c | 152 - .../dtksh/ksh93/src/lib/libast/comp/strtoul.c | 106 - .../dtksh/ksh93/src/lib/libast/comp/symlink.c | 111 - .../dtksh/ksh93/src/lib/libast/comp/sysconf.c | 181 - .../dtksh/ksh93/src/lib/libast/comp/system.c | 105 - .../dtksh/ksh93/src/lib/libast/comp/tmpnam.c | 126 - .../dtksh/ksh93/src/lib/libast/comp/unlink.c | 106 - .../dtksh/ksh93/src/lib/libast/comp/vfork.c | 117 - .../dtksh/ksh93/src/lib/libast/comp/waitpid.c | 260 - .../dtksh/ksh93/src/lib/libast/conf.tab | 318 - .../dtksh/ksh93/src/lib/libast/dir/dirlib.h | 198 - .../dtksh/ksh93/src/lib/libast/dir/dirnsys.h | 144 - .../dtksh/ksh93/src/lib/libast/dir/dirstd.h | 130 - .../dtksh/ksh93/src/lib/libast/dir/dirsys.h | 144 - .../dtksh/ksh93/src/lib/libast/dir/getdents.c | 234 - .../dtksh/ksh93/src/lib/libast/dir/opendir.c | 150 - .../dtksh/ksh93/src/lib/libast/dir/readdir.c | 122 - .../ksh93/src/lib/libast/dir/rewinddir.c | 108 - .../dtksh/ksh93/src/lib/libast/dir/seekdir.c | 116 - .../dtksh/ksh93/src/lib/libast/dir/telldir.c | 106 - .../ksh93/src/lib/libast/disc/sfkeyprintf.c | 429 -- .../ksh93/src/lib/libast/disc/sfslowio.c | 132 - .../ksh93/src/lib/libast/feature/align.c | 226 - .../ksh93/src/lib/libast/feature/botch.c | 140 - .../ksh93/src/lib/libast/feature/fcntl.c | 413 -- .../dtksh/ksh93/src/lib/libast/feature/fs | 176 - .../dtksh/ksh93/src/lib/libast/feature/hdr | 46 - .../dtksh/ksh93/src/lib/libast/feature/int.c | 158 - .../dtksh/ksh93/src/lib/libast/feature/lib | 232 - .../ksh93/src/lib/libast/feature/limits.c | 684 -- .../dtksh/ksh93/src/lib/libast/feature/mode.c | 289 - .../ksh93/src/lib/libast/feature/param.sh | 23 - .../ksh93/src/lib/libast/feature/preroot.sh | 22 - .../dtksh/ksh93/src/lib/libast/feature/sfio | 38 - .../dtksh/ksh93/src/lib/libast/feature/sig.sh | 60 - .../ksh93/src/lib/libast/feature/signal.c | 290 - .../dtksh/ksh93/src/lib/libast/feature/time | 39 - .../dtksh/ksh93/src/lib/libast/feature/tty | 17 - .../dtksh/ksh93/src/lib/libast/feature/types | 49 - .../ksh93/src/lib/libast/feature/unistd.c | 327 - .../dtksh/ksh93/src/lib/libast/feature/wait | 9 - .../ksh93/src/lib/libast/features/align.c | 218 - .../ksh93/src/lib/libast/features/botch.c | 132 - .../ksh93/src/lib/libast/features/fcntl.c | 399 -- .../dtksh/ksh93/src/lib/libast/features/fs | 167 - .../dtksh/ksh93/src/lib/libast/features/hdr | 46 - .../dtksh/ksh93/src/lib/libast/features/int.c | 150 - .../dtksh/ksh93/src/lib/libast/features/lib | 314 - .../ksh93/src/lib/libast/features/limits.c | 440 -- .../ksh93/src/lib/libast/features/mode.c | 281 - .../ksh93/src/lib/libast/features/param.sh | 23 - .../ksh93/src/lib/libast/features/preroot.sh | 22 - .../dtksh/ksh93/src/lib/libast/features/sfio | 36 - .../ksh93/src/lib/libast/features/sig.sh | 70 - .../ksh93/src/lib/libast/features/signal.c | 339 - .../dtksh/ksh93/src/lib/libast/features/time | 39 - .../dtksh/ksh93/src/lib/libast/features/tty | 22 - .../dtksh/ksh93/src/lib/libast/features/types | 49 - .../ksh93/src/lib/libast/features/unistd.c | 125 - .../ksh93/src/lib/libast/features/vmalloc | 1 - .../dtksh/ksh93/src/lib/libast/features/wait | 9 - .../ksh93/src/lib/libast/hash/hashalloc.c | 279 - .../ksh93/src/lib/libast/hash/hashdump.c | 232 - .../ksh93/src/lib/libast/hash/hashfree.c | 200 - .../ksh93/src/lib/libast/hash/hashlast.c | 102 - .../dtksh/ksh93/src/lib/libast/hash/hashlib.h | 175 - .../ksh93/src/lib/libast/hash/hashlook.c | 376 - .../ksh93/src/lib/libast/hash/hashscan.c | 204 - .../ksh93/src/lib/libast/hash/hashsize.c | 146 - .../ksh93/src/lib/libast/hash/hashwalk.c | 113 - .../dtksh/ksh93/src/lib/libast/hash/memhash.c | 107 - .../dtksh/ksh93/src/lib/libast/hash/memsum.c | 115 - .../dtksh/ksh93/src/lib/libast/hash/strhash.c | 107 - .../dtksh/ksh93/src/lib/libast/hash/strsum.c | 115 - .../dtksh/ksh93/src/lib/libast/include/ast.h | 298 - .../ksh93/src/lib/libast/include/ast_dir.h | 124 - .../ksh93/src/lib/libast/include/ast_std.h | 920 --- .../ksh93/src/lib/libast/include/debug.h | 117 - .../ksh93/src/lib/libast/include/error.h | 217 - .../dtksh/ksh93/src/lib/libast/include/find.h | 108 - .../dtksh/ksh93/src/lib/libast/include/fs3d.h | 173 - .../ksh93/src/lib/libast/include/ftwalk.h | 190 - .../dtksh/ksh93/src/lib/libast/include/hash.h | 276 - .../ksh93/src/lib/libast/include/hashpart.h | 122 - .../dtksh/ksh93/src/lib/libast/include/ls.h | 176 - .../ksh93/src/lib/libast/include/magic.h | 132 - .../ksh93/src/lib/libast/include/modecanon.h | 134 - .../ksh93/src/lib/libast/include/modex.h | 116 - .../ksh93/src/lib/libast/include/namval.h | 113 - .../ksh93/src/lib/libast/include/national.h | 106 - .../ksh93/src/lib/libast/include/option.h | 148 - .../dtksh/ksh93/src/lib/libast/include/proc.h | 165 - .../dtksh/ksh93/src/lib/libast/include/re.h | 139 - .../ksh93/src/lib/libast/include/sfdisc.h | 120 - .../dtksh/ksh93/src/lib/libast/include/sfio.h | 391 - .../ksh93/src/lib/libast/include/sfstr.h | 78 - .../ksh93/src/lib/libast/include/stack.h | 148 - .../dtksh/ksh93/src/lib/libast/include/stak.h | 126 - .../ksh93/src/lib/libast/include/stdio.h | 232 - .../dtksh/ksh93/src/lib/libast/include/stk.h | 134 - .../dtksh/ksh93/src/lib/libast/include/swap.h | 114 - .../dtksh/ksh93/src/lib/libast/include/tar.h | 186 - .../ksh93/src/lib/libast/include/times.h | 137 - .../dtksh/ksh93/src/lib/libast/include/tm.h | 208 - .../dtksh/ksh93/src/lib/libast/include/tok.h | 112 - .../dtksh/ksh93/src/lib/libast/include/vdb.h | 117 - .../ksh93/src/lib/libast/include/vecargs.h | 110 - .../ksh93/src/lib/libast/include/vmalloc.h | 320 - .../dtksh/ksh93/src/lib/libast/include/wait.h | 169 - .../dtksh/ksh93/src/lib/libast/man/LIBAST.3 | 83 - .../dtksh/ksh93/src/lib/libast/man/ast.3 | 272 - .../dtksh/ksh93/src/lib/libast/man/chr.3 | 121 - .../ksh93/src/lib/libast/man/compatibility.3 | 92 - .../dtksh/ksh93/src/lib/libast/man/error.3 | 272 - .../dtksh/ksh93/src/lib/libast/man/find.3 | 78 - .../dtksh/ksh93/src/lib/libast/man/fmt.3 | 199 - .../dtksh/ksh93/src/lib/libast/man/fmtls.3 | 133 - .../dtksh/ksh93/src/lib/libast/man/fs3d.3 | 81 - .../dtksh/ksh93/src/lib/libast/man/ftwalk.3 | 235 - .../dtksh/ksh93/src/lib/libast/man/getcwd.3 | 56 - .../dtksh/ksh93/src/lib/libast/man/hash.3 | 633 -- .../dtksh/ksh93/src/lib/libast/man/iblocks.3 | 51 - .../dtksh/ksh93/src/lib/libast/man/int.3 | 60 - .../dtksh/ksh93/src/lib/libast/man/magic.3 | 472 -- .../dtksh/ksh93/src/lib/libast/man/mem.3 | 87 - .../ksh93/src/lib/libast/man/modecanon.3 | 96 - .../dtksh/ksh93/src/lib/libast/man/optget.3 | 42 - .../dtksh/ksh93/src/lib/libast/man/path.3 | 383 - .../dtksh/ksh93/src/lib/libast/man/preroot.3 | 140 - .../dtksh/ksh93/src/lib/libast/man/proc.3 | 308 - .../dtksh/ksh93/src/lib/libast/man/re.3 | 206 - .../ksh93/src/lib/libast/man/setenviron.3 | 68 - .../dtksh/ksh93/src/lib/libast/man/sfdisc.3 | 171 - .../dtksh/ksh93/src/lib/libast/man/sfio.3 | 1362 ---- .../dtksh/ksh93/src/lib/libast/man/sig.3 | 64 - .../dtksh/ksh93/src/lib/libast/man/spawnveg.3 | 89 - .../dtksh/ksh93/src/lib/libast/man/stak.3 | 169 - .../dtksh/ksh93/src/lib/libast/man/stk.3 | 160 - .../dtksh/ksh93/src/lib/libast/man/strcopy.3 | 43 - .../dtksh/ksh93/src/lib/libast/man/strdup.3 | 44 - .../ksh93/src/lib/libast/man/strelapsed.3 | 66 - .../dtksh/ksh93/src/lib/libast/man/strerror.3 | 45 - .../dtksh/ksh93/src/lib/libast/man/stresc.3 | 42 - .../dtksh/ksh93/src/lib/libast/man/streval.3 | 72 - .../dtksh/ksh93/src/lib/libast/man/strgid.3 | 42 - .../dtksh/ksh93/src/lib/libast/man/strmatch.3 | 90 - .../dtksh/ksh93/src/lib/libast/man/stropt.3 | 119 - .../dtksh/ksh93/src/lib/libast/man/strperm.3 | 98 - .../ksh93/src/lib/libast/man/strsignal.3 | 45 - .../dtksh/ksh93/src/lib/libast/man/strsort.3 | 62 - .../dtksh/ksh93/src/lib/libast/man/strtape.3 | 75 - .../dtksh/ksh93/src/lib/libast/man/strton.3 | 86 - .../dtksh/ksh93/src/lib/libast/man/struid.3 | 42 - .../dtksh/ksh93/src/lib/libast/man/swap.3 | 127 - .../dtksh/ksh93/src/lib/libast/man/tab.3 | 63 - .../dtksh/ksh93/src/lib/libast/man/tm.3 | 565 -- .../dtksh/ksh93/src/lib/libast/man/tok.3 | 206 - .../dtksh/ksh93/src/lib/libast/man/touch.3 | 60 - .../dtksh/ksh93/src/lib/libast/man/vecargs.3 | 118 - .../dtksh/ksh93/src/lib/libast/man/vmalloc.3 | 468 -- .../dtksh/ksh93/src/lib/libast/misc/calloc.c | 123 - .../ksh93/src/lib/libast/misc/cmdclose.c | 124 - .../dtksh/ksh93/src/lib/libast/misc/cmdkill.c | 118 - .../dtksh/ksh93/src/lib/libast/misc/cmdlib.h | 132 - .../dtksh/ksh93/src/lib/libast/misc/cmdopen.c | 420 -- .../dtksh/ksh93/src/lib/libast/misc/cmdrun.c | 109 - .../dtksh/ksh93/src/lib/libast/misc/error.c | 397 -- .../ksh93/src/lib/libast/misc/fastfind.c | 279 - .../dtksh/ksh93/src/lib/libast/misc/fs3d.c | 151 - .../dtksh/ksh93/src/lib/libast/misc/ftwalk.c | 861 --- .../ksh93/src/lib/libast/misc/ftwflags.c | 106 - .../dtksh/ksh93/src/lib/libast/misc/getcwd.c | 347 - .../dtksh/ksh93/src/lib/libast/misc/getpath.c | 111 - .../ksh93/src/lib/libast/misc/getshell.c | 144 - .../ksh93/src/lib/libast/misc/getsymlink.c | 176 - .../dtksh/ksh93/src/lib/libast/misc/getuniv.c | 202 - .../dtksh/ksh93/src/lib/libast/misc/hsort.c | 123 - .../ksh93/src/lib/libast/misc/liberror.c | 103 - .../dtksh/ksh93/src/lib/libast/misc/lpstat.c | 127 - .../dtksh/ksh93/src/lib/libast/misc/magic.c | 1794 ----- .../dtksh/ksh93/src/lib/libast/misc/magic.tab | 773 -- .../dtksh/ksh93/src/lib/libast/misc/malloc.c | 1128 --- .../ksh93/src/lib/libast/misc/nomalloc.c | 105 - .../dtksh/ksh93/src/lib/libast/misc/optdata.c | 101 - .../dtksh/ksh93/src/lib/libast/misc/optget.c | 670 -- .../dtksh/ksh93/src/lib/libast/misc/optjoin.c | 188 - .../ksh93/src/lib/libast/misc/pathaccess.c | 125 - .../ksh93/src/lib/libast/misc/pathcanon.c | 257 - .../dtksh/ksh93/src/lib/libast/misc/pathcat.c | 120 - .../ksh93/src/lib/libast/misc/pathcheck.c | 111 - .../dtksh/ksh93/src/lib/libast/misc/pathkey.c | 321 - .../ksh93/src/lib/libast/misc/pathpath.c | 147 - .../ksh93/src/lib/libast/misc/pathprobe.c | 180 - .../ksh93/src/lib/libast/misc/pathrepl.c | 148 - .../ksh93/src/lib/libast/misc/pathtemp.c | 168 - .../ksh93/src/lib/libast/misc/procclose.c | 111 - .../ksh93/src/lib/libast/misc/procfree.c | 101 - .../dtksh/ksh93/src/lib/libast/misc/proclib.h | 116 - .../ksh93/src/lib/libast/misc/procopen.c | 754 -- .../dtksh/ksh93/src/lib/libast/misc/procrun.c | 98 - .../dtksh/ksh93/src/lib/libast/misc/putenv.c | 200 - .../ksh93/src/lib/libast/misc/putsymlink.c | 146 - .../dtksh/ksh93/src/lib/libast/misc/query.c | 158 - .../dtksh/ksh93/src/lib/libast/misc/setcwd.c | 210 - .../dtksh/ksh93/src/lib/libast/misc/setenv.c | 199 - .../ksh93/src/lib/libast/misc/setenviron.c | 189 - .../dtksh/ksh93/src/lib/libast/misc/setuniv.c | 134 - .../dtksh/ksh93/src/lib/libast/misc/sigcrit.c | 227 - .../dtksh/ksh93/src/lib/libast/misc/sigdata.c | 108 - .../dtksh/ksh93/src/lib/libast/misc/signal.c | 164 - .../dtksh/ksh93/src/lib/libast/misc/slowio.c | 147 - .../dtksh/ksh93/src/lib/libast/misc/stack.c | 231 - .../dtksh/ksh93/src/lib/libast/misc/stak.c | 527 -- .../dtksh/ksh93/src/lib/libast/misc/state.c | 118 - .../dtksh/ksh93/src/lib/libast/misc/stk.c | 505 -- .../ksh93/src/lib/libast/misc/systrace.c | 131 - .../ksh93/src/lib/libast/misc/univdata.c | 121 - .../dtksh/ksh93/src/lib/libast/misc/univlib.h | 174 - .../src/lib/libast/obsolete/astfeature.c | 98 - .../ksh93/src/lib/libast/obsolete/cmdclose.c | 108 - .../ksh93/src/lib/libast/obsolete/cmdkill.c | 110 - .../ksh93/src/lib/libast/obsolete/cmdlib.h | 124 - .../ksh93/src/lib/libast/obsolete/cmdopen.c | 176 - .../ksh93/src/lib/libast/obsolete/cmdproc.c | 122 - .../ksh93/src/lib/libast/obsolete/cmdrun.c | 108 - .../ksh93/src/lib/libast/obsolete/copy.c | 108 - .../ksh93/src/lib/libast/obsolete/ctoi.c | 108 - .../ksh93/src/lib/libast/obsolete/fclex.c | 108 - .../ksh93/src/lib/libast/obsolete/fdcopy.c | 98 - .../ksh93/src/lib/libast/obsolete/fgetline.c | 169 - .../ksh93/src/lib/libast/obsolete/gethalf.c | 109 - .../ksh93/src/lib/libast/obsolete/getlong.c | 109 - .../ksh93/src/lib/libast/obsolete/getpath.c | 98 - .../ksh93/src/lib/libast/obsolete/getshell.c | 98 - .../src/lib/libast/obsolete/getsymlink.c | 98 - .../ksh93/src/lib/libast/obsolete/getuniv.c | 98 - .../src/lib/libast/obsolete/getwinsize.c | 98 - .../ksh93/src/lib/libast/obsolete/hsort.c | 98 - .../ksh93/src/lib/libast/obsolete/lexline.c | 108 - .../ksh93/src/lib/libast/obsolete/lexscan.c | 115 - .../ksh93/src/lib/libast/obsolete/lpstat.c | 97 - .../ksh93/src/lib/libast/obsolete/memswap.c | 109 - .../ksh93/src/lib/libast/obsolete/puthalf.c | 109 - .../ksh93/src/lib/libast/obsolete/putlong.c | 109 - .../src/lib/libast/obsolete/putsymlink.c | 98 - .../ksh93/src/lib/libast/obsolete/query.c | 144 - .../ksh93/src/lib/libast/obsolete/setcwd.c | 96 - .../ksh93/src/lib/libast/obsolete/setenv.c | 110 - .../ksh93/src/lib/libast/obsolete/setuniv.c | 98 - .../ksh93/src/lib/libast/obsolete/slowio.c | 99 - .../ksh93/src/lib/libast/obsolete/strerror.c | 106 - .../ksh93/src/lib/libast/obsolete/strsignal.c | 98 - .../ksh93/src/lib/libast/obsolete/swapdata.c | 112 - .../ksh93/src/lib/libast/obsolete/tablook.c | 98 - .../ksh93/src/lib/libast/obsolete/tblocks.c | 109 - .../ksh93/src/lib/libast/obsolete/winsize.c | 108 - .../ksh93/src/lib/libast/path/pathaccess.c | 132 - .../dtksh/ksh93/src/lib/libast/path/pathbin.c | 108 - .../ksh93/src/lib/libast/path/pathcanon.c | 243 - .../dtksh/ksh93/src/lib/libast/path/pathcat.c | 110 - .../dtksh/ksh93/src/lib/libast/path/pathcd.c | 205 - .../ksh93/src/lib/libast/path/pathcheck.c | 139 - .../ksh93/src/lib/libast/path/pathgetlink.c | 166 - .../dtksh/ksh93/src/lib/libast/path/pathkey.c | 309 - .../ksh93/src/lib/libast/path/pathpath.c | 135 - .../ksh93/src/lib/libast/path/pathprobe.c | 170 - .../ksh93/src/lib/libast/path/pathrepl.c | 138 - .../ksh93/src/lib/libast/path/pathsetlink.c | 136 - .../ksh93/src/lib/libast/path/pathshell.c | 142 - .../ksh93/src/lib/libast/path/pathstat.c | 113 - .../ksh93/src/lib/libast/path/pathtemp.c | 150 - .../dtksh/ksh93/src/lib/libast/port/astconf.c | 753 -- .../dtksh/ksh93/src/lib/libast/port/astcopy.c | 176 - .../ksh93/src/lib/libast/port/astquery.c | 144 - .../ksh93/src/lib/libast/port/astwinsize.c | 201 - .../dtksh/ksh93/src/lib/libast/port/fdcopy.c | 186 - .../ksh93/src/lib/libast/port/getwinsize.c | 213 - .../dtksh/ksh93/src/lib/libast/port/iblocks.c | 146 - .../dtksh/ksh93/src/lib/libast/port/sigdata.c | 101 - .../dtksh/ksh93/src/lib/libast/port/touch.c | 243 - .../ksh93/src/lib/libast/preroot/getpreroot.c | 239 - .../ksh93/src/lib/libast/preroot/ispreroot.c | 134 - .../ksh93/src/lib/libast/preroot/realopen.c | 111 - .../ksh93/src/lib/libast/preroot/setpreroot.c | 139 - .../dtksh/ksh93/src/lib/libast/re/recomp.c | 616 -- .../dtksh/ksh93/src/lib/libast/re/reerror.c | 99 - .../dtksh/ksh93/src/lib/libast/re/reexec.c | 326 - .../dtksh/ksh93/src/lib/libast/re/relib.h | 188 - .../dtksh/ksh93/src/lib/libast/re/ressub.c | 183 - .../dtksh/ksh93/src/lib/libast/re/resub.c | 175 - .../ksh93/src/lib/libast/sfio/_sfclrerr.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfecvt.c | 80 - .../dtksh/ksh93/src/lib/libast/sfio/_sfeof.c | 68 - .../ksh93/src/lib/libast/sfio/_sferror.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sffcvt.c | 80 - .../ksh93/src/lib/libast/sfio/_sffileno.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfgetc.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfgetl.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfgetu.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfhdr.h | 84 - .../dtksh/ksh93/src/lib/libast/sfio/_sfputc.c | 70 - .../dtksh/ksh93/src/lib/libast/sfio/_sfputd.c | 70 - .../dtksh/ksh93/src/lib/libast/sfio/_sfputl.c | 70 - .../dtksh/ksh93/src/lib/libast/sfio/_sfputu.c | 70 - .../dtksh/ksh93/src/lib/libast/sfio/_sfslen.c | 66 - .../ksh93/src/lib/libast/sfio/_sfstacked.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/_sfulen.c | 68 - .../dtksh/ksh93/src/lib/libast/sfio/sfclose.c | 192 - .../ksh93/src/lib/libast/sfio/sfclrlock.c | 82 - .../dtksh/ksh93/src/lib/libast/sfio/sfcvt.c | 178 - .../dtksh/ksh93/src/lib/libast/sfio/sfdisc.c | 188 - .../dtksh/ksh93/src/lib/libast/sfio/sfdlen.c | 81 - .../dtksh/ksh93/src/lib/libast/sfio/sfecvt.c | 59 - .../ksh93/src/lib/libast/sfio/sfexcept.c | 147 - .../ksh93/src/lib/libast/sfio/sfextern.c | 77 - .../dtksh/ksh93/src/lib/libast/sfio/sffcvt.c | 59 - .../ksh93/src/lib/libast/sfio/sffilbuf.c | 114 - .../ksh93/src/lib/libast/sfio/sfflsbuf.c | 132 - .../dtksh/ksh93/src/lib/libast/sfio/sfgetd.c | 98 - .../dtksh/ksh93/src/lib/libast/sfio/sfgetl.c | 94 - .../dtksh/ksh93/src/lib/libast/sfio/sfgetr.c | 190 - .../dtksh/ksh93/src/lib/libast/sfio/sfgetu.c | 92 - .../dtksh/ksh93/src/lib/libast/sfio/sfhdr.h | 706 -- .../dtksh/ksh93/src/lib/libast/sfio/sfio_t.h | 98 - .../dtksh/ksh93/src/lib/libast/sfio/sfllen.c | 63 - .../dtksh/ksh93/src/lib/libast/sfio/sfmode.c | 614 -- .../dtksh/ksh93/src/lib/libast/sfio/sfmove.c | 274 - .../dtksh/ksh93/src/lib/libast/sfio/sfnew.c | 138 - .../ksh93/src/lib/libast/sfio/sfnotify.c | 62 - .../dtksh/ksh93/src/lib/libast/sfio/sfnputc.c | 102 - .../dtksh/ksh93/src/lib/libast/sfio/sfopen.c | 172 - .../dtksh/ksh93/src/lib/libast/sfio/sfpeek.c | 108 - .../dtksh/ksh93/src/lib/libast/sfio/sfpkrd.c | 288 - .../dtksh/ksh93/src/lib/libast/sfio/sfpoll.c | 249 - .../dtksh/ksh93/src/lib/libast/sfio/sfpool.c | 335 - .../dtksh/ksh93/src/lib/libast/sfio/sfpopen.c | 213 - .../ksh93/src/lib/libast/sfio/sfprintf.c | 119 - .../ksh93/src/lib/libast/sfio/sfprints.c | 87 - .../dtksh/ksh93/src/lib/libast/sfio/sfpurge.c | 118 - .../dtksh/ksh93/src/lib/libast/sfio/sfputd.c | 116 - .../dtksh/ksh93/src/lib/libast/sfio/sfputl.c | 100 - .../dtksh/ksh93/src/lib/libast/sfio/sfputr.c | 135 - .../dtksh/ksh93/src/lib/libast/sfio/sfputu.c | 92 - .../dtksh/ksh93/src/lib/libast/sfio/sfrd.c | 308 - .../dtksh/ksh93/src/lib/libast/sfio/sfread.c | 146 - .../ksh93/src/lib/libast/sfio/sfreserve.c | 174 - .../dtksh/ksh93/src/lib/libast/sfio/sfscanf.c | 113 - .../dtksh/ksh93/src/lib/libast/sfio/sfseek.c | 216 - .../dtksh/ksh93/src/lib/libast/sfio/sfset.c | 102 - .../ksh93/src/lib/libast/sfio/sfsetbuf.c | 316 - .../dtksh/ksh93/src/lib/libast/sfio/sfsetfd.c | 155 - .../dtksh/ksh93/src/lib/libast/sfio/sfsize.c | 102 - .../dtksh/ksh93/src/lib/libast/sfio/sfsk.c | 105 - .../dtksh/ksh93/src/lib/libast/sfio/sfstack.c | 121 - .../ksh93/src/lib/libast/sfio/sfstrtod.c | 193 - .../dtksh/ksh93/src/lib/libast/sfio/sfswap.c | 144 - .../dtksh/ksh93/src/lib/libast/sfio/sfsync.c | 183 - .../dtksh/ksh93/src/lib/libast/sfio/sftable.c | 108 - .../dtksh/ksh93/src/lib/libast/sfio/sftell.c | 78 - .../dtksh/ksh93/src/lib/libast/sfio/sftmp.c | 245 - .../ksh93/src/lib/libast/sfio/sfungetc.c | 125 - .../ksh93/src/lib/libast/sfio/sfvprintf.c | 762 -- .../ksh93/src/lib/libast/sfio/sfvscanf.c | 646 -- .../dtksh/ksh93/src/lib/libast/sfio/sfwr.c | 253 - .../dtksh/ksh93/src/lib/libast/sfio/sfwrite.c | 184 - .../ksh93/src/lib/libast/stdio/stdgets.c | 144 - .../ksh93/src/lib/libast/stdio/stdopen.c | 66 - .../ksh93/src/lib/libast/stdio/stdprintf.c | 77 - .../ksh93/src/lib/libast/stdio/stdscanf.c | 75 - .../ksh93/src/lib/libast/stdio/stdsprnt.c | 95 - .../ksh93/src/lib/libast/stdio/stdvbuf.c | 80 - .../ksh93/src/lib/libast/stdio/stdvsnprnt.c | 77 - .../ksh93/src/lib/libast/stdio/stdvsprnt.c | 76 - .../ksh93/src/lib/libast/stdio/stdvsscn.c | 71 - .../ksh93/src/lib/libast/string/chresc.c | 178 - .../ksh93/src/lib/libast/string/chrtoi.c | 117 - .../ksh93/src/lib/libast/string/fmtbase.c | 102 - .../ksh93/src/lib/libast/string/fmtdev.c | 125 - .../ksh93/src/lib/libast/string/fmtelapsed.c | 120 - .../ksh93/src/lib/libast/string/fmterror.c | 105 - .../ksh93/src/lib/libast/string/fmtesc.c | 153 - .../dtksh/ksh93/src/lib/libast/string/fmtfs.c | 250 - .../ksh93/src/lib/libast/string/fmtgid.c | 137 - .../dtksh/ksh93/src/lib/libast/string/fmtls.c | 167 - .../ksh93/src/lib/libast/string/fmtmatch.c | 284 - .../ksh93/src/lib/libast/string/fmtmode.c | 107 - .../ksh93/src/lib/libast/string/fmtperm.c | 242 - .../dtksh/ksh93/src/lib/libast/string/fmtre.c | 213 - .../ksh93/src/lib/libast/string/fmtsignal.c | 114 - .../ksh93/src/lib/libast/string/fmttime.c | 101 - .../ksh93/src/lib/libast/string/fmtuid.c | 137 - .../ksh93/src/lib/libast/string/mematoe.c | 147 - .../ksh93/src/lib/libast/string/memdup.c | 112 - .../ksh93/src/lib/libast/string/memetoa.c | 147 - .../ksh93/src/lib/libast/string/modedata.c | 135 - .../dtksh/ksh93/src/lib/libast/string/modei.c | 117 - .../ksh93/src/lib/libast/string/modelib.h | 126 - .../dtksh/ksh93/src/lib/libast/string/modex.c | 137 - .../ksh93/src/lib/libast/string/strcopy.c | 104 - .../ksh93/src/lib/libast/string/strdup.c | 105 - .../ksh93/src/lib/libast/string/strelapsed.c | 159 - .../ksh93/src/lib/libast/string/strerror.c | 125 - .../ksh93/src/lib/libast/string/stresc.c | 117 - .../ksh93/src/lib/libast/string/streval.c | 110 - .../ksh93/src/lib/libast/string/strexpr.c | 344 - .../ksh93/src/lib/libast/string/strgid.c | 156 - .../ksh93/src/lib/libast/string/strlook.c | 111 - .../ksh93/src/lib/libast/string/strmatch.c | 786 --- .../ksh93/src/lib/libast/string/strmode.c | 112 - .../ksh93/src/lib/libast/string/stropt.c | 229 - .../ksh93/src/lib/libast/string/strperm.c | 228 - .../ksh93/src/lib/libast/string/strsignal.c | 122 - .../ksh93/src/lib/libast/string/strsort.c | 113 - .../ksh93/src/lib/libast/string/strtape.c | 209 - .../ksh93/src/lib/libast/string/strton.c | 207 - .../ksh93/src/lib/libast/string/struid.c | 148 - .../ksh93/src/lib/libast/string/swapget.c | 121 - .../ksh93/src/lib/libast/string/swapmem.c | 170 - .../ksh93/src/lib/libast/string/swapop.c | 112 - .../ksh93/src/lib/libast/string/swapput.c | 111 - .../ksh93/src/lib/libast/string/tabindex.c | 121 - .../ksh93/src/lib/libast/string/tablook.c | 120 - .../dtksh/ksh93/src/lib/libast/string/tok.c | 212 - .../ksh93/src/lib/libast/string/tokline.c | 221 - .../ksh93/src/lib/libast/string/tokscan.c | 371 - .../dtksh/ksh93/src/lib/libast/tm/tmdata.c | 294 - .../dtksh/ksh93/src/lib/libast/tm/tmdate.c | 486 -- .../dtksh/ksh93/src/lib/libast/tm/tmfix.c | 158 - .../dtksh/ksh93/src/lib/libast/tm/tmfmt.c | 351 - .../dtksh/ksh93/src/lib/libast/tm/tmform.c | 104 - .../dtksh/ksh93/src/lib/libast/tm/tmgoff.c | 127 - .../dtksh/ksh93/src/lib/libast/tm/tminit.c | 423 -- .../dtksh/ksh93/src/lib/libast/tm/tmleap.c | 115 - .../dtksh/ksh93/src/lib/libast/tm/tmlex.c | 117 - .../dtksh/ksh93/src/lib/libast/tm/tmmake.c | 129 - .../dtksh/ksh93/src/lib/libast/tm/tmpoff.c | 119 - .../dtksh/ksh93/src/lib/libast/tm/tmtime.c | 152 - .../dtksh/ksh93/src/lib/libast/tm/tmtype.c | 119 - .../dtksh/ksh93/src/lib/libast/tm/tmword.c | 144 - .../dtksh/ksh93/src/lib/libast/tm/tmzone.c | 139 - .../dtksh/ksh93/src/lib/libast/vec/vecargs.c | 138 - .../dtksh/ksh93/src/lib/libast/vec/vecfile.c | 124 - .../dtksh/ksh93/src/lib/libast/vec/vecfree.c | 110 - .../dtksh/ksh93/src/lib/libast/vec/vecload.c | 158 - .../ksh93/src/lib/libast/vec/vecstring.c | 108 - .../ksh93/src/lib/libast/vmalloc/malloc.c | 483 -- .../ksh93/src/lib/libast/vmalloc/vmbest.c | 1088 --- .../ksh93/src/lib/libast/vmalloc/vmclear.c | 105 - .../ksh93/src/lib/libast/vmalloc/vmclose.c | 104 - .../ksh93/src/lib/libast/vmalloc/vmdcheap.c | 74 - .../ksh93/src/lib/libast/vmalloc/vmdcsbrk.c | 84 - .../ksh93/src/lib/libast/vmalloc/vmdebug.c | 728 -- .../ksh93/src/lib/libast/vmalloc/vmdisc.c | 72 - .../ksh93/src/lib/libast/vmalloc/vmexit.c | 127 - .../ksh93/src/lib/libast/vmalloc/vmhdr.h | 437 -- .../ksh93/src/lib/libast/vmalloc/vmlast.c | 394 -- .../ksh93/src/lib/libast/vmalloc/vmopen.c | 177 - .../ksh93/src/lib/libast/vmalloc/vmpool.c | 332 - .../ksh93/src/lib/libast/vmalloc/vmprivate.c | 298 - .../ksh93/src/lib/libast/vmalloc/vmprofile.c | 716 -- .../ksh93/src/lib/libast/vmalloc/vmregion.c | 60 - .../ksh93/src/lib/libast/vmalloc/vmsegment.c | 77 - .../ksh93/src/lib/libast/vmalloc/vmset.c | 86 - .../ksh93/src/lib/libast/vmalloc/vmstat.c | 136 - .../ksh93/src/lib/libast/vmalloc/vmstrdup.c | 106 - .../ksh93/src/lib/libast/vmalloc/vmtrace.c | 180 - .../dtksh/ksh93/src/lib/libcmd/Makefile | 22 - .../dtksh/ksh93/src/lib/libcmd/Mamfile | 423 -- .../dtksh/ksh93/src/lib/libcmd/RELEASE | 12 - .../dtksh/ksh93/src/lib/libcmd/basename.c | 149 - cde/programs/dtksh/ksh93/src/lib/libcmd/cat.c | 354 - .../dtksh/ksh93/src/lib/libcmd/chgrp.c | 386 - .../dtksh/ksh93/src/lib/libcmd/chmod.c | 205 - .../dtksh/ksh93/src/lib/libcmd/chown.c | 103 - cde/programs/dtksh/ksh93/src/lib/libcmd/cmd.h | 129 - .../dtksh/ksh93/src/lib/libcmd/cmdinit.c | 102 - .../dtksh/ksh93/src/lib/libcmd/cmdlib.h | 113 - .../dtksh/ksh93/src/lib/libcmd/cmdrecurse.c | 122 - cde/programs/dtksh/ksh93/src/lib/libcmd/cmp.c | 281 - .../dtksh/ksh93/src/lib/libcmd/comm.c | 235 - cde/programs/dtksh/ksh93/src/lib/libcmd/cut.c | 469 -- .../dtksh/ksh93/src/lib/libcmd/dirname.c | 147 - .../dtksh/ksh93/src/lib/libcmd/feature/ids | 2 - .../ksh93/src/lib/libcmd/feature/utsname | 3 - .../dtksh/ksh93/src/lib/libcmd/features/ids | 8 - .../ksh93/src/lib/libcmd/features/symlink | 8 - .../ksh93/src/lib/libcmd/features/utsname | 3 - .../dtksh/ksh93/src/lib/libcmd/fold.c | 234 - .../dtksh/ksh93/src/lib/libcmd/getconf.c | 171 - .../dtksh/ksh93/src/lib/libcmd/head.c | 157 - cde/programs/dtksh/ksh93/src/lib/libcmd/id.c | 501 -- .../dtksh/ksh93/src/lib/libcmd/join.c | 575 -- .../dtksh/ksh93/src/lib/libcmd/logname.c | 128 - .../dtksh/ksh93/src/lib/libcmd/mkdir.c | 173 - .../dtksh/ksh93/src/lib/libcmd/mkfifo.c | 136 - .../dtksh/ksh93/src/lib/libcmd/paste.c | 255 - .../dtksh/ksh93/src/lib/libcmd/pathchk.c | 246 - cde/programs/dtksh/ksh93/src/lib/libcmd/rev.c | 168 - .../dtksh/ksh93/src/lib/libcmd/revlib.c | 177 - .../dtksh/ksh93/src/lib/libcmd/rmdir.c | 121 - .../dtksh/ksh93/src/lib/libcmd/tail.c | 350 - cde/programs/dtksh/ksh93/src/lib/libcmd/tee.c | 207 - cde/programs/dtksh/ksh93/src/lib/libcmd/tty.c | 127 - .../dtksh/ksh93/src/lib/libcmd/uname.c | 482 -- .../dtksh/ksh93/src/lib/libcmd/uniq.c | 292 - cde/programs/dtksh/ksh93/src/lib/libcmd/wc.c | 197 - cde/programs/dtksh/ksh93/src/lib/libcmd/wc.h | 123 - .../dtksh/ksh93/src/lib/libcmd/wclib.c | 179 - .../dtksh/ksh93/src/lib/libodelta/Makefile | 12 - .../dtksh/ksh93/src/lib/libodelta/Mamfile | 106 - .../dtksh/ksh93/src/lib/libodelta/delta.c | 534 -- .../ksh93/src/lib/libodelta/mtchstring.c | 239 - .../dtksh/ksh93/src/lib/libodelta/suftree.c | 427 -- .../dtksh/ksh93/src/lib/libodelta/suftree.h | 145 - .../dtksh/ksh93/src/lib/libodelta/update.c | 274 - .../dtksh/ksh93/src/lib/libodelta/update.h | 121 - .../dtksh/ksh93/src/lib/libvdelta/Makefile | 6 - .../dtksh/ksh93/src/lib/libvdelta/Mamfile | 153 - .../dtksh/ksh93/src/lib/libvdelta/vddelta.c | 518 -- .../dtksh/ksh93/src/lib/libvdelta/vdelhdr.h | 271 - .../dtksh/ksh93/src/lib/libvdelta/vdelta.3 | 83 - .../dtksh/ksh93/src/lib/libvdelta/vdelta.h | 114 - .../dtksh/ksh93/src/lib/libvdelta/vdio.c | 229 - .../dtksh/ksh93/src/lib/libvdelta/vdupdate.c | 433 -- 871 files changed, 192840 deletions(-) delete mode 100644 cde/programs/dtksh/ksh93/Imakefile delete mode 100644 cde/programs/dtksh/ksh93/ship/README delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/930519/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/930519/base delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/930519/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/930519/items delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/930519/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950619/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950619/base delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950619/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950619/items delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950619/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/base delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/items delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/message delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/promo delete mode 100644 cde/programs/dtksh/ksh93/ship/ksh93/950807/report delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950509/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950509/base delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950509/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950509/items delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950509/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/lib0ast/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libAST/930519/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libAST/930519/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libAST/930519/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libAST/930519/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libAST/930519/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/930716/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/930716/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/930716/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/930716/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/930716/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950620/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950620/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950620/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950620/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950620/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libast/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/930527/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/930527/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/930527/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/930527/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/930527/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950620/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950620/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950620/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950620/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950620/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libcmd/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/930125/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/930125/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/930125/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/930125/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/930125/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950509/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950509/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950509/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950509/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950509/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libodelta/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950509/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950509/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950509/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950509/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950509/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/libvdelta/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/930716/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/930716/base delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/930716/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/930716/items delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/930716/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950620/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950620/base delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950620/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950620/items delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950620/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/UNCRATED delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/base delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/copyright delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/items delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/owner delete mode 100644 cde/programs/dtksh/ksh93/ship/pax/950811/promo delete mode 100644 cde/programs/dtksh/ksh93/ship/shipfeature.sh delete mode 100644 cde/programs/dtksh/ksh93/ship/shipiffe.sh delete mode 100755 cde/programs/dtksh/ksh93/ship/shipin delete mode 100644 cde/programs/dtksh/ksh93/ship/shipop.c delete mode 100755 cde/programs/dtksh/ksh93/ship/shipout delete mode 100644 cde/programs/dtksh/ksh93/ship/shipproto.c delete mode 100644 cde/programs/dtksh/ksh93/src/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/COMPATIBILITY delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/OBSOLETE delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/OPTIONS delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/PROMO delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/README delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASE delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASEa delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/alarm.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cd_pwd.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cflow.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getconf.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getopts.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/hist.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/misc.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/print.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/read.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/sleep.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/test.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/trap.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/typeset.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/ulimit.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/umask.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/whence.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/builtins.mm delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/aliases.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/builtins.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/config.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/keywords.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/lexstates.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/limits.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/msg.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/options.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/signals.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/strdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/testops.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/data/variables.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/edit/completion.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/edit/edit.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/edit/emacs.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/edit/history.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/edit/vi.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/cmds delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/dynamic delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/externs delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/locale delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/options.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/poll delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/rlimits delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/setjmp delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/sigfeatures delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/time delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/feature/ttys delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/cmds delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/dynamic delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/externs delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/locale delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/options.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/poll delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/rlimits delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/setjmp delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/sigfeatures delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/time delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/features/ttys delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/grep.mm delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/argnod.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/builtins.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/defs.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/edit.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/fault.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/fcin.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/history.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/io.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/jobs.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/lexstates.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/name.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/national.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/nval.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/path.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/shell.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/shlex.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/shnodes.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/shtable.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/streval.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/terminal.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/test.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/timeout.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/ulimit.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/include/variables.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/ksh.mk delete mode 100755 cde/programs/dtksh/ksh93/src/cmd/ksh93/mamexec delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/mamstate.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/nval.3 delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh.1 delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh.memo delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/args.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/arith.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/array.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/defs.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/deparse.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/dlopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/expand.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/fault.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/fcin.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/init.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/io.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/jobs.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/lex.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/macro.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/main.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/name.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/parse.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/path.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/shcomp.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/streval.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/string.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/subshell.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/suid_exec.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/tdump.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/timers.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/trestore.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/userinit.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/vfork.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/waitevent.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/sh/xec.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/alias.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/arith.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/arrays.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/attributes.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/basic.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/bracket.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/builtins.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/case.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/comvar.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/coprocess.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/exit.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/functions.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/grep.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/heredoc.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/io.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/nameref.sh delete mode 100755 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/options.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/quoting.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/return.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/select.sh delete mode 100755 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/shtests delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/substring.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/tilde.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/ksh93/tests/variables.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/HISTORY delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/RELEASE delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/bax.1 delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/bax.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/bio.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/cia.fmt delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/ciadb.fmt delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/convert.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/copy.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/cpio.sh delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/delta.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/fgetline.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/file.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/format.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/misc.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/nocom.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/options.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/pax.1 delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/pax.1.posix delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/pax.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/pax.h delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/ppar.fmt delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/stubs.c delete mode 100644 cde/programs/dtksh/ksh93/src/cmd/pax/tar.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/C.probe delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/PROBE.mk delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/RELEASE delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/hostinfo.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/lib0ast/hosttype.tst delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libAST/C.probe delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libAST/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libAST/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libAST/PROBE.mk delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/README delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/RELEASE delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/atexit.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/conf.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/conf.tab delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/dup2.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/errno.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/execve.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/fcntl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/getgroups.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/getpgrp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/getwd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/killpg.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/link.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/lstat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memccpy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memchr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memcmp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memcpy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memmove.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/memset.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/mkdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/mkfifo.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/mknod.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/mktemp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/mount.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/open.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/pathconf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/readlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/remove.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/rename.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/rmdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/setlocale.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/setpgid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/setsid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/sigsetmask.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/sigunblock.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/spawnve.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/spawnveg.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/statvfs.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/strchr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/strrchr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/strtod.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/strtol.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/strtoul.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/symlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/sysconf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/system.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/tmpnam.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/unlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/vfork.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/comp/waitpid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/conf.tab delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/dirlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/dirnsys.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/dirstd.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/dirsys.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/getdents.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/opendir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/readdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/rewinddir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/seekdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/dir/telldir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/disc/sfkeyprintf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/disc/sfslowio.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/align.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/botch.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/fcntl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/fs delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/hdr delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/int.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/lib delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/limits.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/mode.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/param.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/preroot.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/sfio delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/sig.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/signal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/time delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/tty delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/types delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/unistd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/feature/wait delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/align.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/botch.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/fcntl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/fs delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/hdr delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/int.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/lib delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/limits.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/mode.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/param.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/preroot.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/sfio delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/sig.sh delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/signal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/time delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/tty delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/types delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/unistd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/vmalloc delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/features/wait delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashalloc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashdump.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashfree.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashlast.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashlook.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashscan.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/hashwalk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/memhash.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/memsum.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/strhash.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/hash/strsum.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/ast.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/ast_dir.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/ast_std.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/debug.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/error.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/find.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/fs3d.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/ftwalk.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/hash.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/hashpart.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/ls.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/magic.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/modecanon.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/modex.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/namval.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/national.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/option.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/proc.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/re.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/sfdisc.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/sfio.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/sfstr.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/stack.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/stak.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/stdio.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/stk.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/swap.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/tar.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/times.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/tm.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/tok.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/vdb.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/vecargs.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/vmalloc.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/include/wait.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/LIBAST.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/ast.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/chr.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/compatibility.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/error.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/find.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/fmt.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/fmtls.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/fs3d.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/ftwalk.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/getcwd.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/hash.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/iblocks.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/int.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/magic.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/mem.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/modecanon.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/optget.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/path.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/preroot.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/proc.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/re.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/setenviron.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/sfdisc.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/sfio.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/sig.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/spawnveg.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/stak.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/stk.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strcopy.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strdup.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strelapsed.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strerror.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/stresc.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/streval.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strgid.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strmatch.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/stropt.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strperm.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strsignal.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strsort.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strtape.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/strton.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/struid.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/swap.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/tab.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/tm.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/tok.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/touch.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/vecargs.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/man/vmalloc.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/calloc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/cmdclose.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/cmdkill.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/cmdlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/cmdopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/cmdrun.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/error.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/fastfind.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/fs3d.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/ftwalk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/ftwflags.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/getcwd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/getpath.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/getshell.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/getsymlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/getuniv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/hsort.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/liberror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/lpstat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/magic.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/magic.tab delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/malloc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/nomalloc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/optdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/optget.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/optjoin.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathaccess.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathcanon.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathcat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathcheck.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathkey.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathpath.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathprobe.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathrepl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/pathtemp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/procclose.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/procfree.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/proclib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/procopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/procrun.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/putenv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/putsymlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/query.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/setcwd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/setenv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/setenviron.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/setuniv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/sigcrit.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/sigdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/signal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/slowio.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/stack.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/stak.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/state.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/stk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/systrace.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/univdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/misc/univlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/astfeature.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdclose.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdkill.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdproc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/cmdrun.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/copy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/ctoi.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/fclex.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/fdcopy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/fgetline.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/gethalf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getlong.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getpath.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getshell.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getsymlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getuniv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/getwinsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/hsort.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/lexline.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/lexscan.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/lpstat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/memswap.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/puthalf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/putlong.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/putsymlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/query.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/setcwd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/setenv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/setuniv.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/slowio.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/strerror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/strsignal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/swapdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/tablook.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/tblocks.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/obsolete/winsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathaccess.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathbin.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathcanon.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathcat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathcd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathcheck.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathgetlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathkey.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathpath.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathprobe.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathrepl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathsetlink.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathshell.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathstat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/path/pathtemp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/astconf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/astcopy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/astquery.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/astwinsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/fdcopy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/getwinsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/iblocks.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/sigdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/port/touch.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/preroot/getpreroot.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/preroot/ispreroot.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/preroot/realopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/preroot/setpreroot.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/recomp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/reerror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/reexec.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/relib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/ressub.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/re/resub.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfclrerr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfecvt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfeof.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sferror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sffcvt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sffileno.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfgetc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfgetl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfgetu.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfhdr.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfputc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfputd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfputl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfputu.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfslen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfstacked.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/_sfulen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfclose.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfclrlock.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfcvt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfdisc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfdlen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfecvt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfexcept.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfextern.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sffcvt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sffilbuf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfflsbuf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfgetd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfgetl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfgetr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfgetu.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfhdr.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfio_t.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfllen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfmode.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfmove.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfnew.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfnotify.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfnputc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpeek.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpkrd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpoll.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpool.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfprintf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfprints.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfpurge.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfputd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfputl.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfputr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfputu.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfrd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfread.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfreserve.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfscanf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfseek.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfset.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfsetbuf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfsetfd.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfsize.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfsk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfstack.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfstrtod.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfswap.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfsync.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sftable.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sftell.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sftmp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfungetc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfvprintf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfvscanf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfwr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/sfio/sfwrite.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdgets.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdprintf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdscanf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdsprnt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdvbuf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdvsnprnt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdvsprnt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/stdio/stdvsscn.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/chresc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/chrtoi.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtbase.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtdev.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtelapsed.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmterror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtesc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtfs.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtgid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtls.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtmatch.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtmode.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtperm.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtre.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtsignal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmttime.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/fmtuid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/mematoe.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/memdup.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/memetoa.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/modedata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/modei.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/modelib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/modex.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strcopy.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strdup.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strelapsed.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strerror.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/stresc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/streval.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strexpr.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strgid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strlook.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strmatch.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strmode.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/stropt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strperm.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strsignal.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strsort.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strtape.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/strton.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/struid.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/swapget.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/swapmem.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/swapop.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/swapput.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/tabindex.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/tablook.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/tok.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/tokline.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/string/tokscan.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmdata.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmdate.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmfix.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmfmt.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmform.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmgoff.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tminit.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmleap.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmlex.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmmake.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmpoff.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmtime.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmtype.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmword.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/tm/tmzone.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vec/vecargs.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vec/vecfile.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vec/vecfree.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vec/vecload.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vec/vecstring.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/malloc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmbest.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmclear.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmclose.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmdcheap.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmdcsbrk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmdebug.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmdisc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmexit.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmhdr.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmlast.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmopen.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmpool.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmprivate.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmprofile.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmregion.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmsegment.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmset.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmstat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmstrdup.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libast/vmalloc/vmtrace.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/RELEASE delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/basename.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cat.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/chgrp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/chmod.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/chown.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cmd.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cmdinit.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cmdlib.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cmdrecurse.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cmp.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/comm.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/cut.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/dirname.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/feature/ids delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/feature/utsname delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/features/ids delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/features/symlink delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/features/utsname delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/fold.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/getconf.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/head.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/id.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/join.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/logname.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/mkdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/mkfifo.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/paste.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/pathchk.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/rev.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/revlib.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/rmdir.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/tail.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/tee.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/tty.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/uname.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/uniq.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/wc.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/wc.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libcmd/wclib.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/delta.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/mtchstring.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/suftree.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/suftree.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/update.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libodelta/update.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/Makefile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/Mamfile delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vddelta.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vdelhdr.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vdelta.3 delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vdelta.h delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vdio.c delete mode 100644 cde/programs/dtksh/ksh93/src/lib/libvdelta/vdupdate.c diff --git a/cde/programs/dtksh/ksh93/Imakefile b/cde/programs/dtksh/ksh93/Imakefile deleted file mode 100644 index 91e6f1aeb..000000000 --- a/cde/programs/dtksh/ksh93/Imakefile +++ /dev/null @@ -1,73 +0,0 @@ -XCOMM $XConsortium: Imakefile /main/7 1996/05/09 17:33:38 drk $ -LOCAL_LIBRARIES = -SRCS = -SUBCFLAGS = -O -UFLAGS = $(SUBCFLAGS) -ULDFLAGS = -IFFECDEBUGFLAGS = -O0 - -#ifdef RsArchitecture -CCFLAGS = CCFLAGS=" " -#else -CCFLAGS = -#endif - -#ifdef SunArchitecture -.NO_PARALLEL: -#endif /* SunArchitecture */ - -FORCE_SHIP = -F - -MALLOCOBJ = - -KSHSRC = ./src/cmd/ksh93 - -KSHLIBS = \ - $(KSHSRC)/../../lib/libcmd/libcmd.a - -KSH_OBJS = \ - $(KSHSRC)/main.o \ - $(KSHSRC)/timers.o \ - $(KSHLIBS) - -OBJS = $(KSH_OBJS) $(KSH_LIBS) - -SUIDEXECDEFINES = \ - -DPROFILEPATH=\"$(CDE_CONFIGURATION_TOP)/config/profile\" \ - -DSUIDPROFILEPATH=\"$(CDE_CONFIGURATION_TOP)/config/suid_profile\" \ - -DSUIDEXECPATH=\"$(CDE_INSTALLATION_TOP)/bin/suid_exec\" \ - -DCDE_INSTALLATION_TOP=\"$(CDE_INSTALLATION_TOP)\" - -CCFLAGS = $(CDEBUGFLAGS) $(SUIDEXECDEFINES) $(STD_DEFINES) $(ANSI_DEFINES) -ICCFLAGS = $(IFFECDEBUGFLAGS) $(STD_DEFINES) $(ANSI_DEFINES) - -all:: ksh93src ksh93.o - -XCOMM -XCOMM A temporary hack until we get Imakefiles in the base of ksh-93. -XCOMM -XCOMM We test for presense of /bin/ksh because on HP/UX there is a -XCOMM limitation in the size of environment variables that prevents the -XCOMM ksh-93 build scripts from functioning. That will be worked around -XCOMM in a near future release of ksh-93 as well, but then again this -XCOMM whole target will change anyway. -XCOMM - -SHIP_DIR = ship -ALL_SUBS = * - -ksh93src: - $(RM) $(SHIP_DIR)/$(ALL_SUBS)/$(ALL_SUBS)/BUILT; \ - SHELL=$(KORNSHELL) CC="$(CC)" CCFLAGS="$(CCFLAGS)" ICCFLAGS="$(ICCFLAGS)" $(KORNSHELL) ship/shipin $(FORCE_SHIP) - -ksh93.o: $(OBJS) - $(LD) -r -o $@ $(OBJS) - -clobber:: clobmine - -clobmine: - $(RM) -f libksh93.a - -depend:: - -install:: diff --git a/cde/programs/dtksh/ksh93/ship/README b/cde/programs/dtksh/ksh93/ship/README deleted file mode 100644 index 81894296e..000000000 --- a/cde/programs/dtksh/ksh93/ship/README +++ /dev/null @@ -1,154 +0,0 @@ -/* $XConsortium: README /main/2 1996/07/15 14:13:29 drk $ */ -Software shipment information. [better documentation forthcoming ...] - -All files and directories, except for those in /var/spool/uucppublic, -are rooted at the shipment/installation directory named by -$INSTALLROOT. The $INSTALLROOT hierarchy is similar to the System V -/usr hierarchy. - -The $INSTALLROOT/ship subdirectory is automatically maintained by -shipin and shipout. If you expect to receive future shipments then -do not change files in this directory. - -pax is the Bell Labs implementation of the proposed POSIX (01/90) -portable archive interchange command. The default output format is -`cpio -c'. The pax delta format is a Bell Labs extension. - -The following assumes: - - INSTALLROOT= - -After each shipment: - - - cd $INSTALLROOT - ship/shipin - -`ship/shipin -n' shows actions but does not unbundle or build. -`ship/shipin -s ' unbundles from rather than /var/spool/uucppublic. -`ship/shipin -u' unbundles the shipment but does not build. -`ship/shipin -i' copies from spool area but does not unbundle or build. -`ship/shipin -E' rebuild components that failed last time (use after fixes). - -Any non-option arguments to shipin are passed as arguments to the -generating make or shell script for each component. - -To pass the shipment to another machine (requires ksh): - - # rcp # TO=host:ship - # uucp # TO=machine!user - # list of files # TO=%list - # remote dk pull script # TO=%pull - cd $INSTALLROOT - ship/shipin -i # if not installed on this machine - cd ship - shipout $TO - -{rcp,uucp} initiate copies whereas {list,pull} generate information on -stdout. {uucp} copies to an intermediate spool area on the other machine -whereas {rcp,list,pull} are relative to $INSTALLROOT on the other machine. - -To copy a command from $INSTALLROOT to a new root you must copy: - - $INSTALLROOT/bin/ - $INSTALLROOT/lib/ - -to the new root directory for all interdependent 's. Depending on -, only one of the above files/directories may exist. - -Be sure to maintain a different $INSTALLROOT for each machine architecture. -If the same $INSTALLROOT/ship must be reused for a different architecture -then delete everything except ship from $INSTALLROOT and run ship/shipin -F. -An alternative would be to use nmake and optionally 3d to viewpath a new -architecture hierarchy on top of $INSTALLROOT. In this case nmake would -be run from within the $INSTALLROOT/src/(cmd|lib) hierarchy. - -The files below may appear on the shipment side, the installation side, -or both. and are defined in the -shipment mail announcement. - -Each shipment is identified by a two part version number [R]YYMMDD - - R release -- if specified then it must match for compatibility - YYMMDD shipment year, month and day number - -/var/spool/uucppublic// directory hierarchy: - - . shipment control directory - ./manifest list of all files in shipment - -$INSTALLROOT directory hierarchy: - - bin/ executable binaries and scripts - include/ common header files - lib/ object archives a common data - man/ man page subtree - man1/ command man pages - man3/ library man pages - man8/ adminstration and maintenance man pages - src/ source subtree - cmd/ command source - lib/ library source - ship/ shipment and installation info - -$INSTALLROOT/ship contents: - - README installation info - ! shipment installation message for machine!user - ship.body optional shipment announcement main body - ship.head optional shipment announcement header - ship.tail optional shipment announcement trailer - shipcost show relative cost of delta/update shipment - shipcrate crate all components for shipout - shipin unbundle, build and install shipment - shiplist shipout using name-tool list - shipop shipin/shipout support executable - shipout split and send shipment - shipslog shipment log and recipient address info - shipswab clean old stuff from the ship area - shipyard shipment support tools component name - lib* library components - * command components - -$INSTALLROOT/ship/ contents: - - <[R]YYMMDD> information for the <[R]YYMMDD> shipment - base link to the newest pax base archive - delta link to the newest pax delta archive - in.log shipin log - items required components (excluding this one) - list optional list of persons to send to - message optional message to include in shipment announcement - owner mail address for installation report - release the the current shipment release number - report optional list of $INSTALLROOT relative files to report - -$INSTALLROOT/ship//<[R]YYMMDD> contents: - - <[R]YYMMDD> pax delta archive for ../[R]YYMMDD/base - <[R]YYMMDD>. delta archive split for uucp - BUILT present if release build succeeded - ERROR present if release build failed - GENERATED present if base archive was generated from a delta - UNCRATED present if release uncrate succeeded - base pax base archive - base. base archive split for uucp - items items for this release - message message for this release - owner owner for this release - report report for this release - -Each component $NAME is extracted into either $INSTALLROOT/src/lib/$NAME -or $INSTALLROOT/src/cmd/$NAME. The following are attempted, in order, -to build and install $NAME under $INSTALLROOT: - - $INSTALLROOT/bin/nmake -f Makefile install - mamexec install < Mamfile # mamexec is built into ship/shipin - make -f makefile install - sh Makescript - -where Mamfile, Makescript and makefile are usually generated from the -corresponding nmake Makefile. - - Glenn Fowler ulysses!gsf - David Korn ulysses!dgk diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/930519/UNCRATED b/cde/programs/dtksh/ksh93/ship/ksh93/930519/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/930519/base b/cde/programs/dtksh/ksh93/ship/ksh93/930519/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/930519/copyright b/cde/programs/dtksh/ksh93/ship/ksh93/930519/copyright deleted file mode 100644 index 2f17b10b2..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/930519/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{ulysses,attmail}!dgk -dgk@ulysses.att.com -David Korn 908-582-7975 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/930519/items b/cde/programs/dtksh/ksh93/ship/ksh93/930519/items deleted file mode 100644 index bc0708727..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/930519/items +++ /dev/null @@ -1 +0,0 @@ -libcmd libast diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/930519/owner b/cde/programs/dtksh/ksh93/ship/ksh93/930519/owner deleted file mode 100644 index fe2fd3391..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/930519/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!dgk diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950619/UNCRATED b/cde/programs/dtksh/ksh93/ship/ksh93/950619/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950619/base b/cde/programs/dtksh/ksh93/ship/ksh93/950619/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950619/copyright b/cde/programs/dtksh/ksh93/ship/ksh93/950619/copyright deleted file mode 100644 index 2f17b10b2..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950619/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{ulysses,attmail}!dgk -dgk@ulysses.att.com -David Korn 908-582-7975 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950619/items b/cde/programs/dtksh/ksh93/ship/ksh93/950619/items deleted file mode 100644 index bc0708727..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950619/items +++ /dev/null @@ -1 +0,0 @@ -libcmd libast diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950619/owner b/cde/programs/dtksh/ksh93/ship/ksh93/950619/owner deleted file mode 100644 index fe2fd3391..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950619/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!dgk diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/UNCRATED b/cde/programs/dtksh/ksh93/ship/ksh93/950807/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/base b/cde/programs/dtksh/ksh93/ship/ksh93/950807/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/copyright b/cde/programs/dtksh/ksh93/ship/ksh93/950807/copyright deleted file mode 100644 index 4274c7e18..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{research,attmail}!dgk -dgk@research.att.com -David Korn 908-582-7975 diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/items b/cde/programs/dtksh/ksh93/ship/ksh93/950807/items deleted file mode 100644 index bc0708727..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/items +++ /dev/null @@ -1 +0,0 @@ -libcmd libast diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/message b/cde/programs/dtksh/ksh93/ship/ksh93/950807/message deleted file mode 100644 index b3ff1a69c..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/message +++ /dev/null @@ -1,32 +0,0 @@ -The is the fourth point release for ksh-93. The RELEASEa -file contains a list of changes since the first release for ksh-93. -The file RELEASE lists the major changes since ksh-88. I have updated -the man page, sh.1, and the introductory memo, sh.memo. I have also -started to write a guideline for adding runtime builtins, builtins.mm. -This release should correspond very closely to the information in the -New KornShell Command and Programming Language book, by Bolsky -and Korn. - -This official release is being distributed and supported by the -Software Technology Center. They are the distributor of -ksh93 within AT&T and will provide support. I will only be -supplying ksh93 for research needs and for machine architectures -that are not supported by the Software Technology Center. -You can contact the STC by sending mail to ksh@mozart.att.com. - -I have fixed most of the bugs that have been reported in -the previous release. Let me know about any remaining bugs. - -There continues to be very few reports of compatibility -problems. The file COMPATIBILITY lists the known incompatibilities. -Please let me know about any script which runs under ksh-88 but -does not run under ksh-93. - -Please look at the man page (troff -man) and the sh.memo -file (troff -mm) and let me know what problems you find. - -I encourage you to run ksh -n script on each of your scripts -since the -n option produces warning messages for obsolete -features that you are using in the script. The file -OBSOLETE, written by Kevin Wall, contains a list of -obsolete features. diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/owner b/cde/programs/dtksh/ksh93/ship/ksh93/950807/owner deleted file mode 100644 index 42d7a55dc..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/owner +++ /dev/null @@ -1 +0,0 @@ -dgk diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/promo b/cde/programs/dtksh/ksh93/ship/ksh93/950807/promo deleted file mode 100644 index ac25656f4..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/promo +++ /dev/null @@ -1,146 +0,0 @@ -.SA 1 -.sp 2 -.H 1 "KSH-93 - The KornShell Command and Programming Language" -.sp 2 -.al -.P -KSH-93 is the most recent version of the KornShell Language -described in -"The KornShell Command and Programming Language," -by Morris Bolsky and David Korn of AT&T Bell Laboratories. -The KornShell is a shell programming language, -which is upward compatible with "sh" (the Bourne Shell), -and is intended to conform to the IEEE P1003.2/ISO 9945.2 Shell and -Utilities standard. -KSH-93 provides an enhanced programming environment in -addition to the major command-entry features of the BSD -shell "csh". With KSH-93, medium-sized programming tasks can be -performed at shell-level without a significant loss in performance. -In addition, "sh" scripts can be run on KSH-93 without modification. -.P -The code should conform to the IEEE POSIX 1003.1 standard and to the -proposed ANSI-C standard so that it should be portable to all -such systems. Like the previous version, KSH-88, -it is designed to accept eight bit character sets -transparently, thereby making it internationally compatible. -It can support multi-byte characters sets with some characteristics -of the character set given at run time. -.P -KSH-93 provides the following features, many of which were also inherent -in KSH-88: -.BL -.LI -Enhanced Command Re-entry Capability: The KSH-93 history -function records commands entered at any shell level and stores -them, up to a user-specified limit, even after you log off. -This allows you to re-enter long commands with a few keystrokes -- even those commands you entered yesterday. -The history file allows for eight bit characters in -commands and supports essentially unlimited size histories. -.LI -In-line Editing: In "sh", the only way to fix mistyped -commands is to backspace or retype the line. KSH-93 allows you -to edit a command line using a choice of EMACS-TC or "vi" -functions. -You can use the in-line editors to complete filenames as -you type them. -You may also use this editing feature when entering -command lines from your history file. -A user can capture keystrokes and rebind keys to customize the -editing interface. -.LI -Extended I/O Capabilities: KSH-93 provides several I/O -capabilities not available in "sh", including the ability to: -.BL -.LI -specify a file descriptor for input and output -.LI -start up and run co-processes -.LI -produce a prompt at the terminal before a read -.LI -easily format and interpret responses to a menu -.LI -echo lines exactly as output without escape processing -.LI -format output using printf formats. -.LI -read and echo lines ending in "\e". -.LE -.LI -Improved performance: KSH-93 executes many scripts faster -than the System V Bourne shell. A major reason for this is -that many of the standard utilities are built-in. -To reduce the time to initiate a command, KSH-93 allows -commands to be added as built-ins at run time -on systems that support dynamic loading such as System V Release 4. -.LI -Arithmetic: KSH-93 allows you to do integer arithmetic in any -base from two to sixty-four. You can also do double -precision floating point arithmetic. -Almost the complete set of C language operators are available -with the same syntax and precedence. -Arithmetic expressions can be used to as an argument expansion -or as a separate command. -In addition there is an arithmetic for command that works -like the for statement in C. -.LI -Arrays: KSH-93 supports both indexed and associative arrays. -The subscript for an indexed array is an arithmetic expression, -whereas, the subscript for an associative array is a string. -.LI -Shell Functions and Aliases: Two mechanisms - functions and -aliases - can be used to assign a user-selected identifier to -an existing command or shell script. -Functions allow local variables and provide scoping -for exception handling. -Functions can be searched for and loaded on first reference the -way scripts are. -.LI -Substring Capabilities: KSH-93 allows you to create a -substring of any given string either by specifying the starting -offset and length, or by stripping off leading -or trailing substrings during parameter substitution. -You can also specify attributes, such as upper and lower case, -field width, and justification to shell variables. -.LI -More pattern matching capabilities: KSH-93 allows you to specify -extended regular expressions for file and string matches. -.LI -KSH-93 uses a hierarchal name space for variables. -Compound variables can be defined and variables can -be passed by reference. In addition, each variable -can have one or more disciplines associated with -it to intercept assignments and references. -.LI -Improved debugging: KSH-93 can generate line numbers on execution -traces. Also, I/O redirections are now traced. -There is a DEBUG trap that gets evaluated after each command -so that errors can be localized. -.LI -Job Control: On systems that support job control, including -System V Release 4, KSH-93 -provides a job-control mechanism almost identical to that of -the BSD "csh", version 4.1. -This feature allows you -to stop and restart programs, and to move programs between the -foreground and the background. -.LI -Added security: -KSH-93 can execute scripts which do not have read permission -and scripts which have the setuid and/or setgid set when -invoked by name, rather than as an argument to the shell. -It is possible to log or control the execution of setuid and/or -setgid scripts. -The noclobber option prevents you from accidentally erasing -a file by redirecting to an existing file. -.LI -KSH-93 can be extended by adding built-in commands at run time. -In addition, KSH-93 can be used as a library that can -be embedded into an application to allow scripting. -.LE -Documentation for KSH-93 consists of an "Introduction to KSH-93", -"Compatibility with the Bourne Shell" and a manual page and a -README file. In addition, the "New KornShell Command and Programming -Language," book is available from Prentice Hall. - diff --git a/cde/programs/dtksh/ksh93/ship/ksh93/950807/report b/cde/programs/dtksh/ksh93/ship/ksh93/950807/report deleted file mode 100644 index d844d7101..000000000 --- a/cde/programs/dtksh/ksh93/ship/ksh93/950807/report +++ /dev/null @@ -1,5 +0,0 @@ -src/cmd/ksh93/FEATURE/options -src/cmd/ksh93/FEATURE/ttys -src/cmd/ksh93/FEATURE/dymamic -src/cmd/ksh93/FEATURE/externs -src/cmd/ksh93/FEATURE/poll diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/UNCRATED b/cde/programs/dtksh/ksh93/ship/lib0ast/950509/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/base b/cde/programs/dtksh/ksh93/ship/lib0ast/950509/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/copyright b/cde/programs/dtksh/ksh93/ship/lib0ast/950509/copyright deleted file mode 100644 index 2f17b10b2..000000000 --- a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{ulysses,attmail}!dgk -dgk@ulysses.att.com -David Korn 908-582-7975 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/items b/cde/programs/dtksh/ksh93/ship/lib0ast/950509/items deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950509/owner b/cde/programs/dtksh/ksh93/ship/lib0ast/950509/owner deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/lib0ast/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/base b/cde/programs/dtksh/ksh93/ship/lib0ast/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/copyright b/cde/programs/dtksh/ksh93/ship/lib0ast/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/items b/cde/programs/dtksh/ksh93/ship/lib0ast/950811/items deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/owner b/cde/programs/dtksh/ksh93/ship/lib0ast/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/lib0ast/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/libAST/930519/UNCRATED b/cde/programs/dtksh/ksh93/ship/libAST/930519/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libAST/930519/base b/cde/programs/dtksh/ksh93/ship/libAST/930519/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libAST/930519/copyright b/cde/programs/dtksh/ksh93/ship/libAST/930519/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/libAST/930519/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libAST/930519/items b/cde/programs/dtksh/ksh93/ship/libAST/930519/items deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libAST/930519/owner b/cde/programs/dtksh/ksh93/ship/libAST/930519/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libAST/930519/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libast/930716/UNCRATED b/cde/programs/dtksh/ksh93/ship/libast/930716/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/930716/base b/cde/programs/dtksh/ksh93/ship/libast/930716/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/930716/copyright b/cde/programs/dtksh/ksh93/ship/libast/930716/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/930716/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libast/930716/items b/cde/programs/dtksh/ksh93/ship/libast/930716/items deleted file mode 100644 index a22cc9071..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/930716/items +++ /dev/null @@ -1 +0,0 @@ -libAST diff --git a/cde/programs/dtksh/ksh93/ship/libast/930716/owner b/cde/programs/dtksh/ksh93/ship/libast/930716/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/930716/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libast/950620/UNCRATED b/cde/programs/dtksh/ksh93/ship/libast/950620/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/950620/base b/cde/programs/dtksh/ksh93/ship/libast/950620/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/950620/copyright b/cde/programs/dtksh/ksh93/ship/libast/950620/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950620/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libast/950620/items b/cde/programs/dtksh/ksh93/ship/libast/950620/items deleted file mode 100644 index d34139bcc..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950620/items +++ /dev/null @@ -1 +0,0 @@ -lib0ast diff --git a/cde/programs/dtksh/ksh93/ship/libast/950620/owner b/cde/programs/dtksh/ksh93/ship/libast/950620/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950620/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libast/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/libast/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/950811/base b/cde/programs/dtksh/ksh93/ship/libast/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libast/950811/copyright b/cde/programs/dtksh/ksh93/ship/libast/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/libast/950811/items b/cde/programs/dtksh/ksh93/ship/libast/950811/items deleted file mode 100644 index d34139bcc..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950811/items +++ /dev/null @@ -1 +0,0 @@ -lib0ast diff --git a/cde/programs/dtksh/ksh93/ship/libast/950811/owner b/cde/programs/dtksh/ksh93/ship/libast/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/libast/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/930527/UNCRATED b/cde/programs/dtksh/ksh93/ship/libcmd/930527/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/930527/base b/cde/programs/dtksh/ksh93/ship/libcmd/930527/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/930527/copyright b/cde/programs/dtksh/ksh93/ship/libcmd/930527/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/930527/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/930527/items b/cde/programs/dtksh/ksh93/ship/libcmd/930527/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/930527/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/930527/owner b/cde/programs/dtksh/ksh93/ship/libcmd/930527/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/930527/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950620/UNCRATED b/cde/programs/dtksh/ksh93/ship/libcmd/950620/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950620/base b/cde/programs/dtksh/ksh93/ship/libcmd/950620/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950620/copyright b/cde/programs/dtksh/ksh93/ship/libcmd/950620/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950620/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950620/items b/cde/programs/dtksh/ksh93/ship/libcmd/950620/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950620/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950620/owner b/cde/programs/dtksh/ksh93/ship/libcmd/950620/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950620/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/libcmd/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950811/base b/cde/programs/dtksh/ksh93/ship/libcmd/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950811/copyright b/cde/programs/dtksh/ksh93/ship/libcmd/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950811/items b/cde/programs/dtksh/ksh93/ship/libcmd/950811/items deleted file mode 100644 index d34139bcc..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950811/items +++ /dev/null @@ -1 +0,0 @@ -lib0ast diff --git a/cde/programs/dtksh/ksh93/ship/libcmd/950811/owner b/cde/programs/dtksh/ksh93/ship/libcmd/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/libcmd/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/930125/UNCRATED b/cde/programs/dtksh/ksh93/ship/libodelta/930125/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/930125/base b/cde/programs/dtksh/ksh93/ship/libodelta/930125/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/930125/copyright b/cde/programs/dtksh/ksh93/ship/libodelta/930125/copyright deleted file mode 100644 index 24958e992..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/930125/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{ulysses,attmail}!advsoft -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/930125/items b/cde/programs/dtksh/ksh93/ship/libodelta/930125/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/930125/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/930125/owner b/cde/programs/dtksh/ksh93/ship/libodelta/930125/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/930125/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950509/UNCRATED b/cde/programs/dtksh/ksh93/ship/libodelta/950509/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950509/base b/cde/programs/dtksh/ksh93/ship/libodelta/950509/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950509/copyright b/cde/programs/dtksh/ksh93/ship/libodelta/950509/copyright deleted file mode 100644 index 24958e992..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950509/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Advanced Software Technology Department -{ulysses,attmail}!advsoft -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950509/items b/cde/programs/dtksh/ksh93/ship/libodelta/950509/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950509/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950509/owner b/cde/programs/dtksh/ksh93/ship/libodelta/950509/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950509/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/libodelta/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950811/base b/cde/programs/dtksh/ksh93/ship/libodelta/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950811/copyright b/cde/programs/dtksh/ksh93/ship/libodelta/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950811/items b/cde/programs/dtksh/ksh93/ship/libodelta/950811/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950811/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libodelta/950811/owner b/cde/programs/dtksh/ksh93/ship/libodelta/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/libodelta/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/UNCRATED b/cde/programs/dtksh/ksh93/ship/libvdelta/950509/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/base b/cde/programs/dtksh/ksh93/ship/libvdelta/950509/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/copyright b/cde/programs/dtksh/ksh93/ship/libvdelta/950509/copyright deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/items b/cde/programs/dtksh/ksh93/ship/libvdelta/950509/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950509/owner b/cde/programs/dtksh/ksh93/ship/libvdelta/950509/owner deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/libvdelta/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/base b/cde/programs/dtksh/ksh93/ship/libvdelta/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/copyright b/cde/programs/dtksh/ksh93/ship/libvdelta/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/items b/cde/programs/dtksh/ksh93/ship/libvdelta/950811/items deleted file mode 100644 index 2822a733b..000000000 --- a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/items +++ /dev/null @@ -1 +0,0 @@ -libast diff --git a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/owner b/cde/programs/dtksh/ksh93/ship/libvdelta/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/libvdelta/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/pax/930716/UNCRATED b/cde/programs/dtksh/ksh93/ship/pax/930716/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/930716/base b/cde/programs/dtksh/ksh93/ship/pax/930716/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/930716/copyright b/cde/programs/dtksh/ksh93/ship/pax/930716/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/930716/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/pax/930716/items b/cde/programs/dtksh/ksh93/ship/pax/930716/items deleted file mode 100644 index 7f8eef32e..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/930716/items +++ /dev/null @@ -1 +0,0 @@ -libodelta libast diff --git a/cde/programs/dtksh/ksh93/ship/pax/930716/owner b/cde/programs/dtksh/ksh93/ship/pax/930716/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/930716/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/pax/950620/UNCRATED b/cde/programs/dtksh/ksh93/ship/pax/950620/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/950620/base b/cde/programs/dtksh/ksh93/ship/pax/950620/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/950620/copyright b/cde/programs/dtksh/ksh93/ship/pax/950620/copyright deleted file mode 100644 index bc3d33f5d..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950620/copyright +++ /dev/null @@ -1,5 +0,0 @@ -AT&T Bell Laboratories -Software Engineering Research Department -advsoft@research.att.com -Randy Hackbarth 908-582-5245 -Dave Belanger 908-582-7427 diff --git a/cde/programs/dtksh/ksh93/ship/pax/950620/items b/cde/programs/dtksh/ksh93/ship/pax/950620/items deleted file mode 100644 index beed98fbb..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950620/items +++ /dev/null @@ -1 +0,0 @@ -libvdelta libodelta libast diff --git a/cde/programs/dtksh/ksh93/ship/pax/950620/owner b/cde/programs/dtksh/ksh93/ship/pax/950620/owner deleted file mode 100644 index bef864759..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950620/owner +++ /dev/null @@ -1 +0,0 @@ -liszt!easy!liszt!easy!usl!att!gryphon!gsf diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/UNCRATED b/cde/programs/dtksh/ksh93/ship/pax/950811/UNCRATED deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/base b/cde/programs/dtksh/ksh93/ship/pax/950811/base deleted file mode 100644 index e69de29bb..000000000 diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/copyright b/cde/programs/dtksh/ksh93/ship/pax/950811/copyright deleted file mode 100644 index 9a8022bcd..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950811/copyright +++ /dev/null @@ -1,6 +0,0 @@ -type=proprietary -corporation=AT&T -company="Bell Laboratories" -organization="Software Engineering Research Department" -license=http://www.research.att.com/orgs/ssr/book/reuse -contact=gsf@research.att.com diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/items b/cde/programs/dtksh/ksh93/ship/pax/950811/items deleted file mode 100644 index beed98fbb..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950811/items +++ /dev/null @@ -1 +0,0 @@ -libvdelta libodelta libast diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/owner b/cde/programs/dtksh/ksh93/ship/pax/950811/owner deleted file mode 100644 index 6936b2c4f..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950811/owner +++ /dev/null @@ -1 +0,0 @@ -gsf diff --git a/cde/programs/dtksh/ksh93/ship/pax/950811/promo b/cde/programs/dtksh/ksh93/ship/pax/950811/promo deleted file mode 100644 index 2e9b8766f..000000000 --- a/cde/programs/dtksh/ksh93/ship/pax/950811/promo +++ /dev/null @@ -1,48 +0,0 @@ -.H 1 pax -.B pax -is a POSIX 1003.2 conformant replacement for -.B tar -and -.B cpio -that handles most UNIX archive and tape formats. -.B pax -uses the -.I vdelta -algorithm to construct efficient delta archives that contain bytewise -changes from a given base archive. -.B gzip -and -.B compress -archives are also handled on input and output. -.P -To create a -.I vdelta -compressed base archive: -.EX -tw | pax -w -f base -z - -.EE -To create a delta archive on the base above (record file changes only): -.EX -tw | pax -w -f delta -z base -.EE -To read the delta archive: -.EX -pax -r -f delta -z base -.EE -To create a delta archive from linux-1.2.0 to linux-1.2.5: -.EX -pax -rf linux-1.2.5.tar.gz -wf 0-5.pax.gz -x gzip -z linux-1.2.0.tar.gz -.EE -To create the linux-1.2.5 archive: -.EX -pax -rf 0-5.pax.gz -z linux-1.2.0.tar.gz -wf linux-1.2.5.tar.gz -x tar -x gzip -.EE -The -.B bax -script, shipped with -.BR pax , -combines -.B tw -and -.B pax -for handy backup control. diff --git a/cde/programs/dtksh/ksh93/ship/shipfeature.sh b/cde/programs/dtksh/ksh93/ship/shipfeature.sh deleted file mode 100644 index fc1a26be1..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipfeature.sh +++ /dev/null @@ -1,1131 +0,0 @@ -# $XConsortium: shipfeature.sh /main/2 1995/07/19 17:09:46 drk $ -: -# Glenn Fowler & Phong Vo -# AT&T Bell Laboratories -# -# C feature test support -# @(#)feature (AT&T Bell Laboratories) 03/01/94 -# -# NOTE: .exe a.out suffix and [\\/] in path patterns for dos/nt - -command=feature -version=03/01/94 - -binding="-Bdynamic -Bstatic -Wl,-ashared -Wl,-aarchive -call_shared -non_shared" -occ=cc -debug= -defhdr= -deflib= -executable='test -x' -gothdr= -gotlib= -dir=FEATURE -in= -out= -pragma= -case $RANDOM in -$RANDOM)shell=bsh - $executable . 2>/dev/null || executable='test -r' - ;; -*) shell=ksh - ;; -esac -static=. -statictest= -case $COTEMP in -"") case $HOSTNAME in - ""|?|??|???|????|????) - tmp=${HOSTNAME} - ;; - *) case $shell in - ksh) tmp=${HOSTNAME%${HOSTNAME#????}} ;; - *) eval `echo $HOSTNAME | sed 's/\(....\).*/tmp=\1/'` ;; - esac - ;; - esac - tmp=${tmp}$$ - ;; -*) tmp=$COTEMP - ;; -esac -case $tmp in -??????????*) - case $shell in - ksh) tmp=${tmp%${tmp#?????????}} ;; - *) eval `echo $tmp | sed 's/\(.........\).*/tmp=\1/'` ;; - esac - ;; -?????????) - ;; -????????) - tmp=F$tmp - ;; -esac -tmp=./$tmp - -# standard error to /dev/null unless debugging -# standard output to the current output file -# -# stdout original standard output -# stderr original standard error -# nullin /dev/null input -# nullout /dev/null output - -stdout=5 stderr=6 nullin=7 nullout=8 -eval "exec $nullin>/dev/null $nullout>/dev/null $stdout>&1 $stderr>&2 2>&$nullout" - -# options -- `-' for output to stdout otherwise usage - -while : -do case $# in - 0) in=- - break - ;; - esac - case $1 in - -) out=- - ;; - -*) echo "Usage: $command [-] [op [arg ... [-l* *.a *.sh * ...]] [: op ...]" >&$stderr - exit 2 - ;; - *) break - ;; - esac - shift -done - -# tmp files cleaned up on exit -# status: 0:success 1:failure 2:interrupt - -status=2 -trap "rm -f $tmp*.*; exit \$status" 0 1 2 - -# loop on op [ arg [ ... ] ] [ : op [ arg [ ... ] ] ] - -cur=. -while : -do case $in in - "") case $# in - 0) set set out + ;; - esac - ;; - *) read lin || lin="set out +" - set x $lin - shift - ;; - esac - - # check if "run xxx" is equivalent to "set in xxx" - - case $1 in - run) case $shell in - ksh) x=${2##*[\\/]} - ;; - *) case $2 in - */*) x=`echo $2 | sed -e 's,.*[\\\\/],,'` ;; - *) x=$2 ;; - esac - ;; - esac - case $x in - *.*) ;; - *) set set in $2 ;; - esac - ;; - esac - - # set drops out early - - case $1 in - ""|\#*) continue - ;; - set) shift - case $1 in - ""|\#*) op= - ;; - *) op=$1 - shift - arg= - while : - do case $# in - 0) break ;; - esac - case $1 in - *" "*) shift - continue - ;; - ""|\#*) break - ;; - :) shift - break - ;; - esac - case $arg in - "") arg=$1 ;; - *) arg="$arg $1" ;; - esac - shift - done - ;; - esac - case $op in - cc) occ= - for x in $arg - do case $occ in - "") case $x in - *=*) case $shell in - ksh) export $x - ;; - *) eval $x - export `echo $x | sed -e 's/=.*//'` - ;; - esac - ;; - *) occ=$x - ;; - esac - ;; - *) occ="$occ $x" - ;; - esac - done - continue - ;; - debug) case $arg in - 0) exec 2>&$nullout - set - - debug= - ;; - ""|1) exec 2>&$stderr - set - - debug= - ;; - 2) exec 2>&$stderr - case $shell in - ksh) PS4="${PS4%+*([ ])}+\$LINENO+ " - esac - set -x - debug=-x - ;; - *) echo "$command: $arg: debug levels are 0, 1, 2" >&$stderr - ;; - esac - continue - ;; - "in") case $arg in - "") in=- - ;; - *) in=$arg - if test ! -f $in - then echo "$command: $in: not found" >&$stderr - exit 1 - fi - exec < $in - case $out in - "") case $in in - *[.\\/]*) - case $shell in - ksh) out=${in##*[\\/]} - out=${out%.*} - ;; - *) eval `echo $in | sed -e 's,.*[\\\\/],,' -e 's/\.[^.]*//' -e 's/^/out=/'` - ;; - esac - ;; - *) out=$in - ;; - esac - ;; - esac - ;; - esac - continue - ;; - nodebug)exec 2>&$nullout - set - - continue - ;; - out) out=$arg - defhdr= - deflib= - gothdr= - gotlib= - ;; - prototyped|noprototyped) - pragma="$pragma $op" - ;; - pragma) pragma="$pragma $arg" - ;; - shell) shell=$arg - continue - ;; - static) static=$arg - continue - ;; - *) echo "$command: $op: unkown option" >&$stderr - exit 1 - ;; - esac - ;; - *) case $1 in - *\{) op=- - ;; - *) op=$1 - shift - ;; - esac - arg= - cc=$occ - fail= - hdr= - lib= - lst=hdr - opt= - pass= - run= - src= - tst= - case $# in - 0) ;; - *) case $1 in - \#*) set x - shift - ;; - *) case $op in - ref) ;; - *) case $1 in - *\{) arg=- - ;; - *) arg=$1 - shift - esac - ;; - esac - ;; - esac - while : - do case $# in - 0) break ;; - esac - case $1 in - "") ;; - \#*) set x - ;; - [a-z]*\{) - v=$1 - x= - shift - while : - do case $# in - 0) case $in in - "") echo "$command: missing }end" >&$stderr - exit 1 - ;; - esac - while : - do if read o lin - then case $o in - \}end) set $o $lin - break 2 - ;; - ' '*|' '*) - set '' $o - o=$2 - ;; - esac - - case $lin in - "") x="$x -$o" ;; - *) x="$x -$o $lin" ;; - esac - else echo "$command: missing }end" >&$stderr - exit 1 - fi - done - ;; - esac - case $1 in - \}end) break - ;; - *) x="$x -$1" - ;; - esac - shift - done - case $v in - fail\{) fail=$x ;; - pass\{) pass=$x ;; - test\{) tst=$x ;; - *) src=$x run=$v ;; - esac - ;; - :) shift - break - ;; - *[\(\)\{\}\ \ ]*) - tst="$tst $1" - ;; - -) case $lst in - hdr) hdr="$hdr $1" ;; - lib) lib="$lib $1" ;; - esac - ;; - -l*) lib="$lib $1" - lst=lib - ;; - -*|+*) case $op in - ref) occ="$occ $1" ;; - run) opt="$opt $1" ;; - *) cc="$cc $1" ;; - esac - ;; - *.a) lib="$lib $1" - lst=lib - ;; - *[.\\/]*) - hdr="$hdr $1" - lst=hdr - ;; - *) tst="$tst $1" - ;; - esac - shift - done - ;; - esac - ;; - esac - - # check the candidate headers - - case $hdr in - ?*) z=$hdr - hdr= - hit=0 - for x in $z - do case $x in - -) case $hit in - 0) hit=1 ;; - 1) ;; - *) break ;; - esac - continue - ;; - *.h) echo "#include \"$x\"" > $tmp.c - $cc -E $tmp.c <&$nullin >&$nullout || continue - ;; - *) test -r $x || continue - ;; - esac - hdr="$hdr $x" - case $hit in - 0) ;; - 1) hit=2 ;; - esac - done - ;; - esac - - # check the candidate libraries - - case $lib in - ?*) z=$lib - e= - lib= - echo "int main(){return(0);}" > $tmp.c - for x in $z - do case $x in - -) case $lib in - "") continue ;; - esac - break - ;; - esac - while : - do rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c $e $x <&$nullin >&$nullout - then lib="$lib $e $x" - e= - break - else case $e in - "") e=$x - break - ;; - *) e= - ;; - esac - fi - done - done - ;; - esac - - # precheck some more ops - - case $op in - ref) deflib="$deflib $lib" - defhdr="$defhdr $hdr" - continue - ;; - esac - ifs=$IFS - IFS=, - eval op=\"$op\" - eval arg=\"$arg\" - IFS=$ifs - - # check for op aliases - - x= - for o in $op - do case $o in - def|default) x="$x cmd hdr key lib mth sys typ" ;; - *) x="$x $o" ;; - esac - done - - # loop on the ops o and args a - - for o in $x - do for a in $arg - do user= - case $a in - *[.\\/]*) - case $o in - hdr|sys) - case $a in - *[\\/]*) x=/ ;; - *) x=. ;; - esac - case $shell in - ksh) p=${a%%${x}*} - v=${a##*${x}} - ;; - *) eval `echo $a | sed -e "s/\\(.*\\)\\\\${x}\\(.*\\)/p=\\1 v=\\2/"` - ;; - esac - ;; - *) case $shell in - ksh) p=${a%.*} - p=${p##*[\\/]} - v=${a##*.} - v=${v##*[\\/]} - ;; - *) eval `echo $a | sed -e 's,.*[\\\\/],,' -e 's/\(.*\)\.\(.*\)/p=\1 v=\2/'` - ;; - esac - ;; - esac - f=${p}/${v} - case $o in - run) v=$p - p= - m=_${v} - ;; - mem) m=_${v}_${p} - ;; - *) m=_${p}_${v} - ;; - esac - ;; - *) p= - v=$a - f=$a - m=_${v} - ;; - esac - - # check output redirection - - case $out in - $cur) ;; - *) case $cur in - $a|$v) ;; - *) case $cur in - .) ;; - -) echo "#endif" - ;; - *) echo "#endif" - exec >&- - case $cur in - *[\\/]*|*.h) x=$cur ;; - *) x=$dir/$cur ;; - esac - proto -r $tmp.h - sed 's,/\*[^/]*\*/, ,g' $tmp.h > $tmp.c - sed 's,/\*[^/]*\*/, ,g' $x > $tmp.t - if cmp -s $tmp.c $tmp.t - then rm -f $tmp.h - else case $x in - ${dir}[\\/]$cur) test -d $dir || mkdir $dir || exit 1 ;; - esac - mv $tmp.h $x - fi - ;; - esac - case $out in - +) case $status in - 1) ;; - *) status=0 ;; - esac - exit $status - ;; - -) eval "exec >&$stdout" - ;; - *) exec >$tmp.h - ;; - esac - case $out in - "") case $a in - *[\\/]*|???????????????*) cur=$v ;; - *) cur=$a ;; - esac - ;; - *) cur=$out - ;; - esac - case $in in - ""|-|+) case $o in - run) x=" from $a" ;; - *) x= ;; - esac - ;; - *) x=" from $in" - ;; - esac - echo "/* : : generated$x by $command version $version : : */" - for x in $pragma - do echo "#pragma $x" - done - case $out in - ""|-|+) x=$m - ;; - *.*) case $shell in - ksh) i=$out - x=_ - while : - do case $i in - *.*) x=$x${i%%.*}_ - i=${i#*.} - ;; - *) x=$x$i - break - ;; - esac - done - ;; - *) eval `echo $in | sed -e 's,\.,_,g' -e 's/^/x=/'` - ;; - esac - ;; - *) x=_$out - ;; - esac - case $x in - *-*) echo "#if 1" - ;; - *) case $x in - _cmd|_lib) - case $shell in - ksh) c=${PWD##*[\\/]} - c=${c#lib} - c=${c%%.*} - x=${x}_${c} - ;; - *) x=${x}_`echo $x | sed -e 's,.*[\\\\/],,' -e 's,^lib,,' -e 's,\..*,,'` - ;; - esac - ;; - esac - x=`echo $x | sed -e 's/[^a-zA-Z0-9_]/_/g'` - echo "#ifndef _def${x}" - echo "#define _def${x} 1" - ;; - esac - ;; - esac - ;; - esac - - # set up the candidate include list - - inc= - for x in $defhdr $hdr - do case $x in - *.h) case $shell in - ksh) c=${x##*[\\/]} - c=${c%%.*} - case $x in - */*) c=${x%%[\\/]*}_${c} ;; - esac - ;; - *) eval `echo $x | sed -e 's,^\([^\\\\/]*\).*[\\\\/]\([^\\\\/]*\)\$,\1_\2,' -e 's/\..*//' -e 's/^/c=/'` - ;; - esac - case " $gothdr " in - *" $x "*) - ;; - *) gothdr="$gothdr $x" - echo "#define _inc_${c} 1 /* candidate header <$x> found */" - ;; - esac - inc="$inc -#include <$x>" - ;; - esac - done - - # set up the candidate lib list - - for x in $lib $deflib - do case " $gotlib " in - *" $x "*) - ;; - *) gotlib="$gotlib $x" - echo "/* candidate library $x found */" - ;; - esac - done - - # src overrides builtin test - - case $o in - tst) ;; - *) m=_${o}${m} - ;; - esac - pre="#undef $v" - case $src in - ?*) echo "$inc -$src" > $tmp.c - e= - case $run in - cat*|nocat*) - echo "$src" - ;; - run*|norun*) - (eval "$src") <&$nullin || e=1 - ;; - mac*|nomac*) - if $cc -E $tmp.c <&$nullin >$tmp.i - then sed -e '/<<[ ]*".*"[ ]*>>/!d' -e 's/<<[ ]*"//g' -e 's/"[ ]*>>//g' $tmp.i - else e=1 - fi - ;; - p*|nop*)$cc -DTEST=$p -DID=$v -E $tmp.c <&$nullin >&$nullout || e=1 - ;; - c*|noc*)$cc -DTEST=$p -DID=$v -c $tmp.c <&$nullin >&$nullout || e=1 - ;; - *) rm -f $tmp.exe - if $cc -DTEST=$p -DID=$v -o $tmp.exe $tmp.c $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then case $run in - l*|nol*);; - o*|noo*)$tmp.exe <&$nullin || e=1 ;; - *) $tmp.exe <&$nullin >&$nullout || e=1 ;; - esac - else e=1 - fi - ;; - esac - case $run in - no*) case $e in - "") e=1 ;; - *) e= ;; - esac - ;; - esac - case $e in - "") case $m in - *-*) ;; - *) echo "#define $m 1 /* ${run}} passed */" ;; - esac - (eval "$pass") <&$nullin - ;; - *) (eval "$fail") <&$nullin - ;; - esac - continue - ;; - esac - - # initialize common builtin state - - case $o in - dat|lib|mth|run) - case $statictest in - "") statictest=FoobaR - echo "#if __cplusplus -extern \"C\" { -#endif -extern int $statictest(); -#if __cplusplus -} -#endif -static int ((*i)())=$statictest;main(){return(i==0);}" > $tmp.c - rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c <&$nullin >&$nullout && $executable $tmp.exe - then case $static in - .) static= - echo '#include -main(){printf("hello");return(0);}' > $tmp.c - rm -f $tmp.exe - if $cc -c $tmp.c <&$nullin >&$nullout && $cc -o $tmp.exe $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe - then e=`wc -l $tmp.e` - set x x $binding - while : - do shift - shift - case $# in - 0) break ;; - esac - rm -f $tmp.exe - $cc -o $tmp.exe $1 $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe || continue - case `wc -l $tmp.e` in - $e) ;; - *) continue ;; - esac - d=`ls -s $tmp.exe` - rm -f $tmp.exe - $cc -o $tmp.exe $2 $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe || continue - case `wc -l $tmp.e` in - $e) ;; - *) continue ;; - esac - case `ls -s $tmp.exe` in - $d) ;; - *) static=$2 - set x - shift - break - ;; - esac - done - fi - ;; - esac - else static= - fi - ;; - esac - ;; - esac - - # builtin tests - - case $o in - cmd) case $p in - ?*) continue ;; - esac - k= - for j in "" usr - do case $j in - "") d= s= ;; - *) d=/$j s=_$j ;; - esac - for i in bin etc ucb - do if test -f $d/$i/$a - then case $k in - "") k=1 - echo "#define $m 1 /* $a in ?(/usr)/(bin|etc|ucb) */" - ;; - esac - echo "#define ${s}_${i}_${v} 1 /* $d/$i/$a found */" - fi - done - done - ;; - dat) case $p in - ?*) continue ;; - esac - { - echo "$pre" - case $inc in - ?*) echo "$inc" - ;; - *) echo "#if __cplusplus -extern \"C\" { -#endif -extern int $v; -#if __cplusplus -} -#endif" - ;; - esac - echo "int main(){char* i = (char*)&$v; return i!=0;}" - } > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout && - rm -f $tmp.exe - if $cc $static -o $tmp.exe $tmp.o $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then echo "#define $m 1 /* $v in default lib(s) */" - fi - ;; - hdr|lcl|sys) - case $p in - lcl) eval p='$'_lcl_$v - case $p in - ?*) continue ;; - esac - eval _lcl_$v=1 - p= - f=$v - ;; - *) case $o in - hdr) echo "#include <$f.h>" > $tmp.c - $cc -E $tmp.c <&$nullin >&$nullout && - echo "#define $m 1 /* #include <$f.h> ok */" - ;; - sys) echo "#include " > $tmp.c - $cc -E $tmp.c <&$nullin >&$nullout && - echo "#define $m 1 /* #include ok */" - ;; - esac - continue - ;; - esac - case $p in - ?*) x="$p\\$v" ;; - *) x=$f ;; - esac - case $f in - *[\\/]*)g=$f ;; - *) g="$f sys/$f" ;; - esac - for f in $g - do echo "$pre -$inc -#include <$f.h>" > $tmp.c - if $cc -E $tmp.c <&$nullin >$tmp.i - then i=`sed -e '/^#[line ]*1[ ][ ]*"[\\\\/].*[\\\\/]'$x'\.h"/!d' -e '/[\\\\/]sys[\\\\/]'$x'\.h"/d' -e s'/.*"\(.*\)".*/\1/' $tmp.i` - for i in $i - do break - done - else i= - fi - case $i in - [\\/]*) echo "#if defined(__STDPP__directive)" - echo "__STDPP__directive pragma pp:hosted" - echo "#endif" - echo "#include \"$i\" /* untrusted local <$f.h> */" - echo "#undef $m" - echo "#define $m 1" - break - ;; - *) echo "/* no local <$f.h> */" - ;; - esac - done - ;; - key) case $p in - ?*) continue ;; - esac - echo "$pre -int f(){int $v = 1;return($v);}" > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout || - echo "#define $m 1 /* $v is a reserved keyword */" - ;; - lib|mth)case $p in - ?*) continue ;; - esac - echo "$pre -$inc -#if __cplusplus -extern \"C\" { -#endif -extern int $v(); -#if __cplusplus -} -#endif -static int ((*i)())=$v;main(){return(i==0);}" > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout && - rm -f $tmp.exe - if $cc $static -o $tmp.exe $tmp.o $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then case $o in - lib) echo "#define $m 1 /* $v() in default lib(s) */" ;; - esac - else case $o in - mth) rm -f $tmp.exe - $cc $static -o $tmp.exe $tmp.o -lm <&$nullin >&$nullout && - $executable $tmp.exe && - echo "#define $m 1 /* $v() in math lib */" - ;; - esac - fi - ;; - mac) case $p in - ?*) continue ;; - esac - echo "$pre -$inc -#ifdef $v -'#define $m 1 /* $v is a macro */' -#endif" > $tmp.c - $cc -E $tmp.c <&$nullin | sed -e "/^'#define/!d" -e "s/'//g" - ;; - mem) case $p in - ?*) for i in "" "struct " - do echo "$pre -$inc -static $i$p i; -int n = sizeof(i.$v);" > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout && - echo "#define $m 1 /* $v is member of $i$p */" && - break - done - ;; - *) echo "$command: $o: . expected" >&$stderr - status=1 - ;; - esac - ;; - nop) ;; - one) for i in $a $hdr - do x="#include <$i>" - echo "$x" > $tmp.c - if $cc -E $tmp.c <&$nullin >&$nullout - then echo "$x" - break - fi - done - ;; - out) ;; - run) if test ! -f $a - then echo "$command: $a: not found" >&$stderr - exit 1 - fi - case $a in - *.c) rm -f $tmp.exe - cp $a $tmp.c - $cc -o $tmp.exe $tmp.c $lib $deflib <&$nullin >&$nullout && - $executable $tmp.exe && - $tmp.exe $opt <&$nullin - ;; - *.sh) ${SHELL-sh} $debug $a "cc='$cc' executable='$executable' id='$m' static='$static' tmp='$tmp'" $opt $hdr <&$nullin - ;; - *) false - ;; - esac - case $? in - 0) ;; - *) echo "$command: $a: cannot run" >&$stderr - exit 1 - ;; - esac - ;; - sym) case $tst in - "") x=$v ;; - *) x=$tst ;; - esac - echo "$pre -$inc -'=' $x '='" > $tmp.c - $cc -E $tmp.c <&$nullin \ - | sed \ - -e "/'='/!d" \ - -e "s/'='//g" \ - -e 's/[ ]//g' \ - -e 's/((([^()]*)))->/->/g' \ - -e 's/(([^()]*))->/->/g' \ - -e 's/([^()]*)->/->/g' \ - -e 's/\([a-zA-Z_][a-zA-Z_0-9]*\)\[/\ -ary \1[/g' \ - -e 's/\([a-zA-Z_][a-zA-Z_0-9]*\)(/\ -fun \1[/g' \ - -e 's/\*->\([a-zA-Z_]\)/->\ -ptr \1/g' \ - -e 's/->\([a-zA-Z_]\)/->\ -reg \1/g' \ - -e "/^$v\$/d" \ - -e 's/^[a-zA-Z_][a-zA-Z_0-9]*$/\ -nam &/g' \ - | sed \ - -e '/^... /!d' \ - | sort \ - -u \ - | sed \ - -e 's/\(...\) \([a-zA-Z_][a-zA-Z_0-9]*\).*/#ifndef _\1_'$v'\ -#define _\1_'$v' \2\ -#define _\1_'$v'_str "\2"\ -#endif/' - ;; - typ) case $p in - "") x= ;; - *) x="$p " ;; - esac - case $typ in - "") typ=" -#include " - c= - h= - for i in time "" times - do case $i in - "") c=sys_ - h=sys/ - continue - ;; - esac - c=${c}$i - h=${h}$i.h - t="$typ -#include <$h>" - echo "$t" > $tmp.c - if $cc -c $tmp.c <&$nullin >&$nullout - then typ="$t" - echo "#define _inc_${c} 1 /* candidate header <$h> found */" - fi - c= - h= - done - t= - for i in stddef stdlib - do u="$t -#include <$i.h>" - echo "$u$typ" > $tmp.c - if $cc -c $tmp.c <&$nullin >&$nullout - then t="$u" - echo "#define _inc_$i 1 /* candidate header <$i.h> found */" - else break - fi - done - typ="$t$typ" - ;; - esac - { - case $p in - long) echo "$pre -$typ$inc -static $x$v i; -$x$v f() { -$x$v v; v = i;" - echo "v <<= 4; i = v >> 2; i = v * i; i = i / v; v = v + i; i = i - v; i = 10; i = v % i; i |= v; v ^= i; i = 123; v &= i; -return v; }" - ;; - *) echo "$pre -$typ$inc -struct xxx { $x$v mem; }; -static struct xxx v; -struct xxx* f() { return &v; }" - ;; - esac - echo "int main() { f(); return 0; }" - } > $tmp.c - rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c <&$nullin >&$nullout && - $executable $tmp.exe - then echo "#define $m 1 /* $x$v is a type */" - user=$pass - else user=$fail - fi - ;; - *) echo "$command: $o: unknown feature test" >&$stderr - status=1 - ;; - esac - case $user in - ?*) (eval "$user") <&$nullin ;; - esac - done - done -done diff --git a/cde/programs/dtksh/ksh93/ship/shipiffe.sh b/cde/programs/dtksh/ksh93/ship/shipiffe.sh deleted file mode 100644 index 87f3737a9..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipiffe.sh +++ /dev/null @@ -1,1419 +0,0 @@ -: $XConsortium: shipiffe.sh /main/3 1996/05/10 16:41:50 drk $ -: -# Glenn Fowler & Phong Vo -# AT&T Bell Laboratories -# -# test if feature exists -# -# @(#)iffe (AT&T Bell Laboratories) 05/09/95 -# -# NOTE: .exe a.out suffix and [\\/] in path patterns for dos/nt - -command=iffe -version=05/09/95 - -binding="-Bdynamic -Bstatic -Wl,-ashared -Wl,-aarchive -call_shared -non_shared" -occ=cc -defhdr= -usr= -deflib= -dir=FEATURE -executable="test -x" -gothdr= -gotlib= -ifs=$IFS -in= -menu= -nl=" -" -one= -out= -puthdr= -putlib= -pragma= -prompt= -case $RANDOM in -$RANDOM)shell=bsh - $executable . 2>/dev/null || executable='test -r' - ;; -*) shell=ksh - ;; -esac -static=. -statictest= -style=C -case $COTEMP in -"") case $HOSTNAME in - ""|?|??|???|????|????) - tmp=${HOSTNAME} - ;; - *) case $shell in - ksh) tmp=${HOSTNAME%${HOSTNAME#????}} ;; - *) eval `echo $HOSTNAME | sed 's/\(....\).*/tmp=\1/'` ;; - esac - ;; - esac - tmp=${tmp}$$ - ;; -*) tmp=$COTEMP - ;; -esac -case $tmp in -??????????*) - case $shell in - ksh) tmp=${tmp%${tmp#?????????}} ;; - *) eval `echo $tmp | sed 's/\(.........\).*/tmp=\1/'` ;; - esac - ;; -?????????) - ;; -????????) - tmp=F$tmp - ;; -esac -tmp=./$tmp - -# standard error to /dev/null unless debugging -# standard output to the current output file -# -# stdout original standard output -# stderr original standard error -# nullin /dev/null input -# nullout /dev/null output - -stdin=4 stdout=5 stderr=6 nullin=7 nullout=8 -eval "exec $stdin<&0 $nullin>/dev/null $nullout>/dev/null $stdout>&1 $stderr>&2 2>&$nullout" - -# options -- `-' for output to stdout otherwise usage - -while : -do case $# in - 0) in=- - break - ;; - esac - case $1 in - -) out=- - ;; - -*) echo "Usage: $command [-] [op [arg ... [-l* *.a *.sh * ...]] [: op ...]" >&$stderr - exit 2 - ;; - *) break - ;; - esac - shift -done - -# tmp files cleaned up on exit -# status: 0:success 1:failure 2:interrupt - -status=2 -trap "rm -f $tmp*.*; exit \$status" 0 1 2 - -# standard header for c source - -std='#if defined(__STDC__) || defined(__cplusplus) || defined(c_plusplus) -#define _STD_ 1 -#define _ARG_(x) x -#define _VOID_ void -#else -#define _STD_ 0 -#define _ARG_(x) () -#define _VOID_ char -#endif -#if defined(__cplusplus) -#define _BEGIN_EXTERNS_ extern "C" { -#define _END_EXTERNS_ } -#else -#define _BEGIN_EXTERNS_ -#define _END_EXTERNS_ -#endif -#define _NIL_(x) ((x)0)' - -# loop on op [ arg [ ... ] ] [ : op [ arg [ ... ] ] ] - -cur=. -while : -do case $in in - "") case $# in - 0) set set out + ;; - esac - ;; - *) read lin || lin="set out +" - set x $lin - shift - ;; - esac - - # check if "run xxx" is equivalent to "set in xxx" - - case $1 in - run) case $shell in - ksh) x=${2##*[\\/]} - ;; - *) case $2 in - */*) x=`echo $2 | sed -e 's,.*[\\\\/],,'` ;; - *) x=$2 ;; - esac - ;; - esac - case $x in - *.*) ;; - *) set set in $2 ;; - esac - ;; - esac - - # set drops out early - - case $1 in - ""|\#*) continue - ;; - set) shift - case $1 in - ""|\#*) op= - ;; - *) op=$1 - shift - arg= - while : - do case $# in - 0) break ;; - esac - case $1 in - *" "*) shift - continue - ;; - ""|\#*) break - ;; - :) shift - break - ;; - esac - case $arg in - "") arg=$1 ;; - *) arg="$arg $1" ;; - esac - shift - done - ;; - esac - case $op in - cc) occ= - for x in $arg - do case $occ in - "") case $x in - *=*) case $shell in - ksh) export $x - ;; - *) eval $x - export `echo $x | sed -e 's/=.*//'` - ;; - esac - ;; - *) occ=$x - ;; - esac - ;; - *) occ="$occ $x" - ;; - esac - done - continue - ;; - debug) case $arg in - 0) exec 2>&$nullout - set - - ;; - ""|1) exec 2>&$stderr - set - - ;; - 2) exec 2>&$stderr - case $shell in - ksh) PS4="${PS4%+*([ ])}+\$LINENO+ " - esac - set -x - ;; - *) echo "$command: $arg: debug levels are 0, 1, 2" >&$stderr - ;; - esac - continue - ;; - "in") case $arg in - "") in=- - ;; - *) in=$arg - if test ! -r $in - then echo "$command: $in: not found" >&$stderr - exit 1 - fi - exec < $in - case $out in - "") case $in in - *[.\\/]*) - case $shell in - ksh) out=${in##*[\\/]} - out=${out%.*} - ;; - *) eval `echo $in | sed -e 's,.*[\\\\/],,' -e 's/\.[^.]*//' -e 's/^/out=/'` - ;; - esac - ;; - *) out=$in - ;; - esac - ;; - esac - ;; - esac - continue - ;; - nodebug)exec 2>&$nullout - set - - continue - ;; - out) out=$arg - defhdr= - usr= - deflib= - gothdr= - gotlib= - one= - puthdr= - putlib= - ;; - prototyped|noprototyped) - pragma="$pragma $op" - ;; - pragma) pragma="$pragma $arg" - ;; - shell) shell=$arg - continue - ;; - static) static=$arg - continue - ;; - *) echo "$command: $op: unkown option" >&$stderr - exit 1 - ;; - esac - ;; - *) case $1 in - *\{) op=- - ;; - *) op=$1 - shift - ;; - esac - arg= - cc=$occ - fail= - hdr= - lib= - lst=hdr - note= - opt= - pass= - run= - src= - test= - case $# in - 0) ;; - *) case $1 in - \#*) set x - shift - ;; - *) case $op in - ref) ;; - *) case $1 in - *\{) arg=- - ;; - *) arg=$1 - shift - esac - ;; - esac - ;; - esac - while : - do case $# in - 0) break ;; - esac - case $1 in - "") ;; - \#*) set x - ;; - [a-z]*\{) - v=$1 - shift - x= - case $v in - menu\{) sep=" $nl " ;; - *) sep=$nl ;; - esac - while : - do case $# in - 0) case $in in - "") echo "$command: missing }end" >&$stderr - exit 1 - ;; - esac - while : - do if read lin - then set "" $lin - case $2 in - \}end) shift - break 2 - ;; - esac - x="$x$sep$lin" - else echo "$command: missing }end" >&$stderr - exit 1 - fi - done - ;; - esac - case $1 in - \}end) break - ;; - *) x="$x$sep$1" - ;; - esac - shift - done - case $v in - fail\{) fail=$x ;; - menu\{) menu=$x ;; - nofail\{) pass=$x v=pass\{ ;; - nopass\{) fail=$x v=fail\{ ;; - note\{) note=$x ;; - pass\{) pass=$x ;; - prompt\{) prompt=$x ;; - test\{) test=$x ;; - *) src=$x run=$v ;; - esac - ;; - :) shift - break - ;; - *[\(\)\{\}\ \ ]*) - test="$test $1" - ;; - -) case $lst in - hdr) hdr="$hdr $1" ;; - lib) lib="$lib $1" ;; - esac - ;; - -l*) lib="$lib $1" - lst=lib - ;; - -*|+*) case $op in - ref) cc="$cc $1" occ="$occ $1" ;; - run) opt="$opt $1" ;; - *) cc="$cc $1" ;; - esac - ;; - *.a) lib="$lib $1" - lst=lib - ;; - *[.\\/]*) - hdr="$hdr $1" - lst=hdr - ;; - *) test="$test $1" - ;; - esac - shift - done - ;; - esac - ;; - esac - - # check for interactive queries - - case $menu$prompt in - ?*) style=sh - case $arg in - "") arg=REPLY ;; - esac - eval $arg= - while : - do case $prompt in - ?*) case $prompt in - $nl*) ;; - *) echo >&$stdout ;; - esac - echo "$prompt" >&$stdout - esac - echo >&$stdout - IFS=" " - set "" $menu "$nl" - IFS=$ifs - shift - any= - n= - while : - do case $1 in - $nl) shift; continue ;; - esac - n=_$n - case $# in - 0) break ;; - esac - case $1 in - -) p="*" any=1 ;; - *) p=$1 ;; - esac - shift - case $1 in - $nl) t= ;; - -) t=; shift ;; - *) t=" $1"; shift ;; - esac - v=$1 - shift - case $1 in - $nl) shift ;; - esac - x=$v - case $v in - -|$nl) v= ;; - esac - case $t in - "") t=$v ;; - esac - case $v$x in - $nl) v=$p ;; - esac - echo " $p)$t" >&$stdout - eval p$n='"$p"' v$n='"$v"' - done - eval p$n="*" v$n= - case $n in - _) any=1 ;; - *) echo >&$stdout ;; - esac - case $shell in - ksh) read -u$stdin val ;; - *) val=`exec <&$stdin; read val; echo val` ;; - esac - i= - while : - do i=_$i - case $i in - $n) case $any in - "") val= ;; - esac - break - ;; - esac - eval p='$'p$i v='$'v$i - case $val in - "$p") any=1 - val=$v - break - ;; - "$v") any=1 - break - ;; - esac - done - case $any:$val in - ":") ;; - *) eval $arg=\$val - case $test in - "") break ;; - *) ( eval "$test" ) <&$stdin >&$stdout 2>&$stderr && break ;; - esac - ;; - esac - echo "$command: invalid input" >&$stderr - done - menu= - prompt= - op=val - ;; - esac - - # check the candidate headers - - case $hdr in - ?*) z=$hdr - hdr= - hit=0 - for x in $z - do case $x in - -) case $hit in - 0) hit=1 ;; - 1) ;; - *) break ;; - esac - continue - ;; - *.h) case " $gothdr " in - *" - $x "*) - continue - ;; - *" + $x "*) - ;; - *) echo "#include <$x>" > $tmp.c - if $cc -E $tmp.c <&$nullin >&$nullout - then gothdr="$gothdr + $x" - else gothdr="$gothdr - $x" - continue - fi - ;; - esac - ;; - *) test -r $x || continue - ;; - esac - hdr="$hdr $x" - case $hit in - 0) ;; - 1) hit=2 ;; - esac - done - ;; - esac - - # check the candidate libraries - - case $lib in - ?*) z=$lib - e= - lib= - echo "int main(){return(0);}" > $tmp.c - for x in $z - do case $x in - -) case $lib in - "") continue ;; - esac - break - ;; - esac - while : - do case $e in - "") p=$x ;; - *) p="$e $x" ;; - esac - case " $gotlib " in - *"- $p "*) - ;; - *"+ $p"*) - lib="$lib $p" - e= - break - ;; - *) rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c $p <&$nullin >&$nullout - then gotlib="$gotlib + $p" - lib="$lib $p" - e= - break - else gotlib="$gotlib - $p" - fi - ;; - esac - case $e in - "") e=$x - break - ;; - *) e= - ;; - esac - done - done - ;; - esac - - # precheck some more ops - - case $op in - ref) deflib="$deflib $lib" - defhdr="$defhdr $hdr" - continue - ;; - esac - IFS=, - eval op=\"$op\" - eval arg=\"$arg\" - IFS=$ifs - - # check for op aliases - - x= - for o in $op - do case $o in - def|default) x="$x cmd dat hdr key lib mth sys typ" ;; - *) x="$x $o" ;; - esac - done - - # loop on the ops o and args a - - for o in $x - do for a in $arg - do user= - case $a in - *[.\\/]*) - case $o in - hdr|sys) - case $a in - *[\\/]*) x=/ ;; - *) x=. ;; - esac - case $shell in - ksh) p=${a%%${x}*} - v=${a##*${x}} - ;; - *) eval `echo $a | sed -e "s/\\(.*\\)\\\\${x}\\(.*\\)/p=\\1 v=\\2/"` - ;; - esac - case $v in - lcl) t=$p - p=$v - v=$t - ;; - esac - ;; - *) case $shell in - ksh) p=${a%.*} - p=${p##*[\\/]} - v=${a##*.} - v=${v##*[\\/]} - ;; - *) eval `echo $a | sed -e 's,.*[\\\\/],,' -e 's/\(.*\)\.\(.*\)/p=\1 v=\2/'` - ;; - esac - ;; - esac - f=${p}/${v} - case $o in - run) v=$p - p= - m=_${v} - ;; - mem) m=_${v}_${p} - ;; - *) m=_${p}_${v} - ;; - esac - ;; - *) p= - v=$a - f=$a - m=_${v} - ;; - esac - - # check output redirection - - case $out in - $cur) ;; - *) case $cur in - $a|$v) ;; - *) case $cur in - .) ;; - -) case $style in - C) echo "#endif" ;; - esac - ;; - *) case $style in - C) echo "#endif" ;; - esac - exec >&- - case $cur in - *[\\/]*|*.h) x=$cur ;; - *) x=$dir/$cur ;; - esac - case $style in - C) proto -r $tmp.h - sed 's,/\*[^/]*\*/, ,g' $tmp.h > $tmp.c - sed 's,/\*[^/]*\*/, ,g' $x > $tmp.t - ;; - *) sed '/^#/d' $tmp.h > $tmp.c - sed '/^#/d' $x > $tmp.t - ;; - esac - if cmp -s $tmp.c $tmp.t - then rm -f $tmp.h - else case $x in - ${dir}[\\/]$cur) test -d $dir || mkdir $dir || exit 1 ;; - esac - mv $tmp.h $x - fi - ;; - esac - case $out in - +) case $status in - 1) ;; - *) status=0 ;; - esac - exit $status - ;; - -) eval "exec >&$stdout" - ;; - *) exec >$tmp.h - ;; - esac - case $out in - "") case $a in - *[\\/]*|???????????????*) cur=$v ;; - *) cur=$a ;; - esac - ;; - *) cur=$out - ;; - esac - case $in in - ""|-|+) case $o in - run) x=" from $a" ;; - *) x= ;; - esac - ;; - *) x=" from $in" - ;; - esac - case $style in - C) echo "/* : : generated$x by $command version $version : : */" - for x in $pragma - do echo "#pragma $x" - done - case $out in - ""|-|+) x=$m - ;; - *.*) case $shell in - ksh) i=$out - x=_ - while : - do case $i in - *.*) x=$x${i%%.*}_ - i=${i#*.} - ;; - *) x=$x$i - break - ;; - esac - done - ;; - *) eval `echo $in | sed -e 's,\.,_,g' -e 's/^/x=/'` - ;; - esac - ;; - *) x=_$out - ;; - esac - case $x in - *-*) echo "#if 1" - ;; - *) x=`pwd | sed -e 's,.*[\\\\/],,' -e 's,\..*,,' -e 's,^lib,,' -e 's,^,'${x}_',' -e 's,[^a-zA-Z0-9_],_,g'` - echo "#ifndef _def${x}" - echo "#define _def${x} 1" - ;; - esac - ;; - *) echo "# : : generated$x by $command version $version : : #" - ;; - esac - ;; - esac - ;; - esac - - # set up the candidate include list - - inc= - for x in $defhdr $hdr - do case $x in - *.h) case $shell in - ksh) c=${x##*[\\/]} - c=${c%%.*} - case $x in - */*) c=${x%%[\\/]*}_${c} ;; - esac - ;; - *) eval `echo $x | sed -e 's,^\([^\\\\/]*\).*[\\\\/]\([^\\\\/]*\)\$,\1_\2,' -e 's/\..*//' -e 's/^/c=/'` - ;; - esac - case $x in - */*) c=_${c} ;; - *) c=_hdr_${c} ;; - esac - case " $puthdr " in - *" $c "*) - ;; - *) puthdr="$puthdr $c" - usr="$usr$nl#define $c 1" - echo "#define $c 1 /* #include <$x> ok */" - ;; - esac - inc="$inc -#include <$x>" - ;; - esac - done - - # set up the candidate lib list - - for x in $lib $deflib - do case " $putlib " in - *" $x "*) - ;; - *) putlib="$putlib $x" - echo "/* candidate library $x found */" - ;; - esac - done - - # src overrides builtin test - - case $o in - tst) ;; - *) m=_${o}${m} ;; - esac - pre="#undef $v" - case $src in - ?*) cat > $tmp.c <$tmp.i - then sed -e '/<<[ ]*".*"[ ]*>>/!d' -e 's/<<[ ]*"//g' -e 's/"[ ]*>>//g' $tmp.i - else e=1 - fi - ;; - p*|nop*)$cc -DTEST=$p -DID=$v -E $tmp.c <&$nullin >&$nullout || e=1 - ;; - c*|noc*)$cc -DTEST=$p -DID=$v -c $tmp.c <&$nullin >&$nullout || e=1 - ;; - *) rm -f $tmp.exe - if $cc -DTEST=$p -DID=$v -o $tmp.exe $tmp.c $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then case $run in - l*|nol*);; - o*|noo*)$tmp.exe <&$nullin || e=1 ;; - *) $tmp.exe <&$nullin >&$nullout || e=1 ;; - esac - else e=1 - fi - ;; - esac - case $run in - no*) case $e in - "") e=1 ;; - *) e= ;; - esac - ;; - esac - case $e in - "") case $m in - *-*) ;; - *) usr="$usr$nl#define $m 1" - case $note in - "") echo "#define $m 1 /* ${run}} passed */" ;; - *) echo "#define $m 1 /*"$note" */" ;; - esac - ;; - esac - (eval "$pass") <&$nullin - ;; - *) (eval "$fail") <&$nullin - ;; - esac - continue - ;; - esac - - # initialize common builtin state - - case $o in - dat|lib|mth|run) - case $statictest in - "") statictest=FoobaR - echo "$std -$usr -_BEGIN_EXTERNS_ -extern int $statictest; -_END_EXTERNS_ -int main(){char* i = (char*)&$statictest; return i!=0;}" > $tmp.c - rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c <&$nullin >&$nullout && $executable $tmp.exe - then case $static in - .) static= - echo '#include -int main(){printf("hello");return(0);}' > $tmp.c - rm -f $tmp.exe - if $cc -c $tmp.c <&$nullin >&$nullout && $cc -o $tmp.exe $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe - then e=`wc -l $tmp.e` - set x x $binding - while : - do shift - shift - case $# in - 0) break ;; - esac - rm -f $tmp.exe - $cc -o $tmp.exe $1 $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe || continue - case `wc -l $tmp.e` in - $e) ;; - *) continue ;; - esac - d=`ls -s $tmp.exe` - rm -f $tmp.exe - $cc -o $tmp.exe $2 $tmp.o <&$nullin >&$nullout 2>$tmp.e && $executable $tmp.exe || continue - case `wc -l $tmp.e` in - $e) ;; - *) continue ;; - esac - case `ls -s $tmp.exe` in - $d) ;; - *) static=$2 - set x - shift - break - ;; - esac - done - fi - ;; - esac - else static= - fi - ;; - esac - ;; - esac - - # builtin tests - - case $o in - cmd) case $p in - ?*) continue ;; - esac - k= - for j in "" usr - do case $j in - "") d= s= ;; - *) d=/$j s=_$j ;; - esac - for i in bin etc ucb - do if test -f $d/$i/$a - then case $k in - "") k=1 - usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $a in ?(/usr)/(bin|etc|ucb) */" - ;; - esac - c=${s}_${i}_${v} - usr="$usr$nl#define $c 1" - echo "#define $c 1 /* $d/$i/$a found */" - fi - done - done - ;; - dat) case $p in - ?*) continue ;; - esac - { - echo "$std -$usr -$pre" - case $inc in - ?*) echo "$inc" - ;; - *) echo "_BEGIN_EXTERNS_ -extern int $v; -_END_EXTERNS_" - ;; - esac - echo "int main(){char* i = (char*)&$v; return i!=0;}" - } > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout && - rm -f $tmp.exe - if $cc $static -o $tmp.exe $tmp.o $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $v in default lib(s) */" - fi - ;; - hdr|lcl|sys) - case $o in - lcl) p=lcl ;; - esac - case $p in - lcl) eval p='$'_lcl_$v - case $p in - ?*) continue ;; - esac - eval _lcl_$v=1 - p= - f=$v - ;; - *) case " $puthdr " in - *" $m "*) - ;; - *) case $o in - hdr) x=$f.h ;; - sys) x=sys/$f.h ;; - esac - case " $gothdr " in - *" - $x "*) - ;; - *" + $x "*) - ;; - *) echo "#include <$x>" > $tmp.c - if $cc -E $tmp.c <&$nullin >&$nullout - then gothdr="$gothdr + $x" - usr="$usr$nl#define $m 1" - echo "#define $m 1 /* #include <$x> ok */" - else gothdr="$gothdr - $x" - fi - ;; - esac - ;; - esac - continue - ;; - esac - case $p in - ?*) x="$p\\$v" ;; - *) x=$f ;; - esac - case $f in - *[\\/]*)g=$f ;; - *) g="$f sys/$f" ;; - esac - for f in $g - do echo "$pre -$inc -#include <$f.h>" > $tmp.c - case $f in - sys/*) e= ;; - *) e='-e /[\\\\/]sys[\\\\/]'$x'\.h"/d' ;; - esac - if $cc -E $tmp.c <&$nullin >$tmp.i - then i=`sed -e '/^#[line ]*[0-9][0-9]*[ ][ ]*"[\\\\/].*[\\\\/]'$x'\.h"/!d' $e -e '/\/bits\//d' -e s'/.*"\(.*\)".*/\1/' -e 's,\\\\,/,g' -e 's,///*,/,g' $tmp.i | sort -u` - for i in $i - do break - done - else i= - fi - case $i in - [\\/]*) echo "#if defined(__STDPP__directive)" - echo "__STDPP__directive pragma pp:hosted" - echo "#endif" - echo "#include \"$i\" /* untrusted local <$f.h> */" - echo "#undef $m" - usr="$usr$nl#define $m 1" - echo "#define $m 1" - break - ;; - *) echo "/* no local <$f.h> */" - ;; - esac - done - ;; - key) case $p in - ?*) continue ;; - esac - echo "$pre -int f(){int $v = 1;return($v);}" > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout || - { - usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $v is a reserved keyword */" - } - ;; - lib|mth)case $p in - ?*) continue ;; - esac - echo "$std -$usr -$pre -$inc -_BEGIN_EXTERNS_ -extern int $v(); -_END_EXTERNS_ -static int ((*i)())=$v;int main(){return(i==0);}" > $tmp.c - $cc -c $tmp.c <&$nullin >&$nullout && - rm -f $tmp.exe - if $cc $static -o $tmp.exe $tmp.o $lib $deflib <&$nullin >&$nullout && $executable $tmp.exe - then case $o in - lib) usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $v() in default lib(s) */" ;; - esac - else case $o in - mth) rm -f $tmp.exe - $cc $static -o $tmp.exe $tmp.o -lm <&$nullin >&$nullout && - $executable $tmp.exe && - { - usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $v() in math lib */" - } - ;; - esac - fi - ;; - mac) case $p in - ?*) continue ;; - esac - echo "$pre -$inc -#ifdef $v -'#define $m 1 /* $v is a macro */' -#endif" > $tmp.c - $cc -E $tmp.c <&$nullin | sed -e "/#define/!d" -e "s/'//g" -e "s/^[ ][ ]*//" - ;; - mem) case $p in - ?*) for i in "" "struct " - do echo "$pre -$inc -static $i$p i; -int n = sizeof(i.$v);" > $tmp.c - if $cc -c $tmp.c <&$nullin >&$nullout - then usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $v is member of $i$p */" - break - fi - done - ;; - *) echo "$command: $o: . expected" >&$stderr - status=1 - ;; - esac - ;; - nop) ;; - one) for i in $a $hdr - do x="#include <$i>" - case " $gothdr " in - *" - $i "*) - continue - ;; - *" + $i "*) - ;; - *) echo "$x" > $tmp.c - if $cc -E $tmp.c <&$nullin >&$nullout - then gothdr="$gothdr + $x" - else gothdr="$gothdr - $x" - continue - fi - ;; - esac - case $one in - "") one=$x - ;; - *"$x"*) break - ;; - *) echo "$one" > $tmp.c - if $cc -E $tmp.c <&$nullin >$tmp.i - then c=$i - case $c in - *[\\/]*) c=`echo $c | sed 's,[\\\\/],[/],g'` ;; - esac - case `sed -e '/^#[line ]*1[ ][ ]*"[\\\\/].*[\\\\/]'$c'"/!d' $tmp.i` in - ?*) break ;; - esac - fi - one="$one$nl$x" - ;; - esac - echo "$x" - break - done - ;; - out) ;; - run) if test ! -r $a - then echo "$command: $a: not found" >&$stderr - exit 1 - fi - case $a in - *.c) rm -f $tmp.exe - cp $a $tmp.c - $cc -o $tmp.exe $tmp.c $lib $deflib <&$nullin >&$stderr 2>&$stderr && - $executable $tmp.exe && - $tmp.exe $opt <&$nullin - ;; - *.sh) ( - set "cc='$cc' executable='$executable' id='$m' static='$static' tmp='$tmp'" $opt $hdr $test - . $a - ) <&$nullin - ;; - *) false - ;; - esac - case $? in - 0) ;; - *) echo "$command: $a: cannot run" >&$stderr - exit 1 - ;; - esac - ;; - sym) case $test in - "") x=$v ;; - *) x=$test ;; - esac - echo "$pre -$inc -'=' $x '='" > $tmp.c - $cc -E $tmp.c <&$nullin \ - | sed \ - -e "/'='/!d" \ - -e "s/'='//g" \ - -e 's/[ ]//g' \ - -e 's/((([^()]*)))->/->/g' \ - -e 's/(([^()]*))->/->/g' \ - -e 's/([^()]*)->/->/g' \ - -e 's/\([a-zA-Z_][a-zA-Z_0-9]*\)\[/\ -ary \1[/g' \ - -e 's/\([a-zA-Z_][a-zA-Z_0-9]*\)(/\ -fun \1[/g' \ - -e 's/\*->\([a-zA-Z_]\)/->\ -ptr \1/g' \ - -e 's/->\([a-zA-Z_]\)/->\ -reg \1/g' \ - -e "/^$v\$/d" \ - -e 's/^[a-zA-Z_][a-zA-Z_0-9]*$/\ -nam &/g' \ - | sed \ - -e '/^... /!d' \ - | sort \ - -u \ - | sed \ - -e 's/\(...\) \([a-zA-Z_][a-zA-Z_0-9]*\).*/#ifndef _\1_'$v'\ -#define _\1_'$v' \2\ -#define _\1_'$v'_str "\2"\ -#endif/' - ;; - typ) case $p in - "") x= ;; - *) x="$p " ;; - esac - case $typ in - "") typ=" -#include " - c=_hdr_ - h= - for i in time "" times - do case $i in - "") c=_sys_ - h=sys/ - continue - ;; - esac - f=$h$i.h - t="$typ -#include <$f>" - case " $gothdr " in - *" - $f "*) - continue - ;; - *" + $f "*) - ;; - *) echo "$t" > $tmp.c - if $cc -c $tmp.c <&$nullin >&$nullout - then gothdr="$gothdr + $f" - else gothdr="$gothdr - $f" - continue - fi - ;; - esac - typ="$t" - c=$c$i - case " $puthdr " in - *" $c "*) - ;; - *) puthdr="$puthdr $c" - usr="$usr$nl#define $c 1" - echo "#define $c 1 /* #include <$f> ok */" - ;; - esac - done - t= - for i in stddef stdlib - do f=$i.h - u="$t -#include <$f>" - case " $gothdr " in - *" - $f "*) - break - ;; - *" + $f "*) - ;; - *) echo "$u$typ" > $tmp.c - if $cc -c $tmp.c <&$nullin >&$nullout - then gothdr="$gothdr + $f" - else gothdr="$gothdr - $f" - break - fi - ;; - esac - t="$u" - c=_hdr_$i - case " $puthdr " in - *" $c "*) - ;; - *) puthdr="$puthdr $c" - usr="$usr$nl#define $c 1" - echo "#define $c 1 /* #include <$f> ok */" - ;; - esac - done - typ="$t$typ" - ;; - esac - { - case $p in - long) echo "$pre -$typ$inc -static $x$v i; -$x$v f() { -$x$v v; v = i;" - echo "v <<= 4; i = v >> 2; i = v * i; i = i / v; v = v + i; i = i - v; i = 10; i = v % i; i |= v; v ^= i; i = 123; v &= i; -return v; }" - ;; - *) echo "$pre -$typ$inc -struct xxx { $x$v mem; }; -static struct xxx v; -struct xxx* f() { return &v; }" - ;; - esac - echo "int main() { f(); return 0; }" - } > $tmp.c - rm -f $tmp.exe - if $cc -o $tmp.exe $tmp.c $lib $deflib <&$nullin >&$nullout && - $executable $tmp.exe - then usr="$usr$nl#define $m 1" - echo "#define $m 1 /* $x$v is a type */" - user=$pass - else user=$fail - fi - ;; - val) case $arg in - \"*\") echo $arg=\'$val\' ;; - *) echo $arg=\"$val\" ;; - esac - ;; - :) shift - ;; - *) echo "$command: $o: unknown feature test" >&$stderr - status=1 - ;; - esac - case $user in - ?*) (eval "$user") <&$nullin ;; - esac - done - done -done diff --git a/cde/programs/dtksh/ksh93/ship/shipin b/cde/programs/dtksh/ksh93/ship/shipin deleted file mode 100755 index 0aef3e9a2..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipin +++ /dev/null @@ -1,1787 +0,0 @@ -csh=obsolete || exec sh $0 $argv:q -OLDEST_nmake=950509 OLDEST_pax=950509 -csh=obsolete || exec sh $0 $argv:q -# -# software shipment installation control -# -: "this id string works around a bug introduced sometime in 1991 -@(#)shipin (AT&T Bell Laboratories) 05/09/95 -" -# -# ship/shipin [options] [component ...] [name=value ...] -# -# options: -# -# -c don't compute closure if components specified -# -d for debugging -# -i read in from spool but do not uncrate or build -# (files set up for shipout) -# -n show actions but do not execute -# -p don't run proto on uncrate -# -r usr usr is the shipment recipient -# -s dir shipment spool hierarchy copied to dir -# -t show component closure but do not build -# -u uncrate shipment source but do not build -# -x set -x -# -E ignore previous tool build errors -# -F force (re)build (no uncrating unless -u) -# -L don't generate proto line syncs on uncrate -# -O preserve old shipments -# -P delete #pragma prototyped on input -# -X tool exclude tools from uncrating or building -# -# The component arguments cause shipin to build only on those components. -# All component source will be uncrated. -# -# The remaining arguments are passed as arguments to the generating -# makes or shell scripts -- handy for `name=value' overrides. -# -# The minimum configuration must have an $INSTALLROOT/ship subdirectory. -# See $INSTALLROOT/ship/README for more details. -# -# If $CC is not set then CC=$INSTALLROOT/bin/cc if it exists. This -# provides a workaround hook for botches in the compilation system -# that go beyond setting CC and CCFLAGS. Botches are so bad/ugly/temporary -# that we refuse to incorporate workarounds in our mainline code. -# Systems that currently require workarounds are: -# NeXT -# Win/NT -# - -case $1 in --x) set -x - ;; -*) case $- in - *x*) set '' -x ${1+"$@"}; shift ;; - esac - ;; -esac -case $- in -*x*) case $PS4 in - *'$LINENO'*) ;; - *) PS4='+$LINENO+ ' ;; - esac - ;; -esac - -# disable the builtin wc because ksh may hang during the execution later of "wc pic.o" -builtin -d wc - -# -# this script may be overwritten while it is being executed -# so copy it and exec from the copy -# - -_command_=ship/shipin -_command_save_=ship/SHIPin -_check_=": $* :" -case $_ship_check_ in -$_check_) - ;; -*) _ship_check_=$_check_ - export _ship_check_ - cp $_command_ $_command_save_ 2>/dev/null && chmod +x $_command_save_ && exec $_command_save_ ${1+"$@"} - ;; -esac - -# -# the components in ORDER are built first -# OLDEST_ is the oldest version of that can be used -# - -INSTALLROOT=`pwd` -export INSTALLROOT - -ORDER="pax ksh nmake" - -USER=${USER-${LOGNAME-`echo $HOME | sed 's/.*\///'`}} -INSTALLER=$USER -export INSTALLER -RECIPIENT=${RECIPIENT-$USER} -FROMSYS=`(uname -n || hostname || cat /etc/whoami) 2>/dev/null` -d=/lib:/usr/lib:/usr/local/lib -for i in LD_LIBRARY_PATH -do eval v='$'$i - case $v in - "") eval $i='$'INSTALLROOT/lib ;; - *) eval $i='$'INSTALLROOT/lib:$v ;; - esac - export $i -done -OPATH=/bin:/usr/bin:$PATH -PATH=:$PATH:$INSTALLROOT/bin -export PATH -case $PS4 in -+\ *|+*\ ) - ;; -*) PS4="+ $PS4" - export PS4 - ;; -esac - -SHIP=$INSTALLROOT/ship -BIN=$INSTALLROOT/bin -_bypass_=Install -LOG=in.log -_mail_=/bin/mail -OWNER=owner -_read_= -REPORT=report -SHIPDATE=[0-9][0-9][0-9][0-9][0-9][0-9] -SHIPMENT=*$SHIPDATE -SHIPSLOG=$SHIP/shipslog -TMP=tmp - -for f in $ORDER -do eval RELEASE_$f= - eval STATE_$f= -done - -if (unalias make) 2> /dev/null -then unalias cp make rm -fi - -# -# check for old exit status botch -# - -_set_= -(set -e; false || true) && _set_=e || echo "$_command_: command errors ignored because of shell botch" >&2 -_set_="set -x$_set_;" - -# -# gobble the options -# - -_closure_=1 -_debug_= -_exclude_=" bin cmd lib src shipslog " -_export_="CC CCFLAGS" -_force_= -_ignore_= -_intermediate_= -_options_= -_preserve_= -_proto_=1 -_proto_default_=npr -_proto_opt_= -_total_= -_trace_= -_uncrate_= -_uuspool_= -while : -do case $# in - 0) break ;; - esac - case $1 in - -[rsX]) case $# in - 1) set '?'; continue ;; - esac - case $1 in - -r) RECIPIENT=$2 ;; - -s) _uuspool_="$_uuspool_ $2" ;; - -X) _exclude_="$_exclude$2 " ;; - esac - _options_="$_options_ $1" - shift - ;; - -c) _closure_= ORDER= ;; - -d) _debug_=1 ;; - -i) _intermediate_=1 ;; - -n) _trace_=echo ;; - -p) _proto_= ;; - -t) _total_=1 _trace_=: _components_= ;; - -u) _uncrate_=1 ;; - -x) set -x ;; - -E) _ignore_=1 ;; - -F) _force_=1 ;; - -L) _proto_default_=pr ;; - -O) _preserve_=1 ;; - -P) _proto_opt_=z$_proto_opt_ ;; - --) _options_="$_options_ $1"; shift; break ;; - '?'|[-+]*) echo "Usage: $_command_ [-cinptuxEF] [-r recipient] [-s spool-dir] [-X tool] [tool ...] [name=value ...]" >&2; exit 2 ;; - *=*) eval `echo $1 | sed -e '/^[a-zA-Z0-9_]*=/!d' -e "s/\([^=]*\)=\(.*\)/i=\1 \1=\'\2\'/"` - _export_="$_export_ $i" - ;; - *) break ;; - esac - _options_="$_options_ $1" - shift -done - -# -# option controlled vars -# - -export RECIPIENT -case $_uuspool_ in -"") case $SHIPSPOOL in - "") SHIPSPOOL="/var/spool/uucppublic/$RECIPIENT/* /var/spool/uucppublic/receive/$RECIPIENT/*" ;; - esac - ;; -*) SHIPSPOOL=$_uuspool_ ;; -esac -export SHIPSPOOL - -# -# must be in $INSTALLROOT -# - -if test ! -d ship -then echo "$_command_: must have \$INSTALLROOT/ship directory" >&2; exit 1 -fi - -cd $SHIP -case $_trace_ in -?*) $_trace_ cd $SHIP ;; -esac -_tmp_=SHIPtmp - -# -# best guess for cc command and flags -# probe info cached in $_ship_probe_ -# - -case $CC in -""|cc) test -f $INSTALLROOT/bin/cc && CC=$INSTALLROOT/bin/cc ;; -esac -case $CC in -$INSTALLROOT/bin/cc) - ;; -*) _ship_probe_=SHIPprobe - _ship_probe_PATH= - _ship_probe_CC= - _ship_probe_CCFLAGS= - test -f $_ship_probe_ && . ./$_ship_probe_ - case "+ $_ship_probe_PATH + $_ship_probe_CC +" in - "+ $PATH + $CC +") - CC="$_ship_probe_CC $_ship_probe_CCFLAGS" - case $_ship_probe_CCFLAGS in - ?*) CC="$CC $_ship_probe_CCFLAGS" ;; - esac - ;; - *) _ship_probe_PATH=$PATH - case $CC in - "") echo 'int main() { return 0; }' > ${_tmp_}0.c - cat > $_tmp_.c <<'!' -#include -#include -#define STD_POSIX1 (1<<5) -#define STD_LIMITS (1<<4) -#define STD_C (0<<3) -#define STD_POSIX2 (1<<2) -#define STD_XOPEN (1<<1) -#define STD_ALL (1<<0) -main(argc, argv) -int argc; -char** argv; -{ - int std = 0; -#ifdef __STDC__ - std |= STD_C; -#endif -#ifdef CHAR_BIT - std |= STD_LIMITS; -#endif -#ifdef PIPE_BUF - std |= STD_POSIX1; -#endif -#ifdef LINE_MAX - std |= STD_POSIX2; -#endif -#ifdef DBL_MAX - std |= STD_XOPEN; -#endif -#ifdef PID_MAX - std |= STD_ALL; -#endif - printf("#ccflags#%04o#%s\n", std, argv[1]); - return 0; -} -! - CC="`ifs=\$IFS - IFS=: - set /opt/SUNWspro/bin:+:$PATH:+:/opt/gnu/bin:/usr/add-on/gnu/bin:/usr/local/bin - IFS=\$ifs - path=\$* - set cc 9 gcc 8 xlc 7 acc 6 apcc 5 - std= - while : - do case \$# in - 0|1) break ;; - esac - for bin in \$path - - do case \$bin in - +) std=1\$std; continue ;; - -) break 2 ;; - esac - test -x \$bin/\$1 && break - done - case $std in - 1) cmd=\$1 ;; - *) cmd=\$bin/\$1 ;; - esac - seq= - rm -f ${_tmp_}0.exe - \$cmd -o ${_tmp_}0.exe ${_tmp_}0.c && ./${_tmp_}0.exe && - for opt in \ - '' \ - -D_ALL_SOURCE \ - -D_ANSI_SOURCE \ - -D_ANSI_C_SOURCE \ - -D_POSIX_SOURCE \ - -D_XOPEN_SOURCE \ - '-D_ANSI_SOURCE -D_POSIX_SOURCE' \ - '-D_ANSI_SOURCE -D_XOPEN_SOURCE' \ - '-D_ANSI_C_SOURCE -D_POSIX_SOURCE' \ - '-D_ANSI_C_SOURCE -D_XOPEN_SOURCE' \ - '-D_POSIX_SOURCE -D_XOPEN_SOURCE' \ - '-D_ANSI_SOURCE -D_POSIX_SOURCE -D_XOPEN_SOURCE' \ - '-D_ANSI_C_SOURCE -D_POSIX_SOURCE -D_XOPEN_SOURCE' \ - -posix - do seq=x$seq - xxx=$cmd - case \$opt in - '') tie=1 ;; - *) xxx=\"\$xxx \$opt\" tie=0 ;; - esac - \$xxx $_tmp_.c -o $_tmp_.exe && ./$_tmp_.exe \"\$2#\$tie# \$seq#\$xxx\" - done - shift - shift - done 2>/dev/null | sort +0r -1 +1 | grep '^#ccflags#' | sed -e '2,$d' -e 's/.*#//'`" - rm -f ${_tmp_}*.* - ;; - esac - case $CC in - "") CC=cc ;; - esac - echo 'int x;' > $_tmp_.c - rm -f $_tmp_.o 2>/dev/null - if $CC -c $_tmp_.c >/dev/null 2>&1 && test -f $_tmp_.o - then : ok - else echo "$_command_: must have CC=\"$CC\" to continue" >&2 - exit 1 - fi - _ship_probe_CC=$CC - _ship_probe_CCFLAGS= - - # - # commit the wimps - # - - echo "#if !defined(TEST) && (defined(__STDC__) || defined(__cplusplus)) -( -#else -#include -#include -#include -#include -#if defined(TEST) -#define glue(a,b) a ## b -glue(i, nt) -#else -int -#endif -int main(int argc, char** argv) { return 0; } -#endif -" > $_tmp_.c - if $CC $CCFLAGS -c $_tmp_.c >/dev/null 2>&1 - then if $CC $CCFLAGS -DTEST -c $_tmp_.c >/dev/null 2>&1 - then : ok - elif $CC -D__STDC__ $CCFLAGS -DTEST -c $_tmp_.c >/dev/null 2>&1 - then CC="$CC -D__STDC__" - case $_ship_probe_CCFLAGS in - ?*) _ship_probe_CCFLAGS="$_ship_probe_CCFLAGS " ;; - esac - _ship_probe_CCFLAGS="${_ship_probe_CCFLAGS}-D__STDC__" - fi - fi - echo "#include -#include -#include -int main() { return socket(0, 0, 0); }" > $_tmp_.c - for i in "" "-systype bsd43" - do if $CC $CCFLAGS $i -o $_tmp_.exe $_tmp_.c >/dev/null 2>&1 - then case $i in - ?*) CC="$CC $i" - case $_ship_probe_CCFLAGS in - ?*) _ship_probe_CCFLAGS="$_ship_probe_CCFLAGS " ;; - esac - _ship_probe_CCFLAGS="${_ship_probe_CCFLAGS}$i" - ;; - esac - break - fi - done - rm -f $_tmp_.* - { - echo _ship_probe_PATH="'$_ship_probe_PATH'" - echo _ship_probe_CC="'$_ship_probe_CC'" - echo _ship_probe_CCFLAGS="'$_ship_probe_CCFLAGS'" - } > $_ship_probe_ - ;; - esac - ;; -esac - -for i in $_export_ -do eval d='"$'$i'"' - case $d in - ?*) export $i ;; - esac -done - -# -# check the manifest and then copy from the spool area to $SHIP -# - -case $_debug_ in -?*) SHIPSPOOL= ;; -esac -for UUSHIP in $SHIPSPOOL -do if test -d $UUSHIP - then cd $UUSHIP - case $_trace_ in - ?*) $_trace_ cd $UUSHIP ;; - esac - for f in ${SHIPDATE}*.* - do if test -f $f/manifest - then _manifest_=`cat $f/manifest` - d= - for i in $_manifest_ - do if test ! -f $i - then case $i in - */*/*) case $i in - *.???) p=`echo $i | sed -e 's/\....$//'` ;; - *) p=$i ;; - esac - if test -d $SHIP/$p - then continue - fi - ;; - esac - echo "$f: $i has not arrived yet" >&2 - d=1 - fi - done - case $d in - ?*) continue ;; - esac - _unspool_= - for i in $_manifest_ - do case $i in - $f/unspool) _unspool_=$i ;; - esac - done - if test "" != "$_unspool_" -a -f $_unspool_ && $_trace_ . $_unspool_ - then : ok - else echo "$f: cannot unspool shipment" >&2; continue - fi - d= - for i in $_manifest_ - do case $i in - $f/*) ;; - *.000) d="$d $i" ;; - */*.*) ;; - */*/*) d="$d $i" ;; - esac - done - d=`echo "$d " | sed -e 's,//*[^/ ]* , ,g'` - $_trace_ rm -rf $f $d - fi - done - cd $INSTALLROOT - case $_trace_ in - ?*) $_trace_ cd $INSTALLROOT ;; - esac - fi -done - -# -# check for shipment support update -# -# B install in $BIN -# M must exist -# P must exist on PATH -# - -_path_=`echo $PATH | sed -e 's/:/ /g' -e 's,///*,/,g'` -_stamp_='`sed -e /@(#)$c'\''.* (AT.T.*).* [0-9][0-9]\\/[0-9][0-9]\\/[0-9][0-9]/!d'\'' -e '\''s/.*@(#).* (.*).* \\(..\\)\\/\\(..\\)\\/\\(..\\).*/\\3\\1\\2/'\'' -e q $f 2>/dev/null`' -_update_= -cd $SHIP -set iffe .sh BM \ - in '' M \ - op .c M \ - proto .c BM \ - ar /usr/ccs/bin P \ - -- ${1+"$@"} -while : -do case $1 in - --) shift; break ;; - esac - _cmd_=$1 - _suf_=$2 - _flg_=$3 - shift; shift; shift - case $_flg_ in - *B*) c=$_cmd_ ;; - *) c=ship$_cmd_ ;; - esac - case $_flg_ in - *P*) for i in $_path_ - do if test -x $i/$_cmd_ - then _flg_= - break - fi - done - case $_flg_ in - *P*) for i in $_suf_ - do if test -x $i/$_cmd_ - then PATH=$PATH:$i - _path_="$_path_ $i" - _flg_= - break - fi - done - case $_flg_ in - *P*) echo "$_command_: must have $_cmd_ to continue" >&2 - exit 1 - ;; - esac - ;; - esac - continue - ;; - esac - eval _ship${_cmd_}_=$SHIP/ship$_cmd_ - case $_trace_ in - ?*) continue ;; - esac - if test -f ship$_cmd_$_suf_ - then f=ship$_cmd_$_suf_; eval new=$_stamp_ - if test -f SHIP$_cmd_$_suf_ - then f=SHIP$_cmd_$_suf_; eval old=$_stamp_ - else old=0 - fi - else case $_flg_ in - *M*) echo "$_command_: must have ship$_cmd_$_suf_ to continue" >&2 - exit 1 - ;; - esac - eval _ship${_cmd_}_= - continue - fi - # the variable "old" can be empty, to avoid "arithmetic syntax error" from ksh, set it to 0 - if test "$new" -gt "${old:-0}" - then case $_suf_ in - ?*) cp ship$_cmd_$_suf_ SHIP$_cmd_$_suf_ ;; - esac - elif test "$new" -lt "$old" - then cp SHIP$_cmd_$_suf_ ship$_cmd_$_suf_ - new=$old - _update_="$_update_ $_cmd_$_suf_" - fi - case $_suf_ in - ?*) f=ship$_cmd_; eval old=$_stamp_ - case $_suf_ in - .c) test -f $f && ./$f /dev/null 2>&1 || old=0 ;; - esac - # the variable "old" can be empty, to avoid "arithmetic syntax error" from ksh, set it to 0 - if test "$new" -gt "${old:-0}" - then case $old in - ""|0) ;; - *) cp ship$_cmd_ SHIP$_cmd_ ;; - esac - case $_suf_ in - .c) if $CC $CCFLAGS -o SHIPa.out ship$_cmd_$_suf_ - then mv SHIPa.out ship$_cmd_ - else case $old in - ""|0) case $_flg_ in - *M*) echo "$_command_: must have ship$_cmd_ to continue" >&2 - exit 1 - ;; - esac - eval _ship${_cmd_}_= - continue - ;; - esac - fi - ;; - .sh) cp ship$_cmd_$_suf_ ship$_cmd_ - chmod +x ship$_cmd_ - ;; - esac - else new=$old - fi - esac - case $_flg_ in - *B*) f=$BIN/$_cmd_; eval old=$_stamp_ - # the variable "old" can be empty, to avoid "arithmetic syntax error" from ksh, set it to 0 - if test "$new" -gt "${old:-0}" - then if test ! -d $BIN - then mkdir $BIN - fi - cp ship$_cmd_ $BIN/$_cmd_ - fi - ;; - esac -done -case $_trace_ in -"") test -x $BIN/feature || ln $BIN/iffe $BIN/feature ;; -esac -case $_proto_ in -"") _shipproto_= ;; -esac -cd $INSTALLROOT -case " $_update_ " in -*" in "*) $_trace_ exec $_command_ $_options_ ${1+"$@"} ;; -esac - -# -# intermediate unpacking from spool area done -# - -case $_debug_$_intermediate_ in -?*) exit 0 ;; -esac - -# -# grab the select args -# - -SELECT=" " -while : -do case $# in - 0) break ;; - esac - case $1 in - *=*) break ;; - esac - SELECT="$SELECT$1 " - shift -done - -# -# handle character class botch -- it's hard to believe 9th edition -# did this, easier to believe BSD never added it -# - -cclasstype='^' -case a in -[${cclasstype}0]) ;; -[!0]) cclasstype='!' ;; -*) cclasstype='' ;; -esac - -# -# set up and verify the default directory hierarchy -# - -hierarchy="src src/cmd src/lib ship/shipslog" -case $_uncrate_ in -"") hierarchy="$hierarchy bin fun include lib man man/man1 man/man3 man/man8" ;; -esac -for d in $hierarchy -do if test ! -d $d - then $_trace_ mkdir $d - fi -done -if test ! -f src/Makefile -then case $_trace_ in - "") echo ":MAKE: lib - cmd" > src/Makefile ;; - *) $_trace_ echo ":MAKE: lib - cmd" "> src/Makefile" ;; - esac -fi -if test ! -f src/lib/Makefile -then case $_trace_ in - "") echo ':MAKE: lib[0-9]* - libast - *' > src/lib/Makefile ;; - *) $_trace_ echo ':MAKE: lib[0-9]* - libast - *' '> src/lib/Makefile' ;; - esac -fi -if test ! -f src/cmd/Makefile -then case $_trace_ in - "") echo ':MAKE: probe - cpp - *' > src/cmd/Makefile ;; - *) $_trace_ echo ':MAKE: probe - cpp - *' '> src/cmd/Makefile' ;; - esac -fi - -# -# ignore and silent may be used by nmake generated bootstraps -# - -case $_trace_$_uncrate_ in -"") if test ! -f bin/ignore - then cat > bin/ignore <<'!' -: -"$@" -exit 0 -! - chmod +x bin/ignore - fi - if test ! -f bin/silent - then cat > bin/silent <<'!' -: -case $1 in -+|-|"") exit 0 ;; -esac -"$@" -! - chmod +x bin/silent - fi - ;; -esac -trap 'exit 2' 1 2 - -# -# check if we can use nmake from the start -# if so then limit proto to notices only -# - -ACCEPT=nmake -_make_= -for p in $_path_ -do if test -f $p/nmake && test "`$p/nmake -n -f - 'error 0 \$(MAKEVERSION:@/.*\\(..\\)\\/\\(..\\)\\/\\(..\\)\$/\\3\\1\\2/)' 'nop:' nop &1`" -ge "$OLDEST_nmake" 2>/dev/null - then l=`echo $p | sed 's,[^/]*\$,lib,'` - _make_="$p/nmake MAKEPP=$l/cpp MAKERULES=$l/make/makerules" - ACCEPT= - _proto_default_=d$_proto_default_ - break - fi -done -_proto_default_=$_proto_default_$_proto_opt_ - -# -# some context for nohup.out -# - -if test -f nohup.out -then _nohup_="===============================================================================" - echo "$_nohup_" - id="`(uname -a) 2>/dev/null`" - case $id in - ?*) echo "system $id" ;; - esac - echo "installroot $INSTALLROOT" - case $SHIPSPOOL in - *"*"*) ;; - *) echo "shipspool $SHIPSPOOL" ;; - esac - case $INSTALLER in - $RECIPIENT) echo "by $FROMSYS!$INSTALLER" ;; - *) echo "by $FROMSYS!$INSTALLER for $RECIPIENT" ;; - esac - echo "archive $AR_PATH $AR_DELTA" - case $_make_ in - ?*) x=$_make_ ;; - *) x=mamexec ;; - esac - echo "build $x" - echo "cc $CC $CCFLAGS" - case $CCS in - ?*) echo "preroot $CCS" ;; - esac - echo "start `date`" - echo "$_nohup_" -else _nohup_= -fi - -# -# finish up initialization -# - -case $_trace_ in -?*) $_trace_ cd $SHIP ;; -esac -cd $SHIP - -# -# uncrate the archives into the source tree -# - -COMPONENTS_SELECT=" " -for NAME in * -do case $_exclude_ in - *" $NAME "*) continue ;; - esac - if test -f $NAME/items - then # don't rebuild items under local control - echo "$_command_: warning: $NAME: delete ship/$NAME/items to build" >&2 - continue - fi - case $cclasstype in - '!'|'^') - case $NAME in - *[${cclasstype}a-zA-Z_0-9]*) - continue ;; - esac - ;; - '') case "`echo $NAME | grep '[^a-zA-Z_0-9]'`" in - ?*) continue ;; - esac - ;; - esac - if test -d $NAME - then _release_= - _state_=found - case $NAME in - *_*) eval `echo $NAME | sed 's/\([^_]*\)_\(.*\)/_system_=\1 _tool_=\2/'` - _root_=$INSTALLROOT/$_system_ - if test ! -d $_root_ - then $_trace_ mkdir $_root_ - fi - for d in $hierarchy - do case $d in - ship/*) ;; - *) if test ! -d $_root_/$d - then $_trace_ mkdir $_root_/$d - fi - ;; - esac - done - ;; - *) _root_=$INSTALLROOT - _tool_=$NAME - ;; - esac - case $_tool_ in - lib*) _type_=lib ;; - *) _type_=cmd ;; - esac - _source_=$_root_/src/$_type_/$_tool_ - if test ! -d $_source_ - then $_trace_ mkdir $_source_ - fi - cd $NAME - base= # newest base - delta= # newest delta for newest base [not in dlist] - dlist= # list of deltas for newest base [no delta] - need= # pax needed to uncrate - new= # delta shipments requiring new base - old= # first base for new chain - remove= # old shipments to be removed - type= # base|delete|delta|patch - for d in $SHIPMENT - do case $d in - "$SHIPMENT") continue ;; - esac - if test -f $d/base -o -f $d/delete - then remove="$remove $base $dlist $delta $need $new" - base=$d - delta= - need= - new= - if test -f $d/delete - then type=delete - else type=base - fi - else if test "" != "$base" -a -f $d/$base && egrep 'DELTA!!!|!PAX!D!' $d/$base >/dev/null - then case $AR_DELTA in - "") need="$need $d" - continue - ;; - esac - type=delta - else type=patch - fi - case $base in - "") dlist="$dlist $d" - ;; - *) if test -f $d/$base - then dlist="$dlist $delta" - delta=$d - elif test "" != "$delta" -a -f $d/$delta - then dlist="$dlist $base" - case $new in - "") old=$base ;; - esac - new="$new $delta" - base=$delta - delta=$d - else dlist="$dlist $d" - fi - ;; - esac - fi - done - case $type in - delete) case $NAME in - lib*) i=lib ;; - *) i=cmd ;; - esac - cd $SHIP - $_trace_ rm -rf $SHIP/$NAME $INSTALLROOT/src/$i/$NAME - continue - ;; - esac - for i in $new - do echo generate $NAME $i base from $old >&2 - case $_trace_ in - "") echo "generate $NAME $i base from $old [`date`]" >> $SHIP/$NAME/$LOG - case $type in - delta) $AR_DELTA -rf $i/$old -z $old/base -wf $i/base - _code_=$? - ;; - patch) mkdir /tmp/ship.$$ - cd /tmp/ship.$$ - $AR_READ < $SHIP/$NAME/$old/base && - $AR_READ < $SHIP/$NAME/$i/$old && - { - $AR_LIST < $SHIP/$NAME/$old/base - $AR_LIST < $SHIP/$NAME/$i/$old - } | sort -u | $AR_WRITE > $SHIP/$NAME/$i/base - _code_=$? - cd $SHIP/$NAME - rm -rf /tmp/ship.$$ - ;; - esac - case $_code_ in - 0) touch $i/GENERATED - ;; - *) echo "cannot generate $i base from $old" >&2 - echo "cannot generate $i base from $old" >> $SHIP/$NAME/$LOG - break - ;; - esac - ;; - *) $_trace_ $AR_DELTA -rf $SHIP/$NAME/$i/$old -z $SHIP/$NAME/$old/base -wf $i/base - $_trace_ touch $SHIP/$NAME/$i/GENERATED - ;; - esac - old=$i - done - case $base in - "") echo "$_command_: warning: $NAME: no base archive" >&2 - cd $SHIP - continue - ;; - esac - case $_preserve_ in - ?*) case `echo $remove $dlist` in - ?*) case $_trace_ in - "") rm -rf $remove $dlist 2>/dev/null ;; - *) $_trace_ "(cd $NAME; rm -rf" $remove $dlist")" ;; - esac - ;; - esac - ;; - esac - $_trace_ cd $_source_ - case $delta in - "") _release_=$base ;; - *) _release_=$delta ;; - esac - if test 11 = "$_force_$_uncrate_" -o ! -f $SHIP/$NAME/$_release_/UNCRATED - then echo uncrate $NAME $_release_ $type >&2 - case $_trace_ in - "") echo "uncrate $NAME $_release_ $type [`date`]" >> $SHIP/$NAME/$LOG ;; - esac - error= - if test -f $SHIP/$NAME/$_release_/delete - then cd $SHIP - rm -rf $NAME - continue - fi - if test ! -f $SHIP/$NAME/$_release_/items - then echo "$_command_: warning: $NAME: no items file" >&2 - fi - _proto_options_="-${_proto_default_}c`cat $SHIP/$NAME/$_release_/copyright 2>/dev/null`" - if test "" = "$AAR_LIST" -o "delta" = "$type" || $OAR_LIST < $SHIP/$NAME/$base/base >/dev/null 2>&1 - then AR_PATH=$OAR_PATH - AR_LIST=$OAR_LIST - AR_READ=$OAR_READ - AR_WRITE=$OAR_WRITE - else AR_PATH=$AAR_PATH - AR_LIST=$AAR_LIST - AR_READ=$AAR_READ - AR_WRITE=$AAR_WRITE - fi - for i in base $base - do case $type in - base|patch) - case $type in - base) if test ! -f $SHIP/$NAME/$_release_/GENERATED - then case $_trace_ in - "") rm -rf * ;; - *) $_trace_ "(cd $_source_; rm -rf *)" ;; - esac - fi - ;; - esac - _base_=$i - case $_base_ in - base) _release_=$base ;; - *) _release_=$delta ;; - esac - case $_trace_ in - "") if $AR_READ < $SHIP/$NAME/$_release_/$_base_ - then case $_shipproto_ in - ?*) $AR_LIST <$SHIP/$NAME/$_release_/$_base_ 2>/dev/null | grep '\.[chlyY]$' | $_shipproto_ -l - "${_proto_options_}" - ;; - esac - if test -d features && test ! -d feature - then ln -s features feature 2>/dev/null - elif test -d feature && test ! -d features - then ln -s feature features 2>/dev/null - fi - else error="$AR_PATH $type read failed" - fi - ;; - *) $_trace_ "$AR_READ < $SHIP/$NAME/$_release_/$_base_" - case $_shipproto_ in - ?*) $_trace_ "$AR_LIST <$SHIP/$NAME/$_release_/$_base_ 2>/dev/null | grep '\.[chlyY]\$' | $_shipproto_ -l - ${_proto_options_}" ;; - esac - ;; - esac - case $type in - base) break ;; - esac - ;; - delta) if $_trace_ $AR_DELTA -rf $SHIP/$NAME/$_release_/$base -z $SHIP/$NAME/$base/base - then $_trace_ touch $SHIP/$NAME/$base/UNCRATED - case $_shipproto_ in - ?*) case $_trace_ in - "") ($AR_DELTA -f $SHIP/$NAME/$base/base '*.[chlyY]'; $AR_DELTA -f $SHIP/$NAME/$_release_/$base '*.[chlyY]') 2>/dev/null | sort -u | $_shipproto_ -l - "${_proto_options_}" ;; - *) $_trace_ "($AR_DELTA -f $SHIP/$NAME/$base/base '*.[chlyY]'; $AR_DELTA -f $SHIP/$NAME/$_release_/$base '*.[chlyY]') 2>/dev/null | sort -u | $_shipproto_ -l - ${_proto_options_}" ;; - esac - ;; - esac - case $_trace_ in - "") if test -d features && test ! -d feature - then ln -s features feature 2>/dev/null - elif test -d feature && test ! -d features - then ln -s feature features 2>/dev/null - fi - ;; - esac - else error="$AR_DELTA $type read failed" - fi - break - ;; - esac - done - case $error in - "") $_trace_ touch $SHIP/$NAME/$_release_/UNCRATED ;; - *) echo "$_command_: $NAME: $_release_: uncrate error: $error" >&2 - case $_trace_ in - "") echo "uncrate $NAME $_release_ $type error: $error" >> $SHIP/$NAME/$LOG ;; - esac - _state_=error - ;; - esac - fi - cd $SHIP - eval STATE_$NAME=$_state_ - case $_state_ in - error) ;; - *) case $need in - ?*) for i in $need - do NEED_pax="$NEED_pax $NAME/$i" - done - ;; - *) eval RELEASE_$NAME=$_release_ SOURCE_$NAME=$_source_ TOOL_$NAME=$_tool_ - COMPONENTS_SELECT="$COMPONENTS_SELECT$NAME " - ;; - esac - ;; - esac - fi -done -case $COMPONENTS_SELECT in -" ") exit 0 ;; -esac -case $_uncrate_ in -?*) case $NEED_pax in - ?*) case $STATE_pax in - found) ;; - *) echo $_command_: pax required to uncrate$NEED_pax >&2 ;; - esac - ;; - esac - exit 0 - ;; -esac - -# -# determine the ordered list of components to (re)build -# - -case $SELECT in -" ") COMPONENTS="$ORDER $COMPONENTS_SELECT" ;; -*) COMPONENTS= - for NAME in $COMPONENTS_SELECT - do case $SELECT in - *" $NAME "*) COMPONENTS="$COMPONENTS $NAME" ;; - esac - done - ;; -esac - -# -# get the component closure -# - -case $_closure_ in -"") ORDER=$COMPONENTS - ;; -*) ORDER= - for NAME in $COMPONENTS - do old= - new=$NAME - while : - do case $new in - $old) break ;; - esac - dup= - for _item_ in $new - do # we assume ITEMS_* not in environment - eval _items_='"$'ITEMS_$_item_'"' - case $_items_ in - "") eval _release_='$'RELEASE_$_item_ - _items_=`cat $_item_/$_release_/items 2>/dev/null`" $_item_" - eval ITEMS_$_item_='"$'_items_'"' - ;; - esac - dup="$dup $_items_" - done - old=$new - new= - for _item_ in $dup - do eval SEEN_$_item_= - done - for _item_ in $dup - do eval seen='$'SEEN_$_item_ - case $seen in - "") eval SEEN_$_item_=1 - new="$new $_item_" - ;; - esac - done - done - eval ITEMS_$NAME='"'$new'"' - ORDER="$ORDER $new" - done - dup=$ORDER - ORDER= - for NAME in $dup - do eval SEEN_$NAME= - done - for NAME in $dup - do eval seen='$'SEEN_$NAME - case $seen in - "") eval SEEN_$NAME=1 - ORDER="$ORDER $NAME" - ;; - esac - done - ;; -esac -_built_= -COMPONENTS= - -for NAME in $ORDER -do case $_exclude_ in - *" $NAME "*) continue ;; - esac - eval _release_='$'RELEASE_$NAME - test -f $NAME/$_release_/items || continue - case $_force_ in - "") _built_=$NAME/$_release_/BUILT - eval _items_='$'ITEMS_$NAME - for i in $_items_ - do case " $COMPONENTS " in - *" $i "*) _built_=; break ;; - esac - case $i in - $NAME) ;; - *) eval _built_='"'$_built_ $i/'$'RELEASE_$i/BUILT'"' ;; - esac - done - case $_built_ in - ?*) if $_shipop_ newer $_built_ - then continue - fi - ;; - esac - ;; - esac - $_trace_ rm -f $NAME/$_release_/BUILT - if test "" != "$_force_" -o "" != "$_ignore_" -o ! -f $NAME/$_release_/ERROR - then COMPONENTS="$COMPONENTS $NAME" - $_trace_ rm -f $NAME/$_release_/ERROR - elif test ! -f $NAME/$_release_/BYPASS - then echo "$_command_: $NAME/$_release_: new shipment required" >&2 - fi -done - -# -# tame the environment -# - -case $_make_ in -?*) STATE_nmake=installed ;; -esac -case $_make_ in -""|$BIN/nmake) - MAKEPP=$INSTALLROOT/lib/cpp - MAKERULES=$INSTALLROOT/lib/make/makerules - export MAKEPP MAKERULES - _make_=$BIN/nmake - ;; -esac -COSHELL_OPTIONS=nodevfd -ENV= -MAKE_OPTIONS="clobber compare link=lib*.a*" -MAKEPATH= -PATH=:$INSTALLROOT/bin:$PATH -VPATH= -export COSHELL_OPTIONS ENV MAKE_OPTIONS MAKEPATH PATH VPATH -case $_AST_FEATURES in -"") _AST_FEATURES='UNIVERSE - att PATH_RESOLVE - logical' - export _AST_FEATURES - ;; -esac - -# -# (re)build the components -# - -cd $INSTALLROOT -for NAME in $COMPONENTS -do case $_exclude_ in - *" $NAME "*) continue ;; - esac - eval _items_='$'ITEMS_$NAME - case $_trace_ in - "") for i in $_items_ - do case $i in - $NAME) ;; - *) eval r='$'RELEASE_$i - if test ! -f $SHIP/$i/$r/BUILT - then if test -f $SHIP/$i/$r/ERROR - then m="had build errors" - elif test -f $SHIP/$i/$r/UNCRATED - then m="was not built" - else m="was not shipped" - fi - m="$NAME requires $i but $i $m" - echo "$m" >&2 - echo "$m" >> $SHIP/$NAME/$LOG - continue 2 - fi - ;; - esac - done - ;; - esac - eval _release_='$'RELEASE_$NAME _source_='$'SOURCE_$NAME _tool_='$'TOOL_$NAME - case $_total_ in - ?*) _components_="$_components_ $NAME/$_release_" - continue - ;; - esac - echo build $NAME $_release_ >&2 - $_trace_ cd $_source_ - case $_trace_ in - "") start="`date`" - if test -f $_bypass_ - then touch $SHIP/$NAME/$_release_/BYPASS - else case $STATE_nmake in - installed|ok) - case $NAME in - nmake) $_make_ -o "ignorelock mismatch" ${1+"$@"} - MAKEPP=$INSTALLROOT/lib/cpp ./nmake -o "ignorelock mismatch" -bcf Makerules.mk - MAKEPP=$INSTALLROOT/lib/cpp MAKERULES=./Makerules.mo ./nmake -o "ignorelock mismatch" install ${1+"$@"} - ;; - *) $_make_ -o "ignorelock mismatch" install ${1+"$@"} - ;; - esac - error=$? - ;; - *) if test -f Mamfile - then # here it is -- make+state in v7 shell -case $_read_ in -"") case `(echo ok | (read -r a; echo $a) 2>/dev/null)` in - ok) _read_='read -r' ;; - *) _read_=read ;; - esac - eval `( - mkdir /tmp/mam$$ - cd /tmp/mam$$ - echo 'int main(){return 0;}' > main.c - if $CC -c main.c >/dev/null 2>&1 - then if $CC -L. main.o -lc >/dev/null 2>&1 - then $CC -L. main.o -lc > libc.a >/dev/null 2>&1 || echo "mam_cc_L=' '" - fi - fi - echo "int f(){return(0);} int main(){return(f());}" > pic.c - if $CC -c pic.c >/dev/null 2>e - then e=\`wc -l e\` - s=\`wc pic.o\` - set x -Kpic -fpic -pic +z '-G 0' - while : - do shift - case $# in - 0) break ;; - esac - rm -f pic.o pic.exe - $CC $1 -c pic.c >/dev/null 2>e && test -f pic.o && $CC $1 -o ./pic.exe pic.o >/dev/null 2>&1 && test -f pic.exe || continue - case \`wc -l e\` in - $e) ;; - *) continue ;; - esac - case $1 in - ???*) os=\`wc pic.o\` - case $os in - $s) continue ;; - esac - m=\`echo " $1" | sed -e 's/^ [-+]//g' -e 's/./-& /g' -e 's/[-+] //g'\` - rm -f pic.o pic.exe - if $CC $m -c pic.c >/dev/null 2>e && test -f pic.o && $CC $m -o ./pic.exe pic.o >/dev/null 2>&1 && test -f pic.exe - then case \`wc -l e\` in - $e) continue - ;; - *) case \`wc pic.o\` in - $s|$os) continue ;; - esac - ;; - esac - fi - echo "mam_cc_PIC='$1'" - break - ;; - *) case \`wc pic.o\` in - $s) ;; - *) echo "mam_cc_PIC='$1'" - break - ;; - esac - ;; - esac - done - fi - cd / - rm -rf /tmp/mam$$ - )` - ;; -esac -case $_redirect_ in -"") case `(a=old; eval a=new /dev/null` in - new) _redirect_=new ;; - *) _redirect_=old ;; - esac - ;; -esac -( -_code_=1 -_list_= -_main_=0 -_mam_=MAM -_targ_=install - -trap " - mv $_mam_.list.tmp $_mam_.list - rm -f $_mam_.*.tmp - $_shipop_ state $_mam_.list < $_mam_.list | sort > $_mam_.time - trap 0 1 2 - exit \$_code_ -" 0 1 2 -# some shells die with diff,next,same in vars -: > $_mam_.diff.tmp -exec 9> $_mam_.list.tmp -if test -f $_mam_.list -a -f $_mam_.time -then $_shipop_ state $_mam_.list < $_mam_.list | sort > $_mam_.sort.tmp - comm -12 $_mam_.time $_mam_.sort.tmp | sed 's/ .*//' > $_mam_.same.tmp - rm -f $_mam_.sort.tmp -else : > $_mam_.same.tmp -fi - -_index_=_ -_ifs_=$IFS -case $_read_ in -"read") # read strips \ -- thanks a lot - # tmp file avoids char at a time read - sed 's/\\/\\\\/g' Mamfile > $_mam_.read.tmp - exec < $_mam_.read.tmp - ;; -*) exec < Mamfile - ;; -esac -eval `sed -e '1,/^make /d' -e '/^setv /!d' -e 's/^setv \([^ ]*\).*/\1= /' Mamfile` -for _data_ -do eval `echo $_data_ | sed -e 's/\"/\\\\"/g' -e 's/=/=\\"/' -e 's/\$/\\"/'` -done -_old_=1 -while IFS=' '; $_read_ _op_ _arg_ _val_ -do IFS=$_ifs_ - case $_op_ in - "note") continue - ;; - "info") case $_arg_ in - "mam") _old_= ;; - esac - continue - ;; - "setv") eval _data_='$'$_arg_ - case $_index_:$_data_ in - __*:*|*:) - case $_redirect_ in - new) eval $_arg_="$_val_" /dev/null && _attr_= ;; - esac - ;; - *) _attr_= - ;; - esac - case " $_val_ " in - *" metarule "*) _attr_=M$_attr_ ;; - esac - case $_attr_ in - *u*) echo $_name_ >> $_mam_.diff.tmp ;; - esac - _index_=_$_index_ - eval _name_$_index_=$_name_ - eval _prev_$_index_=$_prev_ - eval _cmds_$_index_=$_cmds_ - eval _attr_$_index_=$_attr_ - echo $_name_ >&9 - continue - ;; - "prev") case $_attr_ in - *u*) ;; - *) case $_force_ in - "") eval _arg_=$_arg_ - if grep "^$_arg_\$" $_mam_.diff.tmp >/dev/null - then _attr_=u$_attr_ - elif grep "^$_arg_\$" $_mam_.same.tmp >/dev/null - then : - else _attr_=u$_attr_ - fi - ;; - *) _attr_=u$_attr_ - ;; - esac - ;; - esac - continue - ;; - esac - case $_index_ in - _) echo $_op_: missing make op >&2; continue ;; - esac - case $_op_ in - "attr") case $_arg_ in - "meta"|"suff") _attr_=M ;; - esac - ;; - "exec"|"....") - case $_old_ in - "") _arg_=$_val_ - ;; - *) case $_val_ in - ?*) _arg_="$_arg_ $_val_" ;; - esac - ;; - esac - case $_cmds_ in - "") _cmds_=$_arg_ - ;; - *) _cmds_="$_cmds_ -$_arg_" - ;; - esac - ;; - "done") eval _arg_=$_arg_ - _prop_= - case $_arg_ in - $_targ_) _main_=2 ;; - esac - case $_arg_ in - $_name_)case $_attr_ in - *M*) ;; - *u*) case $_cmds_ in - "") case $_attr_ in - *u*) _prop_=u ;; - esac - ;; - *) eval "($_set_$_cmds_) &2 - _code_=$_status_ - exit $_code_ - ;; - esac - } - _prop_=u - echo $_name_ >> $_mam_.diff.tmp - ;; - esac - ;; - esac - _index_=$_prev_ - eval _name_='$'_name_$_index_ - eval _prev_='$'_prev_$_index_ - eval _cmds_='$'_cmds_$_index_ - eval _attr_='$'_attr_$_index_ - case $_attr_ in - *u*) ;; - *) _attr_=$_prop_$_attr_ ;; - esac - ;; - *) echo $_arg_: $_op_ $_name_ expected >&2 - ;; - esac - ;; - esac -done -exec 9>&- -case $_main_ in -2) _code_=0 ;; -*) echo "*** don't know how to make $_targ_" >&2 ;; -esac -exit $_code_ -); error=$? - # ... indent - elif test -f makefile - then make -f makefile install ${1+"$@"}; error=$? - elif test -f Makescript - then ./Makescript ${1+"$@"}; error=$? - elif test -f $_tool_.bs - then ./$_tool_.bs ${1+"$@"}; error=$? - else echo "$_command_: cannot build $NAME" >&2; error=1 - fi - ;; - esac - case $error+$NAME in - 0+nmake) $BIN/nmake -n -f /dev/null debug /dev/null 2>&1 || error=1 ;; - esac - case $error in - 0) touch $SHIP/$NAME/$_release_/BUILT ;; - *) touch $SHIP/$NAME/$_release_/ERROR ;; - esac - fi 2>&1 | (PATH=$OPATH; tee $SHIP/$NAME/$TMP 1>&2) - if test -f $SHIP/$NAME/$_release_/BUILT - then state=ok - elif test -f $SHIP/$NAME/$_release_/BYPASS - then state=bypass - else state=error - fi - { - echo "build $NAME $_release_ $state [$start] [`date`]" - case $CCS in - ?*) echo preroot CCS = $CCS ;; - esac - # some egreps blow this - sed \ - -e '/^$/d' \ - -e '/^[ ]/d' \ - -e '/^+ /d' \ - -e '/^[^ ]*:$/d' \ - -e '/^[a-z] - /d' \ - -e '/^[a-zA-Z_][a-zA-Z_0-9]*$/d' \ - -e '/^[a-zA-Z_][a-zA-Z_0-9]*=/d' \ - -e '/[Cc]opyright/d' \ - -e '/: warning: assignment .* == was expected/d' \ - -e '/: warning: if .* no effect/d' \ - -e '/: warning: Symbol .* multiply defined/d' \ - $SHIP/$NAME/$TMP - rm -f $SHIP/$NAME/$TMP - } >> $SHIP/$NAME/$LOG 2> /dev/null - eval STATE_$NAME=$state - ;; - *) if test -f $_source_/$_bypass_ - then $_trace_ "refer to $_source_/$_bypass_ to install $NAME" - else case $STATE_nmake in - installed|ok) - case $NAME in - nmake) $_trace_ $_make_ -o "ignorelock mismatch" ${1+"$@"} - $_trace_ ./nmake -o "ignorelock mismatch" -bcf Makerules.mk - $_trace_ ./nmake -o "ignorelock mismatch" install ${1+"$@"} - ;; - *) $_trace_ $_make_ -o "ignorelock mismatch" install ${1+"$@"} - ;; - esac - ;; - *) if test -f $_source_/Mamfile - then $_trace_ "mamexec < Mamfile" - elif test -f $_source_/Makescript - then $_trace_ ./Makescript ${1+"$@"} - elif test -f $_source_/$_tool_.bs - then $_trace_ ./$_tool_.bs ${1+"$@"} - else $_trace_ install $NAME - fi - ;; - esac - fi - ;; - esac - $_trace_ cd $INSTALLROOT - - # - # accept stuff built before nmake to sync the state files - # - - case $NAME in - $ACCEPT) - for NAME in $COMPONENTS - do eval state='$'STATE_$NAME _source_='$'SOURCE_$NAME - case $state in - ok) case $_trace_ in - "") cd $_source_ - { - $BIN/nmake -o "accept ignorelock mismatch touch" install force_shared=1 - case $NAME in - lib*) $BIN/nmake -o "accept" install ;; - esac - } 2>&1 | (PATH=$OPATH; tee $SHIP/$NAME/$TMP 1>&2) - { - echo "accept $NAME" - egrep -v '^([^ ]*:$| |\+ |[a-z] - |[a-zA-Z_][a-zA-Z_0-9]*=|$)' $SHIP/$NAME/$TMP - rm -f $SHIP/$NAME/$TMP - } 2>&1 >> $SHIP/$NAME/$LOG - cd $INSTALLROOT - ;; - *) $_trace_ cd $_source_ - $_trace_ $BIN/nmake -o "accept ignorelock mismatch touch" install force_shared=1 - case $NAME in - lib*) $_trace_ $BIN/nmake -o "accept" install ;; - esac - $_trace_ cd $INSTALLROOT - ;; - esac - ;; - esac - done - case $NAME in - $ACCEPT) break ;; - esac - ;; - esac -done -case $_total_ in -?*) case $RANDOM in - $RANDOM)cd $SHIP - ls -Cd $_components_ - ;; - *) PS3='' - eval ' select i in $_components_ - do : - done /dev/null` - case $r in - *\[no\]*) r= ;; - esac - case $r' + '$state in - ?*' + '*|*' + 'error) - address=`cat $o` - owner=`echo $address | sed -e 's/.*\(.............\)/\1/' -e 's/^[^a-zA-Z_]/_/' -e 's/[^a-zA-Z_0-9]/_/g'` - eval f='$'built_$owner - eval built_$owner='"$'f $NAME'"' - report= - for f in $SHIP/$NAME/$LOG $r - do case `ls -dt $f $SHIPSLOG/!$owner 2>/dev/null` in - $f*) report="$report $f" ;; - esac - done - case $report in - ?*) eval f='$'address_$owner - case $f in - "") owners="$owners $owner" - eval address_$owner=$address - ;; - esac - eval eval report_$owner=\\\"\$report_$owner \\\[$NAME\\\] $report\\\" - ;; - esac - ;; - esac - fi -done - -# -# check if any components required pax to uncrate -# - -case $NEED_pax in -?*) AR_DELTA=$INSTALLROOT/bin/pax - ($AR_DELTA -f /dev/null -z /dev/null) >/dev/null 2>&1 || STATE_pax=error - case $STATE_pax in - ok) $_trace_ exec $_command_ $_options_ $SELECT ${1+"$@"} ;; - *) echo $_command_: pax required to uncrate$NEED_pax >&2 ;; - esac - ;; -esac - -# -# done -# - -exit 0 diff --git a/cde/programs/dtksh/ksh93/ship/shipop.c b/cde/programs/dtksh/ksh93/ship/shipop.c deleted file mode 100644 index ecb5281ee..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipop.c +++ /dev/null @@ -1,280 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: shipop.c /main/4 1996/10/04 15:58:45 drk $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS PROPRIETARY SOURCE CODE LICENSED BY * -* AT&T CORP. * -* * -* Copyright (c) 1995 AT&T Corp. * -* All Rights Reserved * -* * -* This software is licensed by AT&T Corp. * -* under the terms and conditions of the license in * -* http://www.research.att.com/orgs/ssr/book/reuse * -* * -* This software was created by the * -* Software Engineering Research Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* gsf@research.att.com * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -static const char id[] = "\n@(#)shipop (AT&T Bell Laboratories) 06/11/92\0\n"; - -#include -#include -#include - -#define elementsof(x) (sizeof(x)/sizeof(x[0])) - -static char* cmd = "shipop"; -static char* op; - -static int status; - -extern __MANGLE__ int close __PROTO__((int)); -extern __MANGLE__ void exit __PROTO__((int)); -extern __MANGLE__ int open __PROTO__((const char*, int, ...)); -extern __MANGLE__ int read __PROTO__((int, char*, int)); -extern __MANGLE__ int strcmp __PROTO__((const char*, const char*)); -extern __MANGLE__ time_t time __PROTO__((time_t*)); - -static void -error __PARAM__((int level, const char* file, const char* msg), (level, file, msg)) __OTORP__(int level; const char* file; const char* msg;){ - fprintf(stderr, "%s: %s", cmd, op); - if (level == 1) fprintf(stderr, ": warning"); - if (file) fprintf(stderr, ": %s", file); - if (msg) fprintf(stderr, ": %s", msg); - fprintf(stderr, "\n"); - if (level > status) - { - if (level > 2) exit(level - 2); - status = level; - } -} - -/* - * shipop newer [ reference [ file ... ] ] - */ - -static int -shipnewer __PARAM__((char** argv), (argv)) __OTORP__(char** argv;){ - unsigned long ref; - struct stat st; - - if (!*argv || stat(*argv, &st)) return(1); - ref = (unsigned long)st.st_mtime; - while (*++argv) - if (stat(*argv, &st) || ref < (unsigned long)st.st_mtime) return(1); - return(0); -} - -#define HASHPART(h,c) (h = (h) * 987654321L + 123456879L + (c)) - -static char buf[4096]; - -static unsigned long -sealfile __PARAM__((char* file, int fd, unsigned long s), (file, fd, s)) __OTORP__(char* file; int fd; unsigned long s;){ - unsigned char* b; - unsigned char* e; - int n; - - HASHPART(s, 0); - while ((n = read(fd, buf, sizeof(buf))) > 0) - { - b = (unsigned char*)buf; - e = b + n; - while (b < e) HASHPART(s, *b++); - } - if (n < 0) error(2, file, "read error"); - return(s); -} - -/* - * shipop seal [ file ... ] - */ - -static int -shipseal __PARAM__((char** argv), (argv)) __OTORP__(char** argv;){ - char* f; - int fd; - unsigned long s; - - s = 0; - if (!*argv) s = sealfile("/dev/stdin", 0, s); - else while (f = *argv++) - { - if (*f == '-' && !*(f + 1)) s = sealfile("/dev/stdin", 0, s); - else if ((fd = open(f, 0)) < 0) error(2, f, "cannot read"); - else - { - s = sealfile(f, fd, s); - close(fd); - } - } - printf("%08lx\n", s); - return(status); -} - -/* - * shipop state reference [ file ... | buf) - { - *s = 0; - if (!stat(buf, &st)) - printf("%s %ld\n", buf, (long)st.st_mtime - ref); - } - } while (c != EOF); - return(status); -} - -/* - * shipop time [ file ] - */ - -static int -shiptime __PARAM__((char** argv), (argv)) __OTORP__(char** argv;){ - struct stat st; - time_t date; - - if (*argv && !stat(*argv, &st)) date = st.st_mtime; - else time(&date); - printf("%08lx\n", (long)date); - return(status); -} - -/* - * shipop xap [ file ... ] - */ - -static int -shipxap __PARAM__((char** argv), (argv)) __OTORP__(char** argv;){ - error(2, "xap not implemented yet", (char*)0); - return(1); -} - -struct optab -{ - char* name; - int (*func) __PROTO__((char**)); -}; - -static struct optab ops[] = -{ - "newer", shipnewer, - "seal", shipseal, - "state", shipstate, - "time", shiptime, - "xap", shipxap, -}; - -int main __PARAM__((int argc, char** argv), (argc, argv)) __OTORP__(int argc; char** argv;){ - char* s; - int i; - - if (!(s = *++argv)) - exit(0); - for (i = 0; i < elementsof(ops); i++) - if (!strcmp(s, ops[i].name)) - { - op = ops[i].name; - exit((*ops[i].func)(argv + 1)); - } - fprintf(stderr, "Usage: %s %s", cmd, ops[0].name); - for (i = 1; i < elementsof(ops); i++) - fprintf(stderr, " | %s", ops[i].name); - fprintf(stderr, " [ file ... ]\n"); - exit(2); -} diff --git a/cde/programs/dtksh/ksh93/ship/shipout b/cde/programs/dtksh/ksh93/ship/shipout deleted file mode 100755 index 5ef658963..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipout +++ /dev/null @@ -1,1908 +0,0 @@ -: -# @(#)shipout (gsf@research.att.com) 07/17/95 -# -# shipout [ options ... ] [ name ... ] [ tool ... ] -# -# ship software to recipient using system|user info in $SHIPINFO -# -# options -- + turns the corresponding option off -# -# -b ship bases with deltas -# -c don't generate tool closure -# -d don't ship deltas -# -i list info on specified recipient(s) only -# -k mark recipient(s) as having received tool(s) -# -l file list of people to ship to -# -m don't send shipment manifest mail message -# -n show but don't execute -# -o set shipment ownership to shipper -# -p name next argument is a recipient to ship to -# -s don't send shipment support files -# -t don't execute but show total shipment -# -u [[yy]mm]dd ignore db info for date pattern -# -v yymmdd override current date stamp -# -w shipment suitable for www -# -x format pax output format and compression -# -C files add to default crate file list -# -D secs delay in seconds between sends -# -F force db override -# -S files add to default support file list -# -# name -- recipient address -# -# machine!user uucp address -# host:directory rcp address -# *%[beta.]bin[.arch] compressed cpio binary archive in Z/*[.arch] -# *%ftp sh script with ftp get's on stdout -# *%[beta.]lib[.arch] compressed cpio binary archive in Z/*[.arch] -# *%list shipment file list on stdout -# *%pull sh script with datakit pull's on stdout -# *%push sh script with datakit push's on stdout -# *%[beta.]src compressed cpio src archive in Z/* -# -# the message file is evaluated by the shell and the following variables -# are predefined by ship: -# -# f list of expanded file names -# name name of shipee -# - -umask 02 -PATH=:$PATH - -SHIPSLOG=${SHIPSLOG:-shipslog} -SHIPINFO=${SHIPINFO:-$SHIPSLOG/info} -SHIPFILES="README shipin shipout" -SHIPAUX="shipiffe.sh shipop.c shipproto.c" -SHIPMENT=*[0-9][0-9][0-9][0-9][0-9][0-9] -SHIPPER=${SHIPPER:-${USER:-${LOGNAME:-${HOME##*/}}}} -SHIPSPOOL=${SHIPSPOOL:-/var/spool/uucppublic} -SHIPORG=${SHIPORG:-"Software and Systems Research"} -SHIPLOGO=${SHIPLOGO:-"http://www1126.research.att.com/logos/attbllogo.gif align=middle"} -SHIPMM2HTML=${SHIPMM2HTML:-mm2html} -CRATEFILES="copyright items message promo release report" -TMP=${TMPDIR:=/tmp}/ship$$ -FROMSYS=$( (uname -n || hostname || cat /etc/whoami) 2>/dev/null ) - -test -f shipinit && . ./shipinit - -function errexit -{ - # print out an error message on unit 2 and exit - print -u2 - "$command: $@" - exit 1 -} - -function warning -{ - print -u2 - "$command: warning: $@" -} - -function cleanup # exitcode -{ - trap - EXIT INT TERM - db_done - rm -f $TMP.? - exit $1 -} - -db_access= -db_data= -db_disable= -db_key_base= -db_key_delta= -db_pid= -db_status= - -# -# send request to dbm server -# status returned in db_status -# data returned in db_data -# - -function db_request # op args ... -{ - print -p "$@" - read -p db_status db_data - case $db_debug in - ?*) print -u2 DB: "$@": $db_status $db_data ;; - esac - case $db_status in - I) return 0 ;; - E) print -u2 $logfile: $db_data; return 1 ;; - *) return 1 ;; - esac -} - -# -# initialize db -# - -function db_init # machine user -{ - typeset log=$logfile machine=$1 user=$2 i j l - - case $db_disable in - ?*) return 0 ;; - esac - case $db_debug in - grep) db_access=grep ;; - esac - case $db_access in - "") case $log in - "") ifs=$IFS - IFS=: - set -- $PATH - IFS=$ifs - for i - do case $i in - */bin) i=${i%/bin} - for j in /share/ / - do l=${i}${j}lib/ship/log - if test -f $l.dir -a -r $l.dir -a -w $l.dir - then log=$l - break 2 - fi - done - ;; - esac - done - case $log in - "") log=$SHIPSLOG/log ;; - esac - ;; - esac - case $log in - /*) ;; - *) log=$PWD/$log ;; - esac - db_access=grep - if cs /dev/null 2>&1 - then cs -i /dev/tcp/share/dbm/group=ship |& - db_pid=$! - if db_request version - then db_request open $log w || errexit $log: cannot access log - db_access=dbm - logfile=$log - fi - fi - ;; - esac - case $db_debug in - ?*) print -u2 DB: init: access=$db_access logfile=$logfile ;; - esac - case $db_access in - dbm) first_time=0 - db_check - $machine $user shipin "*" base || first_time=1 - ;; - grep) typeset -L2 dir=$machine - case $logfile in - ?*) mv $logfile $SHIPSLOG/.tmp. - sort -r < $SHIPSLOG/.tmp. | sort -m -u +0 -1 > $logfile - rm -f $SHIPSLOG/.tmp. - ;; - esac - logfile=$SHIPSLOG/$dir/$machine/$user - if test "" = "$force" -a -r "$logfile" - then first_time=0 - else first_time=1 - case $noexec in - "") if test ! -d "$SHIPSLOG/$dir" - then mkdir "$SHIPSLOG/$dir" || logfile=$SHIPSLOG/log - fi - if test ! -d "$SHIPSLOG/$dir/$machine" - then mkdir "$SHIPSLOG/$dir/$machine" || logfile=$SHIPSLOG/log - fi - ;; - esac - fi - ;; - esac -} - -# -# end db interaction -# - -function db_done # -{ - case $db_disable in - ?*) return 0 ;; - esac - case $noexec in - "") case $db_access in - dbm) db_request close - db_request quit - kill $db_pid - ;; - grep) case $logfile in - ?*) mv $logfile $SHIPSLOG/.tmp. - sort -r < $SHIPSLOG/.tmp. | sort -m -u +0 -1 > $logfile - rm -f $SHIPSLOG/.tmp. - ;; - esac - ;; - esac - ;; - esac -} - -# -# check if < machine user tool version type > was sent -# - -function db_check # [ - ] machine user tool version type -{ - typeset k key ks sav x nocheck= - - case $db_disable:$first_time:$force in - 1:*:*|*:1:*|*:*:1) return 1 ;; - esac - case $1 in - -) shift; nocheck=1 ;; - esac - typeset a=$1!$2 n=$3 v=$4 t=$5 m - case $5 in - "*") ks="base delta" ;; - base) ks=base ;; - *) ks=delta ;; - esac - for k in $ks - do key=$a,$n,$k - eval sav=\$db_key_$k - case $key in - $sav) eval set -- \$db_val_$k - ;; - *) case $db_access in - dbm) if db_request get $key - then set -- $db_data - else continue - fi - ;; - grep) set -- $(grep "^$key" $logfile) - case $# in - 0) continue ;; - esac - shift - ;; - esac - eval db_key_$k='$key' db_val_$k='$*' - ;; - esac - case $1/$2 in - $v/$t) case $undo in - "") ;; - *) case $nocheck in - "") case $3 in - $undo) continue ;; - esac - ;; - esac - ;; - esac - case $v in - "*") return 0 ;; - esac - ;; - *) case "$v" in - "*") return 0 ;; - esac - continue - ;; - esac - if test -d $n - then m=$(shipop time $n/$1/$2) - else m=$(shipop time $n) - fi - case $6 in - ""|$m) return 0 ;; - *) return 1 ;; - esac - done - return 1 -} - -# -# note that < machine user tool version type > was sent -# - -function db_note # machine user tool version type name -{ - typeset k v m - - case $db_disable in - ?*) return 0 ;; - esac - case $5 in - base) k=base ;; - *) k=delta ;; - esac - if test -d $3 - then m=$(shipop time $3/$4/$5) - else m=$(shipop time $3) - fi - v="$1!$2,$3,$k $4 $5 $date $SHIPPER $6 $m" - case $db_access in - dbm) db_request put $v ;; - grep) print $v >> $logfile ;; - esac -} - -# -# output SHIPMENT stamp for file [current date] -# - -function shipstamp # file -{ - typeset -Z2 day month - typeset -R2 year - integer mon Jan=1 Feb=2 Mar=3 Apr=4 May=5 Jun=6 \ - Jul=7 Aug=8 Sep=9 Oct=10 Nov=11 Dec=12 - case $# in - 0) set -- $(date) - shift 1 - ;; - *) set -- $(ls -ld $1 2>/dev/null) - while : - do case $# in - [01]) break ;; - esac - case $1 in - Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) - case $2 in - [1-9]|[0-3][0-9]) - case $3 in - [0-9]*) break ;; - esac - ;; - esac - ;; - - esac - shift - done - ;; - esac - mon=$1 - day=$2 - month=$mon - case $3 in - *:*:*) year=$5 - ;; - *:*) set -- $(date) - year=$6 - if (($mon > $2)) - then let year=year-1 - fi - ;; - *) year=$3 - ;; - esac - print $year$month$day -} - -# -# prepare $tool for shipping -# - -function package # tool [blocks] -{ - typeset tool=$1 - integer package_blocks=${2-20} - integer package_chunk=package_blocks*8*1024 - integer size i=0 skip=0 - typeset -RZ3 suffix - typeset fsize - - if test $tool.000 -nt $tool - then return 0 - fi - fsize=$(wc -c $tool) - size=${fsize%$tool} - if ((size <= package_chunk)) - then return 1 - fi - print packaging $tool - rm -f $tool.??? - while (( size > 0)) - do suffix=$i - dd if=$tool of=$tool.$suffix bs=8k skip=$skip count=$package_blocks 2> /dev/null - let i=i+1 skip=skip+package_blocks size=size-package_chunk - done - set -- $tool.??? - case $1 in - *.\?\?\?) errexit "$tool: cannot package" ;; - esac - return 0 -} - -function gencontrol # tool -{ - typeset tool=${1%/*} - typeset format=${1#$tool/} - typeset init - typeset parts - - if test -f $1 - then if package $1 - then parts='.???' - else parts='' - fi - else # $SHIPFILES - print - "cp $date.$SHIPPER/${tool%/*} \$INSTALLROOT/ship" >> $TMP.u - return - fi - tooldir=${tool%%/*} - { - print - "if test ! -f \$INSTALLROOT/ship/$tooldir/items" - set -- $tool/$format$parts - case $# in - 1) print - "then if test -f $tool/$format$parts" - prefix="then" - ;; - *) print - "then _unspool_nope= - for i in $* - do if test ! -f \$i - then _unspool_nope=1 - break - fi - done - case \$_unspool_nope in" - prefix='"")' - ;; - esac - case $format in - base|delete) init= ;; - *) init=$basetoo ;; - esac - case $init in - "") print - " $prefix if test ! -d \$INSTALLROOT/ship/$tooldir - then mkdir \$INSTALLROOT/ship/$tooldir - fi - rm -rf \$INSTALLROOT/ship/$tool - mkdir \$INSTALLROOT/ship/$tool" - prefix= - ;; - esac - print - " $prefix cat $tool/$format$parts > \$INSTALLROOT/ship/$tool/$format" - print - " rm -f $tool/$format$parts" - case $init in - "") for i in $CRATEFILES - do if test -s $tool/$i - then print - " echo \"$(cat $tool/$i 2>/dev/null)\" > \$INSTALLROOT/ship/$tool/$i" - elif test -f $tool/$i - then print - " : > \$INSTALLROOT/ship/$tool/$i" - fi - done - if test "" != "$www" - then owner= - else if test "" = "$shipper" -a -s $tool/owner - then owner=$(<$tool/owner) - else owner=$SHIPPER - fi - case ${TOSYS##*!} in - ${owner%%!*}) owner=${TOSYS%!*}!$owner ;; - *) owner=$TOSYS!$owner ;; - esac - fi - print - " echo \"$owner\" > \$INSTALLROOT/ship/$tool/owner" - ;; - esac - case $# in - 1) print - " fi" - ;; - *) print - " ;; - esac" - ;; - esac - print - "fi" - } >> $TMP.u -} - -function instructions # first -{ - integer item=0 first=$1 - typeset tool pack packages omit main - - case $first in - 0) print " -As a repeat recipient:" - case $redo in - 1) print " -($((item=item+1))) This shipment includes an update to the installation support tools. - Any tools that failed to build previously will be attempted again." - ;; - esac - ;; - 1) print " -As a first time recipient:" - ;; - esac - - print " -($((item=item+1))) Wait for a \\\`copy succeeded' message from uucp for the file: - - \$user/$FROMSYS/$date.$SHIPPER/manifest" - - print " -($((item=item+1))) For safety do not run as root. If you are not running as \$user then: - - RECIPIENT=\$user - export RECIPIENT" - - packages=$(for tool in "${ship_list[@]}" - do tool=${tool%%/*} - if test -f $tool/Mamfile - then sed -e '/^setv PACKAGE/!d' -e 's/^setv / /' -e 's/ /=/' -e 's/\$/\\&/g' $tool/Mamfile - fi - done | sort -t= -u +0 -1) - case $packages in - ?*) omit= - for tool in "${ship_list[@]}" - do case $tool in - lib*) tool=${tool%%/*} - tool=${tool#lib} - case $omit in - "") omit="$tool" ;; - *) omit="$omit|$tool" ;; - esac - ;; - esac - done - case $omit in - ?*) main=$(echo "$packages" | egrep "PACKAGE_($omit)[=_]" | sed -e 's/^ PACKAGE_\([^_=]*\).*/\1/' | sort -u) - packages=$(echo "$packages" | egrep -v "PACKAGE_($omit)[=_]") - ;; - esac - esac - - case $first in - 0) print " -($((item=item+1))) Name the directory under which previous shipments were installed: - - INSTALLROOT=" - ;; - 1) case $main in - ""|*" -"*) main= ;; - *) main=" - A good final installation directory name would be /usr/add-on/$main." ;; - esac - print " -($((item=item+1))) Create a shipment root directory under which all source and binaries - will be generated. This should not be a final installation directory.$main - - INSTALLROOT= - test -d \\\$INSTALLROOT || mkdir \\\$INSTALLROOT - cd \\\$INSTALLROOT - test -d ship || mkdir ship" - ;; - esac - - print " -($((item=item+1))) If $uuspool/\$user/$FROMSYS was copied to \\\$SPOOLROOT then: - - SHIPSPOOL=\\\$SPOOLROOT - export SHIPSPOOL" - - print " -($((item=item+1))) If your system has att and bsd/ucb universes then in general the tools - will have more functionality when built in the bsd/ucb universe. The - exception is on solaris where /usr/ucb/cc is fubar. Set cc by: - - CC='hackcc -systype bsd43' CCFLAGS='-g' # just an example # - export CC CCFLAGS" - - case $packages in - ?*) print " -($((item=item+1))) This shipment refers to some installation dependent software packages. - Redefine and export any of the following definitions that are incorrect: - -$packages" - ;; - esac - - print " -($((item=item+1))) Execute the following commands to unpack and install the shipment: - - cd \\\$INSTALLROOT" - case $first in - 1) print "\ - cp \\\${SHIPSPOOL-$uuspool/\$user/$FROMSYS}/$date.$SHIPPER/shipin ship/shipin - chmod 0755 ship/shipin" - ;; - esac - print "\ - nohup ksh ship/shipin &" - - print " -($((item=item+1))) Use shipout within \\\$INSTALLROOT/ship to ship to other machines. - \\\$INSTALLROOT/ship/README contains more detailed information." - -} - -function buildscript # machine user -{ - # create mscript to execute as a . script - typeset tool format - integer delta=0 first=1 no_shipin - mscript=$TMP.s tfile=$TMP.f - case $message in - ?*) { - print "cat > $tfile </dev/null | egrep 'DELTA!!!|!PAX!D!' >/dev/null - then t="$format delta" delta=1 - else t="$format patch" - fi - ;; - *) errexit "$format: invalid format" - ;; - esac - print " $n$d$t" - done - print - if ((delta)) - then print "\ -Unpacking delta shipments requires the new pax command. -" - fi - for tool in "${ship_list[@]}" - do if test ! -r $tool - then continue - fi - format=${tool##*/} - tool=${tool%/$format} - if test -s "$tool/message" - then item=${tool%%/*} - eval x='$'_notes_$item - case $x in - 0) print "\ -$item notes: -" - eval _notes_$item=1 - ;; - 1) if cmp -s "$tool/message" "$item/$format/message" - then continue - fi - ;; - esac - cat "$tool/message" - print - fi - done - if test -f ship.tail - then cat ship.tail - elif test -f $HOME/.signature - then cat $HOME/.signature - fi - print '!EOF!' - case $noexec in - "") print 'mail $mail < $tfile' - ;; - *) print 'print "mail $mail < $mscript - ;; - esac -} - -function tosys # machine -{ - # construct return mail address - typeset i IFS=! - TOSYS= - for i in $@ - do case $i in - %*) ;; - *) TOSYS=$i!$TOSYS ;; - esac - done - case $TOSYS in - $FROMSYS!) TOSYS= ;; - esac - TOSYS=$TOSYS$FROMSYS -} - -function genshiplist # machine user mail -{ - typeset tool file x n v t need_pax= missing= - integer i=0 j=0 - - lclfiles= rmtfiles= - db_init $1 $2 - db_check - $1 $2 pax "*" base || need_pax=1 - machine=$1 - user=$2 - mail=$3 - unset ship_list redo - for file in $SHIPFILES - do v=$(shipstamp $file) - if db_check $machine $user $file $v base - then continue - fi - ship_list[i]=$file/$v/base - i=i+1 - case " $SHIPAUX " in - *" $file "*) redo=1 ;; - esac - done - j=i - for tool in "${tool_list[@]}" - do n=${tool%%/*} - case $need_pax in - "") eval t=\$type_$n - case $t in - pax) continue ;; - esac - ;; - esac - v=${tool#*/} - v=${v%/*} - t=${tool##*/} - case $tool in - */*/$SHIPMENT) - if db_check $machine $user $n $t "*" - then case $basetoo in - "") case $noexec in - "") db_note $machine $user $n $t base $name ;; - esac - ;; - ?*) if db_check $machine $user $n $v base - then : - elif test -f $n/$v/base - then ship_list[i]=$n/$v/base - i=i+1 - else print -u2 "$n/$v/base: missing base archive" - missing=1 - fi - ;; - esac - elif test -f "$n/$v/base" - then if db_check $machine $user $n $v base - then : - else ship_list[i]=$n/$v/base - i=i+1 - fi - case $basetoo in - "") continue ;; - esac - elif test -f $n/$t/base - then ship_list[i]=$n/$t/base - i=i+1 - else print -u2 "$n/$t/base: missing base archive" - missing=1 - fi - ;; - esac - if db_check $machine $user $n $v $t - then : - else ship_list[i]=$tool - eval clean_$n= - i=i+1 - fi - done - case $missing in - ?*) exit 1 ;; - esac - if ((j>=i)) - then case $redo in - "") case $total in - "") print -u2 "$mail is up to date" ;; - *) print -u2 "\\n$mail: up to date" ;; - esac - return 0 - ;; - esac - else case $mark in - ?*) case $user:$noexec in - ?*:) for tool in "${ship_list[@]}" - do x=${tool#*/} - x=${x%/*} - db_note $machine $user ${tool%%/*} $x ${tool##*/} $name - done - ;; - esac - return 0 - ;; - esac - fi - case $total in - ?*) print -u2 "\\n$mail:" - PS3='' - select i in ${ship_list[*]} - do : - done on given - case $transport in - uucp) typeset dest=$1!$uupublic/$2/$FROMSYS/$date.$SHIPPER - print "$rmtfiles -$date.$SHIPPER/unspool -$date.$SHIPPER/manifest" > $TMP.m - print uucp -r -C $TMP.u $dest/unspool - case $noexec in - "") uucp -r -C $TMP.u $dest/unspool ;; - esac - case $SHIPID in - ?*) print $date.$SHIPPER/id >> $TMP.m - id="$SHIPPER SEAL $(date) $1!$2" - print "$1!$SHIPID $id" > $TMP.i - print uucp -r -C $TMP.i $dest/id - case $noexec in - "") uucp -r -C $TMP.i $dest/id ;; - esac - case $noexec in - "") print "$id\\t$(shipop seal $lclfiles $TMP.u $TMP.m $TMP.i)" >> $SHIPSLOG/seals - ;; - esac - ;; - esac - print uucp -r -C -m -n"$2" $TMP.m $dest/manifest - case $noexec in - "") uucp -r -C -m -n"$2" $TMP.m $dest/manifest ;; - esac - ;; - uuto) print uuto -m $TMP.u $1!$2 - case $noexec in - "") uuto -m $TMP.u $1!$2 ;; - esac - ;; - esac - case $noexec in - ?*) case $SHIPID in - ?*) print "ID:" - cat $TMP.i - ;; - esac - print "MANIFEST:" - cat $TMP.m - print "UNSPOOL:" - cat $TMP.u - ;; - esac -} - -function doship # -{ - # ship the files - typeset i j tool file - integer d - case "$info" in - ?*) fixedname=${name%% *} - print "$fixedname $address $phone $mail $company $project $transport" - return - esac - user=${mail##*!} machine=${mail%!*} - user=${user%%@*} machine=${machine#*@} - target=$machine!~/$user/$FROMSYS - uuspool=$SHIPSPOOL - case $transport in - uucp) uupublic='~' - ;; - uuto) uuspool=$uuspoool/receive - uupublic=$uuspool - print -u2 $transport: transport not supported for $user - return - ;; - *) print -u2 $transport: unknown transport for $user - return - ;; - esac - if genshiplist $machine $user $mail - then return - fi - tosys $machine - > $TMP.u - for i in "${ship_list[@]}" - do gencontrol "$i" - done - case $redo in - ?*) for i in $tools - do print - "for i in \$INSTALLROOT/ship/${i%/*}/*" - print - "do if test -d \$i -a ! -f \$i/BUILT" - print - " then rm -f \$i/[BEU]*" - print - " fi" - print - "done" - done >> $TMP.u - ;; - esac - buildscript $machine $user - dtime=0 - for tool in "${ship_list[@]}" - do for i in $tool.??? - do case $i in - *.\?\?\?|*.000) - d=25 - if test -f $tool.001 - then j=$i - elif test -f $tool - then i=$tool j=$tool - else # here for $SHIPFILES - i=${tool%%/*}; j=$date.$SHIPPER/$i - fi;; - *) j=$i d=50;; - esac - dfile=$target/$j - if test -f "$i" - then lclfiles="$lclfiles $i" - case $rmtfiles in - "") rmtfiles=$j - ;; - *) rmtfiles="$rmtfiles -$j" - ;; - esac - print uucp -r $nocopy $PWD/"$i" "$dfile" - case $noexec in - "") uucp -r $nocopy $PWD/"$i" "$dfile" - dtime=dtime+d - ;; - esac - fi - done - i=${tool#*/} - i=${i%/*} - case $noexec in - "") db_note $machine $user ${tool%%/*} $i ${tool##*/} $name ;; - esac - done - if test -r $mscript - then . $mscript - fi - sendcontrol $machine $user -} - -function dosend # recipient open -{ - # lookup in database and transport software to them - # if is given, the database is re-opened - addr=$1 - db_disable= - case $addr in - *%beta.*|*%bin*|*%ftp|*%lib*|*%list|*%pull|*%push|*%src) - db_disable=1 - mail=$addr - transport=${addr##*'%'} - machine=%$transport - user=${addr%"$machine"} - case $transport in - beta.*) beta=$SHIPPER transport=${transport#beta.} ;; - *) beta= ;; - esac - case $transport in - bin*|lib*|src) - dir=ship - out=${user:-${transport%%.*}} - view= - case $transport in - bin) arch=${PWD%/ship} - case $arch in - */arch/*) - a=${arch##*/} - ;; - *) a=${HOSTTYPE:-$(hostinfo type)} - ;; - esac - out=$out.$a - type="$a binary" - type_H=".I $a -.B binary" - ;; - bin.*) arch=${transport#bin.} - out=$out.$arch - transport=bin - type="$arch binary" - type_H=".I $arch -.B binary" - view=1 - ;; - lib) arch=${PWD%/ship} - case $arch in - */arch/*) - a=${arch##*/} - ;; - *) a=${HOSTTYPE:-$(hostinfo type)} - ;; - esac - out=$out.$a - type="$a binary and library" - type_H=".I $a -.B binary -and -.B library" - ;; - lib.*) arch=${transport#lib.} - out=$out.$arch - transport=lib - type="$arch binary and library" - type_H=".I $arch -.B binary -and -.B library" - view=1 - ;; - *) arch=.. - type="source" - type_H=".B source" - ;; - esac - ccprobe= - case $view in - ?*) case $PWD in - */arch/*) - arch=${PWD%/arch/*}/arch/$arch - export INSTALLROOT=$arch - vpath $arch ${PWD%/arch/*} 2>/dev/null - export VPATH=$arch:${PWD%/arch/*} - for f in $arch/lib/probe/C/make/[!p]*bincc $arch/lib/probe/C/make/[!p]*cc $arch/lib/probe/C/make/[!p]* - do if test -f $f - then ccprobe=CC.PROBE=$f - break - fi - done - ;; - esac - ;; - esac - MAKE=$(whence nmake) - ;; - *) dir=. - ;; - esac - ;; - *:*) transport=rcp - mail=$1 - host=${addr%:*} - dir=${addr#*:} - case $host in - *@*) user=${host%@*} - host=${host#*@} - ;; - *) user=${dir%%/*} - case $user in - '~'*) user=${user#~} ;; - *) user=$SHIPPER ;; - esac - ;; - esac - machine=$host - ;; - *!*) name=${1##*!} transport=uucp - ;; - *@*) name=${1%%@*} transport=uucp - ;; - *) transport=db - ;; - esac - case $transport in - uucp) address= phone= mail=$1 project= - doship - return 1 - ;; - db) typeset -l given match - case $shipinfo_test in - "") if test ! -f "$SHIPINFO" - then errexit "$SHIPINFO: cannot find information file" - fi - shipinfo_test=1 - ;; - esac - case $2 in - ?*) exec 3< $SHIPINFO ;; - esac - given=$1 - while IFS=: read -ru3 name address phone mail company project unused transport comments - do match=$name - case $match in - \#*) ;; - $given*) doship - return 1 - ;; - esac - done - ;; - *) typeset d i p s - if genshiplist $machine $user $mail - then return 1 - fi - tosys $machine - case $transport in - ftp) ftp_address=$(cs -a addr $FROMSYS 2>/dev/null || print - $FROMSYS) ;; - esac - exec 9>&1 - case $transport in - bin|lib);; - *) case $transport in - list|push|src) - ;; - *) print - "umask 02" - ;; - esac - case $transport in - ftp) print - 'case $INSTALLROOT in' - print - '?*) if test -d $INSTALLROOT' - print - ' then cd $INSTALLROOT' - print - ' else echo "$0: $INSTALLROOT: invalid INSTALLROOT" >&2' - print - ' exit 1' - print - ' fi' - print - ' ;;' - print - 'esac' - print - 'if test ! -d ship' - print - 'then mkdir ship || exit 1' - print - 'fi' - print - 'cd ship' - print - 'if test -r "$HOME/.netrc" && grep -c "machine[ ]*'$ftp_address'[ ]*" "$HOME/.netrc"' - print - 'then :' - print - 'else echo "machine '$ftp_address' login anonymous password '$user'" >> "$HOME/.netrc"' - print - ' chmod 0600 "$HOME/.netrc"' - print - 'fi' - ;; - esac - for i in "${ship_list[@]}" - do if test -f $i - then d=$i/file - p=${d%%/*} - s=${d#${p}/} - t=$p - while test "$s" != file - do if test "" != "$p" - then case $transport in - list|src) - print - "$dir/$p" - ;; - push) ;; - *) print - "if test ! -d $dir/$p" - print - "then mkdir $dir/$p" - print - "fi" - ;; - esac - fi - p=${p}/${s%%/*} - s=${d#${p}/} - done - i=${i%/*} - for f in $CRATEFILES - do if test -s $i/$f - then case $transport in - list|push|src) - print - "$dir/$i/$f" - ;; - *) print - "echo \"$(cat $i/$f 2>/dev/null)\" > $dir/$i/$f" - ;; - esac - elif test -f $i/$f - then case $transport in - list|push|src) - print - "$dir/$i/$f" - ;; - - *) print - "> $dir/$i/$f" - ;; - esac - fi - done - case $transport in - list|push|src) - if test "" = "$www" -a -s $i/owner - then print - "$dir/$i/owner" - fi - ;; - *) if test "" != "$www" - then owner= - else if test "" = "$shipper" -a -s $i/owner - then owner=$(<$i/owner) - else owner=$SHIPPER - fi - case ${TOSYS##*!} in - ${owner%%!*}) owner=${TOSYS%!*}!$owner ;; - *) owner=$TOSYS!$owner ;; - esac - fi - print - "echo \"$owner\" > $dir/$i/owner" - ;; - esac - fi - done - case $transport in - list|push|src) - ;; - *) print - "rm -f $dir/ship.$date" - ;; - esac - case $transport in - ftp) print - '${FTP-ftp} $FTP_ADDRESS <$TMP.f - cat - test -d Z || mkdir Z - ;; - bin:*|lib:*|src:*) - print - "(cd $arch; pax -w $paxformat) > Z/$out.Z <&2; exit 1 ;;' - print - 'esac' - print - 'FTP_ADDRESS=${1-'$ftp_address'}' - print - 'FTP_INSTALLROOT=${2-.}' - cat - ;; - list:*) cat - ;; - pull:*) print - ': pull shipment from remote dk host' - print - 'case $# in' - print - '1|2) ;;' - print - '*) echo "Usage: $0 dk-address [remote-INSTALLROOT]" >&2; exit 1 ;;' - print - 'esac' - print - 'DK_ADDRESS=$1' - print - 'DK_INSTALLROOT=${2-.}' - cat - ;; - push:*) print - ': push shipment to remote dk host' - print - 'case $# in' - print - '1|2) ;;' - print - '*) echo "Usage: $0 dk-address [remote-INSTALLROOT]" >&2; exit 1 ;;' - print - 'esac' - print - 'push $1 - ${2:+$2/}ship <<"!!!"' - cat - ;; - *:) cat > $TMP.r - rcp $TMP.r $host:$dir/ship.$date || exit - rm -f $TMP.r - case $rsh in - "") for i in rcmd remsh - do if ($i $host date) >/dev/null 2>&1 - then rsh=$i - break - fi - done - case $rsh in - "") rsh=rsh ;; - esac - ;; - esac - $rsh $host sh $dir/ship.$date || exit - ;; - *) print - "cat '" - cat - print - "' > ship.$date" - print - "rcp ship.$date $host:$dir" - print - "rm ship.$date" - print - "rsh $host sh $dir/ship.$date" - ;; - esac - chmod= - items= - pwd=. - skip= - for tool in "${ship_list[@]}" - do if test ! -f $tool - then i=${tool%%/*} - else i=$tool - fi - dfile=$mail/$i - if test -f "$i" - then case $transport in - bin|lib)case $i in - */*) case $i in - $tool) i=${i%/*} - i=${i%/*} - case $i in - $skip) ;; - *) ( - cd $arch - r=$PWD - case $i in - lib*) cd src/lib/$i ;; - *) cd src/cmd/$i ;; - esac - list=list.ship - case $transport in - bin) list=$list.$transport ;; - esac - INSTALLROOT=$r $MAKE -o 'accept noexec mismatch reread silent' $list $ccprobe - ) - ;; - esac - ;; - esac - ;; - README|shipout) - print - "ship/$i" - skip=${tool%%/*} - ;; - *) skip=${tool%%/*} - ;; - esac - ;; - ftp) case $i in - */*) t=${i%/*} ;; - *) t=. ;; - esac - case $t in - $pwd) ;; - *) print - cd '$FTP_INSTALLROOT'/ship/${i%/*} - case $pwd in - .) print - lcd $t ;; - *) print - lcd ../../$t ;; - esac - pwd=$t - ;; - esac - print - get ${i##*/} - test -x $i && chmod="$chmod $i" - ;; - list|push) - print - "$i" - ;; - pull) case $i in - */*) t=${i%/*} ;; - *) t=. ;; - esac - print - echo pull '$DK_ADDRESS' '$DK_INSTALLROOT'/ship/$i $t - print - pull '$DK_ADDRESS' '$DK_INSTALLROOT'/ship/$i $t - ;; - rcp) print rcp "$i" "$dfile" - case $noexec in - "") rcp "$i" "$dfile" || exit ;; - esac - ;; - src) print - "ship/$i" - case $i in - */*) ;; - *) skip=${tool%%/*} ;; - esac - ;; - esac - fi - i=${tool#*/} - i=${i%/*} - case $user:$noexec in - ?*:) db_note $machine $user ${tool%%/*} $i ${tool##*/} $name ;; - esac - i=${tool%%/*} - case $i in - $skip) ;; - *) skip=$i - items="$items $i" - ;; - esac - done - exec 1>&9 9>&- - case $transport:$noexec in - bin:|lib:|src:) - test "" != "$www" && { - case $type in - [aehiouAEHIOU]*) - a=an - ;; - *) a=a - ;; - esac - print - ".TL - - \"$SHIPORG\" \"$SHIPLOGO\" -Software Shipment Contents -This is $a -$type_H -shipment of -.IR $out ." - if test -f ship.${out%%.*}.promo - then print - ".P" - cat ship.${out%%.*}.promo - print - ".P" - fi - print - "The shipment contains: -.EX" - case $transport in - bin) ls -Cd $(ls -d $items 2>/dev/null | grep -v '^lib') 2>/dev/null ;; - *) ls -Cd $items 2>/dev/null ;; - esac - print - ".EE" - hit=" " - for tool in "${ship_list[@]}" - do tool=${tool%/*} - case $hit in - *" $tool "*) - ;; - *) hit="$hit$tool " - if test -f $tool/promo - then promo=1 - cat $tool/promo - else promo= - fi - if test -f $tool/release - then case $promo in - "") print - ".H 1 ${tool%/*}" - ;; - esac - print - ".P" - print - ".DS" - cat $tool/release - print - ".DE" - fi - ;; - esac - done - print - ".H 1 -If you have problems send mail to -.I advsoft@attmail.att.com -with -.I $out -in the subject field." - } | $SHIPMM2HTML >Z/$out.H - { - print - "#" - print - "# the following ${beta:+beta }$type shipment" - print - "# of $out has been sent" - case $beta in - ?*) print - "# this beta shipment may only be interface compatible with itself" - print - "# other shipments will be reconciled after beta testing" - ;; - esac - print - "#" - case $transport in - bin) ls -Cd $(ls -d $items 2>/dev/null | grep -v '^lib') 2>/dev/null ;; - *) ls -Cd $items 2>/dev/null ;; - esac | sed 's/^/# /' - print - "#" - print - "# to install:" - print - "#" - print - "INSTALLROOT=${beta:+/beta.$beta}" - print - "SHIPMENT=" - print - "cd \$INSTALLROOT" - print - "$paxuncompress \$SHIPMENT | $paxunformat" - case $transport in - bin|lib)(cd $arch; ls -ld $(<$TMP.f) 2>/dev/null) > $TMP.s - for f in $(sed -e '/^-..s..s/!d' -e 's/.* //' $TMP.s) - do set x $(cd $arch; ls -ld $f 2>/dev/null) - n=$# - g=$5 - set x $(cd $arch; ls -ldg $f 2>/dev/null) - n1=$# - g1=$5 - if test $n -lt $n1 - then g=$g1 - fi - print - "chgrp $g $f || echo ship: $f would be more efficient if owned by group $g >&2" - done - sed -e '/^-..s/!d' -e 's/^-..s..s.* /chmod ug+s /' -e 's/^-..s.* /chmod u+s /' $TMP.s - rm $TMP.s - for f in $items - do test -f $f/binary && cat $f/binary - done - ;; - src) print - "nohup ksh ship/shipin &" - ;; - esac - print - "#" - print - "# to use:" - print - "#" - print - "export LD_LIBRARY_PATH=\$INSTALLROOT/lib\${LD_LIBRARY_PATH:+:\$LD_LIBRARY_PATH}" - print - "export PATH=\$INSTALLROOT/bin:\$PATH" - print - "export FPATH=\$INSTALLROOT/fun\${FPATH:+:\$FPATH}" - } >Z/$out.M - case $transport in - bin) (cd $arch; sort -u $TMP.f | egrep -v '^(include/.*|lib/lib.*\.a)$' | pax -Lw $paxformat; rm $TMP.f) > Z/$out.Z ;; - *) (cd $arch; sort -u $TMP.f | pax -Lw $paxformat; rm $TMP.f) > Z/$out.Z ;; - esac - ;; - bin:*|ftp:*|lib:*|push:*|src:*) - case $transport in - ftp) print - 'quit' ;; - esac - print - '!!!' - case $chmod in - ?*) print - "chmod +x$chmod" ;; - esac - ;; - esac - return 1 - ;; - esac - print -u2 "$command: address for $1 not found" - return 1 -} - -function closure # tools -{ - tools= - for tool - do if test ! -d $tool - then case $original in - *" ${tool%/*} "*|*" $tool "*) warning "${tool%/*}: invalid tool" ;; - esac - else case $tool in - */?*) release=${tool#*/} - tool=${tool#*/} - ;; - *) eval items=\"\$items_$item\" - case $items in - "") release= ;; - *) eval release=\$release_$tool ;; - esac - ;; - esac - eval release_${tool%/*}=$release - tools="$tools $tool" - fi - done - set -- $tools - # - # now generate the closure of the top level tools and releases - # - tools= - for tool - do old= - new=$tool - while : - do case $new in - $old) break - esac - dup= - for item in $new - do # we assume items_* not in environment - eval items=\"\$items_$item\" - case $items in - "") eval release=\$release_$item - case $release in - "") set -- $item/$SHIPMENT - shift $#-1 - case $1 in - "$item/$SHIPMENT") continue ;; - esac - release=${1#*/} - eval release_$item=$release - esac - if test ! -f $item/$release/items - then if test ! -f $item/$release/delete - then continue - fi - items=$item - else case $closure in - "") items=$item ;; - *) items=$(<$item/$release/items)" $item" ;; - esac - fi - eval items_$item=\"$items\" - ;; - esac - dup="$dup $items" - done - old=$new - new= - for item in $dup - do eval seen_$item= - done - for item in $dup - do eval seen=\$seen_$item - case $seen in - "") eval seen_$item=1 - new="$new $item" - esac - done - done - tools="$tools $new" - done -} - -function undup # tools -{ - tools= - for item - do eval seen_$item= - done - for item - do eval seen=\$seen_$item - case $seen in - "") eval seen_$item=1 - tools="$tools $item" - esac - done -} - -command=$0 -integer dtime=0 i=0 nrecipient=0 first_time=1 delay=0 -info= mark= list= logfile= message=1 nocopy= noexec= format=$SHIPMENT -shipinfo_test= force= shipper= closure=1 undo= date= basetoo= www= -paxformat= paxunformat= paxcompress= paxuncompress= -while : -do case $1 in - -b) basetoo=1 ;; - +b) basetoo= ;; - -c) closure= ;; - +c) closure=1 ;; - -d) format=base ;; - +d) format=$SHIPMENT ;; - -i) info=1 delay=0 ;; - -k) mark=1 delay=0 ;; - -l) shift; list=$1 ;; - +l) list= ;; - -m) message= ;; - +m) message=1 ;; - -n) noexec=1 delay=0 ;; - +n) noexec= ;; - -o) shipper=1 ;; - +o) shipper= ;; - -p) shift; recipient_list[nrecipient]=$1; nrecipient=nrecipient+1 ;; - +p) recipient= ;; - -s) SHIPFILES= ;; - -t) total=1 noexec=1 delay=0 ;; - -u) shift; undo=$1 ;; - +u) undo= ;; - -v) shift; date=$1 ;; - -w) www=1 ;; - +w) www= ;; - -x) shift - case $1 in - compress|gzip) - paxcompress=$1 - ;; - *) paxformat=$1 - ;; - esac - ;; - -C) shift; CRATEFILES="$CRATEFILES $1" ;; - -D) shift; delay=$1 ;; - +D) delay=0 ;; - -F) force=1 ;; - +F) force= ;; - -L) shift; logfile=$1 ;; - -S) shift; SHIPFILES="$SHIPFILES $1" ;; - *[,:!%@]*)recipient_list[nrecipient]=$1;nrecipient=nrecipient+1 ;; - --) shift; break ;; - -*|+*) print -u2 "Usage: $command [-bcdikmnostfF] [-l recipient-list] [-p recipient] [-u [[yy]mm]dd] [-v yymmdd] [-x format] [-C crate-file] [-D delay] [-S support-file] [recipient ...] [tool ...]"; exit 2 ;; - *) break ;; - esac - shift -done -case $www in -?*) case $paxformat in - "") paxformat=tar ;; - esac - case $paxcompress in - "") paxcompress=gzip ;; - esac - ;; -esac -case $paxcompress in -""|compress) - paxcompress=compress - paxuncompress="zcat <" - ;; -gzip) paxuncompress="(gunzip || zcat) <" - ;; -esac -case $paxformat in -"") paxformat=cpio ;; -esac -case $paxformat in -cpio) paxunformat="cpio -icdvmu" ;; -tar) paxunformat="tar xvf -" ;; -*) paxunformat="pax -rv" ;; -esac -case $paxformat in -?*) paxformat="-x $paxformat" ;; -esac -case $paxcompress in -?*) paxformat="-x $paxcompress $paxformat" ;; -esac -case $date in -$SHIPMENT) ;; -*) date=$(shipstamp) ;; -esac -($SHIPMM2HTML) >/dev/null 2>&1 || SHIPMM2HTML=cat -case $info in -"") if test 0 = "$nrecipient" -a ! -f "$list" - then errexit "no recipient(s)" - fi - trap 'cleanup $?' EXIT INT TERM - # - # generate the tools list - # - original=" $* " - case $# in - 0) tools= - for tool in * - do set -- $tool/$SHIPMENT - case $1 in - "$tool/$SHIPMENT") ;; - *) tools="$tools $tool" ;; - esac - done - case $tools in - "") errexit "no tools" ;; - esac - set -- $tools - ;; - esac - closure $* - case $tools in - "") errexit "no 'items' file(s)" ;; - esac - tools_usr=$tools - tools_pax= - case $closure:$format:$SHIPFILES in - :*|*:|*:base:*|*:delete:*) - ;; - *) set -- pax/$SHIPMENT - case $1 in - "$tool/$SHIPMENT") - ;; - *) closure pax - tools_pax=$tools - ;; - esac - ;; - esac - undup $tools_pax $tools_usr - set -- $tools - for tool in $tools_pax - do eval type_$tool=pax - done - for tool in $tools_usr - do eval type_$tool=usr - done - set -- $tools - for tool - do eval tool=$tool/\$release_$tool - item= - for f in delete "$format" base - do set -- $tool/$f - if test -f "$1" - then item=${1##*/} - break - fi - done - case $item in - "") if test ! -d ${tool%/*} - then case $original in - *" ${tool%/*} "*|*" $tool "*) warning "${tool%/*}: invalid tool" ;; - esac - continue - fi - case $format in - base) set -- $tool/$SHIPMENT - if test -f "$1" - then eval release_${tool%/*}=${1##*/} - tool=${tool%/*}/${1##*/} - item=base - warning "${tool}: latest base not crated" - else warning "${tool}: base not crated" - continue - fi - ;; - *) continue - ;; - esac - ;; - esac - case $format in - "$SHIPMENT"|$item) - tool=$tool/$item - ;; - *) tool=${tool%/*}/$item/base - if test ! -f $tool - then errexit "${tool%/*}: $item base not crated" - fi - ;; - esac - tool_list[i]=$tool;i=i+1 - done - ;; -*) typeset -lL16 fixedname - typeset -L9 address project - typeset -R12 phone - typeset -L21 mail - typeset -L11 company - ;; -esac -if test ! -d $SHIPSLOG -then mkdir $SHIPSLOG || errexit "$SHIPSLOG: cannot create log directory" -fi - -SHIPID=$FROMSYS!$SHIPPER -case $SHIPFILES in -?*) SHIPFILES="$SHIPFILES $SHIPAUX" - for file in $SHIPFILES - do if test ! -r $file - then print -u2 "$file: cannot read"; exit 1 - fi - done - ;; -esac -while : -do case $undo in - ""|??????*) break ;; - *) undo="?$undo" ;; - esac -done -nocopy=${nocopy+-c} -flag=1 -case $list in -"") set -s -- "${recipient_list[@]}" - ;; -?*) if test ! -r "$list" - then errexit "$list: cannot read" - else set -s -- "${recipient_list[@]}" $(sed -e '/^#/d' -e 's/[: ].*//' $list) - fi - ;; -esac -for recipient -do if ((dtime)) - then sleep $dtime - fi - if dosend "$recipient" $flag - then flag= - case $noexec$info in - "") print "$name" >> ${tool%/*}/list ;; - esac - else flag=1 - fi - if ((delay > dtime)) - then dtime=delay - fi -done -exit 0 diff --git a/cde/programs/dtksh/ksh93/ship/shipproto.c b/cde/programs/dtksh/ksh93/ship/shipproto.c deleted file mode 100644 index c1fe1953a..000000000 --- a/cde/programs/dtksh/ksh93/ship/shipproto.c +++ /dev/null @@ -1,5024 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: shipproto.c /main/5 1995/11/01 16:03:47 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS PROPRIETARY SOURCE CODE LICENSED BY * -* AT&T CORP. * -* * -* Copyright (c) 1995 AT&T Corp. * -* All Rights Reserved * -* * -* This software is licensed by AT&T Corp. * -* under the terms and conditions of the license in * -* http://www.research.att.com/orgs/ssr/book/reuse * -* * -* This software was created by the * -* Software Engineering Research Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* gsf@research.att.com * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#line 1 "/home/gsf/src/cmd/proto/proto.c" - - - -#line 27 - - - - - -# define ctime _huh_ctime -# include -# include -# include -# include - -# undef ctime - -# define remove(x) unlink(x) -# define rename(x,y) ((link(x,y)||remove(x))?-1:0) - - - - - - - - -int -replace __PARAM__((const char* newfile, const char* oldfile, int preserve), (newfile, oldfile, preserve)) __OTORP__(const char* newfile; const char* oldfile; int preserve;){ - struct stat st; - time_t ut[2]; - - if (preserve && stat(oldfile, &st) || remove(oldfile) || rename(newfile, oldfile)) - return(-1); - if (preserve) - { - ut[0] = st.st_atime; - ut[1] = st.st_mtime; - preserve = utime(oldfile, ut); - } - return(preserve); -} - -#line 1 "../../lib/libpp/ppproto.c" - - - - - - - - - - - - -static const char id[] = "\n@(#)proto (AT&T Bell Laboratories) 05/09/95\000\n"; - - - -#line 1 "../../lib/libpp/ppfsm.c" - - - - - - - - - -#line 1 "../../lib/libpp/pplib.h" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -struct ppsymbol; -struct ppindex; - -typedef char* (*PPBUILTIN) __PROTO__((char*, const char*, const char*)); -typedef void (*PPCOMMENT) __PROTO__((const char*, const char*, const char*, int)); -typedef void (*PPINCREF) __PROTO__((const char*, const char*, int, int)); -typedef void (*PPLINESYNC) __PROTO__((int, const char*)); -typedef void (*PPMACREF) __PROTO__((struct ppsymbol*, const char*, int, int, unsigned long)); -typedef int (*PPOPTARG) __PROTO__((int, int, const char*)); -typedef void (*PPPRAGMA) __PROTO__((const char*, const char*, const char*, const char*, int)); - -struct ppinstk -{ - char* nextchr; - struct ppinstk* next; - struct ppinstk* prev; - long* control; - char* buffer; - char* file; - char* prefix; - struct ppsymbol* symbol; - - struct ppindex* index; - int buflen; - - int line; - short fd; - short hide; - short flags; - char type; -}; - - - - - - - - - -struct pplist -{ - char* value; - struct pplist* next; -}; - -struct oplist -{ - int op; - char* value; - struct oplist* next; -}; - -struct pphide -{ - struct ppmacro* macro; - unsigned long flags; - int level; -}; - -struct ppmacstk -{ - struct ppmacstk* next; - struct ppmacstk* prev; - int line; - char* arg[1]; -}; - -struct ppmember -{ - struct ppdirs* archive; - unsigned long offset; - unsigned long size; -}; - -struct counter -{ - int candidate; - int function; - int macro; - int pplex; - int push; - int terminal; - int token; -}; - - - -#line 228 - - -#line 273 - - - - -#line 287 - - - - - - - -#line 304 - - - - - - - - -#line 1 "../../lib/libpp/pp.h" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -struct ppdirs -{ - char* name; - struct ppdirs* next; - - - unsigned char c; unsigned char hosted; unsigned char index; unsigned char type; union { char* buffer; char* sp; struct ppdirs* subdir; } info; - - -}; - -struct ppkeyword -{ - char* name; - int value; -}; - -struct ppmacro -{ - int arity; - char* value; - - - int size; char* formals; - - -}; - -struct ppsymbol -{ - int hash_header; - unsigned long flags; - struct ppmacro* macro; - __V_* value; - - - struct pphide* hidden; - - -}; - - - - - - - - - -struct ppglobals -{ - const char* version; - char* lineid; - char* outfile; - char* pass; - char* token; - struct ppsymbol* symbol; - - - - char* outbuf; - char* outp; - unsigned long offset; - - - struct ppdirs* lcldirs; struct ppdirs* stddirs; int flags; char* symtab; - - - - struct ppcontext* context; long state; long mode; long option; long test; char* filedeps; struct ppdirs* firstdir; struct ppdirs* lastdir; int hide; int column; int pending; char* firstfile; char* lastfile; char* ignore; char* probe; char* filtab; char* prdtab; char* date; char* time; char* maps; long ro_state; long ro_mode; long ro_option; char* cdir; char* hostdir; char* ppdefault; struct ppindex* firstindex; struct ppindex* lastindex; struct oplist* firstop; struct oplist* lastop; struct oplist* firsttx; struct oplist* lasttx; unsigned char arg_file; unsigned char arg_mode; unsigned char arg_style; unsigned char c; unsigned char hosted; unsigned char ignoresrc; unsigned char initialized; unsigned char standalone; unsigned char spare_1; - - - - char* checkpoint; int constack; struct ppinstk* in; char* addp; char* args; char* addbuf; char* catbuf; char* path; char* tmpbuf; char* valbuf; char* include; char* prefix; struct ppmember* member; int hidden; int hiding; int level; struct { int input; int output; } pool; int truncate; struct ppmacstk* macp; char* maxmac; char* mactop; char* toknxt; long* control; long* maxcon; struct oplist* chop; struct ppfile* insert; struct ppfile* original; char* dirtab; char* strtab; PPBUILTIN builtin; PPCOMMENT comment; PPINCREF incref; PPLINESYNC linesync; PPLINESYNC olinesync; PPMACREF macref; PPOPTARG optarg; PPPRAGMA pragma; struct counter counter; - - -}; - - - - - - - -extern __MANGLE__ struct ppglobals pp; -extern __MANGLE__ char _pp_ctype[]; - -extern __MANGLE__ int ppargs __PROTO__((char**, int)); -extern __MANGLE__ void ppcpp __PROTO__((void)); -extern __MANGLE__ void ppcomment __PROTO__((char*, char*, char*, int)); -extern __MANGLE__ __V_* ppcontext __PROTO__((__V_*, int)); -extern __MANGLE__ void pperror __PROTO__((int, ...)); -extern __MANGLE__ void ppincref __PROTO__((char*, char*, int, int)); -extern __MANGLE__ void ppinput __PROTO__((char*, char*, int)); -extern __MANGLE__ int pplex __PROTO__((void)); -extern __MANGLE__ void ppline __PROTO__((int, char*)); -extern __MANGLE__ void ppmacref __PROTO__((struct ppsymbol*, char*, int, int)); -extern __MANGLE__ void ppop __PROTO__((int, ...)); -extern __MANGLE__ void pppragma __PROTO__((char*, char*, char*, char*, int)); -extern __MANGLE__ int ppprintf __PROTO__((char*, ...)); - - -#line 313 "../../lib/libpp/pplib.h" - -#line 1 "../../lib/libpp/ppdef.h" - - -#line 14 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 314 "../../lib/libpp/pplib.h" - -#line 1 "../../lib/libpp/ppkey.h" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -extern __MANGLE__ struct ppkeyword ppkey[]; - - -#line 315 "../../lib/libpp/pplib.h" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 367 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 481 - - - - - -#line 496 - - -#line 510 - - - - - - - - -#line 529 - - -#line 551 - - -#line 563 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -struct ppcontext -{ - struct ppdirs* lcldirs; struct ppdirs* stddirs; int flags; char* symtab; - struct ppcontext* context; long state; long mode; long option; long test; char* filedeps; struct ppdirs* firstdir; struct ppdirs* lastdir; int hide; int column; int pending; char* firstfile; char* lastfile; char* ignore; char* probe; char* filtab; char* prdtab; char* date; char* time; char* maps; long ro_state; long ro_mode; long ro_option; char* cdir; char* hostdir; char* ppdefault; struct ppindex* firstindex; struct ppindex* lastindex; struct oplist* firstop; struct oplist* lastop; struct oplist* firsttx; struct oplist* lasttx; unsigned char arg_file; unsigned char arg_mode; unsigned char arg_style; unsigned char c; unsigned char hosted; unsigned char ignoresrc; unsigned char initialized; unsigned char standalone; unsigned char spare_1; -}; - -struct ppfile -{ - int hash_header; - struct ppsymbol* guard; - struct ppfile* bound[3]; - int flags; -}; - - - -struct ppindex -{ - struct ppindex* next; - struct ppfile* file; - unsigned long begin; - unsigned long end; -}; - - - -struct ppsymkey -{ - struct ppsymbol sym; - int lex; -}; - - - - - - - - - - - - - - - -extern __MANGLE__ int access __PROTO__((const char*, int)); -extern __MANGLE__ __V_* calloc __PROTO__((size_t, size_t)); -extern __MANGLE__ int close __PROTO__((int)); -extern __MANGLE__ int creat __PROTO__((const char*, int)); -extern __MANGLE__ char* ctime __PROTO__((time_t*)); -extern __MANGLE__ void exit __PROTO__((int)); -extern __MANGLE__ void free __PROTO__((__V_*)); -extern __MANGLE__ int link __PROTO__((const char*, const char*)); -extern __MANGLE__ int open __PROTO__((const char*, int, ...)); -extern __MANGLE__ int read __PROTO__((int, __V_*, int)); -extern __MANGLE__ int strncmp __PROTO__((const char*, const char*, size_t)); -extern __MANGLE__ time_t time __PROTO__((time_t*)); -extern __MANGLE__ int unlink __PROTO__((const char*)); -extern __MANGLE__ int write __PROTO__((int, const __V_*, int)); - - - - - - - -#line 691 - - -extern __MANGLE__ void ppassert __PROTO__((int, char*, char*)); -extern __MANGLE__ void ppbuiltin __PROTO__((void)); -extern __MANGLE__ int ppcall __PROTO__((struct ppsymbol*, int)); -extern __MANGLE__ int ppcontrol __PROTO__((void)); -extern __MANGLE__ void ppdump __PROTO__((void)); -extern __MANGLE__ char* ppexpand __PROTO__((char*)); -extern __MANGLE__ long ppexpr __PROTO__((int*)); -extern __MANGLE__ void ppfsm __PROTO__((int, char*)); -extern __MANGLE__ char* ppinstr __PROTO__((struct ppinstk*)); -extern __MANGLE__ char* ppkeyname __PROTO__((int, int)); -extern __MANGLE__ char* pplexstr __PROTO__((int)); -extern __MANGLE__ void ppload __PROTO__((char*)); -extern __MANGLE__ char* ppmodestr __PROTO__((long)); -extern __MANGLE__ int ppmultiple __PROTO__((struct ppfile*, struct ppsymbol*)); -extern __MANGLE__ void ppnest __PROTO__((void)); -extern __MANGLE__ int ppoption __PROTO__((char*)); -extern __MANGLE__ char* ppoptionstr __PROTO__((long)); -extern __MANGLE__ void pppclose __PROTO__((char*)); -extern __MANGLE__ int pppdrop __PROTO__((char*)); -extern __MANGLE__ char* pppopen __PROTO__((char*, int, char*, int)); -extern __MANGLE__ int pppread __PROTO__((char*)); -extern __MANGLE__ int pppredargs __PROTO__((void)); -extern __MANGLE__ void pppush __PROTO__((int, char*, char*, int)); -extern __MANGLE__ struct ppsymbol* pprefmac __PROTO__((char*, int)); -extern __MANGLE__ int ppsearch __PROTO__((char*, int, int)); -extern __MANGLE__ char* ppstatestr __PROTO__((long)); -extern __MANGLE__ char* pptokstr __PROTO__((char*, int)); -extern __MANGLE__ void pptrace __PROTO__((int)); - - -#line 11 "../../lib/libpp/ppfsm.c" - -#line 1 "../../lib/libpp/ppfsm.h" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 106 - - - - -#line 143 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 220 - - - - - - - - - - - - - - - - - - - - -extern __MANGLE__ short _pp_fsmtab[(0+26)+1][255+1]; - - - - - -extern __MANGLE__ char _pp_trigraph[255+1]; - -extern __MANGLE__ void _pp_refill __PROTO__((int)); - - -#line 12 "../../lib/libpp/ppfsm.c" - - - -#line 49 - - - - - - - - - - - - - -struct fsminit -{ - int state; - unsigned char ch[4]; - int nextstate; -}; - -static struct fsminit fsminit[] = -{ - - { 0, { 6 }, ((0+26)+11), }, - { 0, { 5 }, (0), }, - { 0, { 2 }, (0+21), }, - { 0, { '.' }, (0+23), }, - { 0, { 1 }, (0+17), }, - { 0, { 'L' }, (0+18), }, - { 0, { 'd', 'e', 'f', 'i' }, (0+1), }, - { 0, { 'r', 't', 'v', 'w' }, (0+1), }, - { 0, { '"', '\'' }, ((0+26)+3), }, - { 0, { '/' }, (0+10), }, - { 0, { '\n' }, ((0+26)+7), }, - { 0, { ' ','\t','\f','\013' }, (0+25), }, - - - { (0+1), { 6 }, ((0+26)+6), }, - { (0+1), { 1, 2 }, (0+17), }, - { (0+1), { 'a' }, (0+2), }, - { (0+1), { 'e' }, (0+3), }, - { (0+1), { 'f' }, (0+4), }, - { (0+1), { 'h' }, (0+5), }, - { (0+1), { 'l' }, (0+6), }, - { (0+1), { 'o' }, (0+7), }, - { (0+1), { 'x' }, (0+8), }, - { (0+1), { 'y' }, (0+9), }, - - - { (0+2), { 6 }, (((0+26)+12)), }, - { (0+2), { 1, 2 }, (0+17), }, - { (0+2), { '_','s','t','a' }, (0+2), }, - { (0+2), { 'r' }, (0+2), }, - - - { (0+3), { 6 }, (((0+26)+12)), }, - { (0+3), { 1, 2 }, (0+17), }, - { (0+3), { 't','u','r','n' }, (0+3), }, - - - { (0+4), { 6 }, (((0+26)+12)), }, - { (0+4), { 1, 2 }, (0+17), }, - - - { (0+5), { 6 }, (((0+26)+12)), }, - { (0+5), { 1, 2 }, (0+17), }, - { (0+5), { 'i','l','e' }, (0+5), }, - - - { (0+6), { 6 }, (((0+26)+12)), }, - { (0+6), { 1, 2 }, (0+17), }, - { (0+6), { 's','e' }, (0+6), }, - - - { (0+7), { 6 }, (((0+26)+12)), }, - { (0+7), { 1, 2 }, (0+17), }, - { (0+7), { 'r', 'i','d' }, (0+7), }, - - - { (0+8), { 6 }, (((0+26)+12)), }, - { (0+8), { 1, 2 }, (0+17), }, - { (0+8), { 't','e','r','n' }, (0+8), }, - - - { (0+9), { 6 }, (((0+26)+12)), }, - { (0+9), { 1, 2 }, (0+17), }, - { (0+9), { 'p','e','d','f' }, (0+9), }, - - - { (0+10), { 6 }, ((0+26)+0), }, - { (0+10), { '*' }, (0+11), }, - - { (0+10), { '/' }, (0+14), }, - - - - { (0+11), { 6 }, (0+11), }, - { (0+11), { '\n', 5 }, ((0+26)+1), }, - { (0+11), { '/' }, (0+13), }, - { (0+11), { '*' }, (0+12), }, - { (0+11), { '#', ';', ')' }, ((( (0+11))<<(7+1))|(((0+26)+8))), }, - - - { (0+12), { 6 }, (0+11), }, - { (0+12), { '\n', 5 }, ((0+26)+1), }, - { (0+12), { '#', ';', ')' }, ((( (0+11))<<(7+1))|(((0+26)+8))), }, - { (0+12), { '*' }, (0+12), }, - { (0+12), { '/' }, ((0+26)+1), }, - - - { (0+13), { 6 }, (0+11), }, - { (0+13), { '*', '\n', 5 }, ((0+26)+1), }, - { (0+13), { '/' }, (0+13), }, - - - { (0+14), { 6 }, (0+14), }, - { (0+14), { '\n', 5 }, ((0+26)+1), }, - { (0+14), { '/' }, (0+15), }, - { (0+14), { '*' }, (0+16), }, - - - { (0+15), { 6 }, (0+14), }, - { (0+15), { '*', '\n', 5 }, ((0+26)+1), }, - { (0+15), { '/' }, (0+15), }, - - - { (0+16), { 6 }, (0+14), }, - { (0+16), { '\n', 5 }, ((0+26)+1), }, - { (0+16), { '*' }, (0+16), }, - { (0+16), { '/' }, ((0+26)+1), }, - - - { (0+17), { 6 }, ((0+26)+6), }, - { (0+17), { 1, 2 }, (0+17), }, - - - { (0+23), { 6 }, ((0+26)+0), }, - { (0+23), { '.' }, (0+24), }, - { (0+23), { 2 }, (0+21), }, - - - { (0+24), { 6 }, (((( (0401+1))-0401)<<(7+1))|( ((0+26)+14))), }, - { (0+24), { '.' }, (((( (0401+29))-0401)<<(7+1))|( ((0+26)+13))), }, - - - { (0+18), { 6 }, ((0+26)+6), }, - { (0+18), { 1, 2 }, (0+17), }, - { (0+18), { '"', '\'' }, ((( (0+19))<<(7+1))|(((0+26)+8))), }, - - - { (0+19), { 6 }, (0+19), }, - { (0+19), { '"', '\'' }, ((0+26)+4), }, - { (0+19), { '\n', 5 }, ((0+26)+4), }, - { (0+19), { '\\' }, (0+20), }, - - - { (0+20), { 6 }, ((0+26)+5), }, - { (0+20), { '\n', 5 }, ((0+26)+4), }, - - - { (0+21), { 6 }, (((( (0401+1))-0401)<<(7+1))|( ((0+26)+14))), }, - { (0+21), { 1, 2, '.' }, (0+21), }, - { (0+21), { 'e', 'E' }, (0+22), }, - - - { (0+22), { 6 }, (((( (0401+1))-0401)<<(7+1))|( ((0+26)+14))), }, - { (0+22), { 1, 2, '.' }, (0+21), }, - { (0+22), { '+', '-' }, (0+21), }, - - - { (0+25), { 6 }, ((0+26)+15), }, - { (0+25), { ' ', '\t' }, (0+25), }, - { (0+25), { '\f', '\013' }, ((0+26)+10), }, - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { (-1), { 0 }, 0, } -}; - -short _pp_fsmtab[(0+26)+1][255+1]; - -char _pp_trigraph[255+1]; - - -static char spl[] = { '\\', '\r', 0 }; -static char aln[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz_$@"; - - - - -static char* let = &aln[10]; -static char hex[] = "fedcbaFEDCBA9876543210"; -static char* dec = &hex[12]; -static char* oct = &hex[14]; - - - - - - -void -ppfsm __PARAM__((int op, char* s), (op, s)) __OTORP__(int op; char* s;){ - int c; - int n; - int i; - short* rp; - struct fsminit* fp; - - - - - switch (op) - { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - case 4: - for (fp = fsminit;; fp++) - { - if ((n = fp->nextstate) >= (0+26)) n = ~n; - if (fp->state == (-1)) - { - - - - - - - - - - - - - - break; - } - rp = _pp_fsmtab[fp->state]; - for (i = 0; i < sizeof(fp->ch) && (c = fp->ch[i]); i++) - { - switch (c) - { - case 6: - for (c = 0; c <= 255; c++) - rp[c] = n; - - - case 5: - _pp_fsmtab[(0+26)][fp->state+1] = n < 0 ? ~n : n; - continue; - - case 1: - s = let; - break; - - case 3: - s = hex; - break; - - case 2: - s = dec; - break; - - case 4: - s = oct; - break; - - default: - rp[c] = n; - continue; - } - while (c = *s++) - rp[c] = n; - } - } - - - - - - - for (i = 0; i < (0+26); i++) - { - rp = _pp_fsmtab[i]; - s = spl; - while (c = *s++) - if (c != '@' || !(( rp)>=_pp_fsmtab[(0+11)]&&( rp)<=_pp_fsmtab[(0+13)]||(( rp)>=_pp_fsmtab[(0+14)]&&( rp)<=_pp_fsmtab[(0+16)]))) - { - if (rp[c] >= 0) rp[c] = ~rp[c]; - rp[c] &= ~(1<<7); - } - rp[0] = ~((0+26)+2); - for (c = 0; c <= 255; c++) - if (rp[c] == i) - rp[c] = 0; - } - _pp_fsmtab[(0+26)][0] = ~((0+26)+2); - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - break; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - } -} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -#line 18 "../../lib/libpp/ppproto.c" - - - - - - - - - - - - - - - -struct proto -{ - int brace; - int fd; - char* file; - long flags; - int line; - int test; - - char* tp; - - int iz; - char* ib; - char* ip; - - int oz; - char* ob; - char* op; - - char pushback[4]; - - char variadic[256]; - - - - -}; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -static int errors; - - - - - - - - - - - - - - -static int -sstrlen __PARAM__((char* s), (s)) __OTORP__(char* s;){ - char* b; - - for (b = s; *s; s++); - return(s - b); -} - - - - - -static int -sstrncmp __PARAM__((char* s, char* t, int n), (s, t, n)) __OTORP__(char* s; char* t; int n;){ - char* e = s + n; - - while (s < e) - { - if (*s != *t || !*s) return(*s - *t); - s++; - t++; - } - return(0); -} - - - - - -static char* -memcopy __PARAM__((char* s, char* t, int n), (s, t, n)) __OTORP__(char* s; char* t; int n;){ - char* e = t + n; - - while (t < e) *s++ = *t++; - return(s); -} - - - - - -static char* -strcopy __PARAM__((char* s, char* t), (s, t)) __OTORP__(char* s; char* t;){ - while (*s++ = *t++); - return(s - 1); -} - - - - - - - - - - -static char* -comment __PARAM__((char* p, char* s, int n, int u), (p, s, n, u)) __OTORP__(char* p; char* s; int n; int u;){ - char* e; - char* m; - - if (!s) - { - if (n) - { - *p++ = (n > 0) ? '/' : '*'; - e = p + 62; - while (p < e) *p++ = '*'; - *p++ = (n > 0) ? '*' : '/'; - } - else s = ""; - } - if (s) - { - if (n > 62) n = 62; - *p++ = '*'; - e = p + (62 - n) / 2; - m = p + 62; - while (p < e) *p++ = ' '; - e = p + n; - while (p < e) - { - n = *s++; - if (u && n >= 'a' && n <= 'z') n = n - 'a' + 'A'; - *p++ = n; - } - e = m; - while (p < e) *p++ = ' '; - *p++ = '*'; - } - *p++ = '\n'; - return(p); -} - - - -#line 285 - - - - - - - - - - -typedef struct -{ - char* data; - int size; -} Item_t; - -typedef struct -{ - int type; - Item_t item[5]; -} Notice_t; - -static char* -copyright __PARAM__((char* p, char* s), (p, s)) __OTORP__(char* p; char* s;){ - char* v; - char* x; - int c; - int i; - int n; - unsigned long h; - time_t clock; - char buf[(62+4)]; - Notice_t notice; - - notice.type = 2; - for (i = 0; i < 5; i++) - notice.item[i].data = 0; - i = 0; - while (c = *s) - { - while (c == ' ' || c == '\t' || c == '\n' || c == '\r') - c = *++s; - x = s; - n = 0; - h = 0; - while (c && c != '=' && c != ' ' && c != '\t' && c != '\n' && c != '\r') - { - if (n++ < 6) - h = (h << 5) + c - 'a'; - c = *++s; - } - if (c == '=') - { - n = (*++s == '"' || *s == '\'') ? *s++ : 0; - v = s; - while ((c = *s) && (n && c != n || !n && c != ' ' && c != '\t' && c != '\n' && c != '\r')) - s++; - switch (h) - { - case ((('c'-'a')<<25)|(('o'-'a')<<20)|(('m'-'a')<<15)|(('p'-'a')<<10)|(('a'-'a')<<5)|('n'-'a')): - c = 0; - break; - case ((('c'-'a')<<25)|(('o'-'a')<<20)|(('n'-'a')<<15)|(('t'-'a')<<10)|(('a'-'a')<<5)|('c'-'a')): - c = 2; - break; - case ((('c'-'a')<<25)|(('o'-'a')<<20)|(('r'-'a')<<15)|(('p'-'a')<<10)|(('o'-'a')<<5)|('r'-'a')): - c = 3; - break; - case ((('l'-'a')<<25)|(('i'-'a')<<20)|(('c'-'a')<<15)|(('e'-'a')<<10)|(('n'-'a')<<5)|('s'-'a')): - c = 4; - break; - case ((('o'-'a')<<25)|(('r'-'a')<<20)|(('g'-'a')<<15)|(('a'-'a')<<10)|(('n'-'a')<<5)|('i'-'a')): - c = 1; - break; - case ((('t'-'a')<<15)|(('y'-'a')<<10)|(('p'-'a')<<5)|('e'-'a')): - if (!sstrncmp( v, "proprietary", 11)) - notice.type = 2; - else if (!sstrncmp( v, "nonexclusive", 11)) - notice.type = 1; - - default: - c = -1; - break; - } - if (c >= 0 && (notice.item[c].size = s - v)) - notice.item[c].data = v; - } - else - { - while (c && c != '\n') - c = *++s; - if (notice.item[i].size = s - x) - { - notice.item[i].data = x; - if (i == 0) - { - notice.item[3].data = v = x; - while ((c = *x) && c != '\n' && c != ' ' && (c < 'a' || c > 'z')) - x++; - if ((c = (x - v)) >= 3) - { - notice.item[3].size = c++; - notice.item[0].data += c; - notice.item[0].size -= c; - } - else notice.item[3].data = 0; - } - } - if (i++ >= 2) - break; - } - if (*s) s++; - } - p = comment(p, ((char*)0), 1, 0); - p = comment(p, ((char*)0), 0, 0); - s = buf; - if (notice.type == 2) - { - if ((x = notice.item[i = 3].data) || (x = notice.item[i = 0].data)) - { - s = memcopy(s, x, notice.item[i].size); - *s++ = ' '; - *s++ = '-'; - *s++ = ' '; - } - s = strcopy(s, "Proprietary"); - p = comment(p, buf, s - buf, 1); - p = comment(p, ((char*)0), 0, 0); - if (notice.item[4].data) - { - s = strcopy(buf, "This is proprietary source code"); - if (notice.item[3].data || notice.item[0].data) - s = strcopy(s, " licensed by"); - p = comment(p, buf, s - buf, 1); - if (x = notice.item[3].data) - { - s = memcopy(buf, x, notice.item[3].size); - s = strcopy(s, " Corp."); - p = comment(p, buf, s - buf, 1); - } - else if (x = notice.item[0].data) - p = comment(p, x, notice.item[0].size, 1); - } - else - { - s = strcopy(buf, "This is unpublished proprietary source code"); - if (x) s = strcopy(s, " of"); - p = comment(p, buf, s - buf, 1); - s = buf; - if (x = notice.item[3].data) - s = memcopy(s, x, notice.item[3].size); - if (x = notice.item[0].data) - { - if (s > buf) - *s++ = ' '; - s = memcopy(s, x, notice.item[0].size); - } - if (s > buf) - p = comment(p, buf, s - buf, 1); - p = comment( p, "and is not to be disclosed or used except in",sizeof( "and is not to be disclosed or used except in")-1, 1); - p = comment( p, "accordance with applicable agreements",sizeof( "accordance with applicable agreements")-1, 1); - } - p = comment(p, ((char*)0), 0, 0); - } - else if (notice.type == 1) - { - p = comment( p, "For nonexclusive individual use",sizeof( "For nonexclusive individual use")-1, 1); - p = comment(p, ((char*)0), 0, 0); - } - s = strcopy(buf, "Copyright (c) "); - time(&clock); - s = memcopy(s, ctime(&clock) + 20, 4); - if (x = notice.item[3].data) - { - *s++ = ' '; - s = memcopy(s, x, notice.item[3].size); - *s++ = ' '; - s = strcopy(s, "Corp."); - } - else if (x = notice.item[0].data) - { - *s++ = ' '; - s = memcopy(s, x, notice.item[0].size); - } - p = comment(p, buf, s - buf, 0); - if (notice.type == 2) - { - if (!notice.item[4].data) - p = comment( p, "Unpublished & Not for Publication",sizeof( "Unpublished & Not for Publication")-1, 0); - p = comment( p, "All Rights Reserved",sizeof( "All Rights Reserved")-1, 0); - } - p = comment(p, ((char*)0), 0, 0); - if (notice.item[4].data) - { - s = strcopy(buf, "This software is licensed"); - if (x = notice.item[3].data) - { - s = strcopy(s, " by "); - s = memcopy(s, x, notice.item[3].size); - *s++ = ' '; - s = strcopy(s, "Corp."); - } - else if (x = notice.item[0].data) - { - s = strcopy(s, " by "); - s = memcopy(s, x, notice.item[0].size); - } - p = comment(p, buf, s - buf, 0); - p = comment( p, "under the terms and conditions of the license in",sizeof( "under the terms and conditions of the license in")-1, 0); - p = comment(p, notice.item[4].data, notice.item[4].size, 0); - p = comment(p, ((char*)0), 0, 0); - } - else if (notice.type == 2) - { - p = comment( p, "The copyright notice above does not evidence any",sizeof( "The copyright notice above does not evidence any")-1, 0); - p = comment( p, "actual or intended publication of such source code",sizeof( "actual or intended publication of such source code")-1, 0); - p = comment(p, ((char*)0), 0, 0); - } - if (x = notice.item[1].data) - { - p = comment( p, "This software was created by the",sizeof( "This software was created by the")-1, 0); - p = comment(p, x, notice.item[1].size, 0); - s = buf; - if (x = notice.item[3].data) - s = memcopy(s, x, notice.item[3].size); - if (x = notice.item[0].data) - { - if (s > buf) - *s++ = ' '; - s = memcopy(s, x, notice.item[0].size); - } - if (s > buf) - p = comment(p, buf, s - buf, 0); - p = comment(p, ((char*)0), 0, 0); - } - if (x = notice.item[2].data) - { - p = comment( p, "For further information contact",sizeof( "For further information contact")-1, 0); - p = comment(p, x, notice.item[2].size, 0); - p = comment(p, ((char*)0), 0, 0); - } - p = comment(p, ((char*)0), -1, 0); - return(p); -} - - - - - - - - - - - - -static char* -number __PARAM__((char* p, long n), (p, n)) __OTORP__(char* p; long n;){ - long d; - - for (d = 1000000; d > 1; d /= 10) - if (n >= d) *p++ = '0' + (n / d) % 10; - *p++ = '0' + n % 10; - return(p); -} - - - - - - -static void -proto_error __PARAM__((char* iob, int level, char* msg, char* arg), (iob, level, msg, arg)) __OTORP__(char* iob; int level; char* msg; char* arg;){ - char* p; - char buf[1024]; - - p = strcopy(buf, "proto: "); - if (iob) - { - struct proto* proto = (struct proto*)(iob - sizeof(struct proto)); - - if (proto->line) - { - if (proto->file) - { - *p++ = '"'; - p = strcopy(p, proto->file); - *p++ = '"'; - *p++ = ','; - *p++ = ' '; - } - p = strcopy(p, "line "); - p = number(p, proto->line); - } - else if (proto->file) p = strcopy(p, proto->file); - } - else - { - p = strcopy(p, msg); - msg = arg; - arg = 0; - } - *p++ = ':'; - *p++ = ' '; - if (level == 1) p = strcopy(p, "warning: "); - p = strcopy(p, msg); - if (arg) - { - *p++ = ' '; - p = strcopy(p, arg); - } - *p++ = '\n'; - write(2, buf, p - buf); - if (level >= 3) exit(level - 2); - if (level >= 2) errors++; -} - - - - - - - - -static char* -linesync __PARAM__((struct proto* proto, char* p, long n), (proto, p, n)) __OTORP__(struct proto* proto; char* p; long n;){ - - if (proto->flags & (1L<<12)) - - { - p = strcopy(p, "\n#line "); - - - - - p = number(p, n); - *p++ = '\n'; - } - return(p); -} - - - - - - -static char* -init __PARAM__((char* op, int flags), (op, flags)) __OTORP__(char* op; int flags;){ - if (flags & (1L<<9)) op = strcopy(op, "\ -\n\ -#if !defined(__PROTO__)\n\ -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus)\n\ -#if defined(__cplusplus)\n\ -#define __MANGLE__ \"C\"\n\ -#else\n\ -#define __MANGLE__\n\ -#endif\n\ -#define __STDARG__\n\ -#define __PROTO__(x) x\n\ -#define __OTORP__(x)\n\ -#define __PARAM__(n,o) n\n\ -#if !defined(__STDC__) && !defined(__cplusplus)\n\ -#if !defined(c_plusplus)\n\ -#define const\n\ -#endif\n\ -#define signed\n\ -#define void int\n\ -#define volatile\n\ -#define __V_ char\n\ -#else\n\ -#define __V_ void\n\ -#endif\n\ -#else\n\ -#define __PROTO__(x) ()\n\ -#define __OTORP__(x) x\n\ -#define __PARAM__(n,o) o\n\ -#define __MANGLE__\n\ -#define __V_ char\n\ -#define const\n\ -#define signed\n\ -#define void int\n\ -#define volatile\n\ -#endif\n\ -#if defined(__cplusplus) || defined(c_plusplus)\n\ -#define __VARARG__ ...\n\ -#else\n\ -#define __VARARG__\n\ -#endif\n\ -#if defined(__STDARG__)\n\ -#define __VA_START__(p,a) va_start(p,a)\n\ -#else\n\ -#define __VA_START__(p,a) va_start(p)\n\ -#endif\n\ -#endif\n\ -"); - else op = strcopy(op, "\ -\n\ -#if !defined(__PROTO__)\n\ -#include \n\ -#endif\n\ -"); - return(op); -} - - - - - - - - - - - - - - - - - - - - - -static int -lex __PARAM__((struct proto* proto, long flags), (proto, flags)) __OTORP__(struct proto* proto; long flags;){ - char* ip; - char* op; - int c; - int state; - short* rp; - char* m; - char* e; - char* t; - char* bp; - char* v; - char* im; - char* ko; - char* aom; - int n; - int line; - int quot; - int x; - int vc; - - char* ie = 0; - char* om = 0; - char* aim = 0; - char* aie = 0; - int call = 0; - int group = 0; - int last = 0; - int paren = 0; - - char* qe = 0; - int qn = 0; - int args = 0; - - - ((ip=proto->ip),(op=proto->op)); - - if (flags & (1L<<5)) (ko=op); - - fsm_start: - proto->tp = ip; - state = 0; - bp = ip; - do - { - rp = _pp_fsmtab[state]; - fsm_get: - while (!(state = rp[c = (*(unsigned char*)ip++)])); - fsm_next: - ; - } while (state > 0); - if ((n = ip - bp - 1) > 0) - { - ip = bp; - do switch( n) { default : memcpy( op, ip, n); op += n; ip += n; break; case 7 : * op++ = * ip++; case 6 : * op++ = * ip++; case 5 : * op++ = * ip++; case 4 : * op++ = * ip++; case 3 : * op++ = * ip++; case 2 : * op++ = * ip++; case 1 : * op++ = * ip++; case 0 : break; } while (0); - ip++; - } - state = ~state; - fsm_terminal: - switch ((( state)&((1<<(7+1))-1))) - { - case ((0+26)+11): - if (op > proto->ob && *(op - 1) == '=' && (op == proto->ob + 1 || *(op - 2) != '=')) switch (c) - { - case '+': - case '-': - case '*': - case '&': - (*op++=( ' ')); - break; - } - (*op++=( c)); - break; - - case ((0+26)+0): - (ip--); - c = (*(op-1)); - break; - - case ((0+26)+1): - switch (c) - { - case '\n': - if ((( rp)>=_pp_fsmtab[(0+14)]&&( rp)<=_pp_fsmtab[(0+16)])) goto fsm_newline; - (*op++=( c)); - proto->line++; - rp = _pp_fsmtab[(0+11)]; - break; - case '/': - - if ((flags & ((1L<<5)|(1L<<14))) == (1L<<5)) (op=ko); - else - - (*op++=( c)); - if ((( rp)>=_pp_fsmtab[(0+14)]&&( rp)<=_pp_fsmtab[(0+16)])) - { - rp = _pp_fsmtab[(0+14)]; - break; - } - goto fsm_start; - case (255+1): - break; - default: - - if ((flags & ((1L<<5)|(1L<<14))) == (1L<<5)) (op=ko); - else - - (*op++=( c)); - rp = _pp_fsmtab[(( rp)>=_pp_fsmtab[(0+14)]&&( rp)<=_pp_fsmtab[(0+16)]) ? (0+14) : (0+12)]; - break; - } - bp = ip; - goto fsm_get; - - case ((0+26)+2): - if (c) - { - if (state = _pp_fsmtab[(0+26)][((( rp)-_pp_fsmtab[0])/(255+1))+1]) - goto fsm_terminal; - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(0); - } - (ip--); - fsm_eob: - if ((flags & ((1L<<1)|((1L<<15))|(1L<<20))) == ((1L<<15)) && (proto->flags & (1L<<15))) - { - - if (!(flags & (1L<<5))) - - flags |= (1L<<24); - c = ip - proto->ib; - if (!(flags & (1L<<14))) im = proto->tp; - n = ip - im; - if (ip - n < proto->ib) - proto->flags |= (1L<<4); - memcopy(proto->ib - n, ip - n, n); - ip = proto->ib; - proto->tp -= c; - if (flags & (1L<<14)) - { - im -= c; - ie -= c; - } - if (aim) aim -= c; - if (aie) aie -= c; - if ((n = read(proto->fd, ip, proto->iz)) > 0) - { - if ((proto->flags & (1L<<21)) && n < proto->iz) - { - proto->flags &= ~(1L<<15); - close(proto->fd); - } - *(ip + n) = 0; - if (state & (1<<7)) goto fsm_splice; - bp = ip; - goto fsm_get; - } - *ip = 0; - proto->flags &= ~(1L<<15); - close(proto->fd); - } - if (state & (1<<7)) goto fsm_splice; - - if (!(flags & (1L<<20)) && (state = rp[c = (255+1)])) - { - bp = ip; - goto fsm_next; - } - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(0); - - case ((0+26)+3): - quot = c; - - if (c == '"' && qe) - { - for (n = 0, t = qe + 1; t < op && (*t == ' ' || *t == '\t' || *t == '\n' && ++n); t++); - if (t == op) - { - op = qe; - qe = 0; - qn = n; - } - else (*op++=( c)); - } - else - - (*op++=( c)); - rp = _pp_fsmtab[(0+19)]; - bp = ip; - goto fsm_get; - - case ((0+26)+4): - if (c == quot) - { - - if (!(flags & (1L<<3))) - qe = (c == '"') ? op : (char*)0; - - (*op++=( c)); - - while (qn > 0) - { - qn--; - (*op++=( '\n')); - } - - } - else if (c != '\n' && c != (255+1)) - { - (*op++=( c)); - bp = ip; - goto fsm_get; - } - else - { - - while (qn > 0) - { - qn--; - (*op++=( '\n')); - } - - (ip--); - } - c = (0401+1); - break; - - case ((0+26)+5): - - if (flags & (1L<<0)) (*op++=( c)); - else - - switch (c) - { - case 'a': - (*op++=( '0')); - (*op++=( '0')); - (*op++=( '7')); - break; - case 'v': - (*op++=( '0')); - (*op++=( '1')); - (*op++=( '3')); - break; - case 'x': - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - lex(proto, (flags & ((1L<<15))) | (1L<<20)); - for (n = x = 0; (c = (*(unsigned char*)ip++)), x < 3; x++) switch (c) - { - case '0': case '1': case '2': case '3': - case '4': case '5': case '6': case '7': - case '8': case '9': - n = (n << 4) + c - '0'; - break; - case 'a': case 'b': case 'c': case 'd': - case 'e': case 'f': - n = (n << 4) + c - 'a' + 10; - break; - case 'A': case 'B': case 'C': case 'D': - case 'E': case 'F': - n = (n << 4) + c - 'A' + 10; - break; - default: - goto fsm_hex; - } - fsm_hex: - (ip--); - (*op++=( ((n >> 6) & 07) + '0')); - (*op++=( ((n >> 3) & 07) + '0')); - (*op++=( (n & 07) + '0')); - break; - default: - (*op++=( c)); - break; - } - rp = _pp_fsmtab[(0+19)]; - bp = ip; - goto fsm_get; - - case ((0+26)+6): - (ip--); - - if ((flags & (1L<<5)) && *proto->tp == 's' && !sstrncmp( proto->tp, "static", 6)) - { - c = ((0500+4)+9); - break; - } - - if (*proto->tp == '_' && !sstrncmp( proto->tp, "__STDPP__directive", 6)) c = '#'; - else c = (0401+0); - - break; - - case ((0+26)+7): - fsm_newline: - proto->line++; - - if (flags & (1L<<5)) - { - if (op != proto->ob && (*(op-1)) != ' ' && (*(op-1)) != '\n') - (*op++=( ' ')); - } - else - - (*op++=( c)); - if (flags & (1L<<3)) - { - - if (flags & (1L<<0)) - { - if (flags & (1L<<5)) (op=ko); - if (flags & (1L<<11)) - { - *(ip - 1) = 0; - op = strcopy(om, "/* "); - op = strcopy(op, im); - op = strcopy(op, " */\n"); - } - flags &= ~((1L<<2)|(1L<<3)|(1L<<6)|(1L<<7)|(1L<<11)|(1L<<14)|(1L<<22)|(1L<<26)); - } - else - - { - if ((flags & ((1L<<2)|(1L<<22))) == ((1L<<2)|(1L<<22))) - { - *(ip - 1) = 0; - op = strcopy(om, "#if defined(__STDC__) || defined(__STDPP__)\n"); - op = strcopy(op, im); - op = strcopy(op, "\n#else\n"); - bp = ip; - ip = im; - *op++ = *ip++; - while (*op = *ip++) - if (*op++ == '#' && *ip != '(') - { - op--; - while (*--op == ' ' || *op == '\t'); - if (*ip == '#') - { - op = strcopy(op + 1, "/**/"); - while (*++ip == ' ' || *ip == '\t'); - } - else - { - if (*op != '"') *++op = '"'; - op++; - while (*ip == ' ' || *ip == '\t') ip++; - while ((c = *ip) >= 'A' && c <= 'Z' || c >= 'a' && c <= 'z' || c >= '0' && c <= '9' || c == '_') *op++ = *ip++; - while (*ip == ' ' || *ip == '\t') ip++; - if (*ip == '"') ip++; - else *op++ = '"'; - } - } - ip = bp; - op = strcopy(op, "\n#endif\n"); - op = linesync(proto, op, proto->line); - } - flags &= ~((1L<<2)|(1L<<3)|(1L<<6)|(1L<<7)|(1L<<14)|(1L<<16)|(1L<<22)|(1L<<23)|(1L<<26)); - } - call = 0; - group = 0; - paren = 0; - last = '\n'; - } - if (paren == 0 && (flags & ((1L<<14)|(1L<<20)|(1L<<23)|(1L<<24))) == (1L<<24)) - { - - if (flags & (1L<<5)) (op=ko); - - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(0); - } - goto fsm_start; - - case ((0+26)+8): - (*op++=( c)); - rp = _pp_fsmtab[((( state)>>(7+1))&((1<<7)-1))]; - bp = ip; - goto fsm_get; - - case ((0+26)+13): - (*op++=( c)); - c = (((( state)>>(7+1))&((1<<7)-1))+0401); - break; - - case ((0+26)+14): - (ip--); - c = (((( state)>>(7+1))&((1<<7)-1))+0401); - break; - - case (((0+26)+12)): - (ip--); - c = (0401+0); - if (!(flags & (1L<<1))) switch (((((long)( *proto->tp))<<16)|(((long)( *(ip - 1)))<<8)|((long)( ip - proto->tp)))) - { - case ((((long)( 'd'))<<16)|(((long)( 'o'))<<8)|((long)( 2))): - c = ((0500+4)+6); - break; - case ((((long)( 'e'))<<16)|(((long)( 'e'))<<8)|((long)( 4))): - if (!(flags & (1L<<20)) && !sstrncmp( proto->tp, "else", 4)) - { - c = ((0500+4)+8); - goto fsm_id; - } - break; - case ((((long)( 'e'))<<16)|(((long)( 'n'))<<8)|((long)( 6))): - if (!sstrncmp( proto->tp, "extern", 6)) - c = ((0500+4)+9); - break; - case ((((long)( 'f'))<<16)|(((long)( 'r'))<<8)|((long)( 3))): - if (!(flags & (1L<<20)) && !sstrncmp( proto->tp, "for", 3)) - { - c = ((0500+4)+11); - goto fsm_id; - } - break; - case ((((long)( 'i'))<<16)|(((long)( 'f'))<<8)|((long)( 2))): - c = ((0500+4)+13); - break; - case ((((long)( 'r'))<<16)|(((long)( 'n'))<<8)|((long)( 6))): - if (!(flags & (1L<<20)) && !sstrncmp( proto->tp, "return", 6)) - { - c = ((0500+4)+17); - goto fsm_id; - } - break; - case ((((long)( 't'))<<16)|(((long)( 'f'))<<8)|((long)( 7))): - if (!(flags & (1L<<20)) && !sstrncmp( proto->tp, "typedef", 7)) - { - flags |= (1L<<26); - c = ((0500+4)+9); - } - break; - case ((((long)( 'v'))<<16)|(((long)( 't'))<<8)|((long)( 8))): - if (*ip == '(' && !sstrncmp( proto->tp, "va_start", 8)) c = (0500+1); - break; - case ((((long)( 'v'))<<16)|(((long)( 'd'))<<8)|((long)( 4))): - if (!sstrncmp( proto->tp, "void", 4)) - { - if (flags & ((1L<<0)|(1L<<18)|(1L<<9)|(1L<<10))) c = ((0500+4)+30); - else - { - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - line = proto->line; - if (lex(proto, (flags & ((1L<<15))) | (1L<<20)) == '*') - { - memcopy(op - 4, "__V_", 4); - memcopy(ip - 4, "__V_", 4); - } - else c = ((0500+4)+30); - proto->line = line; - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - bp = ip; - } - } - break; - case ((((long)( 'w'))<<16)|(((long)( 'e'))<<8)|((long)( 5))): - if (!(flags & (1L<<20)) && !sstrncmp( proto->tp, "while", 5)) - { - c = ((0500+4)+26); - goto fsm_id; - } - break; - } - - if ((flags & (1L<<0)) && c != ((0500+4)+9)) - c = (0401+0); - - break; - - case ((0+26)+10): - goto fsm_start; - - case ((0+26)+15): - (ip--); - - if ((flags & ((1L<<5)|(1L<<14))) == (1L<<5)) - { - while (op > proto->ob && (*(op - 1) == ' ' || *(op - 1) == '\t')) - op--; - if (op > proto->ob && *(op - 1) != '\n') *op++ = ' '; - } - - goto fsm_start; - - default: - if (c == '\\' && (state & (1<<7))) - { - if (!(n = (*(unsigned char*)ip++))) - { - goto fsm_eob; - fsm_splice: - c = '\\'; - n = (*(unsigned char*)ip++); - } - if (n == '\n') - { - proto->line++; - (*op++=( '\\')); - (*op++=( '\n')); - bp = ip; - goto fsm_get; - } - (ip--); - state &= ~(1<<7); - if (state >= (0+26)) goto fsm_terminal; - rp = _pp_fsmtab[state]; - } - (*op++=( c)); - bp = ip; - goto fsm_get; - } - if (!(flags & ((1L<<9)|(1L<<10)|(1L<<20)))) - { - if (!(flags & (1L<<3))) switch (c) - { - case '(': - - if (!(flags & (1L<<0)) || proto->brace == 0) - - { - if (paren++ == 0) - { - - if (!(flags & (1L<<0)) || group <= 1) - - { - - args = 0; - - if (group++ == 0) group++; - else if (flags & (1L<<7)) call++; - flags |= (1L<<14); - im = ip - 1; - om = op - 1; - } - } - else if (paren == 2 && !aim) - { - if (flags & (1L<<7)) - { - aim = ip - 1; - aom = op - 1; - } - else if ((flags & ((1L<<14)|(1L<<25))) == (1L<<14)) - { - for (m = ip - 2; m > im && (*m == ' ' || *m == '\t'); m--); - if (m == im) - { - flags &= ~(1L<<14); - om = 0; - } - } - } - flags &= ~(1L<<25); - } - break; - case ')': - - if (!(flags & (1L<<0)) || proto->brace == 0) - - if (--paren == 0) - { - - if (flags & (1L<<0)) - { - if (group != 2) - { - c = (0401+0); - break; - } - group++; - } - - ie = ip; - } - else if (paren == 1 && (flags & (1L<<7)) && !aie) - aie = ip; - break; - case '*': - if (last == '(' && group == 2) - { - group--; - if (paren == 1) - { - flags |= (1L<<7); - aim = aie = 0; - } - } - break; - case '#': - fsm_directive: - if (!(flags & ((1L<<1)|(1L<<3)))) - { - flags |= (1L<<3); - if (!(flags & (1L<<18))) - { - bp = ip; - while (*ip == ' ' || *ip == '\t') ip++; - if (*ip == 'l' && *++ip == 'i' && *++ip == 'n' && *++ip == 'e') - { - if (*++ip == ' ' || *ip == '\t') - { - proto->line = 0; - while (*++ip >= '0' && *ip <= '9') - proto->line = proto->line * 10 + *ip - '0'; - proto->line--; - } - } - - else if ((flags & ((1L<<0)|(1L<<5))) == (1L<<0)) - { - n = 0; - t = ip + 6; - while (ip < t && *ip >= 'a' && *ip <= 'z') n = (n << 5) | (*ip++ - 'a'); - switch (n) - { - case ((('e'-'a')<<15)|(('l'-'a')<<10)|(('s'-'a')<<5)|('e'-'a')): - case ((('e'-'a')<<20)|(('n'-'a')<<15)|(('d'-'a')<<10)|(('i'-'a')<<5)|('f'-'a')): - while (*ip == ' ' || *ip == '\t') ip++; - if (*ip != '\n' && *ip != '/' && *(ip + 1) != '*') - { - flags |= (1L<<11)|(1L<<14); - im = ip; - om = op + (ip - bp); - } - break; - case ((('e'-'a')<<15)|(('l'-'a')<<10)|(('i'-'a')<<5)|('f'-'a')): - case ((('e'-'a')<<20)|(('r'-'a')<<15)|(('r'-'a')<<10)|(('o'-'a')<<5)|('r'-'a')): - case ((('i'-'a')<<5)|('f'-'a')): - case ((('i'-'a')<<20)|(('f'-'a')<<15)|(('d'-'a')<<10)|(('e'-'a')<<5)|('f'-'a')): - case ((('i'-'a')<<25)|(('f'-'a')<<20)|(('n'-'a')<<15)|(('d'-'a')<<10)|(('e'-'a')<<5)|('f'-'a')): - case ((('u'-'a')<<20)|(('n'-'a')<<15)|(('d'-'a')<<10)|(('e'-'a')<<5)|('f'-'a')): - break; - case ((('i'-'a')<<25)|(('n'-'a')<<20)|(('c'-'a')<<15)|(('l'-'a')<<10)|(('u'-'a')<<5)|('d'-'a')): - if (*ip == 'e') ip++; - - case ((('d'-'a')<<25)|(('e'-'a')<<20)|(('f'-'a')<<15)|(('i'-'a')<<10)|(('n'-'a')<<5)|('e'-'a')): - case ((('p'-'a')<<25)|(('r'-'a')<<20)|(('a'-'a')<<15)|(('g'-'a')<<10)|(('m'-'a')<<5)|('a'-'a')): - if (*ip < 'a' || *ip > 'z') break; - - default: - flags |= (1L<<11)|(1L<<14); - im = bp - 1; - om = op - 1; - break; - } - } - else - - { - if (*ip == 'i' && *++ip == 'n' && *++ip == 'c' && *++ip == 'l' && *++ip == 'u' && *++ip == 'd' && *++ip == 'e') - { - while (*++ip == ' ' || *ip == '\t'); - if (*ip++ == '<' && *ip++ == 's' && *ip++ == 't' && *ip++ == 'd' && *ip++ == 'a' && *ip++ == 'r' && *ip++ == 'g' && *ip++ == '.' && *ip++ == 'h' && *ip++ == '>') - { - op = strcopy(op, "\ -if !defined(va_start)\n\ -#if defined(__STDARG__)\n\ -#include \n\ -#else\n\ -#include \n\ -#endif\n\ -#endif\n\ -"); - op = linesync(proto, op, proto->line); - break; - } - } - else if (*ip == 'd' && *++ip == 'e' && *++ ip == 'f' && *++ip == 'i' && *++ip == 'n' && *++ip == 'e' && (*++ip == ' ' || *ip == '\t')) - { - flags |= (1L<<2)|(1L<<14); - im = bp - 1; - om = op - 1; - } - } - ip = bp; - } - } - break; - case '{': - if (proto->brace++ == 0 && paren == 0) - { - if (last == '=') flags |= (1L<<8); - - else if (flags & (1L<<0)) - { - if ((flags & ((1L<<14)|(1L<<16)|(1L<<23))) == (1L<<14)) - { - if (args) - { - v = number(op, args < 0 ? -args : args); - v = strcopy(v, " argument actual/formal mismatch"); - *v++ = ' '; - v = memcopy(v, im, ie - im); - *v = 0; - proto_error((char*)proto + sizeof(struct proto), 2, op, ((char*)0)); - } - ip--; - - v = ie; - while (ie < ip) - if (*ie++ == '/' && *ie == '*') - { - e = ie - 1; - while (++ie < ip) - { - if (*ie == '*') - { - while (ie < ip && *ie == '*') ie++; - if (ie < ip && *ie == '/') - { - while (++ie < ip && (*ie == ' ' || *ie == '\t')); - while (e > v && (*(e - 1) == ' ' || *(e - 1) == '\t')) e--; - if (e > v && *e != '\n') *e++ = ' '; - t = ie; - while (--e >= v) - *--t = *e; - v = t; - break; - } - } - } - } - ie = v; - - op = om++; - if (flags & (1L<<5)) - { - v = op; - while (v > ko && *--v != ' '); - if (*v != ' ') - { - om = (v = (op += 4)) + 1; - while (v >= ko + 4) - { - *v = *(v - 4); - v--; - } - memcopy(ko, "int ", 4); - } - if (*v == ' ') - { - while (*(v + 1) == '*') - *v++ = '*'; - *v = '\t'; - if ((v - ko) <= 8) - { - om = (e = ++op) + 1; - while (e > v) - { - *e = *(e - 1); - e--; - } - } - } - om = (v = (op += 7)) + 1; - while (v >= ko + 7) - { - *v = *(v - 7); - v--; - } - memcopy(ko, "extern ", 7); - } - (*op++=( '(')); - t = op; - e = 0; - - while (ie < ip) - { - if ((c = *ie) == ' ' || c == '\t' || c == '\n') - { - while ((c = *++ie) == ' ' || c == '\t' || c == '\n'); - if (ie >= ip) break; - if (c != '*' && op > om) (*op++=( ' ')); - } - if ((n = ((c = *ie) == ',')) || c == ';') - { - if (flags & (1L<<5)) - { - m = op; - while (op > om && ((c = *(op - 1)) == '(' || c == ')' || c == '[' || c == ']')) - op--; - v = op; - while (op > om && (c = *(op - 1)) != ' ' && c != '*') - op--; - while (*(op - 1) == ' ') - op--; - if (!e) - { - e = op; - while (e > om && *(e - 1) == '*') - e--; - } - - - - - if (op <= om) - op = strcopy(op, "int"); - else if (*(op - 1) == ',') - op = strcopy(op, " int"); - - while (v < m) - (*op++=( *v++)); - } - (*op++=( ',')); - if (n) - { - if (x = !e) e = op - 1; - (*op++=( ' ')); - m = t; - while (m < e) - (*op++=( *m++)); - if (x) - { - m = e; - while (*--e != ' '); - while (*(e - 1) == '*') e--; - op -= m - e; - } - } - while ((c = *++ie) == ' ' || c == '\t' || c == '\n'); - if (ie >= ip) (op--); - else (*op++=( ' ')); - if (!n) - { - t = op; - e = 0; - } - } - else if (*ie == '*') - { - if (op > om && (c = *(op - 1)) == ' ') op--; - while (*ie == '*') (*op++=( *ie++)); - while (*ie == ' ' || *ie == '\t' || *ie == '\n') ie++; - if (c != '(') (*op++=( ' ')); - } - else if (*ie == '(') - { - if (op > om && *(op - 1) == ' ') op--; - (*op++=( *ie++)); - while (*ie == ' ' || *ie == '\t' || *ie == '\n') ie++; - } - else if (*ie == ')') - { - if (op > om && *(op - 1) == '(') - proto_error((char*)proto + sizeof(struct proto), 1, "function pointer argument prototype omitted", ((char*)0)); - (*op++=( *ie++)); - while (*ie == ' ' || *ie == '\t' || *ie == '\n') ie++; - } - else if ((flags & (1L<<5)) && (op == om || *(op - 1) == ' ') && *ie == 'r' && !sstrncmp( ie, "register", 8) && (*(ie + 8) == ' ' || *(ie + 8) == '\t' || *(ie + 8) == '\n')) - { - ie += 8; - if (op > om) (op--); - } - else (*op++=( *ie++)); - } - - if (op <= om) op = strcopy(op, "void"); - (*op++=( ')')); - if (flags & (1L<<5)) - { - (*op++=( ';')); - (*op++=( '\n')); - (proto->op=op); - (ko=op); - } - else - { - (*op++=( '\n')); - (*op++=( *ip)); - } - ip++; - flags &= ~((1L<<14)|(1L<<23)); - } - } - - else if ((flags & ((1L<<14)|(1L<<18)|(1L<<23)|(1L<<25))) == ((1L<<14)|(1L<<25))) - { - line = proto->line; - op = strcopy(om, " __PARAM__("); - op = memcopy(op, im, ie - im); - (*op++=( ',')); - (*op++=( ' ')); - (*op++=( '(')); - flags &= ~((1L<<14)|(1L<<23)); - if (flags & (1L<<27)) - { - if ((vc = ie - im + 1) > sizeof(proto->variadic)) vc = sizeof(proto->variadic); - memcopy(proto->variadic, im, vc); - op = strcopy(op, "va_alist)) __OTORP__(va_dcl)\n{"); - } - else - { - flags |= (1L<<23); - proto->ip = im; - proto->op = op; - group = 0; - for (;;) - { - switch (lex(proto, (flags & ((1L<<15))) | (1L<<20))) - { - case '(': - if (paren++) group++; - continue; - case ')': - if (--paren == 0) - { - group = 0; - if (flags & (1L<<14)) - { - flags &= ~((1L<<14)|(1L<<23)); - op = memcopy(op, m, e - m); - } - break; - } - continue; - case ',': - if (paren == 1) - { - group = 0; - if (flags & (1L<<14)) - { - flags &= ~((1L<<14)|(1L<<23)); - op = memcopy(op, m, e - m); - } - (*op++=( ',')); - (*op++=( ' ')); - proto->op = op; - } - continue; - case (0401+0): - if (group <= 1) - { - flags |= (1L<<14); - m = proto->tp; - e = proto->ip; - } - continue; - default: - continue; - } - break; - } - (*op++=( ')')); - (*op++=( ')')); - } - if (!(flags & (1L<<23))) - { - flags |= (1L<<23); - proto->op = strcopy(op, " __OTORP__("); - proto->ip = im + 1; - n = *(ie - 1); - *(ie - 1) = ';'; - c = *ie; - *ie = 0; - lex(proto, (flags & ((1L<<15))) | (1L<<1)); - *(ie - 1) = n; - *ie = c; - proto->ip = ie; - op = proto->op; - (*op++=( ')')); - } - op = linesync(proto, op, proto->line = line); - if (!(flags & (1L<<27))) (*op++=( '{')); - } - } - flags &= ~((1L<<6)|(1L<<7)|(1L<<14)|(1L<<16)|(1L<<23)); - call = 0; - group = 0; - break; - case '}': - flags &= ~((1L<<6)|(1L<<7)|(1L<<14)|(1L<<16)|(1L<<23)|(1L<<25)); - if (--proto->brace == 0) - { - flags &= ~((1L<<8)|(1L<<27)|(1L<<28)); - - if (flags & (1L<<5)) (op=ko); - - } - call = 0; - group = 0; - paren = 0; - break; - case '=': - if (last == '?') flags |= (1L<<3); - else if (paren == 0 && (flags & ((1L<<8)|(1L<<14)|(1L<<23))) == (1L<<14)) goto fsm_statement; - goto fsm_other; - case ',': - - if (flags & (1L<<0)) - { - if (paren == 1) args++; - else - { - args--; - flags &= ~(1L<<14); - } - break; - } - - if (paren == 0 && (flags & (1L<<1))) *(op - 1) = c = ';'; - - case ';': - fsm_statement: - if (flags & (1L<<8)) ; - - else if (flags & (1L<<0)) - { - if (paren == 0) - { - if ((flags & (1L<<14)) && last == ')') - flags &= ~(1L<<14); - if (!(flags & (1L<<14))) - { - call = 0; - group = 0; - flags &= ~(1L<<23); - if (flags & (1L<<5)) (op=ko); - if (flags & (1L<<24)) - { - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(0); - } - } - else - { - args--; - if ((flags & ((1L<<5)|(1L<<23))) == ((1L<<5)|(1L<<23))) - (op=ko); - } - } - } - - else if (paren == 0) - { - if ((flags & ((1L<<14)|(1L<<16)|(1L<<23))) == (1L<<14) && call > 1) - { - if ((flags & ((1L<<1)|(1L<<7))) == (1L<<7) && aim && aie < im) - { - while (aie < ip && (*aie == ' ' || *aie == '\t' || *aie == '\n')) aie++; - v = aim; - while (v < aie) - if (*v++ == ')') break; - while (v < aie && (*v == ' ' || *v == '\t' || *v == '\n')) v++; - if (v == aie || !(flags & (1L<<19))) - { - if (flags & (1L<<19)) n = 3; - else if (v == aie && *v == '(') n = 10; - else n = 11; - ko = op; - om += n; - v = op += n; - while (v >= ko + n) - { - *v = *(v - n); - v--; - } - if (flags & (1L<<19)) memcopy(aom, "(...))", 6); - else if (n == 10) memcopy(aom, "(__VARARG__))", 13); - else - { - ko = strcopy(aom, " __PROTO__("); - ko = memcopy(ko, aim, aie - aim); - *ko = ')'; - if (++ko >= om) - { - *ko++ = ')'; - om = ko; - } - } - } - } - else if (flags & (1L<<26)) - { - op = om; - while (*--op == ' ' || *op == '\t' || *op == '\n'); - if (*op != ')') - { - op = om += 14; - *--op = ')'; - while ((x = *(op - 14)) >= 'A' && x <= 'Z' || x >= 'a' && x <= 'z' || x >= '0' && x <= '9' || x == '_') - *--op = x; - memcopy(op - 13, "(__OTORP__(*)", 13); - } - } - if (flags & (1L<<19)) - { - if (!(flags & (1L<<25))) - { - op = strcopy(om, "(...)"); - (*op++=( c)); - } - } - else - { - if (flags & (1L<<1)) op = strcopy(om, "()"); - else if (!(flags & (1L<<25))) op = strcopy(om, "(__VARARG__)"); - else - { - op = strcopy(om, " __PROTO__("); - op = memcopy(op, im, ie - im); - (*op++=( ')')); - } - (*op++=( c)); - } - flags &= ~((1L<<14)|(1L<<27)|(1L<<28)); - if (c == ',' && !(flags & (1L<<7))) - { - call = 1; - group = 0; - break; - } - } - else if (flags & ((1L<<16)|(1L<<23))) call = 0; - if (c == ';') - { - flags &= ~((1L<<13)|(1L<<26)); - if (flags & (1L<<24)) - { - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(0); - } - call = 0; - } - else call = call > 1 && c == ','; - group = 0; - flags &= ~((1L<<6)|(1L<<7)|(1L<<14)|(1L<<16)|(1L<<23)); - } - else if (paren == 1 && group == 1 && !(flags & ((1L<<6)|(1L<<13)))) flags |= (1L<<25)|(1L<<16); - break; - case ((0500+4)+6): - case ((0500+4)+13): - flags |= (1L<<25)|(1L<<23); - break; - case ((0500+4)+9): - - if (flags & (1L<<0)) - { - if (proto->brace == 0) - flags |= (1L<<23); - } - else - - if (paren == 0 && !(flags & (1L<<26))) - { - flags |= (1L<<13); - if (!(flags & (1L<<18))) - op = strcopy(op, " __MANGLE__"); - } - break; - case (0401+29): - if (paren == 0 && (flags & ((1L<<1)|(1L<<27))) == (1L<<1)) - { - op -= 3; - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(c); - } - if (paren == 1 && !(flags & (1L<<23))) - flags |= (1L<<27); - flags |= (1L<<25); - break; - case ((0500+4)+30): - goto fsm_id; - case (0500+1): - if ((flags & ((1L<<18)|(1L<<27))) == (1L<<27)) - { - flags &= ~(1L<<14); - line = proto->line; - op = strcopy(op - 8, "__VA_START__"); - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - for (;;) - { - switch (lex(proto, (flags & ((1L<<15))) | (1L<<20))) - { - case 0: - case ';': - break; - case (0401+0): - if (!(flags & (1L<<14))) - { - flags |= (1L<<14); - m = proto->tp; - e = proto->ip; - } - continue; - default: - continue; - } - break; - } - ((ip=proto->ip),(op=proto->op)); - if (flags & (1L<<14)) - { - v = m; - n = e - m; - } - else - { - v = "ap"; - n = 2; - } - op = strcopy(op, " __OTORP__("); - proto->ip = proto->variadic; - proto->op = op; - flags &= ~(1L<<14); - group = 0; - bp = proto->ip + 1; - if (*bp == 'r' && !sstrncmp( bp, "register", 8) && (*(bp + 8) == ' ' || *(bp + 8) == '\t')) bp += 9; - for (;;) - { - switch (lex(proto, (flags & ((1L<<15))) | (1L<<20))) - { - case '(': - if (paren++) group++; - continue; - case ')': - if (--paren == 0) - { - if (flags & (1L<<14)) - { - flags &= ~(1L<<14); - if (!(flags & (1L<<28))) - { - op = memcopy(op, m, e - m); - op = strcopy(op, " = "); - } - op = strcopy(op, "va_arg("); - op = memcopy(op, v, n); - (*op++=( ',')); - (*op++=( ' ')); - if (m > bp) op = memcopy(op, bp, m - bp); - else op = strcopy(op, "int "); - if (group > 1) op = strcopy(op, ")()"); - else op = memcopy(op, e, proto->ip - e - 1); - (*op++=( ')')); - (*op++=( ';')); - } - group = 0; - break; - } - continue; - case ',': - if (paren == 1) - { - if (flags & (1L<<14)) - { - flags &= ~(1L<<14); - if (!(flags & (1L<<28))) - { - op = memcopy(op, m, e - m); - op = strcopy(op, " = "); - } - op = strcopy(op, "va_arg("); - op = memcopy(op, v, n); - (*op++=( ',')); - (*op++=( ' ')); - if (m > bp) op = memcopy(op, bp, m - bp); - else op = strcopy(op, "int "); - if (group > 1) op = strcopy(op, ")()"); - else op = memcopy(op, e, proto->ip - e - 1); - (*op++=( ')')); - (*op++=( ';')); - bp = proto->ip + 1; - if (*bp == 'r' && !sstrncmp( bp, "register", 8) && (*(bp + 8) == ' ' || *(bp + 8) == '\t')) bp += 9; - } - group = 0; - proto->op = op; - } - continue; - case (0401+0): - if (group <= 1) - { - flags |= (1L<<14); - m = proto->tp; - e = proto->ip; - } - continue; - default: - continue; - } - break; - } - op = strcopy(op, ")"); - flags |= (1L<<28); - proto->line = line; - call = 0; - break; - } - - case (0401+0): - fsm_id: - - if (flags & (1L<<0)) - { - if (!args && paren == 1) args++; - break; - } - - if (paren == 0) - { - if (last == ')') - { - if (proto->brace == 0 && !(flags & (1L<<1))) flags |= (1L<<23); - call = !call; - } - else if ((flags & (1L<<23)) || c == (0401+0) || c == ((0500+4)+30)) call++; - else flags |= (1L<<23); - if (last == (0401+0)) flags |= (1L<<6); - } - c = (0401+0); - flags |= (1L<<25); - break; - case (0401+1): - if (*proto->tp >= '0' && *proto->tp <= '9') - switch (*(op - 1)) - { - case 'l': - case 'L': - switch (*(op - 2)) - { - case 'l': - case 'L': - case 'u': - case 'U': - *(op - 2) = *(op - 1); - op--; - break; - } - break; - case 'u': - case 'U': - op--; - break; - } - goto fsm_other; - - case '[': - if ((flags & (1L<<0)) && paren == 0 && group <= 2) flags |= (1L<<23); - - - default: - fsm_other: - - if (flags & (1L<<0)) break; - - flags |= (1L<<25); - if (paren == 0) flags |= (1L<<16); - break; - } - else if (c == '#' && *ip != '(') flags |= (1L<<22); - last = c; - - if ((flags & ((1L<<5)|(1L<<14))) == ((1L<<5)|(1L<<14)) && ((flags & ((1L<<3)|(1L<<23))) || proto->brace || c != '(' && c != ')' && c != '*' && c != (0401+0))) - (op=proto->op); - else - - (proto->op=op); - goto fsm_start; - } - else if (flags & ((1L<<9)|(1L<<10))) - { - - if ((flags & (1L<<29)) && c == '%' && *ip == '{') t = 0; - else - - { - if (c == '#') for (t = ip; *t == ' ' || *t == '\t'; t++); - else t = ""; - if (*t++ == 'i' && *t++ == 'f' && *t++ == 'n' && *t++ == 'd' && *t++ == 'e' && *t++ == 'f') - { - - - - - t = 0; - } - } - if (t) - { - ip = bp; - op = proto->op; - } - else while (*ip != '\n') *op++ = *ip++; - op = init(op, flags); - op = linesync(proto, op, proto->line); - flags &= ~((1L<<9)|(1L<<10)); - proto->flags &= ~((1L<<9)|(1L<<10)); - goto fsm_start; - } - do{(proto->ip=ip);(proto->op=op);proto->flags&=~((1L<<8)|(1L<<27)|(1L<<28));proto->flags|=flags&((1L<<8)|(1L<<27)|(1L<<28));}while(0); - return(c); -} - - - - - -void -pppclose __PARAM__((char* iob), (iob)) __OTORP__(char* iob;){ - struct proto* proto = (struct proto*)(iob - sizeof(struct proto)); - - if (proto->flags & (1L<<15)) close(proto->fd); - free((char*)proto); -} - - - - - - - - - - - -char* -pppopen __PARAM__((char* file, int fd, char* notice, int flags), (file, fd, notice, flags)) __OTORP__(char* file; int fd; char* notice; int flags;){ - struct proto* proto; - char* iob; - long n; - char* s; - int pragma; - char* b; - - int comlen; - char com[(62+4)]; - - int m = 0; - - static int retain; - - - - - - - if (flags & (1<<0)) flags &= ~(1<<4); - - if (flags & (1<<10)) flags &= ~retain; - else retain &= (1<<5); - if (file && (fd = open(file, 0)) < 0) return(0); - - - - - - - - - - - - - - - - - - - - - - - { - - - - - n = (4*1024); - if (!(proto = (( 0)?( struct proto*)realloc((char*)( 0),sizeof( struct proto)*( 1)+( 5 * n + 2)):( struct proto*)calloc(1,sizeof( struct proto)*( 1)+( 5 * n + 2))))) - return(0); - proto->iz = n; - proto->oz = 3 * n; - proto->flags |= (1L<<15); - } - proto->fd = fd; - iob = (char*)proto + sizeof(struct proto); - proto->op = proto->ob = iob; - proto->ip = proto->ib = iob + proto->oz + n; - if (m) proto->flags |= (1L<<21); - - - - - - n = read(fd, proto->ip, proto->iz); - if (!(proto->flags & (1L<<15))) - close(fd); - if (n < 0) - { - pppclose(iob); - return(0); - } - *(proto->ip + n) = 0; - - - - - - - - - - - - - - if (notice) - { - s = comment(com, ((char*)0), 0, 0); - comlen = s - com; - } - else *com = 0; - - pragma = -1; - s = proto->ip; - m = 64; - while (m-- > 0 && *s) - { - while (*s == ' ' || *s == '\t') s++; - if (*s == '#') - { - b = s++; - while (*s == ' ' || *s == '\t') s++; - if (!sstrncmp( s, "pragma", sizeof("pragma") - 1) && (*(s += sizeof("pragma") - 1) == ' ' || *s == '\t')) - { - while (*s == ' ' || *s == '\t') s++; - if (*s == 'n' && *(s + 1) == 'o') - { - s += 2; - pragma = -2; - } - if (!sstrncmp( s, "prototyped", sizeof("prototyped") - 1) && (*(s += sizeof("prototyped") - 1) == ' ' || *s == '\t' || *s == '\n' || *s == '\r')) - { - while (*s) - if (*s++ == '\n') - { - pragma += 2; - - if (!(flags & (1<<1)) || (flags & (1<<7))) - - for (s--; b < s; *b++ = ' '); - goto magic; - } - } - pragma = -1; - } - } - else if (*s == '/' && !sstrncmp( s, "/* : : generated by proto : : */\n", sizeof("/* : : generated by proto : : */\n") - 1)) - { - pragma = 0; - break; - } - - else if (*s == '%' && *(s + 1) == '{') proto->flags |= (1L<<29); - else if (notice) - { - if (*s == *com && !sstrncmp( s, com, comlen)) notice = 0; - else - { - while (*s) - { - if (*s == *"Copyright"&& !sstrncmp( s, "Copyright", sizeof("Copyright") - 1)) - { - s += sizeof("Copyright") - 1; - while (*s == ' ' || *s == '\t') s++; - if (*s == '(' && (*(s + 1) == 'c' || *(s + 1) == 'C') && *(s + 2) == ')') - notice = 0; - } - else if (*s++ == '\n') break; - } - continue; - } - } - - while (*s && *s++ != '\n'); - } - magic: - if (flags & (1<<9)) proto->flags |= (1L<<19); - if (flags & (1<<11)) proto->test = 1; - - if (flags & (1<<0)) pragma = -pragma; - if (flags & (1<<1)) pragma = 0; - if (flags & (1<<6)) proto->flags |= (1L<<12); - if (!(proto->flags & (1L<<29)) && file && (m = sstrlen( file)) > 2 && file[--m] == 'y' && file[--m] == '.') - proto->flags |= (1L<<29); - - if (pragma <= 0) - { - if (flags & (1<<9)) - { - flags &= ~((1<<3)|(1<<4)); - proto->flags |= (1L<<18); - } - else if (!(flags & ((1<<2)|(1<<8)))) - { - pppclose(iob); - return(0); - } - else if ((flags & (1<<8)) || !pragma) - { - proto->flags |= (1L<<17); - if (proto->flags & (1L<<15)) proto->oz += proto->iz; - proto->iz = n; - if (notice) - { - - proto->op = copyright(proto->op, notice); - if (!(flags & (1<<0)) && !(proto->flags & (1L<<29))) - - proto->op = linesync(proto, proto->op, 1); - proto->iz += proto->op - proto->ob; - } - memcopy(proto->op, proto->ip, n); - return(iob); - } - } - - if (!(retain & (1<<5))) - { - retain |= (1<<5); - ppfsm(4, ((char*)0)); - } - - proto->line = 1; - - if (notice || (flags & ((1<<3)|(1<<4)))) - { - - if (notice) proto->op = copyright(proto->op, notice); - - if (flags & (1<<4)) - { - proto->flags |= (1L<<10); - if (flags & (1<<10)) - retain |= (1<<4); - } - else if (flags & (1<<3)) - { - if (flags & (1<<10)) retain |= (1<<3); - - if (flags & (1<<0)) - { - *proto->op++ = '#'; - proto->op = strcopy(proto->op, "pragma"); - *proto->op++ = ' '; - proto->op = strcopy(proto->op, "prototyped"); - *proto->op++ = '\n'; - } - else - - proto->flags |= (1L<<9); - } - - if (!(flags & (1<<0))) - { - if (proto->flags & (1L<<29)) - { - proto->op = strcopy(proto->op, "\n%{\n"+ !notice); - proto->op = strcopy(proto->op, "/* : : generated by proto : : */\n"); - proto->op = strcopy(proto->op, "%}\n"); - } - else - { - if (n || notice) *proto->op++ = '\n'; - proto->op = strcopy(proto->op, "/* : : generated by proto : : */\n"); - if (n) proto->op = linesync(proto, proto->op, proto->line); - else if (proto->flags & ((1L<<9)|(1L<<10))) - proto->op = init(proto->op, proto->flags); - } - } - - } - - - proto->file = file; - if (flags & (1<<0)) - { - proto->flags |= (1L<<0); - if (!(flags & (1<<3))) proto->flags |= (1L<<5); - } - - return(iob); -} - - - - - - -int -pppread __PARAM__((char* iob), (iob)) __OTORP__(char* iob;){ - struct proto* proto = (struct proto*)(iob - sizeof(struct proto)); - int n; - - if (proto->flags & (1L<<17)) - { - if (proto->iz) - { - n = proto->iz; - proto->iz = 0; - } - else if (!(proto->flags & (1L<<15))) n = 0; - else if ((n = read(proto->fd, proto->ob, proto->oz)) <= 0 || (proto->flags & (1L<<21)) && n < proto->oz) - { - proto->flags &= ~(1L<<15); - close(proto->fd); - } - } - else - { - if (proto->op == proto->ob) - { - if (proto->flags & (1L<<4)) return(-1); - - if (proto->flags & (1L<<29)) - { - char* ip = proto->ip; - char* op = proto->ob; - char* ep = proto->ob + proto->oz - 2; - - if (!*ip) - { - ip = proto->ip = proto->ib; - if (!(proto->flags & (1L<<15))) n = 0; - else if ((n = read(proto->fd, ip, proto->iz)) <= 0 || (proto->flags & (1L<<21)) && n < proto->iz) - { - if (n < 0) n = 0; - proto->flags &= ~(1L<<15); - close(proto->fd); - } - ip[n] = 0; - } - if (proto->flags & (1L<<30)) - { - proto->flags &= ~(1L<<30); - if (*ip == '%') - { - *op++ = *ip++; - if (proto->flags & (1L<<31)) proto->flags &= ~(1L<<29); - else proto->flags |= (1L<<31); - } - } - if (proto->flags & (1L<<29)) - while (op < ep && (n = *op++ = *ip)) - { - ip++; - if (n == '%') - { - if (*ip == '%' && (ip == proto->ip + 1 || *(ip - 2) == '\n')) - { - *op++ = *ip++; - if (proto->flags & (1L<<31)) proto->flags &= ~(1L<<29); - else proto->flags |= (1L<<31); - break; - } - if (!*ip) - { - *op++ = '%'; - proto->flags |= (1L<<30); - break; - } - } - else if (n == '\n') proto->line++; - } - proto->op = memcopy(proto->ob, proto->ip, ip - proto->ip); - proto->ip = ip; - } - else - - lex(proto, proto->flags); - if ((proto->flags & ((1L<<4)|(1L<<15))) == (1L<<4)) - proto->op = strcopy(proto->op, "/* NOTE: some constructs may not have been converted */\n"); - } - n = proto->op - proto->ob; - proto->op = proto->ob; - } - return(n); -} - - - - - - - - - - - - - - - - - - - - - - - -#line 69 "/home/gsf/src/cmd/proto/proto.c" - - - - -static int -proto __PARAM__((char* file, char* notice, int flags), (file, notice, flags)) __OTORP__(char* file; char* notice; int flags;){ - char* b; - char* e; - int n; - int x; - int fd; - - if (file && access(file, 4)) proto_error(((char*)0), 2, file, "not found"); - else if (b = pppopen(file, 0, notice, flags)) - { - if (file) - { - e = file + sstrlen( file) - 1; - x = *e; - *e = '_'; - if ((fd = (flags & ((1<<13)<<1)) ? creat(file, 0666) : 1) < 0) - { - proto_error(b, 2, "cannot create temporary file", ((char*)0)); - return(flags); - } - *e = x; - } - else fd = 1; - while ((n = pppread(b)) > 0) - if (write(fd, b, n) != n) - { - proto_error(b, 2, "write error", ((char*)0)); - flags |= ((1<<13)<<0); - break; - } - if (file && (flags & ((1<<13)<<1))) - { - close(fd); - *e = '_'; - strcpy(b, file); - *e = x; - if (replace(b, file, !(flags & (1<<0)))) - proto_error(b, 2, "cannot rename to", file); - } - pppclose(b); - } - return(flags); -} - -int main __PARAM__((int argc, char** argv), (argc, argv)) __OTORP__(int argc; char** argv;){ - char* b; - char* file; - int fd; - char* list = 0; - char* notice = 0; - int flags = (1<<3); - char buf[1024]; - - ; - while ((file = *++argv) && *file == '-' && *(file + 1)) - { - for (;;) - { - switch (*++file) - { - case 0: - break; - case 'c': - if (!*(notice = ++file) && !(notice = *++argv)) - { - file = "??"; - continue; - } - break; - case 'd': - flags |= (1<<1); - continue; - case 'f': - flags |= (1<<2); - continue; - case 'h': - flags &= ~(1<<3); - continue; - case 'i': - flags |= (1<<0); - continue; - case 'l': - if (!*(list = ++file) && !(list = *++argv)) - { - file = "??"; - continue; - } - break; - case 'n': - flags |= (1<<6); - continue; - case 'p': - flags |= (1<<8); - continue; - case 'r': - flags |= ((1<<13)<<1); - continue; - case 's': - flags |= (1<<4); - continue; - case 't': - flags |= (1<<11); - continue; - case 'z': - flags |= (1<<1)|(1<<7); - continue; - case '+': - flags |= (1<<9); - continue; - default: - proto_error(((char*)0), 2, file, "unknown option"); - - case '?': - b = "Usage: proto [-dfhinprst+] [-c \"name='value' ...\"] [-l list] file ...\n"; - write(2, b, sstrlen( b)); - exit(2); - } - break; - } - } - if (list) - { - if (*list == '-' && !*(list + 1)) fd = 0; - else if ((fd = open(list, 0)) < 0) proto_error(((char*)0), 3, list, "not found"); - for (;;) - { - b = buf; - while (read(0, b, 1) == 1 && *b != '\n' && b < &buf[sizeof(buf) - 1]) b++; - if (b == buf) break; - *b = 0; - flags = proto(buf, notice, flags); - } - } - if (file) do flags = proto(file, notice, flags); while (file = *++argv); - else if (!list) flags = proto(file, notice, flags); - exit(errors ? 1 : (flags & ((1<<13)<<0)) ? 2 : 0); -} diff --git a/cde/programs/dtksh/ksh93/src/Makefile b/cde/programs/dtksh/ksh93/src/Makefile deleted file mode 100644 index 037825000..000000000 --- a/cde/programs/dtksh/ksh93/src/Makefile +++ /dev/null @@ -1,2 +0,0 @@ -/* $XConsortium: Makefile /main/2 1996/05/10 17:17:41 drk $ */ -:MAKE: lib - cmd diff --git a/cde/programs/dtksh/ksh93/src/cmd/Makefile b/cde/programs/dtksh/ksh93/src/cmd/Makefile deleted file mode 100644 index 1e04b7ecc..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/Makefile +++ /dev/null @@ -1,2 +0,0 @@ -/* $XConsortium: Makefile /main/3 1996/05/10 17:18:02 drk $ */ -:MAKE: probe - cpp - * diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/COMPATIBILITY b/cde/programs/dtksh/ksh93/src/cmd/ksh93/COMPATIBILITY deleted file mode 100644 index 66ff06c7e..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/COMPATIBILITY +++ /dev/null @@ -1,95 +0,0 @@ - - KSH-93 VS. KSH-88 - - -The following is a list of known incompatibilities between ksh-93 and ksh-88. -I have not include cases that are clearly bugs in ksh-88. I also have -omitted features that are completely upward compatible. - -1. Functions, defined with name() with ksh-93 are compatible with - the POSIX standard, not with ksh-88. No local variables are - permitted, and there is no separate scope. Functions defined - with the function name syntax, maintain compatibility. - This also affects function traces. - -2. ! is now a reserved word. As a result, any command by that - name will no longer work with ksh-93. - -3. The -x attribute of alias and typeset -f, is no longer - effective and the ENV file is only read for interactive - shells. You need to use FPATH to make function definitions - visible to scripts. -4. A built-in command named command has been added which is - always found before the PATH search. Any script which uses - this name as the name of a command (or function) will not - be compatible. - -5. The output format for some built-ins has changed. In particular - the output format for set, typeset and alias now have single - quotes around values that have special characters. The output - for trap without arguments has a format that can be used as input. - -6. With ksh-88, a dollar sign ($') followed by a single quote was - interpreted literally. Now it is an ANSI-C string. You - must quote the dollar sign to get the previous behavior. - Also, a $ in front of a " indicates that the string needs - to be translated for locales other than C or POSIX. The $ - is ignored in the C and POSIX locale. - -7. With ksh-88, tilde expansion did not take place inside ${...}. - with ksh-93, ${foo-~} will cause tilde expansion if foo is - not set. You need to escape the ~ for the previous behavior. - -8. Some changes in the tokenizing rules where made that might - cause some scripts with previously ambiguous use of quoting - to produce syntax errors. - -9. Programs that rely on specific exit values for the shell, - (rather than 0 or non-zero) may not be compatible. The - exit status for many shell failures has been changed. - -10. Built-ins in ksh-88 were always executed before looking for - the command in the PATH variable. This is no longer true. - Thus, with ksh-93, if you have the current directory first - in your PATH, and you have a program named test in your - directory, it will be executed when you type test; the - built-in version will be run at the point /bin is found - in your PATH. - -11. Some undocumented combinations of argument passing to ksh - builtins no longer works since ksh-93 is getopts conforming - with respect to its built-ins. For example, typeset -8i - previously would work as a synonym for typeset -i8. - -12. Command substitution and arithmetic expansion are now performed - on PS1, PS3, and ENV when they are expanded. Thus, ` and $( - as part of the value of these variables must be preceded by a \ - to preserve their previous behavior. - -13. The ERRNO variable has been dropped. - -14. If the file name following a redirection symbol contain pattern - characters they will only be expanded for interactive shells. - -15. The arguments to a dot script will be restored when it completes. - -16. The list of tracked aliases is not displayed with alias unless - the -t option is specified. - -17. The POSIX standard requires that test "$arg" have exit status - of 0, if and only if $arg is null. However, since this breaks - programs that use test -t, ksh93 treats an explicit test -t - as if the user had entered test -t 1. - -18. The ^T directive of emacs mode has been changed to work the - way it does in gnu-emacs. - -19. ksh-88 allowed unbalanced parenthes within ${name op val} whereas - ksh-93 does not. Thus, ${foo-(} needs to be written as ${foo-\(} - which works with both versions. - -20. kill -l in ksh-93 lists only the signal names, not their numerical - values. - -I am interested in expanding this list so please let me know if you -uncover any others. diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/Makefile b/cde/programs/dtksh/ksh93/src/cmd/ksh93/Makefile deleted file mode 100644 index af7b38b06..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/Makefile +++ /dev/null @@ -1,85 +0,0 @@ -/* $XConsortium: Makefile /main/3 1996/05/10 17:18:25 drk $ */ -/* - * ksh makefile - * This makefile should work with nmake 2.3 and higher - */ - -:PACKAGE: ast - -.SOURCE : edit sh bltins data tests -.SOURCE.h : include - -clobber = !(ksh) /* move ksh to ksh.old on clobber */ - -SH = ksh /* name of the shell program */ -VERSION = 1.1 - -/* documentation files */ -DOCFILES = sh.memo grep.mm builtins.mm README RELEASE COMPATIBILITY PROMO \ - OBSOLETE RELEASEa - -KSHELL == 1 /* this is ksh */ - -/* set these variables to 1 to enable, null to disable */ -DEBUG == /* debugging purposes only */ -MTRACE == /* on for malloc tracing */ -SHOPT_ESH == 1 /* emacs/gmacs edit mode */ -SHOPT_VSH == 1 /* vi edit mode */ -SHOPT_SPAWN == /* use spawnve for fork/exec */ -SHOPT_SUID_EXEC == 1 /* allow (safe) suid/sgid shell scripts */ - -/* use the following libraries only if they exist */ -LIBS_opt := +lm +ljobs +li -if ! "$(-mam:N=static*)" && ! "$(HOSTTYPE:N=sgi.mips*)" - LIBS_opt += +lsocket +lnsl -end -LIBS_opt += -ldl -ldld +lintl -$(LIBS_opt) : .DONTCARE - -LDLIBRARIES = $(LIBS_opt) - -FILES_opt = /* optional file list enabled by vars above */ -FILES_opt += $(SHOPT_ESH:T=V?emacs.c) -FILES_opt += $(SHOPT_VSH:T=V?vi.c) -/* -LDFLAGS += -u _XtAppInitialize -L/usr/add-on/X11/lib -*/ - -.ALL : $(SH) shcomp ksh.msg $(SHOPT_SUID_EXEC:T=V?suid_exec.c) - -$(SH) :: sh.1 main.c -lshell +lcmd /* -lXaw -lXmu -lXt -lXtext -lX11 */ +last - -DATAFILES = limits.c msg.c strdata.c testops.c keywords.c options.c \ - signals.c aliases.c builtins.c variables.c lexstates.c - -shell $(VERSION) :LIBRARY: nval.3 alarm.c cd_pwd.c cflow.c deparse.c \ - getopts.c hist.c misc.c print.c read.c sleep.c trap.c test.c \ - typeset.c ulimit.c umask.c whence.c \ - arith.c args.c array.c completion.c dlopen.c defs.c edit.c expand.c \ - fault.c fcin.c history.c init.c io.c jobs.c lex.c macro.c name.c \ - parse.c path.c string.c streval.c subshell.c tdump.c timers.c \ - trestore.c userinit.c waitevent.c xec.c $(DATAFILES) $(FILES_opt) - -:READONLY: $(DATAFILES) - -$(INCLUDEDIR) :INSTALLPROTO: nval.h shell.h - -suid_exec :: suid_exec.c - -shcomp :: shcomp.c -lshell -lcmd -last - -ksh.msg : $(DATAFILES) /* build error message dictionary */ - grep '[ ]e_[a-z].*".*[^\][a-z].*"' $(*) | grep -v /bin/ | grep -v /usr/ | grep -v /dev/ | grep -v /etc/ | grep -v A__z | sed 's/.*=[ ]*\(".*"\);.*/\1/' | sort | uniq > $(<) - grep '[ ]sh_opt.*".*[^\][a-z].*"' $(*) | sed 's/.*=[ ]*\(".*"\);.*/\1/' >> $(<) - grep '[ ]is_[a-z].*".*[^\][a-z].*"' $(*) | sed 's/.*=[ ]*\(".*"\);.*/\1/' >> $(<) - grep '[ ]e_notset' $(*) | sed 's/.*"....\(.*"\).*/"\1/' >> $(<) - grep '[ ]e_subst' $(*) | sed 's/.*"....\(.*"\).*/"\1/' >> $(<) - grep '[ ]e_file' $(*) | sed 's/.*"....\(.*"\).*/"\1/' >> $(<) - grep ',$' $(*:N=*signals.c) | sed 's/.*\(".*"\),/\1/' | sort | uniq >> $(<) - -:: syscall.s mamexec mamstate.c apollo.c deparse.c ksh.mk OPTIONS $(DOCFILES) - -$(TESTS):: alias.sh arith.sh arrays.sh attributes.sh basic.sh bracket.sh \ - builtins.sh case.sh comvar.sh coprocess.sh exit.sh functions.sh \ - grep.sh heredoc.sh io.sh options.sh quoting.sh return.sh select.sh \ - substring.sh tilde.sh variables.sh nameref.sh shtests diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/Mamfile b/cde/programs/dtksh/ksh93/src/cmd/ksh93/Mamfile deleted file mode 100644 index 6fa6a414c..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/Mamfile +++ /dev/null @@ -1,1113 +0,0 @@ -note : : make abstract machine file generated from Makefile : : note -info mam static 00000 07/17/94 make (AT&T Bell Laboratories) 3.2 research 05/09/95 -setv INSTALLROOT ../../.. -setv PACKAGE_ast ${INSTALLROOT} -setv PACKAGE_ast_INCLUDE ${PACKAGE_ast}/include -setv PACKAGE_ast_LIB ${PACKAGE_ast}/lib -setv AR ar -setv ARFLAGS cr -setv AS as -setv ASFLAGS -setv CC cc -setv CCFLAGS "-O" -setv COTEMP $$ -setv CPIO cpio -setv CPIOFLAGS -setv CPP "${CC} -E" -setv F77 f77 -setv HOSTCC ${CC} -setv IGNORE -setv LD ld -setv LDFLAGS -setv LEX lex -setv LEXFLAGS -setv LPR lpr -setv LPRFLAGS -setv M4FLAGS -setv MAKE nmake -setv MAKEFLAGS -setv PR pr -setv PRFLAGS -setv SHELL /bin/sh -setv SILENT -setv TAR tar -setv YACC yacc -setv YACCFLAGS -d -make install -make all -make ksh -make main.o -make sh/main.c -make FEATURE/externs implicit -make features/externs -done features/externs -setv mam_libm `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -lm >/dev/null 2>&1 && echo ' -lm'; rm -f x.${!-$$}.[cox])` -setv mam_libjobs `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -ljobs >/dev/null 2>&1 && echo ' -ljobs'; rm -f x.${!-$$}.[cox])` -setv mam_libi `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -li >/dev/null 2>&1 && echo ' -li'; rm -f x.${!-$$}.[cox])` -setv mam_libdl `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -ldl >/dev/null 2>&1 && echo ' -ldl'; rm -f x.${!-$$}.[cox])` -setv mam_libdld `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -ldld >/dev/null 2>&1 && echo ' -ldld'; rm -f x.${!-$$}.[cox])` -setv mam_libintl `(set -; cd /tmp; echo 'int main(){return(0);}' > x.${!-$$}.c; ${CC} ${CCFLAGS} -o x.${!-$$}.x x.${!-$$}.c -lintl >/dev/null 2>&1 && echo ' -lintl'; rm -f x.${!-$$}.[cox])` -setv mam_libast ${mam_cc_L+-last}${mam_cc_L-${INSTALLROOT}/lib/libast.a} -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/externs -done FEATURE/externs generated -make FEATURE/execargs implicit -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : def execargs -done FEATURE/execargs generated -make FEATURE/pstat implicit -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : def pstat -done FEATURE/pstat generated -make FEATURE/time implicit -make features/time -done features/time -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/time -done FEATURE/time generated -make include/timeout.h implicit -done include/timeout.h -make include/history.h implicit -done include/history.h -make include/shnodes.h implicit -done include/shnodes.h -make include/jobs.h implicit -make FEATURE/ttys implicit -make features/ttys -done features/ttys -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/ttys -done FEATURE/ttys dontcare generated -make FEATURE/options implicit -make features/options.sh -make OPTIONS implicit -done OPTIONS -done features/options.sh -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/options.sh OPTIONS -done FEATURE/options dontcare generated -done include/jobs.h -make include/io.h implicit -make ${PACKAGE_ast_INCLUDE}/ast/sfio.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/sfio.h -make ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/ast.h -done include/io.h -make include/path.h implicit -make FEATURE/acct implicit -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : def acct -done FEATURE/acct dontcare generated -make FEATURE/options implicit -done FEATURE/options dontcare generated -done include/path.h -make include/variables.h implicit -make FEATURE/dynamic implicit -make features/dynamic -done features/dynamic -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/dynamic -done FEATURE/dynamic dontcare generated -prev FEATURE/options implicit -done include/variables.h -make include/defs.h implicit -make include/shell.h implicit -done include/shell.h -make include/argnod.h implicit -done include/argnod.h -make include/fault.h implicit -make FEATURE/sigfeatures implicit -make features/sigfeatures -done features/sigfeatures -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/sigfeatures -done FEATURE/sigfeatures dontcare generated -make FEATURE/setjmp implicit -make features/setjmp -done features/setjmp -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/setjmp -done FEATURE/setjmp dontcare generated -done include/fault.h -prev include/history.h implicit -prev FEATURE/options implicit -done include/defs.h -make ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/ls.h -done sh/main.c -prev sh/main.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -DKSHELL -c sh/main.c -done main.o generated -make libshell.a archive -make alarm.o -make bltins/alarm.c -prev FEATURE/time implicit -make include/builtins.h implicit -make FEATURE/dynamic implicit -done FEATURE/dynamic dontcare generated -prev FEATURE/options implicit -done include/builtins.h -make ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/stak.h -make ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/error.h -prev include/defs.h implicit -done bltins/alarm.c -prev bltins/alarm.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/alarm.c -done alarm.o generated -make cd_pwd.o -make bltins/cd_pwd.c -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev include/builtins.h implicit -make include/name.h implicit -done include/name.h -prev include/path.h implicit -prev include/variables.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev include/defs.h implicit -done bltins/cd_pwd.c -prev bltins/cd_pwd.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/cd_pwd.c -done cd_pwd.o generated -make cflow.o -make bltins/cflow.c -prev include/builtins.h implicit -prev include/shnodes.h implicit -make /usr/include/ctype.h implicit -done /usr/include/ctype.h -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -prev include/defs.h implicit -done bltins/cflow.c -prev bltins/cflow.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/cflow.c -done cflow.o generated -make deparse.o -make sh/deparse.c -make include/test.h implicit -done include/test.h -prev include/shnodes.h implicit -prev include/defs.h implicit -done sh/deparse.c -prev sh/deparse.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/deparse.c -done deparse.o generated -make getopts.o -make bltins/getopts.c -prev include/builtins.h implicit -make include/nval.h implicit -done include/nval.h -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/variables.h implicit -prev include/defs.h implicit -done bltins/getopts.c -prev bltins/getopts.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/getopts.c -done getopts.o generated -make hist.o -make bltins/hist.c -prev include/builtins.h implicit -prev include/history.h implicit -prev include/name.h implicit -prev include/io.h implicit -prev include/variables.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev include/defs.h implicit -done bltins/hist.c -prev bltins/hist.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c bltins/hist.c -done hist.o generated -make misc.o -make bltins/misc.c -prev include/jobs.h implicit -prev include/builtins.h implicit -prev include/history.h implicit -prev include/name.h implicit -prev include/io.h implicit -prev include/path.h implicit -prev include/shnodes.h implicit -prev include/variables.h implicit -prev include/defs.h implicit -done bltins/misc.c -prev bltins/misc.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c bltins/misc.c -done misc.o generated -make print.o -make bltins/print.c -prev include/builtins.h implicit -prev include/history.h implicit -prev include/name.h implicit -prev include/io.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/defs.h implicit -done bltins/print.c -prev bltins/print.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c bltins/print.c -done print.o generated -make read.o -make bltins/read.c -make include/national.h implicit -done include/national.h -make include/terminal.h implicit -done include/terminal.h -prev include/history.h implicit -prev include/builtins.h implicit -prev include/name.h implicit -prev include/io.h implicit -make include/lexstates.h implicit -done include/lexstates.h -prev include/variables.h implicit -prev include/defs.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done bltins/read.c -prev bltins/read.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -DKSHELL -c bltins/read.c -done read.o generated -make sleep.o -make bltins/sleep.c -make FEATURE/poll implicit -make features/poll -done features/poll -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/poll -done FEATURE/poll generated -prev FEATURE/time implicit -prev include/builtins.h implicit -make /usr/include/errno.h implicit -done /usr/include/errno.h -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/defs.h implicit -done bltins/sleep.c -prev bltins/sleep.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/sleep.c -done sleep.o generated -make trap.o -make bltins/trap.c -prev include/builtins.h implicit -prev include/jobs.h implicit -prev /usr/include/ctype.h implicit -prev include/defs.h implicit -done bltins/trap.c -prev bltins/trap.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/trap.c -done trap.o generated -make test.o -make bltins/test.c -prev FEATURE/externs implicit -prev include/builtins.h implicit -prev include/test.h implicit -prev include/terminal.h implicit -prev include/io.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev /usr/include/ctype.h implicit -prev include/defs.h implicit -done bltins/test.c -prev bltins/test.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c bltins/test.c -done test.o generated -make typeset.o -make bltins/typeset.c -prev include/argnod.h implicit -make include/fcin.h implicit -done include/fcin.h -prev include/variables.h implicit -prev include/builtins.h implicit -prev include/history.h implicit -prev include/name.h implicit -prev include/path.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/defs.h implicit -done bltins/typeset.c -prev bltins/typeset.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/typeset.c -done typeset.o generated -make ulimit.o -make bltins/ulimit.c -make include/ulimit.h implicit -prev FEATURE/time implicit -make FEATURE/rlimits implicit -make features/rlimits -done features/rlimits -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/rlimits -done FEATURE/rlimits dontcare generated -done include/ulimit.h -prev include/builtins.h implicit -prev include/shell.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/sfio.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done bltins/ulimit.c -prev bltins/ulimit.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/ulimit.c -done ulimit.o generated -make umask.o -make bltins/umask.c -prev include/builtins.h implicit -prev include/shell.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/sfio.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done bltins/umask.c -prev bltins/umask.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/umask.c -done umask.o generated -make whence.o -make bltins/whence.c -prev include/builtins.h implicit -make include/shlex.h implicit -prev FEATURE/options implicit -done include/shlex.h -prev include/path.h implicit -prev include/name.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/defs.h implicit -done bltins/whence.c -prev bltins/whence.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c bltins/whence.c -done whence.o generated -make arith.o -make sh/arith.c -make FEATURE/locale implicit -make features/locale -done features/locale -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/locale -done FEATURE/locale generated -make include/streval.h implicit -done include/streval.h -prev include/name.h implicit -prev include/lexstates.h implicit -prev /usr/include/ctype.h implicit -prev include/defs.h implicit -done sh/arith.c -prev sh/arith.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/arith.c -done arith.o generated -make args.o -make sh/args.c -prev include/terminal.h implicit -prev include/builtins.h implicit -prev include/path.h implicit -prev include/defs.h implicit -done sh/args.c -prev sh/args.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c sh/args.c -done args.o generated -make array.o -make sh/array.c -prev include/name.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev include/defs.h implicit -done sh/array.c -prev sh/array.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/array.c -done array.o generated -make completion.o -make edit/completion.c -prev include/history.h implicit -make include/edit.h implicit -make FEATURE/setjmp implicit -done FEATURE/setjmp dontcare generated -prev FEATURE/options implicit -done include/edit.h -prev include/io.h implicit -prev include/path.h implicit -prev include/lexstates.h implicit -prev include/defs.h implicit -done edit/completion.c -prev edit/completion.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DKSHELL -DSHOPT_VSH -DSHOPT_SUID_EXEC -c edit/completion.c -done completion.o generated -make dlopen.o -make sh/dlopen.c -prev FEATURE/dynamic implicit -prev include/nval.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/dlopen.c -prev sh/dlopen.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c sh/dlopen.c -done dlopen.o generated -make defs.o -make sh/defs.c -prev include/timeout.h implicit -prev include/edit.h implicit -prev include/shlex.h implicit -prev include/jobs.h implicit -prev include/defs.h implicit -done sh/defs.c -prev sh/defs.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DKSHELL -DSHOPT_SUID_EXEC -c sh/defs.c -done defs.o generated -make edit.o -make edit/edit.c -prev include/edit.h implicit -prev include/history.h implicit -prev include/terminal.h implicit -prev include/io.h implicit -prev FEATURE/time implicit -prev include/path.h implicit -prev FEATURE/options implicit -prev /usr/include/ctype.h implicit -prev /usr/include/errno.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done edit/edit.c -prev edit/edit.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DKSHELL -DSHOPT_SUID_EXEC -c edit/edit.c -done edit.o generated -make expand.o -make sh/expand.c -prev include/path.h implicit -prev include/io.h implicit -make ${PACKAGE_ast_INCLUDE}/ast/ast_dir.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/ast_dir.h -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -done sh/expand.c -prev sh/expand.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -DKSHELL -c sh/expand.c -done expand.o generated -make fault.o -make sh/fault.c -prev include/path.h implicit -prev include/jobs.h implicit -prev include/shnodes.h implicit -prev include/history.h implicit -prev include/io.h implicit -prev include/fcin.h implicit -prev include/defs.h implicit -done sh/fault.c -prev sh/fault.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -DKSHELL -c sh/fault.c -done fault.o generated -make fcin.o -make sh/fcin.c -prev include/fcin.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/sfio.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/fcin.c -prev sh/fcin.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c sh/fcin.c -done fcin.o generated -make history.o -make edit/history.c -prev include/national.h implicit -prev include/history.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev FEATURE/time implicit -prev ${PACKAGE_ast_INCLUDE}/ast/sfio.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done edit/history.c -prev edit/history.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_ESH -DKSHELL -DSHOPT_SUID_EXEC -c edit/history.c -done history.o generated -make init.o -make sh/init.c -prev include/national.h implicit -prev FEATURE/locale implicit -prev include/lexstates.h implicit -prev FEATURE/dynamic implicit -prev FEATURE/time implicit -prev include/io.h implicit -prev include/jobs.h implicit -prev include/name.h implicit -prev include/fault.h implicit -prev include/path.h implicit -prev include/variables.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev include/defs.h implicit -done sh/init.c -prev sh/init.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/init.c -done init.o generated -make io.o -make sh/io.c -prev FEATURE/poll implicit -prev FEATURE/dynamic implicit -prev FEATURE/externs implicit -prev include/timeout.h implicit -prev include/edit.h implicit -prev include/history.h implicit -prev include/shnodes.h implicit -prev include/jobs.h implicit -prev include/io.h implicit -prev include/variables.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev include/fcin.h implicit -prev include/defs.h implicit -done sh/io.c -prev sh/io.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_ESH -DKSHELL -DSHOPT_SUID_EXEC -c sh/io.c -done io.o generated -make jobs.o -make sh/jobs.c -prev include/history.h implicit -prev include/jobs.h implicit -prev include/io.h implicit -make ${PACKAGE_ast_INCLUDE}/ast/wait.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/wait.h -prev /usr/include/ctype.h implicit -prev include/defs.h implicit -done sh/jobs.c -prev sh/jobs.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_ESH -DSHOPT_SUID_EXEC -DKSHELL -c sh/jobs.c -done jobs.o generated -make lex.o -make sh/lex.c -prev include/lexstates.h implicit -prev include/test.h implicit -prev include/shlex.h implicit -prev include/argnod.h implicit -prev FEATURE/options implicit -prev include/nval.h implicit -prev include/fcin.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/lex.c -prev sh/lex.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -DKSHELL -c sh/lex.c -done lex.o generated -make macro.o -make sh/macro.c -prev include/national.h implicit -prev include/path.h implicit -prev include/shnodes.h implicit -prev include/io.h implicit -prev include/shlex.h implicit -prev include/variables.h implicit -prev include/name.h implicit -make /usr/include/pwd.h implicit -done /usr/include/pwd.h -prev include/fcin.h implicit -prev include/defs.h implicit -done sh/macro.c -prev sh/macro.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -c sh/macro.c -done macro.o generated -make name.o -make sh/name.c -prev include/builtins.h implicit -prev include/shnodes.h implicit -prev include/national.h implicit -prev FEATURE/locale implicit -prev include/timeout.h implicit -prev include/lexstates.h implicit -prev include/path.h implicit -prev include/variables.h implicit -prev /usr/include/ctype.h implicit -prev include/defs.h implicit -done sh/name.c -prev sh/name.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c sh/name.c -done name.o generated -make parse.o -make sh/parse.c -prev include/test.h implicit -prev include/builtins.h implicit -prev include/history.h implicit -prev include/shlex.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev include/fcin.h implicit -prev /usr/include/ctype.h implicit -done sh/parse.c -prev sh/parse.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c sh/parse.c -done parse.o generated -make path.o -make sh/path.c -prev FEATURE/time implicit -prev FEATURE/externs implicit -prev include/test.h implicit -prev include/history.h implicit -prev include/jobs.h implicit -prev include/io.h implicit -prev include/path.h implicit -prev include/variables.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev include/fcin.h implicit -prev include/defs.h implicit -done sh/path.c -prev sh/path.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_SUID_EXEC -DSHOPT_ESH -DSHOPT_VSH -DKSHELL -c sh/path.c -done path.o generated -make string.o -make sh/string.c -prev include/national.h implicit -prev include/lexstates.h implicit -make include/shtable.h implicit -done include/shtable.h -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/stak.h implicit -prev include/defs.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/string.c -prev sh/string.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/string.c -done string.o generated -make streval.o -make sh/streval.c -prev FEATURE/externs implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev /usr/include/ctype.h implicit -prev include/streval.h implicit -done sh/streval.c -prev sh/streval.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c sh/streval.c -done streval.o generated -make subshell.o -make sh/subshell.c -prev include/path.h implicit -prev include/variables.h implicit -prev include/jobs.h implicit -prev include/shlex.h implicit -prev include/shnodes.h implicit -prev include/fault.h implicit -prev include/io.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev include/defs.h implicit -done sh/subshell.c -prev sh/subshell.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -DKSHELL -c sh/subshell.c -done subshell.o generated -make tdump.o -make sh/tdump.c -prev include/io.h implicit -prev include/path.h implicit -prev include/shnodes.h implicit -prev include/defs.h implicit -done sh/tdump.c -prev sh/tdump.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -c sh/tdump.c -done tdump.o generated -make timers.o -make sh/timers.c -prev FEATURE/time implicit -make FEATURE/sigfeatures implicit -done FEATURE/sigfeatures generated -prev include/fault.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -make ${PACKAGE_ast_INCLUDE}/ast/sig.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/sig.h -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/timers.c -prev sh/timers.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c sh/timers.c -done timers.o generated -make trestore.o -make sh/trestore.c -prev include/io.h implicit -prev include/path.h implicit -prev include/shnodes.h implicit -prev include/defs.h implicit -done sh/trestore.c -prev sh/trestore.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -c sh/trestore.c -done trestore.o generated -make userinit.o -make sh/userinit.c -prev include/defs.h implicit -done sh/userinit.c -prev sh/userinit.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/userinit.c -done userinit.o generated -make waitevent.o -make sh/waitevent.c -prev include/defs.h implicit -done sh/waitevent.c -prev sh/waitevent.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c sh/waitevent.c -done waitevent.o generated -make xec.o -make sh/xec.c -prev FEATURE/locale implicit -prev FEATURE/externs implicit -prev FEATURE/time implicit -prev include/builtins.h implicit -prev include/test.h implicit -prev include/jobs.h implicit -prev include/shnodes.h implicit -prev include/io.h implicit -prev include/path.h implicit -prev include/variables.h implicit -prev include/fcin.h implicit -prev include/defs.h implicit -done sh/xec.c -prev sh/xec.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c sh/xec.c -done xec.o generated -make limits.o -make data/limits.c -prev include/ulimit.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done data/limits.c -prev data/limits.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c data/limits.c -done limits.o generated -make msg.o -make data/msg.c -prev include/national.h implicit -prev include/edit.h implicit -prev include/jobs.h implicit -prev include/builtins.h implicit -prev include/history.h implicit -prev include/timeout.h implicit -prev include/shlex.h implicit -prev include/io.h implicit -prev include/path.h implicit -prev include/defs.h implicit -prev /usr/include/errno.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done data/msg.c -prev data/msg.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_SUID_EXEC -DKSHELL -DSHOPT_ESH -DSHOPT_VSH -c data/msg.c -done msg.o generated -make strdata.o -make data/strdata.c -prev include/streval.h implicit -prev FEATURE/options implicit -done data/strdata.c -prev data/strdata.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/strdata.c -done strdata.o generated -make testops.o -make data/testops.c -prev include/test.h implicit -prev include/shtable.h implicit -done data/testops.c -prev data/testops.c -exec - ${CC} ${CCFLAGS} -Iinclude -c data/testops.c -done testops.o generated -make keywords.o -make data/keywords.c -prev FEATURE/options implicit -prev include/shlex.h implicit -prev include/shtable.h implicit -make ${PACKAGE_ast_INCLUDE}/ast/hash.h implicit -done ${PACKAGE_ast_INCLUDE}/ast/hash.h -done data/keywords.c -prev data/keywords.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/keywords.c -done keywords.o generated -make options.o -make data/options.c -prev include/shtable.h implicit -prev include/name.h implicit -prev FEATURE/options implicit -prev include/shell.h implicit -done data/options.c -prev data/options.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/options.c -done options.o generated -make signals.o -make data/signals.c -prev include/fault.h implicit -prev include/shtable.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done data/signals.c -prev data/signals.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -c data/signals.c -done signals.o generated -make aliases.o -make data/aliases.c -prev include/name.h implicit -prev include/shtable.h implicit -prev FEATURE/dynamic implicit -prev FEATURE/options implicit -make /usr/include/signal.h implicit -done /usr/include/signal.h -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done data/aliases.c -prev data/aliases.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/aliases.c -done aliases.o generated -make builtins.o -make data/builtins.c -make FEATURE/cmds implicit -make features/cmds -done features/cmds -exec - iffe set cc ${CC} ${ICCFLAGS} ${LDFLAGS} : ref ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} : run features/cmds -done FEATURE/cmds dontcare generated -prev include/name.h implicit -prev include/shtable.h implicit -prev /usr/include/signal.h implicit -prev include/shell.h implicit -done data/builtins.c -prev data/builtins.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -DKSHELL -c data/builtins.c -done builtins.o generated -make variables.o -make data/variables.c -prev include/name.h implicit -prev include/shtable.h implicit -prev include/shell.h implicit -prev FEATURE/dynamic implicit -prev FEATURE/options implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done data/variables.c -prev data/variables.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/variables.c -done variables.o generated -make lexstates.o -make data/lexstates.c -prev include/lexstates.h implicit -prev FEATURE/options implicit -done data/lexstates.c -prev data/lexstates.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -DSHOPT_VSH -DSHOPT_SUID_EXEC -DSHOPT_ESH -c data/lexstates.c -done lexstates.o generated -make emacs.o -make edit/emacs.c -prev include/terminal.h implicit -prev include/edit.h implicit -prev include/history.h implicit -prev include/io.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done edit/emacs.c -prev edit/emacs.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c edit/emacs.c -done emacs.o generated -make vi.o -make edit/vi.c -prev FEATURE/time implicit -prev include/terminal.h implicit -prev include/edit.h implicit -prev include/history.h implicit -prev include/io.h implicit -prev /usr/include/ctype.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev FEATURE/options implicit -done edit/vi.c -prev edit/vi.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_ESH -DSHOPT_VSH -DSHOPT_SUID_EXEC -c edit/vi.c -done vi.o generated -exec - ${AR} cr libshell.a alarm.o cd_pwd.o cflow.o deparse.o getopts.o hist.o misc.o print.o read.o sleep.o trap.o test.o typeset.o ulimit.o umask.o whence.o arith.o args.o array.o completion.o dlopen.o defs.o edit.o expand.o fault.o fcin.o history.o init.o io.o jobs.o -exec - ${AR} cr libshell.a lex.o macro.o name.o parse.o path.o string.o streval.o subshell.o tdump.o timers.o trestore.o userinit.o waitevent.o xec.o limits.o msg.o strdata.o testops.o keywords.o options.o signals.o aliases.o builtins.o variables.o lexstates.o emacs.o vi.o -exec - (ranlib libshell.a) >/dev/null 2>&1 || true -done libshell.a generated -setv mam_libcmd ${mam_cc_L+-lcmd}${mam_cc_L-${INSTALLROOT}/lib/libcmd.a} -setv mam_libcmd `${mam_cc_L+cat} ${mam_cc_L-sed} ${mam_cc_L-s,-lcmd,${INSTALLROOT}/lib/libcmd.a,} ${PACKAGE_ast_LIB}/lib/cmd` -exec - ${CC} ${CCFLAGS} ${LDFLAGS} ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} -o ksh main.o libshell.a ${mam_libcmd} ${mam_cc_static} ${mam_libast} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} -done ksh generated -make shcomp -make shcomp.o -make sh/shcomp.c -prev include/io.h implicit -prev include/path.h implicit -prev include/shnodes.h implicit -prev include/defs.h implicit -done sh/shcomp.c -prev sh/shcomp.c -exec - ${CC} ${CCFLAGS} -I. -Iinclude -I${PACKAGE_ast_INCLUDE}/ast -DKSHELL -DSHOPT_SUID_EXEC -DSHOPT_VSH -DSHOPT_ESH -c sh/shcomp.c -done shcomp.o virtual -prev libshell.a archive -setv mam_libcmd `${mam_cc_L+cat} ${mam_cc_L-sed} ${mam_cc_L-s,-lcmd,${INSTALLROOT}/lib/libcmd.a,} ${PACKAGE_ast_LIB}/lib/cmd` -exec - ${CC} ${CCFLAGS} ${LDFLAGS} ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} -o shcomp shcomp.o libshell.a ${mam_libcmd} ${mam_libast} ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} -done shcomp virtual -make ksh.msg -prev data/limits.c -prev data/msg.c -prev data/strdata.c -prev data/testops.c -prev data/keywords.c -prev data/options.c -prev data/signals.c -prev data/aliases.c -prev data/builtins.c -prev data/variables.c -prev data/lexstates.c -exec - grep '[ ]e_[a-z].*".*[^\][a-z].*"' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | grep -v /bin/ | grep -v /usr/ | grep -v /dev/ | grep -v /etc/ | grep -v A__z | sed 's/.*=[ ]*\(".*"\);.*/\1/' | sort | uniq > ksh.msg -exec - grep '[ ]sh_opt.*".*[^\][a-z].*"' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | sed 's/.*=[ ]*\(".*"\);.*/\1/' >> ksh.msg -exec - grep '[ ]is_[a-z].*".*[^\][a-z].*"' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | sed 's/.*=[ ]*\(".*"\);.*/\1/' >> ksh.msg -exec - grep '[ ]e_notset' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | sed 's/.*"....\(.*"\).*/"\1/' >> ksh.msg -exec - grep '[ ]e_subst' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | sed 's/.*"....\(.*"\).*/"\1/' >> ksh.msg -exec - grep '[ ]e_file' data/limits.c data/msg.c data/strdata.c data/testops.c data/keywords.c data/options.c data/signals.c data/aliases.c data/builtins.c data/variables.c data/lexstates.c | sed 's/.*"....\(.*"\).*/"\1/' >> ksh.msg -exec - grep ',$' data/signals.c | sed 's/.*\(".*"\),/\1/' | sort | uniq >> ksh.msg -done ksh.msg virtual -make sh/suid_exec.c -prev ${PACKAGE_ast_INCLUDE}/ast/error.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/sig.h implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ls.h implicit -prev FEATURE/externs implicit -prev ${PACKAGE_ast_INCLUDE}/ast/ast.h implicit -done sh/suid_exec.c -make shell -prev libshell.a archive -done shell virtual -prev libshell.a archive -make suid_exec -make suid_exec.o -prev sh/suid_exec.c -prev sh/suid_exec.c -exec - ${CC} ${CCFLAGS} -I. -I${PACKAGE_ast_INCLUDE}/ast -c sh/suid_exec.c -done suid_exec.o virtual -exec - ${CC} ${CCFLAGS} ${LDFLAGS} ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} -o suid_exec suid_exec.o ${mam_cc_static} ${mam_libm} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libjobs} ${mam_cc_dynamic} ${mam_cc_static} ${mam_libi} ${mam_cc_dynamic} ${mam_libdl} ${mam_libdld} ${mam_cc_static} ${mam_libintl} ${mam_cc_dynamic} ${mam_libast} -done suid_exec virtual -done all virtual -make ${INSTALLROOT}/bin -exec - set - -exec - if test ! -d ${INSTALLROOT}/bin -exec - then set -x && mkdir -p ${INSTALLROOT}/bin 2>/dev/null && set - || -exec - { -exec - test -d ./-p && rm -rf ./-p -exec - p= -exec - for d in `echo ${INSTALLROOT}/bin | sed -e 's%\\(.\\)/%\\1 %g'` -exec - do case $p in -exec - "") p=$d ;; -exec - *) p=$p/$d ;; -exec - esac -exec - case $d in -exec - .|..) ;; -exec - *) if test ! -d $p -exec - then rm -f $p -exec - set -x && mkdir $p && set - -exec - fi -exec - ;; -exec - esac -exec - done -exec - } && set -x -exec - fi -done ${INSTALLROOT}/bin generated -make ${INSTALLROOT}/bin/ksh -prev ksh -exec - { mv ${INSTALLROOT}/bin/ksh ${INSTALLROOT}/bin/ksh.old 2>/dev/null; cp ksh ${INSTALLROOT}/bin/ksh 2>/dev/null ;} || true -done ${INSTALLROOT}/bin/ksh virtual -make ${INSTALLROOT}/man/man1 -exec - set - -exec - if test ! -d ${INSTALLROOT}/man/man1 -exec - then set -x && mkdir -p ${INSTALLROOT}/man/man1 2>/dev/null && set - || -exec - { -exec - test -d ./-p && rm -rf ./-p -exec - p= -exec - for d in `echo ${INSTALLROOT}/man/man1 | sed -e 's%\\(.\\)/%\\1 %g'` -exec - do case $p in -exec - "") p=$d ;; -exec - *) p=$p/$d ;; -exec - esac -exec - case $d in -exec - .|..) ;; -exec - *) if test ! -d $p -exec - then rm -f $p -exec - set -x && mkdir $p && set - -exec - fi -exec - ;; -exec - esac -exec - done -exec - } && set -x -exec - fi -done ${INSTALLROOT}/man/man1 generated -make ${INSTALLROOT}/man/man1/sh.1 -make sh.1 -done sh.1 -exec - { mv ${INSTALLROOT}/man/man1/sh.1 ${INSTALLROOT}/man/man1/sh.1.old 2>/dev/null; cp sh.1 ${INSTALLROOT}/man/man1/sh.1 2>/dev/null ;} || true -done ${INSTALLROOT}/man/man1/sh.1 generated -make ${INSTALLROOT}/lib -exec - set - -exec - if test ! -d ${INSTALLROOT}/lib -exec - then set -x && mkdir -p ${INSTALLROOT}/lib 2>/dev/null && set - || -exec - { -exec - test -d ./-p && rm -rf ./-p -exec - p= -exec - for d in `echo ${INSTALLROOT}/lib | sed -e 's%\\(.\\)/%\\1 %g'` -exec - do case $p in -exec - "") p=$d ;; -exec - *) p=$p/$d ;; -exec - esac -exec - case $d in -exec - .|..) ;; -exec - *) if test ! -d $p -exec - then rm -f $p -exec - set -x && mkdir $p && set - -exec - fi -exec - ;; -exec - esac -exec - done -exec - } && set -x -exec - fi -done ${INSTALLROOT}/lib generated -make ${INSTALLROOT}/lib/libshell.a archive -prev libshell.a archive -exec - { mv ${INSTALLROOT}/lib/libshell.a ${INSTALLROOT}/lib/libshell.a.old 2>/dev/null; cp libshell.a ${INSTALLROOT}/lib/libshell.a 2>/dev/null ;} || true -exec - (ranlib ${INSTALLROOT}/lib/libshell.a) >/dev/null 2>&1 || true -done ${INSTALLROOT}/lib/libshell.a generated -make ${INSTALLROOT}/man/man3 -exec - set - -exec - if test ! -d ${INSTALLROOT}/man/man3 -exec - then set -x && mkdir -p ${INSTALLROOT}/man/man3 2>/dev/null && set - || -exec - { -exec - test -d ./-p && rm -rf ./-p -exec - p= -exec - for d in `echo ${INSTALLROOT}/man/man3 | sed -e 's%\\(.\\)/%\\1 %g'` -exec - do case $p in -exec - "") p=$d ;; -exec - *) p=$p/$d ;; -exec - esac -exec - case $d in -exec - .|..) ;; -exec - *) if test ! -d $p -exec - then rm -f $p -exec - set -x && mkdir $p && set - -exec - fi -exec - ;; -exec - esac -exec - done -exec - } && set -x -exec - fi -done ${INSTALLROOT}/man/man3 generated -make ${INSTALLROOT}/man/man3/nval.3 -make nval.3 -done nval.3 -exec - { mv ${INSTALLROOT}/man/man3/nval.3 ${INSTALLROOT}/man/man3/nval.3.old 2>/dev/null; cp nval.3 ${INSTALLROOT}/man/man3/nval.3 2>/dev/null ;} || true -done ${INSTALLROOT}/man/man3/nval.3 generated -make ${INSTALLROOT}/include/ast -exec - set - -exec - if test ! -d ${INSTALLROOT}/include/ast -exec - then set -x && mkdir -p ${INSTALLROOT}/include/ast 2>/dev/null && set - || -exec - { -exec - test -d ./-p && rm -rf ./-p -exec - p= -exec - for d in `echo ${INSTALLROOT}/include/ast | sed -e 's%\\(.\\)/%\\1 %g'` -exec - do case $p in -exec - "") p=$d ;; -exec - *) p=$p/$d ;; -exec - esac -exec - case $d in -exec - .|..) ;; -exec - *) if test ! -d $p -exec - then rm -f $p -exec - set -x && mkdir $p && set - -exec - fi -exec - ;; -exec - esac -exec - done -exec - } && set -x -exec - fi -done ${INSTALLROOT}/include/ast virtual -make ${INSTALLROOT}/include/ast/nval.h -prev include/nval.h -exec - proto -p -s -c AT\&T\ Bell\ Laboratories include/nval.h > 1.${COTEMP}.x -exec - if cmp -s ${INSTALLROOT}/include/ast/nval.h 1.${COTEMP}.x -exec - then rm -f 1.${COTEMP}.x -exec - else mv 1.${COTEMP}.x ${INSTALLROOT}/include/ast/nval.h -exec - fi -done ${INSTALLROOT}/include/ast/nval.h virtual -make ${INSTALLROOT}/include/ast/shell.h -prev include/shell.h -exec - proto -p -s -c AT\&T\ Bell\ Laboratories include/shell.h > 1.${COTEMP}.x -exec - if cmp -s ${INSTALLROOT}/include/ast/shell.h 1.${COTEMP}.x -exec - then rm -f 1.${COTEMP}.x -exec - else mv 1.${COTEMP}.x ${INSTALLROOT}/include/ast/shell.h -exec - fi -done ${INSTALLROOT}/include/ast/shell.h virtual -make ${INSTALLROOT}/bin/suid_exec -prev suid_exec -exec - { mv ${INSTALLROOT}/bin/suid_exec ${INSTALLROOT}/bin/suid_exec.old 2>/dev/null; cp suid_exec ${INSTALLROOT}/bin/suid_exec 2>/dev/null ;} || true -done ${INSTALLROOT}/bin/suid_exec generated -make ${INSTALLROOT}/bin/shcomp -prev shcomp -exec - { mv ${INSTALLROOT}/bin/shcomp ${INSTALLROOT}/bin/shcomp.old 2>/dev/null; cp shcomp ${INSTALLROOT}/bin/shcomp 2>/dev/null ;} || true -done ${INSTALLROOT}/bin/shcomp virtual -done install virtual diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/OBSOLETE b/cde/programs/dtksh/ksh93/src/cmd/ksh93/OBSOLETE deleted file mode 100644 index c29cb8bb6..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/OBSOLETE +++ /dev/null @@ -1,152 +0,0 @@ -.sp 3 -.tl ''Ksh Features That Are Obsolete in Ksh93'' -.sp 2 -.AL 1 -.LI -Using a pair of grave accents \^\fB\(ga\fR ... \fB\(ga\fR\^ -for command substition. Use \fB$(\fR ... \fB)\fR instead. -.LI -.B FCEDIT -is an obsolete name for -the default editor name for the -.B hist -command. -.B FCEDIT -is not used when -.B HISTEDIT -is set. Use -.B HISTEDIT -instead. -.LI -The newtest (\fB[[\fR ... \fB]]\fR) operator -\fB\-a\fP \fIfile\fP -is obsolete. Use -\fB\-e\fP instead. -.LI -The newtest (\fB[[\fR ... \fB]]\fR) operator -.BR = , -as used in -\fIstring\fP \fB=\fP \fIpattern\fP -is obsolete. Use -\fB==\fP instead. -.LI -The following obsolete arithmetic comparisons are also permitted: -.in +5 -.VL 20 -.LI "\fIexp1\fP \fB\-eq\fP \fIexp2\fP" -True, if -.I exp1 -is equal to -.IR exp2 . -.LI "\fIexp1\fP \fB\-ne\fP \fIexp2\fP" -True, if -.I exp1 -is not equal to -.IR exp2 . -.LI "\fIexp1\fP \fB\-lt\fP \fIexp2\fP" -True, if -.I exp1 -is less than -.IR exp2 . -.LI "\fIexp1\fP \fB\-gt\fP \fIexp2\fP" -True, if -.I exp1 -is greater than -.IR exp2 . -.LI "\fIexp1\fP \fB\-le\fP \fIexp2\fP" -True, if -.I exp1 -is less than or equal to -.IR exp2 . -.LI "\fIexp1\fP \fB\-ge\fP \fIexp2\fP" -True, if -.I exp1 -is greater than or equal to -.IR exp2 . -.LE \" End .VL -.in -5 -.LI -Using test -t or [ -t ] without specifying the file unit number. -.LI -The -.B \-k -option to the \fBset\fR builtin is obsolete. It causes -.I all\^ -variable assignment arguments are placed in the environment, -even if they occur after the command name. -The following -first prints -.B "a=b c" -and then -.BR c : -There is no alternative. -.LI -The obsolete -.B \-xf -option of the -.B typeset -command allows a function to be exported -to scripts that are executed without a separate -invocation of the shell. -Functions that need to be defined across separate -invocations of the shell should -be placed in a directory and the -.B FPATH -variable should contains the name of this directory. -They may also -be specified in the -.B ENV -file with the -.B \-xf -option of -.BR typeset . -.LI -The shell environment variable -.B FCEDIT -is obsolete. Use -.B HISTEDIT -instead. -.LI -In the -.B \-s -option -(to \fBfc\fR or \fBhist\fR command???) -( -and in obsolete versions, the editor name -.B \- -) -is used to skip the editing phase and -to re-execute the command. -.LI -The -.B \-t -option to \fBalias\fR builtin is is obsolete. It -is used to set and list tracked aliases. -There is no replacement. -.LI -The shell command line option -.B \-t -is obsolete. This option cause the shell to exit after reading -and executing one command. The is no replacement (although ending -\&"command" with the exit builtin should have the same effect). -.LI -As an obsolete feature of the "set" builtin, -if the first -.I arg\^ -is -.B \- -then the -.B \-x -and -.B \-v -options are turned off and the next -.I arg -is treated as the first argument. -Using -.B \+ -rather than -.B \- -causes these options to be turned off. -These options can also be used upon invocation of the shell. -.LE - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/OPTIONS b/cde/programs/dtksh/ksh93/src/cmd/ksh93/OPTIONS deleted file mode 100644 index bbaa60808..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/OPTIONS +++ /dev/null @@ -1,19 +0,0 @@ -ACCT= # accounting -ACCTFILE= # enable per user accounting info -BRACEPAT=1 # C-shell {...,...} expansions (note , required) -CRNL=0 # accept for -DYNAMIC=1 # dynamic loading for builtins, requires dlopen() -ECHOPRINT=0 # make echo equivalent to print, overrides ECHO_N -ESH=1 # emacs edit option -FS_3D= # 3d file system -KIA=1 # shell information database generation -MULTIBYTE=1 # multibyte character handling -OLDTERMIO=0 # for systems that must support both TCGETA and TCGETS -OO=1 # partial object oriented extension, not complete -P_SUID=0 # real uid's that require -p flag for setuid/setgid -RAWONLY=0 # make viraw the only vi mode. Sometimes set automatically -SEVENBIT=0 # strip the eigth bit from characters -SPAWN=0 # use libast spawnve() in place of fork/exec when possible -SUID_EXEC=1 # execute /etc/suid_exec for suid, sgid script -TIMEOUT=0 # number of seconds for shell timeout, 0 disables feature -VSH=1 # vi edit option diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/PROMO b/cde/programs/dtksh/ksh93/src/cmd/ksh93/PROMO deleted file mode 100644 index 9361a30e9..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/PROMO +++ /dev/null @@ -1,147 +0,0 @@ -.SA 1 -.sp 2 -.ce -KSH-93 - The KornShell Command and Programming Language -.sp 2 -.al -.P -KSH-93 is the most recent version of the KornShell Language -described in -"The KornShell Command and Programming Language," -by Morris Bolsky and David Korn of AT&T Bell Laboratories, ISBN 0-13-182700-6. -The KornShell is a shell programming language, -which is upward compatible with "sh" (the Bourne Shell), -and is intended to conform to the IEEE P1003.2/ISO 9945.2 Shell and -Utilities standard. -KSH-93 provides an enhanced programming environment in -addition to the major command-entry features of the BSD -shell "csh". With KSH-93, medium-sized programming tasks can be -performed at shell-level without a significant loss in performance. -In addition, "sh" scripts can be run on KSH-93 without modification. -.P -The code should conform to the IEEE POSIX 1003.1 standard and to the -proposed ANSI-C standard so that it should be portable to all -such systems. Like the previous version, KSH-88, -it is designed to accept eight bit character sets -transparently, thereby making it internationally compatible. -It can support multi-byte characters sets with some characteristics -of the character set given at run time. -.P -KSH-93 provides the following features, many of which were also inherent -in KSH-88: -.BL -.LI -Enhanced Command Re-entry Capability: The KSH-93 history -function records commands entered at any shell level and stores -them, up to a user-specified limit, even after you log off. -This allows you to re-enter long commands with a few keystrokes -- even those commands you entered yesterday. -The history file allows for eight bit characters in -commands and supports essentially unlimited size histories. -.LI -In-line Editing: In "sh", the only way to fix mistyped -commands is to backspace or retype the line. KSH-93 allows you -to edit a command line using a choice of EMACS-TC or "vi" -functions. -You can use the in-line editors to complete filenames as -you type them. -You may also use this editing feature when entering -command lines from your history file. -A user can capture keystrokes and rebind keys to customize the -editing interface. -.LI -Extended I/O Capabilities: KSH-93 provides several I/O -capabilities not available in "sh", including the ability to: -.BL -.LI -specify a file descriptor for input and output -.LI -start up and run co-processes -.LI -produce a prompt at the terminal before a read -.LI -easily format and interpret responses to a menu -.LI -echo lines exactly as output without escape processing -.LI -format output using printf formats. -.LI -read and echo lines ending in "\e". -.LE -.LI -Improved performance: KSH-93 executes many scripts faster -than the System V Bourne shell. A major reason for this is -that many of the standard utilities are built-in. -To reduce the time to initiate a command, KSH-93 allows -commands to be added as built-ins at run time -on systems that support dynamic loading such as System V Release 4. -.LI -Arithmetic: KSH-93 allows you to do integer arithmetic in any -base from two to sixty-four. You can also do double -precision floating point arithmetic. -Almost the complete set of C language operators are available -with the same syntax and precedence. -Arithmetic expressions can be used to as an argument expansion -or as a separate command. -In addition there is an arithmetic for command that works -like the for statement in C. -.LI -Arrays: KSH-93 supports both indexed and associative arrays. -The subscript for an indexed array is an arithmetic expression, -whereas, the subscript for an associative array is a string. -.LI -Shell Functions and Aliases: Two mechanisms - functions and -aliases - can be used to assign a user-selected identifier to -an existing command or shell script. -Functions allow local variables and provide scoping -for exception handling. -Functions can be searched for and loaded on first reference the -way scripts are. -.LI -Substring Capabilities: KSH-93 allows you to create a -substring of any given string either by specifying the starting -offset and length, or by stripping off leading -or trailing substrings during parameter substitution. -You can also specify attributes, such as upper and lower case, -field width, and justification to shell variables. -.LI -More pattern matching capabilities: KSH-93 allows you to specify -extended regular expressions for file and string matches. -.LI -KSH-93 uses a hierarchal name space for variables. -Compound variables can be defined and variables can -be passed by reference. In addition, each variable -can have one or more disciplines associated with -it to intercept assignments and references. -.LI -Improved debugging: KSH-93 can generate line numbers on execution -traces. Also, I/O redirections are now traced. -There is a DEBUG trap that gets evaluated after each command -so that errors can be localized. -.LI -Job Control: On systems that support job control, including -System V Release 4, KSH-93 -provides a job-control mechanism almost identical to that of -the BSD "csh", version 4.1. -This feature allows you -to stop and restart programs, and to move programs between the -foreground and the background. -.LI -Added security: -KSH-93 can execute scripts which do not have read permission -and scripts which have the setuid and/or setgid set when -invoked by name, rather than as an argument to the shell. -It is possible to log or control the execution of setuid and/or -setgid scripts. -The noclobber option prevents you from accidentally erasing -a file by redirecting to an existing file. -.LI -KSH-93 can be extended by adding built-in commands at run time. -In addition, KSH-93 can be used as a library that can -be embedded into an application to allow scripting. -.LE -Documentation for KSH-93 consists of an "Introduction to KSH-93", -"Compatibility with the Bourne Shell" and a manual page and a -README file. In addition, the "New KornShell Command and Programming -Language," book is available from Prentice Hall. - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/README b/cde/programs/dtksh/ksh93/src/cmd/ksh93/README deleted file mode 100644 index db7f15afd..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/README +++ /dev/null @@ -1,178 +0,0 @@ -/* $XConsortium: README /main/3 1996/07/15 14:14:10 drk $ */ -This directory, and its subdirectories contain the source code -for ksh-93; the language described in the second addition of -the book, "The KornShell Command and Programming Language," by -Morris Bolsky and David Korn which is published by Prentice Hall. -ksh-93 has been compiled and run on several machines with several -operating systems. The end of this file contains a partial list of -operating systems and machines that ksh-93 has been known to run on. - -The layout of files for ksh-93 has changed somewhat since ksh-88, -the last major release. Most of the source code for ksh remains in -the sh directory. However, the shell editing and history routines -are in the edit sub-directory. The code for shell built-ins is -in the bltins directory. The data directory contains read-only -data tables and messages that are used by the shell. The include -files remain in the include directory and the shlib directory -is gone. The feature directory replaces the older install -directory. The method for generating systems specific feature -information has changed substantially. - -The OPTIONS file contains several options that can be set before -compiling ksh. This file is used to generate the FEATURE/options -include file. The OPTIONS are set to their recommended value. -A value of 0 represents off, 1 represents on. -The options have the following defaults and meanings: - ACCT off Shell accounting. - ACCTFILE off Enable per user accounting info - BRACEPAT on C-shell type abc{d,e}f style file generation - CRNL off treated as in shell grammar. - DYNAMIC on Dynamic loading of builtins. (Requires dlopen() interface.) - ECHOPRINT off Make echo equivalent to print. - ESH on Compile with emacs command line editing. The original - emacs line editor code was provided by Mike Veach at IH. - FS_3D off For use with 3-D file system. Enabled automatically for - sytems with dynamic linking. - JOBS on Job notification, job control if possible. - KIA off Allow generation of shell cross reference database with -I. - MULTIBYTE on Multibyte character handling. Requires mblen() and mbctowc(). - OLDTERMIO off Use either termios or termio at runtime. - P_SUID off If set, all real uids, greater than or equal to this - value will require the -p flag to run suid/sgid scripts. - RAWONLY off Turn on if the vi line mode doesn't work right unless - you do a set -o viraw. - SEVENBIT off Strip the eigth bit from characters. - SPAWN off Use spawn as combined fork/exec. May improve speed. - SUID_EXEC on Execute /etc/suid_exec for setuid, setgid script. - TIMEOUT off Set this to the number of seconds for timing out and - exiting the shell when you don't enter a command. If - non-zero, TMOUT can not be set larger than this value. - VSH on Compile with vi command line editing. The original vi - line editor code was provided by Pat Sullivan at CB. - -The following compile options are set automatically by the feature testing: - DEVFD Set when /dev/fd is a directory that names open files. - SHELLMAGIC - Set on systems that recognize script beginning with #! specially. - VPIX Set on systems the have /usr/bin/vpix program for running MS-DOS. - - -In most instances, you will generate ksh from a higher level directory -which also generates libcmd and libast libraries on which ksh depends. -However, it is possible to generate ksh, with by running make -f ksh.mk -in this directory. The ksh.mk file was generated from the nmake Makefile. -If you do not have make or nmake, but do have a Version 7 UNIX compatible -shell, then you can run the script mamexec < Mamfile to build ksh. -If you have nmake, version 2.3 or later, you can use it without the -f ksh.mk. -In either case, ksh relies on libraries libast and libcmd which must be -built first. The binary for ksh becomes the file named ./ksh which can -be copied to where ever you install it. - -If you use old make or the Mamfile, and you system has dynamic shared -libraries, then you should define the variables mam_cc_static and -mam_cc_dynanamic as the compiler options that request static linking -and dynamic linking respectively. This will decrease the number of -shared libraries that ksh need and cut startup time substantially. - -The makefile should also generate shcomp, a program that will precompile -a script. ksh93 is able to recognize files in this format and process -them as scripts. You can use shcomp to send out scripts when you -don't want to give away the original script source. - -It is advisable that you put the line PWD=$HOME;export PWD into the -/etc/profile file to reduce initialization time for ksh. - -To be able to run setuid/setgid shell scripts, or scripts without read -permission, the SUID_EXEC compile option must be on, and ksh must be installed -in the /bin directory, the /usr/bin directory, the /usr/lbin directory, -or the /usr/local/bin directory and the name must end in sh. The program -suid_exec must be installed in the /etc directory, must be owned by root, -and must be a suid program. If you must install ksh in some other directory -and want to be able to run setuid/setgid and execute only scripts, then -you will have to change the source code file sh/suid_exec.c explicitly. -If you do not have ksh in one of these secure locations, /bin/sh will -be invoked with the -p options and will fail when you execute a setuid/setgid -and/or execute only script. Note, that ksh does not read the .profile -or $ENV file when it the real and effective user/group id's are not -equal. - -The tests sub-directory contains a number of regression tests for ksh. -To run all these tests with the shell you just built, go to the tests -directory and run the command - SHELL=../ksh shtests - -The file PROMO is an advertisement that extolls the virtues of ksh. -The file sh.1 contains the troff (man) description of this Shell. -The file nval.3 contains the troff (man) description of the name-value -pair library that is needed for writing built-ins that need to -access shell variables. - -The file sh.memo contains a draft troff (mm) memo describing ksh. The -file RELEASE contains the changes made in this release since ksh-88. -The file COMPATIBILITY contains a list of incompatibilities with ksh-88. -The file bltins.mm is a draft troff (mm) memo describing how to write -built-in commands that can be loaded at run time. - -Most of the work for internationalization has been done with ksh93. -The file ksh.msg is a generated file that contains error messages -that need to be translated. In addition, the function translate() -in sh/init.c has to be completed to interface with the dictionary -lookup. The translate function takes two argument, the string -that is to be translated and a type which is - 0 when a library string needs translation. - 1 when one of the error messages in ksh.msg needs translation. - 2 when a string in a script needs translation. You use a $ in front - of a double quoted string in a script to indicate that it - needs translation. The -D option for ksh builds the dictionary. -The translate routine needs to return the translated message. -For dictionaries that need to use a numeric key, it should be -possible to use the strhash() function to generate numbers to -go along with each of the messages and to use this number both -when generating the dictionary and when converting strings. -If you encounter error messages of type 1 that are not be translated via -this translate() function send mail to the address below. - -Please report any problems or suggestions to: - -ksh@mozart.att.com - - -ksh93 has been compiled and alpha tested on the following. An asterisk -signifies that ksh has been installed as /bin/sh on this machine. - -* Sun OS 4.1.[123] on sparc[12]. - Sun OS 4.1.1 on sun3. - Solaris 2.[1234] on sparc2. - Solaris 2.4 on Intel 486.. - HP/UX 8.05 on HP-9000/730. - HP/UX 9.01 on HP-9000/730. - HP/UX 9.00 on HP-9000/857. - System V Release 3 on Counterpoint C19 - System V Release 4 on AT&T Intel 486. - System V Release 4 on NCR 4850 Intel 486. - IRIX Release 4.0.? System V on SGI-MIPS. - IRIX Release 5.1 System V on SGI-MIPS. - System V Release 3.2 on 3B2. - UTS 5.2.6 on Amdahl 3090,5990,580. - System V Release 3.2 on i386. - SMP_DC.OSx olivetti dcosx MIServer-S 2/128. - SMP_DC.OSx Pyramid dcosx MIServer-S 2/160 r3000. - 4.3BSD on Vax 8650. - AIX release 2 on RS6000. - AIX 3.2 on RS6000. - Linux 1.1.59 on Intel 486 - OSF1 on DEC alpha. - UMIPS 4.52 on mips. - BSD-i 2.0 on Intel 486. - NeXT on Intel 486. - NeXT on HP. - Windows NT with NutCracker libraries. - Windows NT with Portage libraries. - Windows NT using custom C library. - Windows 3.1 using custom C library. - -Good luck!! - -David Korn -dgk@research.att.com - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASE b/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASE deleted file mode 100644 index 2466e3978..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASE +++ /dev/null @@ -1,422 +0,0 @@ -This is a list of changes that have been made since the 11/16/88 version -of ksh. - -1. New features in 12/28/93 - a. Associative arrays. The new version of ksh supports both - associate arrays and the older indexed arrays with the same - array syntax. A new -A option of typeset is used to declare - an array to be associative. As with indexed arrays, $name is - equivalent to ${name[0]}. The prefix operator ! was added - to the parameter expansion syntax to expand to the list of - indices. For example, ${!name[@]} expands to the list of array - indices for variable name. - - b. Several additions have been made to shell arithmetic: - 1. The shell now performs floating point arithmetic. The - typeset options -F and -E have been added for floating - point and scientific notation respectively. - 2. The prefix and postfix ++ and -- operators. - 3. The comma and ?: operators. - 4. The math library functions. - 5. An arithmetic for statement of the form - for ((expr1; expr2; expr3)) - do ... - done - 6. Integer arithmetic extended up to base 64. - - c. Some additions to the macro expansion syntax have been made - to specify substrings and sub-arrays: - 1. ${name:expr} expands to the substring of ${name} starting at - the character position defined by arithmetic expression expr. - 2. ${name:expr1:expr2} expands to the substring of ${name} starting - at expr1 and consisting of at most expr2 characters. - 3. ${name[@]:expr} expands to the values of ${name[@]} starting at - the element defined by arithmetic expression expr. - 4. ${name[@]:expr1:expr2} expands to at most expr2 values of - ${name} starting at expr1. - 5. ${@:expr} expands the positional parameters starting at expr. - 6. ${@:expr1:expr2} expands to at most expr2 positional parameters - starting at expr1. - 7. ${!name} expands to the name of the variable named by name. - It will expand to name unless name is reference variable. - 8. ${!name[sub]} expands to the name of the subscript of the - given variable. If sub is @ or * the list of subscripts - is generated. - 9. ${!prefix*} and ${!prefix@} expand to the list of variable - names beginning with prefix. - 10. The substring operators, # and % can be now be applied - with aggregates (@ or *) and are applied to each. - 11. ${name/pattern/string} expands to the value of name with - the first occurrence of pattern replaced by string. - With aggregates (@ or *) this operation is applied to each. - 12. ${name/#pattern/string} Same as above but the pattern - to be replaced must match at the beginning. - 13. ${name/%pattern/string} Same as above but the pattern - to be replaced must match at the end. - 14. ${name//pattern/string} expands to the value of name with - the each occurrence of pattern replaced by string. - With aggregates (@ or *) this operation is applied to each. - - d. The name space for variables has been extended. The character '.' - can be used at the beginning of a name, and to separate identifiers - within a name. However, to create a name of the form, foo.bar, - the variable foo must exist. The namespace starting with .sh - is reserved for shell implementation variables. Exported - variable cannot contain a '.'. - - e. Compound assignments. The assignment syntax, varname=value, - has been extended to allow assignments of the form - varname=(assignment_list). As elsewhere in the shell - spaces or tabs are optional around the parentheses, and - no space is permitted between the varname and the =. The - assignment_list can be one of the following: - 1. A list of words. In this case each word is expanded as - in a for list and the resulting items become elements - of the indexed array varname. - 2. A list of subscript assignments in the form - [subscript]=value. In this, these elements become - elements of the associative array varname. - 3. A list of assignments; simple or compound. In this - case, each assignment is made to varname.name, where - name is the name of the enclosed assignment. - 4. Assignments in the form of readonly or typeset - statements. In this case each assignment is made as - in 3 above, and the attributes are given to the - corresponding variable. - In case 3 and 4 above, the value of "$varname" after - the above assignment is (assignment_list), where the - assignment_list produced would reproduce all of the - variables under varname.*. - - f. Function names of the form variable.action (called discipline - functions) can be defined where variable is any valid variable - name and action is get, set, or unset. The function variable.get - is invoked each time the variable is referenced. The set - discipline is invoked each time the variable is assigned to. - The unset discipline is invoked when a variable is unset. - The new variables .sh.name, .sh.subscript, and .sh.value are - defined inside the function body. Other shell extensions - may have their own set of discipline functions. - - g. The compound command !, which negates the return value of the - following pipeline, has been added. - - h. On systems that support dynamic loading with dlopen(), it is - now possible to add built-in commands at runtime with the - a builtin command named builtin. - - i. The following builtins have been added: - 1. command name [ ... ] - 2. sleep [decimal-seconds] - 3. builtin [-ds] [-f file] [name...] - 4. getconf name [pathname] - 5. disown [job...] - - j. An addition format for literal strings, $'....' can - be used where ever literal strings are valid. The string - inside the single quotes will be converted using the ANSI-C - escape conventions. Additionally, the escape sequence \E - expands to the escape character (default \033) whenever ANSI-C - escape sequences are recognized. - - k. A typeset -n option has been added which causes the value of a - variable to be treated as a reference to another variable so that - variables can be indirectly named. For example, if $1 contains - the name of a variable, then typeset -n foo=$1 causes the variable - foo to be synonymous with the variable whose name is $1. A builtin - alias, nameref='typeset -n' has been added to aid mnemonics. - Reference names cannot contain a '.'. Whenever that portion of - a variable up to the first '.' matches a reference name, the - reference value is substituted. For example, with nameref foo=.top, - then ${foo.bar} is equivalent to ${.top.bar}. When used as the - index of a for or select loop, each assignment causes a - new name reference to occur. - - l. The KEYBD trap has been added which is triggered when a key - or escape sequence is typed while reading from the keyboard - in an edit mode. This, combined with some new variables - makes it possible to program your key bindings in ksh. - - m. New variables have been added: - 1. FIGNORE defines a set of file names to be ignored in each - directory when performing pathname expansion, replacing - the rule that requires that a leading . be matched explicitly. - 2. Variable sh.edchar contains the value of the keyboard character - that has been entered when processing a KEYBD trap. If the value - is changed as part of the trap action, then the new value replaces - the key or keys that caused the trap. - 3. Variable sh.edcol is set to the character position of the cursor - within the input buffer during a KEYBD trap. - 4. Variable sh.edmode is set to the escape character when in vi - insert mode. - 5. Variable sh.edtext is set to the contents of the input buffer - during a KEYBD trap. - 6. HISTEDIT is checked before FCEDIT. FCEDIT is obsolete. - 7. HISTCMD is the number of the current command in the history - file. - 8. Variable .sh.version is set to the version string for - this shell. - 9. Variable .sh.name is set to the name of the variable - that that was referenced or assigned to when executing a get - or set discipline function. - 10. Variable .sh.subscript is set to the subscript for the variable - that was referenced or assign to when executing a get or - set discipline function. - 11. Variable .sh.value is set to the new value for the variable - that was assigned to when executing the set discipline function. - - n. New invocation and set -o options have been added: - 1. set -o notify (or set -b) causes background completion messages - to be displayed as soon as the job completes. - 2. There is a compile time option named KIA which enables - creation of a relational database for commands, variables - and functions defined and referenced by a script. The - option -I , causes the database to be generated - in . The database format can be queried via - the cql command. - o. ksh93 can read and evaluate pre-compiled scripts generated by - a separate program called shcomp. - p. More work on internationalization has been added: - 1. The decimal point character is processed per locale - 2. A $ can be placed in front of each string to indicate - that the string needs translation but is otherwise ignored. - This means that if a message catalog of all $"..." strings - is generated, then a program such as print $"hello world" - could display "bonjour monde" in the french locale. - q. Backreferences have been added to pattern matching. The sequence - \d, where d is a digit from 1-9, matches the same string as - the d-th previous parenthesis group. Backreferences - can be used within patterns, and within replacement strings - with any of the ${name/...} operators. - -2. Changes made in 12/28/93 - a. The output format of many commands has changed as follows: - 1. System error messages are displayed whenever a failure - is caused by a system call. - 2. The exit status has changed in many cases: - a. USAGE messages cause an exit status of 2. - b. Commands not found cause exit - 127. - c. Command found, but not executable - 126. - d. Terminated because of signal - 256+sig - 3. The output of values from built-ins that contain special - characters are quoted in a manner that then can be re-input. - 4. The trace output puts quotes around the output so that it - can be reused as input. - 5. The output for trap is in a format that can be reinput the - the shell to restore the traps. - 6. kill -l lists the signal names without numbers as - required by the POSIX standard. - - b. The following changes have been made to shell functions: - 1. The semantics of functions declared with name() has changed - to conform with the IEEE-POSIX 1003.2 standard. In particular, - these functions are executed in a dot script environment rather - than a separated function environment so that there are no - local variables and no scoping for traps. - 2. Functions declared as function name, preserve the old ksh - semantics can be also used as the first argument to the dot (.) - command to have them executed in a dot script environment. - - c. The command search rules have changed as follows: - 1. Special built-ins (those with a dagger in front of them) are - executed first. - 2. Functions are executed next. - 3. Other built-ins that do not require an executable version - (for example cd and read) come next. - 4. If the command name contains a slash, the pathname corresponding - to the command name is executed. - 5. If name corresponds to a previously encountered pathname - on the PATH variable, the corresponding command is executed. - 6. If the command name does not contain a slash, then the PATH - variable is used to find an executable by that name. If - the directory that the command is found is also contained in - the FPATH variable, then the command treated as a function. - If the shell has a built-in version of the command corresponding - to this command, then the built-in version of this command - is executed. Otherwise, the shell remembers that pathname - corresponding to this command name and executes this pathname. - 7. If the name is not found on PATH, then the directories in - FPATH are searched. If found, then the command is executed - as a function. - - d. Built-in commands options now conform to the IEEE-POSIX 1003.2 - conventions with some additions. In particular, - name -? - will now print a Usage line for name, except for true, false, - colon, login, newgrp, echo, [, and command. - - e. Tilde expansion is now performed as part of the word expansions. - The effect of this is that if word begins with ~ in ${name op word}, - it will be expanded unless escaped. - - f. Pathname expansion is no longer performed on redirection words - unless the shell is interactive. - - g. Changes to shell and options: - 1. The -n option has been enhanced to produce more warning and - portability messages. - 2. The -C option is equivalent to -o noclobber. Files are - created with O_EXCL when -C is on. - - h. The following changes have been made to [[...]]: - 1. A string by itself is equivalent to -n string. - 2. -e has been added as equivalent to -a. - 3. == has been added as equivalent =. - 4. -a and = are now considered obsolete. - 5. Arithmetic comparisons are now considered obsolete. - - i. kill has been changed as follows: - 1. Signal names can be upper case or lower case. - 2. Numerical arguments to kill -l cause the given signal names to - be displayed. - 3. String arguments to kill -l cause the given signal numbers to - be displayed. - 4. Synopsis changed for getopts conformance. - - j. print has a -f format option which is equivalent to - the IEEE POSIX printf. Both print -f format, and - printf have the following extensions from IEEE POSIX: - 1. Floating point formats are supported. - 2. Size and precision specifications can be *. - 3. The %d option can take an argument after precision to - specify the base that the number will be displayed. - 4. A %q format can be used to output a string quoted so - that it can be re-input to the shell. - 5. A %P format can be used to output the shell pattern which - corresponds to the give extended regular expression. - 6. For numerical fields, the arguments can be arithmetic - expressions which will be evaluated. - 7. The %n format works as described in ANSI-C. - - k. The following changes have been made to fc: - 1. It has been renamed hist. fc is now a predefined alias. - 2. hist uses ${HISTEDIT:-$FCEDIT}. FCEDIT is obsolete. - 3. A new -s option is equivalent to the obsolete -e -. - 4. If the first argument refers to a command earlier than the - first accessible command, it now implies the first accessible - command, so that hist -l 1 lists all accessible history commands. - - l. The dot command (.) has changed as follows: - 1. The argument can be the name of a function declared as - function name. The function will execute without creating a - new scope. - 2. If there are arguments to the given script or function, - the positional parameters are restored to their original - value when . completes. - - m. The read built-in has been changed as follows: - 1. A -A option to read has been added to allow the fields to be - read into an indexed array. - 2. A -t n option has been added which causes read to - timeout after n seconds when reading from a slow device. - 3. A -d char option has been added which causes the read - to terminate at char rather than at new-line. - - n. The trap command has been changed as follows: - 1. Trap names can be either upper case or lower case. - 2. Trap -p cause only the specified trap values to be displayed. - 3. The value of trap in a subshell will be the value in the parent - shell until a call to trap which changes the trap settings has - been made. Thus, savetraps=$(trap) works as required by the - POSIX standard. - - o. The exec command has been extended as follows: - 1. The -c option clears the environment first. - 2. The -a name option sets argv[0] to name for the program. - - p. true and false are built-ins, not aliases to built-ins. - - q. test has been modified to conform to the IEEE-POSIX 1003.2 - standard when there are three or less arguments. - - r. umask -S option displays the mask in a symbolic format. - - s. wait now returns the correct exit status of any previous - background job that has not been waited for, not just - the most recent one. - - t. The whence built-in has an option -a which causes all - uses for the given command name to be reported. - - u. unalias has -a option to clear all the aliases. - - v. The times built-in command has been removed. The time - reserved word, without a command, gives time cumulative - time for the shell and its children. A built-in alias - for times should enable scripts using times to continue - to run. - - w. Command substitution and arithmetic substitution will now be - performed for PS1, ENV, and PS4 evaluation in addition to - parameter expansion. - - x. The SECONDS variable now displays elapsed time in floating - point seconds with 3 places after the decimal point by - default. - - y. The getopts built-in now handles the complete libast optget - functionality. If any errors have occurred with getopts - when it has reached the end of arguments, then the Usage - message will be generated from the option string and the - exit status from getopts will be 2 rather than 1. The - usage message will be stored in the OPTARG variable if - the option string contains a leading colon; otherwise - it will be printed on standard error automatically. - - z. THE ENV file is only processed for interactive shell - invocations. In addition, the -x attributes for - aliases and functions is ignored. - - aa. The built-in edit modes have been changed as follows: - 1. The pathname completion and pathname listing options - now perform command completion and command listing - when applied to a word in the command position. - 2. In emacs mode ^N as the first related command after - the prompt will move to the next command relative to the - last known history position. - 3. In emacs mode, successive kill and delete commands will - accumulate their data in the kill buffer, by appending or - prepending as appropriate. This mode will be reset by any - command not adding something to the kill buffer. - 4. The control-T of emacs mode has been changed to behave like - control-T in gnu-emacs. - bb. The TMOUT variable also sets a limit for select timeouts - and default timeouts for read. - - -4. The source code has undergone significant modification. - a. Much of the code has been rewritten, In many cases this has - resulted in significant performance improvement. - - b. The code is organized differently. See the README files - for more details. - - c. Most configuration parameters now get generated using - the FEATURE mechanism of nmake. Other options are set - in the OPTIONS file. - - c. The are several new compile time options. See the README - file for details. Some of the old ones have been removed. - - d. The install script is a Mamfile that is generated by - nmake and processed by a script that comes with the - distribution. - - e. There are far fewer global names. This should make it - must easier to add built-in commands without worrying - about conflicts. - - f. The code uses the sfio library which makes it possible - to mix with stdio. - - g. The code is written in ANSI C with full prototypes. - The code is based on the IEEE POSIX 1003.1 standard. - The code can be compiled with K&R C and with C++ by - using the ANSI cpp that comes with nmake or running - the code through the proto filter before pre-processing. - This happens automatically with our shipping system. - - h. There is a programming interface for capturing references - and assignment to shell variables. It is also possible - to intercept variable creation and supply the array processing - function for that variable. See nval.3 for a description. diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASEa b/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASEa deleted file mode 100644 index 4a5c4710c..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/RELEASEa +++ /dev/null @@ -1,214 +0,0 @@ -This is a list of changes that have been made since the 12/28/93 version -of ksh. - -1. New features in 12/28/93[b] - a. If IFS contains two consecutive identical characters belonging - to the [:space:] class, then this character is treated as - a non-space delimiter so that each instance will delimit - a field. For example, IFS=$'\t\t' will cause two consecutive - tabs to delimit a null field. - b. The getopts command has a -a name option that specifies a - name that will be used for usage messages. - -2. Bugs fixed in 12/28/93a for default OPTIONS - a. An expansion bug which causes portions of a word after - a $((...)) expansion that contains a nested $var expansion - to be lost has been fixed. - b. A bug that caused a core dump when a script that did not - have PWD set and did a cd inside command substitution - has been fixed. - c. A bug which caused a core dump on some machines when - the LANG variable was assigned to has been fixed. - d. A bug which incorrectly handled set disciplines that - performed arithmetic evaluation when the discipline - was called from the arithmetic evaluator has been fixed. - e. A bug caused by an EXIT trap inside a function that - was executed in a subshell was fixed. - f. If foo is a function, and not a program, then command foo - now reports that foo isn't found rather than invoking foo. - g. The previous version incorrectly listed -A as an - invocation option. The -A option is only for set. - h. A bug was fixed which caused ksh to loop when execution trace - was enabled and the PS4 prompt required command substitution. - i. A bug which could cause the job control switch character - to be disabled when a script that enabled monitor mode - terminated was fixed. - j. A bug in the macro expansion global replacement operator //, - when the pattern began with a [ or +( has been fixed. - k. A bug which prevented ~ expansion from occurring when - it was terminated with a colon inside an assignment - has been fixed. - l. A bug in the dot command which prevented autoload functions - from working has been fixed. - m. A bug which caused a variable to be unset if the - its value were expanded inside a set discipline has - been fixed. - n. Whence -a now longer reports that a defined function - is undefined. - o. A bug on some systems in which $0 would be incorrect - in scripts invoked by name has been fixed. - p. Here documents with an empty body now work. - 1. A bug which disabled argument passing and resetting - of options for a script invoked by name inside a - function has been fixed. - r. A bug in which an EXIT trap set the caller of a function - would be executed if a command called inside a function - was not found has been fixed. - s. A bug which allowed a script to trap signals that are - ignored at the time that the shell was invoked has - been fixed. - t. A bug which caused 2<&1- when applied to a shell built-in - to leave standard input closed has been fixed. - u. A bug which caused the shell to incorrectly parse - $() command substitutions with nested case statements - has been fixed. - -3. Bugs fixed in 12/28/93b for default OPTIONS - a. A bug which caused unset RANDOM to dump core has been - fixed. - b. A bug which prevented return for terminating a profile - or ENV file has been fixed. - c. A bug which prevented standard input from being - directed to /dev/null for background jobs when - monitor mode was turned off has been fixed. - d. Statements of the form typeset -options var[expr]=value - did not perform substitutions on expr as expected. - e. A bug which prevented the shell from sending a HUP - signal to some background jobs that were not disowned - has been fixed. - f. A bug which allowed a script to trap signals that are - ignored at the time that the shell was invoked by exec - has been fixed. - g. A bug which could cause a core dump when a discipline - function was unset within a discipline was fixed. - h. The typeset builtin now accepts a first argument of - + or - for compatibility with ksh88. - i. For compatibility with ksh88, the results of expansions - of command arguments will treat the extended character - match characters ()|& as ordinary characters. - j. A bug which caused read to fail on a file that was - open for read/write with <> when the first operation - was print or printf has been fixed. - k. When a job is suspended, it is put on the top of - the job list as required by the POSIX standard. - l. The value of OPTARG when an option that required - an argument but didn't have one was incorrect in the - case the the option string began with a :. - m. A bug which caused the terminal to get into a bad - state with some KEYBD traps in vi-mode has been fixed. - n. A bug which caused an invalid trap to cause a script - to terminate, rather than just return an error, has - been fixed. - o. Backreferencing sub-expressions in patterns and replacement - strings now works. - p. A bug in chmod which caused the -R option to fail has - been fixed. - -4. Bugs fixed in 12/28/93c for default OPTIONS - a. The expansion of "$@" was incorrect when $1 was the null - string. - b. A bug which could incorrectly report a syntax error in - a backquoted expression when a $ was preceded by \\ - has been fixed. - c. A bug which prevented the shell from exiting after - reporting an error when failing to open a script - has been fixed. - d. A bug that could lead to memory corruption when a - large here document that required parameter or command - substitution was expanded has been fixed. - e. A bug that could cause a core dump on some systems - after ksh detected an error when reading a function - has been fixed. - f. A bug which could cause a coprocess to hang when - reading from a process that has terminated has been fixed. - g. A bug which caused a script to terminate when set -e - was on and the first command of and && or || list - failed has been fixed. - h. A bug with here documents inside $(...) when the delimiter - word is an identifier has been fixed. - i. A bug which caused $0 to display the wrong value when - a script was invoked as an argument to the . command - and the eval command has been fixed. - j. A bug that could cause the built-in sleep to hang - has been fixed. - k. A bug introduces in 12/28/93b which caused the backslash - to be removed when it was followed by digit inside double - quotes in some instances has been fixed. - l. A bug which could cause a core dump if ksh was invoked with - standard input closed has been fixed. - m. A bug which could cause a core dump if typeset -A was - specified for an existing variable has been fixed. - n. Variables that were unset but had attributes such as readonly - and export were not listed with readonly, export and typeset. - o. Several problems with signals have been fixed. - p. A bug which prevented ulimit -t from working has been fixed. - Also, a bug in which failed ulimits could cause a core dump - has also been fixed. - q. A bug in expansion of the form ${name/#pattern/string} and - ${name/%pattern/string} has been fixed. - r. A bug which caused read -r on a line that contained only - blanks to get a non-null value has been fixed. - s. A bug introduced in the 'a' point release in which - ${x='\\'} expanded to \ when x was unset has been fixed. - t. A bug which prevented a trap on EXIT from being executed - when the last command in a script was a function invocation - has been fixed. - u. A bug which caused an interactive shell ignore input when - standard error was redirected to a file with exec, - and then restored with exec 2>&1 has been fixed. - v. An interactive shell turns on monitor mode even when - standard error has been redirected to a file. - w. A bug which could cause standard input to be incorrectly - positioned for the last command of a script has been fixed. - y. A bug in the edit modes which allowed walking back in - the history file for more than HISTSIZE commands has - beed fixed. - z. A bug which could cause a core dump if variable TMPDIR was - changed between two command substitutions has been fixed. - aa. A bug which prevented a trap on EXIT from being cleared - has been fixed. - -5. Bugs fixed in 12/28/93d for default OPTIONS - a. The \ character was not handled correctly in replacement - patterns with ${x/pattern/replace}. - b. A bug with read in which the line did not end with - a new-line has been fixed. - c. A bug in file name generation which sometimes - appended a . for filenames that ended in / has - been fixed. - d. If a process is waited for after a status has - been returned by a previous wait, wait now - returns 127. - e. A bug with hist (fc) -e which prevented a command - to re-executed after it had been edited has been fixed. - f. A bug which prevented quoting from removint the meaning - of unary test operators has been fixed. - -6. Bug fixes for specific non-default option combinations. - a. More signal names have been added for Solaris - b. A bug fixed for the v directive in vi MULTIBYTE has been - fixed. - c. Code to for IFS handling of multibyte characters has - been added. - d. The displaying of multibyte strings in export, readonly, - typeset, and execution traces has been fixed. - e. A bug with typeahead and KEYBOARD traps with the - MULTIBYTE option set has been fixed. - -7. Other changes to 12/28/93[abcd] - a. A couple of minor changes to make adding built-ins easier. - b. Variables inside functions are now statically scoped. - The previous behavior was never documented. - c. A few changes have been made to the name-value library - that affect built-ins that use disciplines. The - changes allow disciplines to be shared by variables - and should make it possible to add new disciplines - without recompilation. - d. The name-value library interface has undergone significant - change for this revision. See the new nval.3 man page. - e. Builtin functions can take a third argument which is - a void*. - -8. Incompatibilities with 12/28/93 version. - None intentional. - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/alarm.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/alarm.c deleted file mode 100644 index ae102ab24..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/alarm.c +++ /dev/null @@ -1,333 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: alarm.c /main/3 1995/11/01 16:27:14 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include "builtins.h" -#include "FEATURE/time" - -#define R_FLAG 1 -#define L_FLAG 2 - -struct tevent -{ - Namfun_t fun; - Namval_t *node; - Namval_t *action; - struct tevent *next; - long milli; - int flags; - __V_ *timeout; -}; - -static const char ALARM[] = "alarm"; - -static void trap_timeout __PROTO__((__V_*)); - -/* - * insert timeout item on current given list in sorted order - */ -static __V_ *time_add __PARAM__((struct tevent *item, __V_ *list), (item, list)) __OTORP__(struct tevent *item; __V_ *list;){ - struct tevent *tp = (struct tevent*)list; - if(!tp || item->milli < tp->milli) - { - item->next = tp; - list = (__V_*)item; - } - else - { - while(tp->next && item->milli > tp->next->milli) - tp = tp->next; - item->next = tp->next; - tp->next = item; - } - tp = item; - tp->timeout = (__V_*)kshtimeradd(tp->milli,tp->flags&R_FLAG,trap_timeout,(__V_*)tp); - return(list); -} - -/* - * delete timeout item from current given list, delete timer - */ -static __V_ *time_delete __PARAM__((struct tevent *item, __V_ *list), (item, list)) __OTORP__(struct tevent *item; __V_ *list;){ - struct tevent *tp = (struct tevent*)list; - if(item==tp) - list = (__V_*)tp->next; - else - { - while(tp && tp->next != item) - tp = tp->next; - if(tp) - tp->next = item->next; - } - if(item->timeout) - timerdel((__V_*)item->timeout); - return(list); -} - -static void print_alarms __PARAM__((__V_ *list), (list)) __OTORP__(__V_ *list;){ - struct tevent *tp = (struct tevent*)list; - while(tp) - { - if(tp->timeout) - { - char *name = nv_name(tp->node); - if(tp->flags&R_FLAG) - { - double d = tp->milli; - sfprintf(sfstdout,e_alrm1,name,d/1000.); - } - else - sfprintf(sfstdout,e_alrm2,name,nv_getnum(tp->node)); - } - tp = tp->next; - } -} - -static void trap_timeout __PARAM__((__V_* handle), (handle)) __OTORP__(__V_* handle;){ - struct tevent *tp = (struct tevent*)handle; - sh.trapnote |= SH_SIGTRAP; - if(!(tp->flags&R_FLAG)) - tp->timeout = 0; - tp->flags |= L_FLAG; - sh.sigflag[SIGALRM] |= SH_SIGTRAP; - if(sh_isstate(SH_TTYWAIT)) - sh_timetraps(); -} - -void sh_timetraps __PARAM__((void), ()){ - struct tevent *tp, *tpnext; - struct tevent *tptop; - while(1) - { - sh.sigflag[SIGALRM] &= ~SH_SIGTRAP; - tptop= (struct tevent*)sh.st.timetrap; - for(tp=tptop;tp;tp=tpnext) - { - tpnext = tp->next; - if(tp->flags&L_FLAG) - { - tp->flags &= ~L_FLAG; - if(tp->action) - sh_fun(tp->action,tp->node); - tp->flags &= ~L_FLAG; - if(!tp->flags) - { - nv_unset(tp->node); - nv_close(tp->node); - } - } - } - if(!(sh.sigflag[SIGALRM]&SH_SIGTRAP)) - break; - } -} - - -/* - * This trap function catches "alarm" actions only - */ -static char *setdisc __PARAM__((Namval_t *np, const char *event, Namval_t* action, Namfun_t - *fp), (np, event, action, fp)) __OTORP__(Namval_t *np; const char *event; Namval_t* action; Namfun_t - *fp;){ - struct tevent *tp = (struct tevent*)fp; - if(!event) - return(action?"":(char*)ALARM); - if(strcmp(event,ALARM)!=0) - { - /* try the next level */ - return(nv_setdisc(np, event, action, fp)); - } - if(action==np) - action = tp->action; - else - tp->action = action; - return(action?(char*)action:""); -} - -/* - * catch assignments and set alarm traps - */ -static void putval __PARAM__((Namval_t* np, const char* val, int flag, Namfun_t* fp), (np, val, flag, fp)) __OTORP__(Namval_t* np; const char* val; int flag; Namfun_t* fp;){ - struct tevent *tp; - double d; - if(val) - { - double now; -#ifdef _lib_gettimeofday - struct timeval tmp; - gettimeofday(&tmp,NIL(void *)); - now = tmp.tv_sec + 1.e-6*tmp.tv_usec; -#else - now = (double)time(NIL(time_t*)); -#endif /*_lib_gettimeofday */ - nv_putv(np,val,flag,fp); - d = nv_getnum(np); - tp = (struct tevent*)fp; - if(*val=='+') - { - double x = d + now; - nv_putv(np,(char*)&x,NV_INTEGER,fp); - } - else - d -= now; - tp->milli = 1000*(d+.0005); - if(tp->timeout) - sh.st.timetrap = time_delete(tp,sh.st.timetrap); - if(tp->milli > 0) - sh.st.timetrap = time_add(tp,sh.st.timetrap); - } - else - { - tp = (struct tevent*)nv_stack(np, (Namfun_t*)0); - sh.st.timetrap = time_delete(tp,sh.st.timetrap); - if(tp->action) - nv_close(tp->action); - nv_unset(np); - free((__V_*)fp); - } -} - -static const Namdisc_t alarmdisc = -{ - sizeof(struct tevent), - putval, - 0, - 0, - setdisc, -}; - -int b_alarm __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - int n,rflag=0; - Namval_t *np; - struct tevent *tp; - NOT_USED(extra); - while (n = optget(argv, sh_optalarm)) switch (n) - { - case 'r': - rflag = R_FLAG; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argc -= opt_index; - argv += opt_index; - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - if(argc==0) - { - print_alarms(sh.st.timetrap); - return(0); - } - if(argc!=2) - error(ERROR_usage(2),optusage((char*)0)); - np = nv_open(argv[0],sh.var_tree,NV_ARRAY|NV_VARNAME|NV_NOASSIGN); - if(!nv_isnull(np)) - nv_unset(np); - nv_setattr(np, NV_INTEGER|NV_DOUBLE); - if(!(tp = newof(NIL(struct tevent*),struct tevent,1,0))) - error(ERROR_exit(1),e_nospace); - tp->fun.disc = &alarmdisc; - tp->flags = rflag; - tp->node = np; - nv_stack(np,(Namfun_t*)tp); - nv_putval(np, argv[1], 0); - return(0); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cd_pwd.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cd_pwd.c deleted file mode 100644 index da85d2802..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cd_pwd.c +++ /dev/null @@ -1,277 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: cd_pwd.c /main/3 1995/11/01 16:27:31 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include "variables.h" -#include "path.h" -#include "name.h" -#include "builtins.h" -#include - -int b_cd __PARAM__((int argc, char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[];__V_ *extra;){ - char *dir, *cdpath=""; - const char *dp; - int saverrno=0; - int rval,flag = (sh_isoption(SH_PHYSICAL)!=0); - char *oldpwd; - Namval_t *opwdnod, *pwdnod; - NOT_USED(extra); - if(sh_isoption(SH_RESTRICTED)) - error(ERROR_exit(1),e_restricted+4); - while((rval = optget(argv,sh_optcd))) switch(rval) - { - case 'L': - flag = 0; - break; - case 'P': - flag = 1; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - argc -= opt_index; - dir = argv[0]; - if(error_info.errors>0 || argc >2) - error(ERROR_usage(2),optusage((char*)0)); - oldpwd = (char*)sh.pwd; - opwdnod = (sh.subshell?sh_assignok(OLDPWDNOD,1):OLDPWDNOD); - pwdnod = (sh.subshell?sh_assignok(PWDNOD,1):PWDNOD); - if(argc==2) - dir = sh_substitute(oldpwd,dir,argv[1]); - else if(!dir || *dir==0) - dir = nv_getval(HOME); - else if(*dir == '-' && dir[1]==0) - dir = nv_getval(opwdnod); - if(!dir || *dir==0) - error(ERROR_exit(1),argc==2?e_subst+4:e_direct); - if(*dir != '/') - { - cdpath = nv_getval(nv_scoped(CDPNOD)); - if(!oldpwd) - oldpwd = path_pwd(1); - } - if(!cdpath) - cdpath = ""; - if(*dir=='.') - { - /* test for pathname . ./ .. or ../ */ - if(*(dp=dir+1) == '.') - dp++; - if(*dp==0 || *dp=='/') - cdpath = ""; - } - rval = -1; - do - { - dp = cdpath; - cdpath=path_join(cdpath,dir); - if(*stakptr(PATH_OFFSET)!='/') - { - char *last=(char*)stakfreeze(1); - stakseek(PATH_OFFSET); - stakputs(oldpwd); - stakputc('/'); - stakputs(last+PATH_OFFSET); - stakputc(0); - } - if(!flag) - { - char *cp; - stakseek(PATH_MAX+PATH_OFFSET); -#ifdef SHOPT_FS_3D - if(!(cp = pathcanon(stakptr(PATH_OFFSET),PATH_DOTDOT))) - continue; - /* eliminate trailing '/' */ - while(*--cp == '/' && cp>stakptr(PATH_OFFSET)) - *cp = 0; -#else - if(*(cp=stakptr(PATH_OFFSET))=='/') - if(!pathcanon(cp,PATH_DOTDOT)) - continue; -#endif /* SHOPT_FS_3D */ - } - if((rval=chdir(path_relative(stakptr(PATH_OFFSET)))) >= 0) - goto success; - if(errno!=ENOENT && saverrno==0) - saverrno=errno; - } - while(cdpath); - if(rval<0 && *dir=='/' && *(path_relative(stakptr(PATH_OFFSET)))!='/') - rval = chdir(dir); - /* use absolute chdir() if relative chdir() fails */ - if(rval<0) - { - if(saverrno) - errno = saverrno; - error(ERROR_system(1),"%s:",dir); - } -success: - if(dir == nv_getval(opwdnod) || argc==2) - dp = dir; /* print out directory for cd - */ - if(flag) - { - dir = stakptr(PATH_OFFSET); - if (!(dir=pathcanon(dir,PATH_PHYSICAL))) - { - dir = stakptr(PATH_OFFSET); - error(ERROR_system(1),"%s:",dir); - } - stakseek(dir-stakptr(0)); - } - dir = (char*)stakfreeze(1)+PATH_OFFSET; - if(*dp && *dp!= ':' && strchr(dir,'/')) - sfputr(sfstdout,dir,'\n'); - if(*dir != '/') - return(0); - nv_putval(opwdnod,oldpwd,NV_RDONLY); - if(oldpwd) - free(oldpwd); - flag = strlen(dir); - /* delete trailing '/' */ - while(--flag>0 && dir[flag]=='/') - dir[flag] = 0; - nv_putval(pwdnod,dir,NV_RDONLY); - nv_onattr(pwdnod,NV_NOFREE|NV_EXPORT); - sh.pwd = pwdnod->nvalue.cp; - return(0); -} - -int b_pwd __PARAM__((int argc, char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[];__V_ *extra;){ - int n, flag = (sh_isoption(SH_PHYSICAL)!=0); - char *cp; - NOT_USED(extra); - NOT_USED(argc); - while((n = optget(argv,sh_optpwd))) switch(n) - { - case 'L': - flag = 0; - break; - case 'P': - flag = 1; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - if(*(cp = path_pwd(0)) != '/') - error(ERROR_system(1), e_pwd); - if(flag) - { -#ifdef SHOPT_FS_3D - if((flag = mount(e_dot,NIL(char*),FS3D_GET|FS3D_VIEW,0))>=0) - { - cp = (char*)stakseek(++flag+PATH_MAX); - mount(e_dot,cp,FS3D_GET|FS3D_VIEW|FS3D_SIZE(flag),0); - } - else -#endif /* SHOPT_FS_3D */ - cp = strcpy(stakseek(strlen(cp)+PATH_MAX),cp); - pathcanon(cp,PATH_PHYSICAL); - } - sfputr(sfstdout,cp,'\n'); - return(0); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cflow.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cflow.c deleted file mode 100644 index ccbd2da09..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/cflow.c +++ /dev/null @@ -1,169 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: cflow.c /main/3 1995/11/01 16:27:48 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include -#include "shnodes.h" -#include "builtins.h" - -/* - * return and exit - */ -int b_ret_exit __PARAM__((int n, char *argv[],__V_ *extra), (n, argv, extra)) __OTORP__(int n; char *argv[];__V_ *extra;){ - struct checkpt *pp = (struct checkpt*)sh.jmplist; - char *arg; - NOT_USED(extra); - while((n = optget(argv,sh_optcflow))) switch(n) - { - case ':': - if(!strmatch(argv[opt_index],"[+-]+([0-9])")) - error(2, opt_arg); - goto done; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } -done: - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - pp->mode = (**argv=='e'?SH_JMPEXIT:SH_JMPFUN); - argv += opt_index; - n = (((arg= *argv)?atoi(arg):sh.oldexit)&SH_EXITMASK); - /* return outside of function, dotscript and profile is exit */ - if(sh.fn_depth==0 && sh.dot_depth==0 && !sh_isstate(SH_PROFILE)) - pp->mode = SH_JMPEXIT; - sh_exit(n); - return(1); -} - - -/* - * break and continue - */ -int b_brk_cont __PARAM__((int n, char *argv[],__V_ *extra), (n, argv, extra)) __OTORP__(int n; char *argv[];__V_ *extra;){ - char *arg; - int cont= **argv=='c'; - NOT_USED(extra); - while((n = optget(argv,sh_optcflow))) switch(n) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - argv += opt_index; - n=1; - if(arg= *argv) - { - n = strtol(arg,&arg,10); - if(n<=0 || *arg) - error(ERROR_exit(1),e_nolabels,*argv); - } - if(sh.st.loopcnt) - { - sh.st.execbrk = sh.st.breakcnt = n; - if(sh.st.breakcnt > sh.st.loopcnt) - sh.st.breakcnt = sh.st.loopcnt; - if(cont) - sh.st.breakcnt = -sh.st.breakcnt; - } - return(0); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getconf.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getconf.c deleted file mode 100644 index 0bf7ddb29..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getconf.c +++ /dev/null @@ -1,197 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: getconf.c /main/3 1995/11/01 16:28:05 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include -#include -#include -#include -#include "shtable.h" -#include "builtins.h" -#include "FEATURE/externs" - -#define next_config(p) ((Shtable_t*)((char*)(p) + sizeof(*shtab_config))) -#define MIN_LEN 20 - -int b_getconf __PARAM__((int argc, char *argv[]), (argc, argv)) __OTORP__(int argc; char *argv[];){ - int m,n; - long val; - const char *name, *path=""; - int offset = staktell(); - const Shtable_t *tp = shtab_config; - error_info.id = argv[0]; - while (n = optget(argv, sh_optgetconf)) switch (n) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - argc -= opt_index; - if(argc >2) - error(ERROR_usage(2),optusage((char*)0)); - while(1) - { - if(argc) - { - name = *argv; - n = sh_lookup(name,shtab_config); - } - else - { - name = tp->sh_name; - n = tp->sh_number; - if(*name==0) - break; - } - m = n>>2; - errno = 0; - val = -1; - switch(n&03) - { - case 0: - if(m==0) - errno = EINVAL; - break; - case 1: -#ifdef _lib_confstr - stakseek(offset+MIN_LEN); - if((n=confstr(m,stakptr(offset),MIN_LEN)) > MIN_LEN) - { - stakseek(offset+n); - confstr(m,stakptr(offset),n); - } -#else - if(strcmp(name,"PATH")) - errno = EINVAL; - else - stakputs(e_defpath); -#endif /* _lib_confstr */ - val = 0; - break; - case 2: - val = sysconf(m); - break; - case 3: - if(argc==0) - path = "/"; - else if(argc!=2) - error(ERROR_exit(1),e_needspath,name); - else - path=argv[1]; - val = pathconf(path,m); - break; - } - if(errno) - error(ERROR_system(0),e_badconf,name,path); - path= ""; - if(argc==0) - sfputr(sfstdout,name,'='); - if(val==-1) - sfputr(sfstdout,"undefined",'\n'); - else if((n&03)==1) - sfputr(sfstdout,stakptr(offset),'\n'); - else - sfprintf(sfstdout,"%ld\n",val); - if(argc) - break; - tp= next_config(tp); - val = -1; - } - stakseek(offset); - return(error_info.errors); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getopts.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getopts.c deleted file mode 100644 index c6abdbccd..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/getopts.c +++ /dev/null @@ -1,200 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: getopts.c /main/3 1995/11/01 16:28:23 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include "variables.h" -#include -#include -#include "builtins.h" - -int b_getopts __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - char *options=error_info.context->id; - Namval_t *np; - int flag, mode, r=0; - static char value[2], key[2]; - NOT_USED(extra); - while((flag = optget(argv,sh_optgetopts))) switch(flag) - { - case 'a': - options = opt_arg; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - argc -= opt_index; - if(error_info.errors || argc<2) - error(ERROR_usage(2),optusage((char*)0)); - error_info.context->flags |= ERROR_SILENT; - error_info.id = options; - options = argv[0]; - np = nv_open(argv[1],sh.var_tree,NV_NOASSIGN|NV_VARNAME); - if(argc>2) - { - argv +=1; - argc -=1; - } - else - { - argv = sh.st.dolv; - argc = sh.st.dolc; - } - opt_index = sh.st.optindex; - opt_char = sh.st.optchar; - if(mode= (*options==':')) - options++; - switch(opt_index<=argc?(opt_num= LONG_MIN,flag=optget(argv,options)):0) - { - case '?': - error(ERROR_usage(0),opt_arg); - r = 2; - *(options = value) = flag; - break; - case ':': - key[0] = opt_option[1]; - if(strmatch(opt_arg,"*unknown*")) - flag = '?'; - if(mode) - opt_arg = key; - else - { - error(2, opt_arg); - opt_arg = 0; - flag = '?'; - } - *(options = value) = flag; - sh.st.opterror = 1; - break; - case 0: - if(sh.st.opterror) - { - char *com[2]; - com[0] = "-?"; - com[1] = 0; - flag = opt_index; - opt_index = 0; - optget(com,options); - opt_index = flag; - if(!mode && strchr(options,' ')) - error(ERROR_usage(0),optusage((char*)0)); - } - opt_arg = 0; - options = value; - *options = '?'; - r=1; - opt_char = 0; - break; - default: - options = opt_option + (*opt_option!='+'); - } - error_info.context->flags &= ~ERROR_SILENT; - sh.st.optindex = opt_index; - sh.st.optchar = opt_char; - nv_putval(np, options, 0); - nv_close(np); - np = nv_search((char*)OPTARGNOD,sh.var_tree,NV_ADD|HASH_BUCKET|HASH_NOSCOPE); - if(opt_num != LONG_MIN) - { - double d = opt_num; - nv_putval(np, (char*)&d, NV_INTEGER|NV_RDONLY); - } - else - nv_putval(np, opt_arg, NV_RDONLY); - return(r); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/hist.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/hist.c deleted file mode 100644 index 35001f200..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/hist.c +++ /dev/null @@ -1,324 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: hist.c /main/3 1995/11/01 16:28:36 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include -#include -#include "variables.h" -#include "io.h" -#include "name.h" -#include "history.h" -#include "builtins.h" - -static void hist_subst __PROTO__((const char*, int fd, char*)); - -int b_hist __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - History_t *hp; - char *arg; - int flag,fdo; - struct stat statb; - time_t before; - Sfio_t *outfile; - char *fname; - int range[2], incr, index2, indx= -1; - char *edit = 0; /* name of editor */ - char *replace = 0; /* replace old=new */ - int lflag = 0, nflag = 0, rflag = 0; - Histloc_t location; - NOT_USED(argc); - NOT_USED(extra); - if(!sh_histinit()) - error(ERROR_system(1),e_histopen); - hp = sh.hist_ptr; - while((flag = optget(argv,sh_opthist))) switch(flag) - { - case 'e': - edit = opt_arg; - break; - case 'n': - nflag++; - break; - case 'l': - lflag++; - break; - case 'r': - rflag++; - break; - case 's': - edit = "-"; - break; - case 'N': - if(indx<=0) - { - if((flag = hist_max(hp) - opt_num-1) < 0) - flag = 1; - range[++indx] = flag; - break; - } - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - argv += (opt_index-1); - flag = indx; - while(flag<1 && (arg=argv[1])) - { - /* look for old=new argument */ - if(!replace && strchr(arg+1,'=')) - { - replace = arg; - argv++; - continue; - } - else if(isdigit(*arg) || *arg == '-') - { - /* see if completely numeric */ - do arg++; - while(isdigit(*arg)); - if(*arg==0) - { - arg = argv[1]; - range[++flag] = atoi(arg); - if(*arg == '-') - range[flag] += (hist_max(hp)-1); - argv++; - continue; - } - } - /* search for last line starting with string */ - location = hist_find(hp,argv[1],hist_max(hp)-1,0,-1); - if((range[++flag] = location.hist_command) < 0) - error(ERROR_exit(1),e_found,argv[1]); - argv++; - } - if(flag <0) - { - /* set default starting range */ - if(lflag) - { - flag = hist_max(hp)-17; - if(flag<1) - flag = 1; - } - else - flag = hist_max(hp)-2; - range[0] = flag; - flag = 0; - } - index2 = hist_min(hp); - if(range[0]=(flag=(hist_max(hp) - 1))) - range[1] = flag; - /* check for valid ranges */ - if(range[1]=flag) - error(ERROR_exit(1),e_badrange,range[0],range[1]); - if(edit && *edit=='-' && range[0]!=range[1]) - error(ERROR_exit(1),e_eneedsarg); - /* now list commands from range[rflag] to range[1-rflag] */ - incr = 1; - flag = rflag>0; - if(range[1-flag] < range[flag]) - incr = -1; - if(lflag) - { - outfile = sfstdout; - arg = "\n\t"; - } - else - { - if(!(fname=pathtemp(NIL(char*),0,0))) - error(ERROR_exit(1),e_create,""); - if((fdo=open(fname,O_CREAT|O_RDWR,S_IRUSR|S_IWUSR)) < 0) - error(ERROR_system(1),e_create,fname); - outfile= sfnew(NIL(Sfio_t*),sh.outbuff,IOBSIZE,fdo,SF_WRITE); - arg = "\n"; - nflag++; - } - while(1) - { - if(nflag==0) - sfprintf(outfile,"%d\t",range[flag]); - else if(lflag) - sfputc(outfile,'\t'); - hist_list(sh.hist_ptr,outfile,hist_tell(sh.hist_ptr,range[flag]),0,arg); - if(lflag) - sh_sigcheck(); - if(range[flag] == range[1-flag]) - break; - range[flag] += incr; - } - if(lflag) - return(0); - if(fstat(sffileno(outfile),&statb)>=0) - before = statb.st_mtime; - sfclose(outfile); - hist_eof(hp); - arg = edit; - if(!arg && !(arg=nv_getval(nv_scoped(HISTEDIT))) && !(arg=nv_getval(nv_scoped(FCEDNOD)))) - arg = (char*)e_defedit; - - if(*arg != '-') - { - char *com[3]; - com[0] = arg; - com[1] = fname; - com[2] = 0; - error_info.errors = sh_eval(sh_sfeval(com),0); - } - fdo = sh_chkopen(fname); - unlink(fname); - free((__V_*)fname); - - /* don't history fc itself unless forked */ - error_info.flags |= ERROR_SILENT; - if(!sh_isstate(SH_FORKED)) - hist_cancel(hp); - sh_onstate(SH_VERBOSE|SH_HISTORY); /* echo lines as read */ - if(replace) - hist_subst(error_info.id,fdo,replace); - else if(error_info.errors == 0) - { - char buff[IOBSIZE+1]; - Sfio_t *iop = sfnew(NIL(Sfio_t*),buff,IOBSIZE,fdo,SF_READ); - /* read in and run the command */ - sh_eval(iop,1); - } - else - { - sh_close(fdo); - if(!sh_isoption(SH_VERBOSE)) - sh_offstate(SH_VERBOSE|SH_HISTORY); - } - return(sh.exitval); -} - - -/* - * given a file containing a command and a string of the form old=new, - * execute the command with the string old replaced by new - */ - -static void hist_subst __PARAM__((const char *command,int fd,char *replace), (command, fd, replace)) __OTORP__(const char *command;int fd;char *replace;){ - char *newp=replace; - char *sp; - int c; - off_t size; - char *string; - while(*++newp != '='); /* skip to '=' */ - if((size = lseek(fd,(off_t)0,SEEK_END)) < 0) - return; - lseek(fd,(off_t)0,SEEK_SET); - c = (int)size; - string = stakalloc(c+1); - if(read(fd,string,c)!=c) - return; - string[c] = 0; - *newp++ = 0; - if((sp=sh_substitute(string,replace,newp))==0) - error(ERROR_exit(1),e_subst,command); - *(newp-1) = '='; - sh_eval(sfopen(NIL(Sfio_t*),sp,"s"),1); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/misc.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/misc.c deleted file mode 100644 index 56731d0e0..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/misc.c +++ /dev/null @@ -1,561 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: misc.c /main/3 1995/11/01 16:28:50 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include "variables.h" -#include "shnodes.h" -#include "path.h" -#include "io.h" -#include "name.h" -#include "history.h" -#include "builtins.h" -#include "jobs.h" - -#define DOTMAX 32 /* maximum level of . nesting */ - -static int clear; -static void noexport __PROTO__((Namval_t*)); -static char *arg0; - -int b_exec __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - int n; - sh.st.ioset = 0; - clear = 0; - NOT_USED(extra); - while (n = optget(argv, sh_optexec)) switch (n) - { - case 'a': - arg0 = opt_arg; - argc = 0; - break; - case 'c': - clear=1; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - argv += opt_index; - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - if(*argv) - b_login(argc,argv,0); - return(0); -} - -static void noexport __PARAM__((Namval_t* np), (np)) __OTORP__(Namval_t* np;){ - nv_offattr(np,NV_EXPORT); -} - -int b_login __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - const char *pname; - struct checkpt *pp = (struct checkpt*)sh.jmplist; - NOT_USED(extra); - if(sh_isoption(SH_RESTRICTED)) - error(ERROR_exit(1),e_restricted,argv[0]); - else - { - struct argnod *arg=sh.envlist; - Namval_t* np; - char *cp; - if(sh.subshell) - sh_subfork(); - if(clear) - nv_scan(sh.var_tree,noexport,NV_EXPORT,NV_EXPORT); - while(arg) - { - if((cp=strchr(arg->argval,'=')) && - (*cp=0,np=nv_search(arg->argval,sh.var_tree,0))) - nv_onattr(np,NV_EXPORT); - if(cp) - *cp = '='; - arg=arg->argnxt.ap; - } - pname = argv[0]; - if(argc==0) - argv[0] = arg0; -#ifdef JOBS - if(job_close() < 0) - return(1); -#endif /* JOBS */ - /* force bad exec to terminate shell */ - pp->mode = SH_JMPEXIT; - sh_sigreset(2); - sh_freeup(); - path_exec(pname,argv,NIL(struct argnod*)); - sh_done(0); - } - return(1); -} - -int b_let __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - int r; - char *arg; - NOT_USED(argc); - NOT_USED(extra); - while (r = optget(argv,sh_optlet)) switch (r) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors || !*argv) - error(ERROR_usage(2),optusage((char*)0)); - while(arg= *argv++) - r = !sh_arith(arg); - return(r); -} - -int b_eval __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - int r; - NOT_USED(argc); - NOT_USED(extra); - while (r = optget(argv,sh_opteval)) switch (r) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - argv += opt_index; - if(*argv && **argv) - { - sh_offstate(SH_MONITOR); - sh_eval(sh_sfeval(argv),0); - } - return(sh.exitval); -} - -int b_dot_cmd __PARAM__((int n,char *argv[],__V_* extra), (n, argv, extra)) __OTORP__(int n;char *argv[];__V_* extra;){ - char *script; - Namval_t *np; - int jmpval; - int fd; - struct dolnod *argsave=0, *saveargfor; - char **saveargv; - struct checkpt buff; - Sfio_t *iop=0; - NOT_USED(extra); - while (n = optget(argv,sh_optdot)) switch (n) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - argv += opt_index; - script = *argv; - if(error_info.errors || !script) - error(ERROR_usage(2),optusage((char*)0)); - if(!(np=sh.posix_fun)) - { - /* check for KornShell style function first */ - np = nv_search(script,sh.fun_tree,0); - if(np && is_afunction(np) && !nv_isattr(np,NV_FPOSIX)) - { - if(!np->nvalue.ip) - { - path_search(script,NIL(char*),0); - if(np->nvalue.ip) - { - if(nv_isattr(np,NV_FPOSIX)) - np = 0; - } - else - error(ERROR_exit(1),e_found,script); - } - } - else - np = 0; - if(!np && (fd=path_open(script,path_get(script))) < 0) - error(ERROR_system(1),e_open,script); - } - sh.posix_fun = 0; - if(sh.dot_depth++ > DOTMAX) - error(ERROR_exit(1),e_toodeep,script); - if(np || argv[1]) - { - n = sh.st.dolc; - saveargv = sh.st.dolv; - argsave = sh_argnew(argv,&saveargfor); - } - sh_pushcontext(&buff,SH_JMPDOT); - jmpval = sigsetjmp(buff.buff,0); - if(jmpval == 0) - { - if(np) - sh_exec((union anynode*)(nv_funtree(np)),sh_isstate(SH_ERREXIT)); - else - { - char buff[IOBSIZE+1]; - iop = sfnew(NIL(Sfio_t*),buff,IOBSIZE,fd,SF_READ); - sh_eval(iop,0); - } - } - sh_popcontext(&buff); - sh.dot_depth--; - if((np || argv[1]) && jmpval!=SH_JMPSCRIPT) - { - sh_argreset(argsave,saveargfor); - sh.st.dolc = n; - sh.st.dolv = saveargv; - } - if(sh.exitval > SH_EXITSIG) - sh_fault(sh.exitval&SH_EXITMASK); - if(jmpval && jmpval!=SH_JMPFUN) - siglongjmp(*sh.jmplist,jmpval); - return(sh.exitval); -} - -/* - * null, true command - */ -int b_true __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - NOT_USED(argc); - NOT_USED(argv[0]); - NOT_USED(extra); - return(0); -} - -/* - * false command - */ -int b_false __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - NOT_USED(argc); - NOT_USED(argv[0]); - NOT_USED(extra); - return(1); -} - -int b_shift __PARAM__((int n, char *argv[], __V_ *extra), (n, argv, extra)) __OTORP__(int n; char *argv[]; __V_ *extra;){ - char *arg; - NOT_USED(extra); - while((n = optget(argv,sh_optcflow))) switch(n) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - argv += opt_index; - n = ((arg= *argv)?(int)sh_arith(arg):1); - if(n<0 || sh.st.dolc1) - error(ERROR_usage(2),optusage((char*)0)); - if(arg = argv[0]) - { - if(!astconf("_AST_UNIVERSE",0,arg)) - error(ERROR_exit(1), e_badname,arg); - } - else - { - if(!(arg=astconf("_AST_UNIVERSE",0,0))) - error(ERROR_exit(1),e_nouniverse); - else - sfputr(sfstdout,arg,'\n'); - } - return(0); -} -#endif /* cmd_universe */ - -#ifdef SHOPT_FS_3D - int b_vpath_map __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - int flag, n; - const char *optstr; - char *vend; - NOT_USED(extra); - if(argv[0][1]=='p') - { - optstr = sh_optvpath; - flag = FS3D_VIEW; - } - else - { - optstr = sh_optvmap; - flag = FS3D_VERSION; - } - while(n = optget(argv, optstr)) switch(n) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - argv += opt_index; - argc -= opt_index; - switch(argc) - { - case 0: - case 1: - flag |= FS3D_GET; - if((n = mount(*argv,(char*)0,flag,0)) >= 0) - { - vend = stakalloc(++n); - n = mount(*argv,vend,flag|FS3D_SIZE(n),0); - } - if(n < 0) - goto failed; - if(argc==1) - { - sfprintf(sfstdout,"%s\n",vend); - break; - } - n = 0; - while(flag = *vend++) - { - if(flag==' ') - { - flag = e_sptbnl[n+1]; - n = !n; - } - sfputc(sfstdout,flag); - } - if(n) - sfputc(sfstdout,'\n'); - break; - default: - if((argc&1)) - error(ERROR_usage(2),optusage((char*)0)); - /*FALLTHROUGH*/ - case 2: - if(!sh.lim.fs3d) - goto failed; - if(sh.subshell) - sh_subfork(); - for(n=0;n1) - error(ERROR_exit(1),e_cantset,flag==2?e_mapping:e_versions); - else - error(ERROR_exit(1),e_cantget,flag==2?e_mapping:e_versions); - return(1); - } -#endif /* SHOPT_FS_3D */ - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/print.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/print.c deleted file mode 100644 index 7c9b637e1..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/print.c +++ /dev/null @@ -1,630 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: print.c /main/3 1995/11/01 16:29:05 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include "io.h" -#include "name.h" -#include "history.h" -#include "builtins.h" - -union types_t -{ - unsigned char c; - int i; - long l; - double d; - float f; - char *s; - int *ip; - char **p; -}; - -static int getarg __PROTO__((int, union types_t *)); -static int extend __PROTO__((char*, int, int, char**)); -static char *genformat __PROTO__((char*)); -static int fmtvecho __PROTO__((const char*)); -#define fmtre(x) (x) - -static char bsd_univ,cescape, raw, echon; -static char **nextarg; -static const char *options; -static const char preformat[] = "%&%@"; - -/* - * Need to handle write failures to avoid locking output pool - */ -static int outexceptf __PARAM__((Sfio_t* iop, int mode, Sfdisc_t* dp), (iop, mode, dp)) __OTORP__(Sfio_t* iop; int mode; Sfdisc_t* dp;){ - if(mode==SF_DPOP || mode==SF_CLOSE) - free((__V_*)dp); - else if(mode==SF_WRITE) - { - int save = errno; - sfpurge(iop); - sfpool(iop,NIL(Sfio_t*),SF_WRITE); - errno = save; - error(ERROR_system(1),e_badwrite,sffileno(iop)); - } - return(0); -} - -#ifndef SHOPT_ECHOPRINT - int b_echo __PARAM__((int argc, char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[];__V_ *extra;){ - options = sh_optecho+5; - raw = echon = 0; - NOT_USED(argc); - NOT_USED(extra); - /* This mess is because /bin/echo on BSD is different */ - if(!sh.universe) - { - char *universe; - if(universe=astconf("_AST_UNIVERSE",0,0)) - bsd_univ = (strcmp(universe,"ucb")==0); - sh.universe = 1; - } - if(!bsd_univ) - return(b_print(0,argv,0)); - options = sh_optecho; - raw = 1; - if(argv[1] && strcmp(argv[1],"-n")==0) - echon = 1; - return(b_print(0,argv+echon,0)); - } -#endif /* SHOPT_ECHOPRINT */ - -int b_printf __PARAM__((int argc, char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[];__V_ *extra;){ - NOT_USED(argc); - NOT_USED(extra); - options = sh_optprintf; - return(b_print(-1,argv,0)); -} - -/* - * argc==0 when called from echo - * argc==-1 when called from printf - */ - -int b_print __PARAM__((int argc, char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[]; __V_ *extra;){ - Sfio_t *outfile; - int n, fd = 1; - const char *msg = e_file+4; - char *format = 0; - int sflag = 0, nflag, rflag; - NOT_USED(extra); - if(argc>0) - { - options = sh_optprint; - nflag = rflag = 0; - format = 0; - } - else if(argc==0) - { - nflag = echon; - rflag = raw; - argv++; - goto skip; - } - while((n = optget(argv,options))) switch(n) - { - case 'n': - nflag++; - break; - case 'p': - fd = sh.coutpipe; - msg = e_query; - break; - case 'f': - format = opt_arg; - break; - case 's': - /* print to history file */ - if(!sh_histinit()) - error(ERROR_system(1),e_history); - fd = sffileno(sh.hist_ptr->histfp); - sh_onstate(SH_HISTORY); - sflag++; - break; - case 'e': - rflag = 0; - break; - case 'r': - rflag = 1; - break; - case 'u': - fd = (int)strtol(opt_arg,&opt_arg,10); - if(*opt_arg) - fd = -1; - else if(fd<0 || fd >= sh.lim.open_max) - fd = -1; - else if(sh_inuse(fd) || (sh.hist_ptr && fd==sffileno(sh.hist_ptr->histfp))) - fd = -1; - break; - case ':': - /* The followin is for backward compatibility */ - if(strcmp(opt_option,"-R")==0) - { - rflag = 1; - if(error_info.errors==0) - { - argv += opt_index+1; - /* special case test for -Rn */ - if(strchr(argv[-1],'n')) - nflag++; - if(*argv && strcmp(*argv,"-n")==0) - { - - nflag++; - argv++; - } - goto skip2; - } - } - else - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors || (argc<0 && !(format = *argv++))) - error(ERROR_usage(2),optusage((char*)0)); -skip: - if(format) - format = genformat(format); - /* handle special case of '-' operand for print */ - if(argc>0 && *argv && strcmp(*argv,"-")==0 && strcmp(argv[-1],"--")) - argv++; -skip2: - if(fd < 0) - { - errno = EBADF; - n = 0; - } - else if(!(n=sh.fdstatus[fd])) - n = sh_iocheckfd(fd); - if(!(n&IOWRITE)) - { - /* don't print error message for stdout for compatibility */ - if(fd==1) - return(1); - error(ERROR_system(1),msg); - } - if(!(outfile=sh.sftable[fd])) - { - Sfdisc_t *dp; - sh_onstate(SH_NOTRACK); - n = SF_WRITE|((n&IOREAD)?SF_READ:0); - sh.sftable[fd] = outfile = sfnew(NIL(Sfio_t*),sh.outbuff,IOBSIZE,fd,n); - sh_offstate(SH_NOTRACK); - sfpool(outfile,sh.outpool,SF_WRITE); - if(dp = new_of(Sfdisc_t,0)) - { - dp->exceptf = outexceptf; - dp->seekf = 0; - dp->writef = 0; - dp->readf = 0; - sfdisc(outfile,dp); - } - } - cescape = 0; - /* turn off share to guarantee atomic writes for printf */ - n = sfset(outfile,SF_SHARE|SF_PUBLIC,0); - if(format) - { - /* printf style print */ - Sfio_t *pool; - sh_offstate(SH_STOPOK); - pool=sfpool(sfstderr,NIL(Sfio_t*),SF_WRITE); - nextarg = argv; - do - { - if(sh.trapnote&SH_SIGSET) - break; - sfprintf(outfile,format,extend,getarg); - } - while(*nextarg && nextarg!=argv); - sfpool(sfstderr,pool,SF_WRITE); - } - else - { - /* echo style print */ - if(sh_echolist(outfile,rflag,argv) && !nflag) - sfputc(outfile,'\n'); - } - if(sflag) - { - hist_flush(sh.hist_ptr); - sh_offstate(SH_HISTORY); - } - else if(n&SF_SHARE) - { - sfset(outfile,SF_SHARE|SF_PUBLIC,1); - sfsync(outfile); - } - return(0); -} - -/* - * echo the argument list onto - * if is non-zero then \ is not a special character. - * returns 0 for \c otherwise 1. - */ - -int sh_echolist __PARAM__((Sfio_t *outfile, int raw, char *argv[]), (outfile, raw, argv)) __OTORP__(Sfio_t *outfile; int raw; char *argv[];){ - char *cp; - int n; - while(!cescape && (cp= *argv++)) - { - if(!raw && (n=fmtvecho(cp))>=0) - { - if(n) - sfwrite(outfile,stakptr(staktell()),n); - } - else - sfputr(outfile,cp,-1); - if(*argv) - sfputc(outfile,' '); - sh_sigcheck(); - } - return(!cescape); -} - - -static char *genformat __PARAM__((char *format), (format)) __OTORP__(char *format;){ - char *fp; - stakseek(0); - stakputs(preformat); - stakputs(format); - fp = (char*)stakfreeze(1); - stresc(fp+sizeof(preformat)-1); - return(fp); -} - -static int getarg __PARAM__((int format,union types_t *value), (format, value)) __OTORP__(int format;union types_t *value;){ - char *argp = *nextarg; - char *lastchar = ""; - int neg = 0; - if(!argp) - { - switch(format) - { - case 'c': - value->c = 0; - break; - case 's': - case 'q': - case 'P': - case 'R': - case 'b': - value->s = ""; - break; - case 'f': - value->f = 0.; - break; - case 'F': - value->d = 0.; - break; - case 'n': - { - static int intvar; - value->ip = &intvar; - break; - } - default: - value->l = 0; - } - return(0); - } - switch(format) - { - case 'p': - value->p = (char**)strtol(argp,&lastchar,10); - break; - case 'n': - { - Namval_t *np; - np = nv_open(argp,sh.var_tree,NV_VARNAME|NV_NOASSIGN|NV_ARRAY); - nv_unset(np); - nv_onattr(np,NV_INTEGER); - np->nvalue.lp = new_of(long,0); - nv_setsize(np,10); - if(sizeof(int)==sizeof(long)) - value->ip = (int*)np->nvalue.lp; - else - { - struct temp { int hi; int low; } *sp = (struct temp*)(np->nvalue.lp); - sp->hi = 0; - sp->low = 1; - if(*np->nvalue.lp==1) - value->ip = &sp->low; - else - value->ip = &sp->hi; - } - nv_close(np); - break; - } - case 'q': - case 'b': - case 's': - case 'P': - case 'R': - value->s = argp; - break; - case 'c': - value->c = *argp; - break; - case 'u': - case 'U': - case 'd': - case 'D': - switch(*argp) - { - case '\'': case '"': - value->l = argp[1]; - break; - default: - value->l = (long)sh_strnum(argp,&lastchar); - if(lastchar == *nextarg) - { - value->l = *argp; - lastchar = ""; - } - } - if(neg) - value->l = -value->l; - if(sizeof(int)!=sizeof(long) && format=='d') - value->i = (int)value->l; - break; - case 'f': - case 'F': - value->d = sh_strnum(*nextarg,&lastchar); - if(sizeof(float)!=sizeof(double) && format=='f') - value->f = (float)value->d; - break; - default: - value->l = 0; - error(ERROR_exit(1),e_formspec,format); - } - if(*lastchar) - error(ERROR_exit(1),e_argtype,format); - nextarg++; - return(0); -} - -/* - * This routine adds new % escape sequences to printf - */ -static int extend __PARAM__((char *invalue,int format,int precis,char **outval), (invalue, format, precis, outval)) __OTORP__(char *invalue;int format;int precis;char **outval;){ - int n; - NOT_USED(precis); - switch(format) - { - case 'b': - if((n=fmtvecho(invalue))>=0) - { - *outval = stakptr(staktell()); - return(n); - } - *outval = invalue; - return(strlen(*outval)); - case 'q': - *outval = sh_fmtq(invalue); - return(strlen(*outval)); - case 'P': - *outval = fmtmatch(invalue); - if(*outval==0) - error(ERROR_exit(1),e_badregexp,invalue); - return(strlen(*outval)); - case 'R': - *outval = fmtre(invalue); - if(*outval==0) - error(ERROR_exit(1),e_badregexp,invalue); - return(strlen(*outval)); - default: - *outval = 0; - return(-1); - } -} - -/* - * construct System V echo string out of - * If there are not escape sequences, returns -1 - * Otherwise, puts null terminated result on stack, but doesn't freeze it - * returns lenght of output. - */ - -static int fmtvecho __PARAM__((const char *string), (string)) __OTORP__(const char *string;){ - static char *nullarg; - const char *cp = string, *cpmax; - int c; - int offset = staktell(); - int chlen; - if (MB_CUR_MAX > 1) - { - while (1) - { - if ((chlen = mblen(cp, MB_CUR_MAX)) > 1) - { - /* Skip over multibyte characters */ - cp += chlen; - } - else - { - c = *cp++; - if ((c == '\0') || (c == '\\')) - break; - } - } - } - else - while((c= *cp++) && (c!='\\')); - if(c==0) - return(-1); - c = --cp - string; - if(c>0) - stakwrite((__V_*)string,c); - /* for(; c= *cp; cp++) */ - while(1) - { - if ((MB_CUR_MAX > 1) && ((chlen = mblen(cp, MB_CUR_MAX)) > 1)) - { - /* Skip over multibyte characters */ - int i; - for (i = 0; i < chlen; i++) - { - c = *cp++; - stakputc(c); - } - } - else - { - if ((c = *cp) == '\0') - break; - - if( c=='\\') switch(*++cp) - { - case 'E': - c = '\033'; - break; - case 'a': - c = '\007'; - break; - case 'b': - c = '\b'; - break; - case 'c': - cescape++; - nextarg = &nullarg; - goto done; - case 'f': - c = '\f'; - break; - case 'n': - c = '\n'; - break; - case 'r': - c = '\r'; - break; - case 'v': - c = '\013'; - break; - case 't': - c = '\t'; - break; - case '\\': - c = '\\'; - break; - case '0': - c = 0; - cpmax = cp + 4; - while(++cp='0' && *cp<='7') - { - c <<= 3; - c |= (*cp-'0'); - } - default: - cp--; - } - stakputc(c); - cp++; - } - } -done: - c = staktell()-offset; - stakseek(offset); - return(c); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/read.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/read.c deleted file mode 100644 index caba67fb3..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/read.c +++ /dev/null @@ -1,488 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: read.c /main/3 1995/11/01 16:29:22 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include -#include -#include -#include "defs.h" -#include "variables.h" -#include "lexstates.h" -#include "io.h" -#include "name.h" -#include "builtins.h" -#include "history.h" -#include "terminal.h" -#include "national.h" - -#define R_FLAG 1 /* raw mode */ -#define S_FLAG 2 /* save in history file */ -#define A_FLAG 4 /* read into array */ -#define D_FLAG 6 /* must be number of bits for all flags */ - -int b_read __PARAM__((int argc,char *argv[], __V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[]; __V_ *extra;){ - char *name; - int r, flags=0, fd=0; - long timeout = 1000*sh.tmout; - int save_prompt; - NOT_USED(argc); - NOT_USED(extra); - while((r = optget(argv,sh_optread))) switch(r) - { - case 'A': - flags |= A_FLAG; - break; - case 't': - timeout = 1000*opt_num; - break; - case 'd': - if(opt_arg && *opt_arg!='\n') - flags |= ((*opt_arg)<< D_FLAG); - break; - case 'p': - if((fd = sh.cpipe[0])<=0) - error(ERROR_exit(1),e_query); - break; - case 'r': - flags |= R_FLAG; - break; - case 's': - /* save in history file */ - flags |= S_FLAG; - break; - case 'u': - fd = (int)opt_num; - if(sh_inuse(fd)) - fd = -1; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - if(!((r=sh.fdstatus[fd])&IOREAD) || !(r&(IOSEEK|IONOSEEK))) - r = sh_iocheckfd(fd); - if(fd<0 || !(r&IOREAD)) - error(ERROR_system(1),e_file+4); - /* look for prompt */ - if((name = *argv) && (name=strchr(name,'?')) && (r&IOTTY)) - { - r = strlen(++name)+1; - if(sh.prompt=(char*)sfreserve(sfstderr,r,1)) - { - memcpy(sh.prompt,name,r); - sfwrite(sfstderr,sh.prompt,r); - } - } - sh.timeout = 0; - save_prompt = sh.nextprompt; - sh.nextprompt = 0; - r=sh_readline(argv,fd,flags,timeout); - sh.nextprompt = save_prompt; - if(r==0 && (r=(sfeof(sh.sftable[fd])||sferror(sh.sftable[fd])))) - { - if(fd == sh.cpipe[0]) - { - sh_pclose(sh.cpipe); - return(1); - } - } - sfclrerr(sh.sftable[fd]); - return(r); -} - -/* - * here for read timeout - */ -static void timedout __PARAM__((__V_ *handle), (handle)) __OTORP__(__V_ *handle;){ - sfclrlock((Sfio_t*)handle); - sh_exit(1); -} - -/* - * This is the code to read a line and to split it into tokens - * is an array of variable names - * is the file descriptor - * is union of -A, -r, -s, and contains delimiter if not '\n' - * is number of milli-seconds until timeout - */ - -int sh_readline __PARAM__((char **names, int fd, int flags,long timeout), (names, fd, flags, timeout)) __OTORP__(char **names; int fd; int flags;long timeout;){ - int c; - unsigned char *cp; - Namval_t *np; - char *name, *val; - Sfio_t *iop; - char *ifs; - unsigned char *cpmax; - char was_escape = 0; - char use_stak = 0; - int rel; - long array_index = 0; - __V_ *timeslot=0; - int delim = '\n'; - int jmpval=0; - struct checkpt buff; - if(!(iop=sh.sftable[fd]) && !(iop=sh_iostream(fd))) - return(1); - if(flags>>D_FLAG) /* delimiter not new-line */ - { - delim = ((unsigned)flags)>>D_FLAG; - if(sh.fdstatus[fd]&IOTTY) - tty_raw(fd,1); - } - /* set up state table based on IFS */ - ifs = nv_getval(np=nv_scoped(IFSNOD)); - if((flags&R_FLAG) && sh.ifstable['\\']==S_ESC) - sh.ifstable['\\'] = 0; - else if(!(flags&R_FLAG) && sh.ifstable['\\']==0) - sh.ifstable['\\'] = S_ESC; - sh.ifstable[delim] = S_NL; - if(delim!='\n') - { - sh.ifstable['\n'] = 0; - nv_putval(np, ifs, NV_RDONLY); - } - sh.ifstable[0] = S_EOF; - if(names && (name = *names)) - { - if(val= strchr(name,'?')) - *val = 0; - np = nv_open(name,sh.var_tree,NV_NOASSIGN|NV_VARNAME); - if(flags&A_FLAG) - { - flags &= ~A_FLAG; - array_index = 1; - nv_unset(np); - nv_putsub(np,NIL(char*),0L); - } - else - name = *++names; - if(val) - *val = '?'; - } - else - { - name = 0; - if(hashscope(sh.var_tree)) - np = nv_search((char*)REPLYNOD,sh.var_tree,HASH_BUCKET); - else - np = REPLYNOD; - } - sfclrerr(iop); - if(timeout) - { - sh_pushcontext(&buff,1); - jmpval = sigsetjmp(buff.buff,0); - if(jmpval) - goto done; - timeslot = (__V_*)kshtimeradd(timeout,0,timedout,(__V_*)iop); - } - if(!(cp = (unsigned char*)sfgetr(iop,delim,0))) - cp = (unsigned char*)sfgetr(iop,delim,-1); - if(timeslot) - timerdel(timeslot); - if(cp) - { - cpmax = cp + sfslen(); - if(*(cpmax-1) != delim) - *(cpmax-1) = delim; - if(flags&S_FLAG) - sfwrite(sh.hist_ptr->histfp,(char*)cp,sfslen()); - c = sh.ifstable[*cp++]; -#ifndef SHOPT_MULTIBYTE - if(!name && (flags&R_FLAG)) /* special case single argument */ - { - /* skip over leading blanks */ - while(c==S_SPACE) - c = sh.ifstable[*cp++]; - /* strip trailing delimiters */ - if(cpmax[-1] == '\n') - cpmax--; - *cpmax =0; - if(cpmax>cp) - { - while((c=sh.ifstable[*--cpmax])==S_DELIM || c==S_SPACE); - cpmax[1] = 0; - } - nv_putval(np,(char*)cp-1,0); - goto done; - } -#endif /* !SHOPT_MULTIBYTE */ - } - else - c = S_NL; - sh.nextprompt = 2; - rel= staktell(); - /* val==0 at the start of a field */ - val = 0; - while(1) - { - switch(c) - { -#ifdef SHOPT_MULTIBYTE - case S_MBYTE: - if(sh_strchr(ifs,(char*)cp-1)>=0) - { - c = mblen((char*)cp-1,MB_CUR_MAX); - cp[-1] = 0; - cp += (c-1); - c = S_DELIM; - } - else - c = 0; - continue; -#endif /*SHOPT_MULTIBYTE */ - case S_ESC: - /* process escape character */ - if((c = sh.ifstable[*cp++]) == S_NL) - was_escape = 1; - else - c = 0; - if(val) - { - stakputs(val); - use_stak = 1; - was_escape = 1; - *val = 0; - } - continue; - - case S_EOF: - /* check for end of buffer */ - if(val && *val) - { - stakputs(val); - use_stak = 1; - } - val = 0; - if(cp>=cpmax) - { - c = S_NL; - break; - } - /* eliminate null bytes */ - c = sh.ifstable[*cp++]; - if(!name && val && (c==S_SPACE||c==S_DELIM||c==S_MBYTE)) - c = 0; - continue; - case S_NL: - if(was_escape) - { - was_escape = 0; - if((cp = (unsigned char*)sfgetr(iop,delim,0)) || - (cp = (unsigned char*)sfgetr(iop,delim,-1))) - { - if(flags&S_FLAG) - sfwrite(sh.hist_ptr->histfp,(char*)cp,sfslen()); - cpmax = cp + sfslen(); - c = sh.ifstable[*cp++]; - val=0; - if(!name && (c==S_SPACE || c==S_DELIM || c==S_MBYTE)) - c = 0; - continue; - } - } - c = S_NL; - break; - - case S_SPACE: - /* skip over blanks */ - while(c==S_SPACE) - c = sh.ifstable[*cp++]; - if(!val) - continue; -#ifdef SHOPT_MULTIBYTE - if(c==S_MBYTE) - { - if(sh_strchr(ifs,(char*)cp-1)>=0) - { - c = mblen((char*)cp-1,MB_CUR_MAX); - cp += (c-1); - c = S_DELIM; - } - else - c = 0; - } -#endif /* SHOPT_MULTIBYTE */ - if(c!=S_DELIM) - break; - /* FALL THRU */ - case S_DELIM: - if(name) - { - /* skip over trailing blanks */ - while((c=sh.ifstable[*cp++])==S_SPACE); - break; - } - - case 0: - was_escape = 0; - val = (char*)(cp-1); - /* skip over word characters */ - while(1) - { - while((c=sh.ifstable[*cp++])==0); - if(name || c==S_NL || c==S_ESC || c==S_EOF || c==S_MBYTE) - break; - } - if(c!=S_MBYTE) - cp[-1] = 0; - continue; - } - /* assign value and advance to next variable */ - if(!val) - val = ""; - if(use_stak) - { - stakputs(val); - stakputc(0); - val = stakptr(rel); - } - if(!name && *val) - { - /* strip off trailing delimiters */ - char *cp = val + strlen(val); - int n; - while((n=sh.ifstable[*--cp])==S_DELIM || n==S_SPACE); - cp[1] = 0; - } - nv_putval(np,val,0); - val = 0; - if(use_stak) - { - stakseek(rel); - use_stak = 0; - } - if(array_index) - { - nv_putsub(np, NIL(char*), array_index++); - if(c!=S_NL) - continue; - name = *++names; - } - while(1) - { - if(sh_isoption(SH_ALLEXPORT)&&!strchr(nv_name(np),'.')) - nv_onattr(np,NV_EXPORT); - if(name) - { - nv_close(np); - np = nv_open(name,sh.var_tree,NV_NOASSIGN|NV_VARNAME); - name = *++names; - } - else - np = 0; - if(c!=S_NL) - break; - if(!np) - goto done; - nv_putval(np, "", 0); - } - } -done: - nv_close(np); - if(timeout) - sh_popcontext(&buff); - if((flags>>D_FLAG) && (sh.fdstatus[fd]&IOTTY)) - tty_cooked(fd); - if(flags&S_FLAG) - hist_flush(sh.hist_ptr); - return(jmpval); -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/sleep.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/sleep.c deleted file mode 100644 index 7d0e2c333..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/sleep.c +++ /dev/null @@ -1,234 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: sleep.c /main/3 1995/11/01 16:29:36 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include "builtins.h" -#include "FEATURE/time" -#include "FEATURE/poll" -#ifdef _NEXT_SOURCE -# define sleep _ast_sleep -#endif /* _NEXT_SOURCE */ -#ifdef _lib_poll_notimer -# undef _lib_poll -#endif /* _lib_poll_notimer */ - -int b_sleep __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - char *cp; - double d; - time_t tloc = 0; - NOT_USED(extra); - while((argc = optget(argv,sh_optsleep))) switch(argc) - { - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors || !(cp= *argv) || !(strmatch(cp,e_numeric))) - error(ERROR_usage(2),optusage((char*)0)); - if((d=atof(cp)) > 1.0) - { - sfsync(sh.outpool); - time(&tloc); - tloc += (time_t)(d+.5); - } - while(1) - { - time_t now; - errno = 0; - sh.lastsig=0; - sh_delay(d); - if(tloc==0 || errno!=EINTR || sh.lastsig) - break; - sh_sigcheck(); - if(tloc < (now=time(NIL(time_t*)))) - break; - d = (double)(tloc-now); - if(sh.sigflag[SIGALRM]&SH_SIGTRAP) - sh_timetraps(); - } - return(0); -} - -static char expired; -static void completed __PARAM__((__V_ * handle), (handle)) __OTORP__(__V_ * handle;){ - NOT_USED(handle); - expired = 1; -} - -unsigned sleep __PARAM__((unsigned sec), (sec)) __OTORP__(unsigned sec;){ - pid_t newpid, curpid=getpid(); - __V_ *tp; - expired = 0; - sh.lastsig = 0; - tp = (__V_*)kshtimeradd(1000*sec, 0, completed, (__V_*)0); - do - { - pause(); - if(sh.sigflag[SIGALRM]&SH_SIGTRAP) - sh_timetraps(); - if((newpid=getpid()) != curpid) - { - curpid = newpid; - alarm(1); - } - } - while(!expired && sh.lastsig==0); - if(!expired) - timerdel(tp); - sh_sigcheck(); - return(0); -} - -/* - * delay execution for time - */ - -void sh_delay __PARAM__((double t), (t)) __OTORP__(double t;){ - int n = (int)t; -#ifdef _lib_poll - struct pollfd fd; - if(t<=0) - return; - else if(n > 30) - { - sleep(n); - t -= n; - } - if(n=(int)(1000*t)) - poll(&fd,0,n); -#else -# if defined(_lib_select) && defined(_mem_tv_usec_timeval) - struct timeval timeloc; - if(t<=0) - return; - timeloc.tv_sec = n; - timeloc.tv_usec = 1000000*(t-(double)n); - select(0,(fd_set*)0,(fd_set*)0,(fd_set*)0,&timeloc); -# else -# ifdef _lib_select - /* for 9th edition machines */ - if(t<=0) - return; - if(n > 30) - { - sleep(n); - t -= n; - } - if(n=(int)(1000*t)) - select(0,(fd_set*)0,(fd_set*)0,n); -# else - struct tms tt; - if(t<=0) - return; - sleep(n); - t -= n; - if(t) - { - clock_t begin = times(&tt); - if(begin==0) - return; - t *= sh.lim.clk_tck; - n += (t+.5); - while((times(&tt)-begin) < n); - } -# endif -# endif -#endif /* _lib_poll */ -} diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/test.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/test.c deleted file mode 100644 index 046d608d4..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/test.c +++ /dev/null @@ -1,601 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: test.c /main/5 1995/12/12 14:46:01 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include -#include -#include "io.h" -#include "terminal.h" -#include "test.h" -#include "builtins.h" -#include "FEATURE/externs" - -#ifndef _lib_setregid -# undef _lib_setreuid -#endif /* _lib_setregid */ - -#if defined(_lib_setreuid) && !defined(_AIX) - extern __MANGLE__ int setreuid __PROTO__((uid_t,uid_t)); - extern __MANGLE__ int setregid __PROTO__((uid_t,uid_t)); -#endif /* _lib_setreuid */ - -#define permission(a,f) (sh_access(a,f)==0) -static time_t test_time __PROTO__((const char*, const char*)); -static int test_stat __PROTO__((const char*, struct stat*)); -static int test_mode __PROTO__((const char*)); - -static struct stat statb; - -/* single char string compare */ -#define c_eq(a,c) (*a==c && *(a+1)==0) -/* two character string compare */ -#define c2_eq(a,c1,c2) (*a==c1 && *(a+1)==c2 && *(a+2)==0) - -static char *nxtarg __PROTO__((int)); -static int expr __PROTO__((int)); -static int e3 __PROTO__((void)); - -static int ap, ac; -static char **av; - -int b_test __PARAM__((int argc, char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc; char *argv[];__V_ *extra;){ - char *cp = argv[0]; - int not; - NOT_USED(extra); - av = argv; - ap = 1; - if(c_eq(cp,'[')) - { - cp = argv[--argc]; - if(!c_eq(cp, ']')) - error(ERROR_exit(2),e_missing,"']'"); - } - if(argc <= 1) - return(1); - cp = argv[1]; - not = c_eq(cp,'!'); - /* posix portion for test */ - switch(argc) - { - case 5: - if(!not) - break; - argv++; - /* fall through */ - case 4: - { - int op = sh_lookup(cp=argv[2],shtab_testops); - if(op&TEST_BINOP) - break; - if(!op) - { - if(argc==5) - break; - if(not && cp[0]=='-' && cp[2]==0) - return(test_unop(cp[1],argv[3])); - error(ERROR_exit(2),e_badop,cp); - } - return(test_binop(op,argv[1],argv[3])^(argc!=5)); - } - case 3: - if(not) - return(*argv[2]!=0); - if(cp[0] != '-' || cp[2]) - break; - return(!test_unop(cp[1],argv[2])); - case 2: - return(*cp==0); - } - if(argc==5) - argv--; - ac = argc; - return(!expr(0)); -} - -/* - * evaluate a test expression. - * flag is 0 on outer level - * flag is 1 when in parenthesis - * flag is 2 when evaluating -a - */ -static int expr __PARAM__((int flag), (flag)) __OTORP__(int flag;){ - int r; - char *p; - r = e3(); - while(ap < ac) - { - p = nxtarg(0); - /* check for -o and -a */ - if(flag && c_eq(p,')')) - { - ap--; - break; - } - if(*p=='-' && *(p+2)==0) - { - if(*++p == 'o') - { - if(flag==2) - { - ap--; - break; - } - r |= expr(3); - continue; - } - else if(*p == 'a') - { - r &= expr(2); - continue; - } - } - if(flag==0) - break; - error(ERROR_exit(2),e_badsyntax); - } - return(r); -} - -static char *nxtarg __PARAM__((int mt), (mt)) __OTORP__(int mt;){ - if(ap >= ac) - { - if(mt) - { - ap++; - return(0); - } - error(ERROR_exit(2),e_argument); - } - return(av[ap++]); -} - - -static int e3 __PARAM__((void), ()){ - char *arg, *cp; - int op; - char *binop; - arg=nxtarg(0); - if(c_eq(arg, '!')) - return(!e3()); - if(c_eq(arg, '(')) - { - op = expr(1); - cp = nxtarg(0); - if(!c_eq(cp, ')')) - error(ERROR_exit(2),e_missing,"')'"); - return(op); - } - cp = nxtarg(1); - if(cp!=0 && (c_eq(cp,'=') || c2_eq(cp,'!','='))) - goto skip; - if(c2_eq(arg,'-','t')) - { - if(cp && isdigit(*cp)) - return(*(cp+1)?0:tty_check(*cp-'0')); - else - { - /* test -t with no arguments */ - ap--; - return(tty_check(1)); - } - } - if(*arg=='-' && arg[2]==0) - { - op = arg[1]; - if(!cp) - { - /* for backward compatibility with new flags */ - if(op==0 || !strchr(test_opchars+10,op)) - return(1); - error(ERROR_exit(2),e_argument); - } - if(strchr(test_opchars,op)) - return(test_unop(op,cp)); - } - if(!cp) - { - ap--; - return(*arg!=0); - } -skip: - op = sh_lookup(binop=cp,shtab_testops); - if(!(op&TEST_BINOP)) - cp = nxtarg(0); - if(!op) - error(ERROR_exit(2),e_badop,binop); - return(test_binop(op,arg,cp)); -} - -int test_unop __PARAM__((int op,const char *arg), (op, arg)) __OTORP__(int op;const char *arg;){ - switch(op) - { - case 'r': - return(permission(arg, R_OK)); - case 'w': - return(permission(arg, W_OK)); - case 'x': - return(permission(arg, X_OK)); - case 'V': -#ifdef SHOPT_FS_3D - { - int offset = staktell(); - if(stat(arg,&statb)<0 || !S_ISREG(statb.st_mode)) - return(0); - /* add trailing / */ - stakputs(arg); - stakputc('/'); - stakputc(0); - arg = (const char*)stakptr(offset); - stakseek(offset); - /* FALL THRU */ - } -#else - return(0); -#endif /* SHOPT_FS_3D */ - case 'd': - return(test_stat(arg,&statb)>=0 && S_ISDIR(statb.st_mode)); - case 'c': - return(test_stat(arg,&statb)>=0 && S_ISCHR(statb.st_mode)); - case 'b': - return(test_stat(arg,&statb)>=0 && S_ISBLK(statb.st_mode)); - case 'f': - return(test_stat(arg,&statb)>=0 && S_ISREG(statb.st_mode)); - case 'u': - return(test_mode(arg)&S_ISUID); - case 'g': - return(test_mode(arg)&S_ISGID); - case 'k': -#ifdef S_ISVTX - return(test_mode(arg)&S_ISVTX); -#else - return(0); -#endif /* S_ISVTX */ - case 'L': - case 'h': /* undocumented, and hopefully will disappear */ - { - struct stat statb; - if(*arg==0 || lstat(arg,&statb)<0) - return(0); - return(S_ISLNK(statb.st_mode)); - } - - case 'C': -#ifdef S_ISCTG - return(test_stat(arg,&statb)>=0 && S_ISCTG(statb.st_mode)); -#else - return(0); -#endif /* S_ISCTG */ - case 'H': -#ifdef S_ISCDF - { - int offset = staktell(); - if(test_stat(arg,&statb)>=0 && S_ISCDF(statb.st_mode)) - return(1); - stakputs(arg); - stakputc('+'); - stakputc(0); - arg = (const char*)stakptr(offset); - stakseek(offset); - return(test_stat(arg,&statb)>=0 && S_ISCDF(statb.st_mode)); - } -#else - return(0); -#endif /* S_ISCDF */ - - case 'S': -#ifdef S_ISSOCK - return(test_stat(arg,&statb)>=0 && S_ISSOCK(statb.st_mode)); -#else - return(0); -#endif /* S_ISSOCK */ - case 'p': - return(test_stat(arg,&statb)>=0 && S_ISFIFO(statb.st_mode)); - case 'n': - return(*arg != 0); - case 'z': - return(*arg == 0); - case 's': - case 'O': - case 'G': - { - struct stat statb; - if(*arg==0 || test_stat(arg,&statb)<0) - return(0); - if(op=='s') - return(statb.st_size>0); - else if(op=='O') - return(statb.st_uid==sh.userid); - return(statb.st_gid==sh.groupid); - } - case 'a': - case 'e': - return(permission(arg, F_OK)); - case 'o': - op = sh_lookup(arg,shtab_options); - return(op && sh_isoption((1L<0); - case TEST_SLT: - return(strcoll(left, right)<0); - case TEST_SEQ: - return(strcmp(left, right)==0); - case TEST_SNE: - return(strcmp(left, right)!=0); - case TEST_EF: - return(test_inode(left,right)); - case TEST_NT: - return(test_time(left,right)>0); - case TEST_OT: - return(test_time(left,right)<0); - case TEST_EQ: - return(lnum==rnum); - case TEST_NE: - return(lnum!=rnum); - case TEST_GT: - return(lnum>rnum); - case TEST_LT: - return(lnum=rnum); - case TEST_LE: - return(lnum<=rnum); - } - /* NOTREACHED */ -} - -/* - * returns the modification time of f1 - modification time of f2 - */ - -static time_t test_time __PARAM__((const char *file1,const char *file2), (file1, file2)) __OTORP__(const char *file1;const char *file2;){ - struct stat statb1,statb2; - if(test_stat(file1,&statb1)<0) - statb1.st_mtime = 0; - if(test_stat(file2,&statb2)<0) - statb2.st_mtime = 0; - return(statb1.st_mtime-statb2.st_mtime); -} - -/* - * return true if inode of two files are the same - */ - -int test_inode __PARAM__((const char *file1,const char *file2), (file1, file2)) __OTORP__(const char *file1;const char *file2;){ - struct stat stat1,stat2; - if(test_stat(file1,&stat1)>=0 && test_stat(file2,&stat2)>=0) - if(stat1.st_dev == stat2.st_dev && stat1.st_ino == stat2.st_ino) - return(1); - return(0); -} - - -/* - * This version of access checks against effective uid/gid - * The static buffer statb is shared with test_mode. - */ - -int sh_access __PARAM__((const char *name, int mode), (name, mode)) __OTORP__(const char *name; int mode;){ - if(*name==0) - return(-1); - if(strmatch(name,(char*)e_devfdNN)) - return(sh_ioaccess(atoi(name+8),mode)); - /* can't use access function for execute permission with root */ - if(mode==X_OK && sh.euserid==0) - goto skip; - if(sh.userid==sh.euserid && sh.groupid==sh.egroupid) - return(access(name,mode)); -#ifdef _lib_setreuid - /* swap the real uid to effective, check access then restore */ - /* first swap real and effective gid, if different */ - if(sh.groupid==sh.euserid || setregid(sh.egroupid,sh.groupid)==0) - { - /* next swap real and effective uid, if needed */ - if(sh.userid==sh.euserid || setreuid(sh.euserid,sh.userid)==0) - { - mode = access(name,mode); - /* restore ids */ - if(sh.userid!=sh.euserid) - setreuid(sh.userid,sh.euserid); - if(sh.groupid!=sh.egroupid) - setregid(sh.groupid,sh.egroupid); - return(mode); - } - else if(sh.groupid!=sh.egroupid) - setregid(sh.groupid,sh.egroupid); - } -#endif /* _lib_setreuid */ -skip: - if(test_stat(name, &statb) == 0) - { - if(mode == F_OK) - return(mode); - else if(sh.euserid == 0) - { - if(!S_ISREG(statb.st_mode) || mode!=X_OK) - return(0); - /* root needs execute permission for someone */ - mode = (S_IXUSR|S_IXGRP|S_IXOTH); - } - else if(sh.euserid == statb.st_uid) - mode <<= 6; - else if(sh.egroupid == statb.st_gid) - mode <<= 3; -#ifdef _lib_getgroups - /* on some systems you can be in several groups */ - else - { - static int maxgroups = 0; - gid_t *groups; - int n; - if(maxgroups==0) - { - /* first time */ - if((maxgroups=getgroups(0, (gid_t *)NULL)) <= 0) - { - /* pre-POSIX system */ - maxgroups=NGROUPS_MAX; - } - } - groups = (gid_t*)stakalloc((maxgroups+1)*sizeof(gid_t)); - n = getgroups(maxgroups,groups); - while(--n >= 0) - { - if(groups[n] == statb.st_gid) - { - mode <<= 3; - break; - } - } - } -# endif /* _lib_getgroups */ - if(statb.st_mode & mode) - return(0); - } - return(-1); -} - -/* - * Return the mode bits of file - * If is null, then the previous stat buffer is used. - * The mode bits are zero if the file doesn't exist. - */ - -static int test_mode __PARAM__((const char *file), (file)) __OTORP__(const char *file;){ - if(file && (*file==0 || test_stat(file,&statb)<0)) - return(0); - return(statb.st_mode); -} - -/* - * do an fstat() for /dev/fd/n, otherwise stat() - */ -static int test_stat __PARAM__((const char *name,struct stat *buff), (name, buff)) __OTORP__(const char *name;struct stat *buff;){ - if(strmatch(name,(char*)e_devfdNN)) - return(fstat(atoi(name+8),buff)); - else - return(stat(name,buff)); -} diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/trap.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/trap.c deleted file mode 100644 index 2496bf819..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/trap.c +++ /dev/null @@ -1,391 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: trap.c /main/4 1996/08/16 15:31:57 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include "jobs.h" -#include "builtins.h" - -#define L_FLAG 1 -#define S_FLAG 2 - -static const char trapfmt[] = "trap -- %s %s\n"; - -static int sig_number __PROTO__((const char*)); -static void sig_list __PROTO__((int)); - -int b_trap __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - char *arg = argv[1]; - int sig, pflag = 0; - NOT_USED(argc); - NOT_USED(extra); - while (sig = optget(argv, sh_opttrap)) switch (sig) - { - case 'p': - pflag=1; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors) - error(ERROR_usage(2),optusage((char*)0)); - if(arg = *argv) - { - int clear; - char *action = arg; - if(!pflag) - { - /* first argument all digits or - means clear */ - while(isdigit(*arg)) - arg++; - clear = (arg!=action && *arg==0); - if(!clear) - { - ++argv; - if(*action=='-' && action[1]==0) - clear++; - } - while(!argv[0]) - error(ERROR_exit(1),e_condition); - } - while(arg = *argv++) - { - sig = sig_number(arg); - if(sig<0) - { - error(2,e_trap,arg); - return(1); - } - /* internal traps */ - if(sig&SH_TRAP) - { - sig &= ~SH_TRAP; - if(sig>SH_DEBUGTRAP) - { - error(2,e_trap,arg); - return(1); - } - if(pflag) - { - if(arg=sh.st.trap[sig]) - sfputr(sfstdout,sh_fmtq(arg),'\n'); - continue; - } - if(sh.st.trap[sig]) - free(sh.st.trap[sig]); - sh.st.trap[sig] = 0; - if(!clear && *action) - sh.st.trap[sig] = strdup(action); - if(sig == SH_DEBUGTRAP) - { - if(sh.st.trap[sig]) - sh.trapnote |= SH_SIGTRAP; - else - sh.trapnote = 0; - } - continue; - } - if(sig>sh.sigmax) - { - error(2,e_trap,arg); - return(1); - } - else if(pflag) - { - if(arg=sh.st.trapcom[sig]) - sfputr(sfstdout,sh_fmtq(arg),'\n'); - } - else if(clear) - sh_sigclear(sig); - else - { - if(sig >= sh.st.trapmax) - sh.st.trapmax = sig+1; - if(arg=sh.st.trapcom[sig]) - free(arg); - sh.st.trapcom[sig] = strdup(action); - sh_sigtrap(sig); - } - } - } - else /* print out current traps */ - sig_list(-1); - return(0); -} - -int b_kill __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - char *signame; - int sig=SIGTERM, flag=0, n; - NOT_USED(argc); - NOT_USED(extra); - while((n = optget(argv,sh_optkill))) switch(n) - { - case ':': - if((signame=argv[opt_index++]) && (sig=sig_number(signame+1))>=0) - { - if(argv[opt_index] && strcmp(argv[opt_index],"--")==0) - opt_index++; - goto endopts; - } - opt_index--; - error(2, opt_arg); - break; - case 'n': - sig = (int)opt_num; - break; - case 's': - flag |= S_FLAG; - signame = opt_arg; - break; - case 'l': - flag |= L_FLAG; - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } -endopts: - argv += opt_index; - if(error_info.errors || flag==(L_FLAG|S_FLAG) || (!(*argv) && !(flag&L_FLAG))) - error(ERROR_usage(2),optusage((char*)0)); - /* just in case we send a kill -9 $$ */ - sfsync(sfstderr); - if(flag&L_FLAG) - { - if(!(*argv)) - sig_list(0); - else while(signame = *argv++) - { - if(isdigit(*signame)) - sig_list((atoi(signame)&0177)+1); - else - { - if((sig=sig_number(signame))<0) - { - sh.exitval = 2; - error(ERROR_exit(1),e_nosignal,signame); - } - sfprintf(sfstdout,"%d\n",sig); - } - } - return(sh.exitval); - } - if(flag&S_FLAG) - { - if((sig=sig_number(signame)) < 0 || sig > sh.sigmax) - error(ERROR_exit(1),e_nosignal,signame); - } - if(job_walk(sfstdout,job_kill,sig,argv)) - sh.exitval = 1; - return(sh.exitval); -} - -/* - * Given the name or number of a signal return the signal number - */ - -static int sig_number __PARAM__((const char *string), (string)) __OTORP__(const char *string;){ - int n; - char *last; - if(isdigit(*string)) - { - n = strtol(string,&last,10); - if(*last) - n = -1; - } - else - { - int c; - n = staktell(); - do - { - c = *string++; - if(islower(c)) - c = toupper(c); - stakputc(c); - } - while(c); - stakseek(n); - init_shtab_signals(); - n = sh_lookup(stakptr(n),shtab_signals); - n &= (1< is positive, then print signal name corresponding to - * if is zero, then print all signal names - * if is negative, then print all traps - */ -static void sig_list __PARAM__((int flag), (flag)) __OTORP__(int flag;){ - const struct shtable2 *tp; - int sig = sh.sigmax+1; - const char *names[SH_TRAP]; - const char *traps[SH_DEBUGTRAP+1]; - - init_shtab_signals(); - - tp=shtab_signals; - if(flag==0) - { - /* not all signals may be defined, so initialize */ - while(--sig >= 0) - names[sig] = 0; - for(sig=SH_DEBUGTRAP; sig>=0; sig--) - traps[sig] = 0; - } - while(*tp->sh_name) - { - sig = tp->sh_number; - sig &= ((1<sh_name); - return; - } - else if(sig&SH_TRAP) - traps[sig&~SH_TRAP] = (char*)tp->sh_name; - else if(sig < sizeof(names)/sizeof(char*)) - names[sig] = (char*)tp->sh_name; - tp++; - } - if(flag > 0) - sfprintf(sfstdout,"%d\n",flag-1); - else if(flag<0) - { - /* print the traps */ - char *trap,*sname,**trapcom; - sig = sh.st.trapmax; - /* use parent traps if otrapcom is set (for $(trap) */ - trapcom = (sh.st.otrapcom?sh.st.otrapcom:sh.st.trapcom); - while(--sig >= 0) - { - if(!(trap=trapcom[sig])) - continue; - if(!(sname=(char*)names[sig+1])) - { - sname="SIG??"; - sname[3] = (sig/10)+'0'; - sname[4] = (sig%10)+'0'; - } - sfprintf(sfstdout,trapfmt,sh_fmtq(trap),sname); - } - for(sig=SH_DEBUGTRAP; sig>=0; sig--) - { - if(!(trap=sh.st.trap[sig])) - continue; - sfprintf(sfstdout,trapfmt,sh_fmtq(trap),traps[sig]); - } - } - else - { - /* print all the signal names */ - for(sig=2; sig <= sh.sigmax; sig++) - { - if(names[sig]) - sfputr(sfstdout,names[sig],'\n'); - else - sfprintf(sfstdout,"SIG%d\n",sig-1); - } - } -} - diff --git a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/typeset.c b/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/typeset.c deleted file mode 100644 index 69f967aee..000000000 --- a/cde/programs/dtksh/ksh93/src/cmd/ksh93/bltins/typeset.c +++ /dev/null @@ -1,1158 +0,0 @@ -/* - * CDE - Common Desktop Environment - * - * Copyright (c) 1993-2012, The Open Group. All rights reserved. - * - * These libraries and programs are free software; you can - * redistribute them and/or modify them under the terms of the GNU - * Lesser General Public License as published by the Free Software - * Foundation; either version 2 of the License, or (at your option) - * any later version. - * - * These libraries and programs are distributed in the hope that - * they will be useful, but WITHOUT ANY WARRANTY; without even the - * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - * PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with these libraries and programs; if not, write - * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth - * Floor, Boston, MA 02110-1301 USA - */ -/* $XConsortium: typeset.c /main/3 1995/11/01 16:30:25 rswiston $ */ -/*************************************************************** -* * -* AT&T - PROPRIETARY * -* * -* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF * -* AT&T BELL LABORATORIES * -* AND IS NOT TO BE DISCLOSED OR USED EXCEPT IN * -* ACCORDANCE WITH APPLICABLE AGREEMENTS * -* * -* Copyright (c) 1995 AT&T Corp. * -* Unpublished & Not for Publication * -* All Rights Reserved * -* * -* The copyright notice above does not evidence any * -* actual or intended publication of such source code * -* * -* This software was created by the * -* Advanced Software Technology Department * -* AT&T Bell Laboratories * -* * -* For further information contact * -* {research,attmail}!dgk * -* * -***************************************************************/ - -/* : : generated by proto : : */ - -#if !defined(__PROTO__) -#if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) -#if defined(__cplusplus) -#define __MANGLE__ "C" -#else -#define __MANGLE__ -#endif -#define __STDARG__ -#define __PROTO__(x) x -#define __OTORP__(x) -#define __PARAM__(n,o) n -#if !defined(__STDC__) && !defined(__cplusplus) -#if !defined(c_plusplus) -#define const -#endif -#define signed -#define void int -#define volatile -#define __V_ char -#else -#define __V_ void -#endif -#else -#define __PROTO__(x) () -#define __OTORP__(x) x -#define __PARAM__(n,o) o -#define __MANGLE__ -#define __V_ char -#define const -#define signed -#define void int -#define volatile -#endif -#if defined(__cplusplus) || defined(c_plusplus) -#define __VARARG__ ... -#else -#define __VARARG__ -#endif -#if defined(__STDARG__) -#define __VA_START__(p,a) va_start(p,a) -#else -#define __VA_START__(p,a) va_start(p) -#endif -#endif -#include "defs.h" -#include -#include "path.h" -#include "name.h" -#include "history.h" -#include "builtins.h" -#include "variables.h" - -/* use these prototyped because dlhdr.h may be wrong */ -extern __MANGLE__ __V_ *dlopen __PROTO__((const char*,int)); -extern __MANGLE__ __V_ *dlsym __PROTO__((__V_*, const char*)); -extern __MANGLE__ char *dlerror __PROTO__((void)); -#define DL_MODE 1 - -static int print_namval __PROTO__((Sfio_t*, Namval_t*, int)); -static void print_attribute __PROTO__((Namval_t*)); -static void print_all __PROTO__((Sfio_t*, Hashtab_t*)); -static void print_scan __PROTO__((Sfio_t*, int, Hashtab_t*, int)); -static int b_unall __PROTO__((int, char**, Hashtab_t*)); -static int b_common __PROTO__((char**, int, Hashtab_t*)); -static void pushname __PROTO__((Namval_t*)); -static void unref __PROTO__((Namval_t*)); -static char **argnam; -static int argnum; -static int aflag; -static int scanmask; -static Hashtab_t *scanroot; -static Sfio_t *outfile; -static void(*nullscan) __PROTO__((Namval_t*)); -static char *prefix; - -static char *get_tree __PROTO__((Namval_t*, Namfun_t *)); -static void put_tree __PROTO__((Namval_t*, const char*, int,Namfun_t*)); - -static const Namdisc_t treedisc = -{ - 0, - put_tree, - get_tree -}; - - -/* - * The following few builtins are provided to set,print, - * and test attributes and variables for shell variables, - * aliases, and functions. - * In addition, typeset -f can be used to test whether a - * function has been defined or to list all defined functions - * Note readonly is same as typeset -r. - * Note export is same as typeset -x. - */ - -int b_read_export __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - int flag; - char *command = argv[0]; - NOT_USED(argc); - NOT_USED(extra); - aflag = '-'; - argnum = 0; - prefix = 0; - while((flag = optget(argv,sh_optexport))) switch(flag) - { - case 'p': - prefix = command; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(error_info.errors) - error(ERROR_usage(2),optusage(NIL(char*))); - argv += (opt_index-1); - if(*command=='r') - flag = (NV_ASSIGN|NV_RDONLY|NV_VARNAME); - else - flag = (NV_ASSIGN|NV_EXPORT|NV_IDENT); - if(*argv) - return(b_common(argv,flag,sh.var_tree)); - print_scan(sfstdout,flag,sh.var_tree,aflag=='+'); - return(0); -} - - -int b_alias __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - unsigned flag = NV_ARRAY|NV_NOSCOPE|NV_ASSIGN; - Hashtab_t *troot = sh.alias_tree; - int n; - NOT_USED(argc); - NOT_USED(extra); - prefix=0; - if(*argv[0]=='h') - flag = NV_TAGGED; - if(argv[1]) - { - opt_char = 0; - opt_index = 1; - *opt_option = 0; - argnum = 0; - aflag = *argv[1]; - while((n = optget(argv,sh_optalias))) switch(n) - { - case 'p': - prefix = argv[0]; - break; - case 't': - flag |= NV_TAGGED; - break; - case 'x': - flag |= NV_EXPORT; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(error_info.errors) - error(ERROR_usage(2),optusage(NIL(char*))); - argv += (opt_index-1); - if(flag&NV_TAGGED) - { - if(argv[1] && strcmp(argv[1],"-r")==0) - { - /* hack to handle hash -r */ - nv_putval(PATHNOD,nv_getval(PATHNOD),NV_RDONLY); - return(0); - } - troot = sh.track_tree; - } - } - return(b_common(argv,flag,troot)); -} - - -int b_typeset __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - int flag = NV_VARNAME|NV_ASSIGN; - int n; - Hashtab_t *troot = sh.var_tree; - int isfloat = 0; - NOT_USED(argc); - NOT_USED(extra); - aflag = argnum = 0; - prefix = 0; - while((n = optget(argv,sh_opttypeset))) - { - switch(n) - { - case 'A': - flag |= NV_ARRAY; - break; - case 'E': - /* The following is for ksh88 compatibility */ - if(opt_char && !strchr(argv[opt_index],'E')) - { - argnum = (int)opt_num; - break; - } - case 'F': - if(!opt_arg || (argnum = opt_num) <0) - argnum = 10; - isfloat = 1; - if(n=='E') - flag |= NV_EXPNOTE; - break; - case 'n': - flag &= ~NV_VARNAME; - flag |= (NV_REF|NV_IDENT); - break; - case 'H': - flag |= NV_HOST; - break; -#ifdef SHOPT_OO - case 'C': - prefix = opt_arg; - flag |= NV_IMPORT; - break; -#endif /* SHOPT_OO */ - case 'L': - if(argnum==0) - argnum = (int)opt_num; - if(argnum < 0) - error(ERROR_exit(1), e_badfield, argnum); - flag |= NV_LJUST; - break; - case 'Z': - flag |= NV_ZFILL; - /* FALL THRU*/ - case 'R': - if(argnum==0) - argnum = (int)opt_num; - if(argnum < 0) - error(ERROR_exit(1), e_badfield, argnum); - flag |= NV_RJUST; - break; - case 'f': - flag &= ~(NV_VARNAME|NV_ASSIGN); - troot = sh.fun_tree; - break; - case 'i': - if(!opt_arg || (argnum = opt_num) <0) - argnum = 1; - flag |= NV_INTEGER; - break; - case 'l': - flag |= NV_UTOL; - break; - case 'p': - prefix = argv[0]; - continue; - case 'r': - flag |= NV_RDONLY; - break; - case 't': - flag |= NV_TAGGED; - break; - case 'u': - flag |= NV_LTOU; - break; - case 'x': - flag &= ~NV_VARNAME; - flag |= (NV_EXPORT|NV_IDENT); - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - if(aflag==0) - aflag = *opt_option; - } - argv += opt_index; - /* handle argument of + and - specially */ - if(*argv && argv[0][1]==0 && (*argv[0]=='+' || *argv[0]=='-')) - aflag = *argv[0]; - else - argv--; - if((flag&NV_INTEGER) && (flag&(NV_LJUST|NV_RJUST|NV_ZFILL))) - error_info.errors++; - if(troot==sh.fun_tree && ((isfloat || flag&~(NV_FUNCT|NV_TAGGED|NV_EXPORT|NV_LTOU)))) - error_info.errors++; - if(error_info.errors) - error(ERROR_usage(2),optusage(NIL(char*))); - if(isfloat) - flag |= NV_INTEGER|NV_DOUBLE; - if(sh.fn_depth) - flag |= NV_NOSCOPE; - return(b_common(argv,flag,troot)); -} - -static int b_common __PARAM__((char **argv,int flag,Hashtab_t *troot), (argv, flag, troot)) __OTORP__(char **argv;int flag;Hashtab_t *troot;){ - char *name; - int nvflags=(flag&(NV_ARRAY|NV_NOSCOPE|NV_VARNAME|NV_IDENT|NV_ASSIGN)); - int r=0, ref=0; -#ifdef SHOPT_OO - char *base=0; - if(flag&NV_IMPORT) - { - if(!argv[1]) - error(ERROR_exit(1),"requires arguments"); - if(aflag!='-') - error(ERROR_exit(1),"cannot be unset"); - base = prefix; - prefix = 0; - flag &= ~(NV_IMPORT|NV_ASSIGN); - } -#endif /* SHOPT_OO */ - flag &= ~(NV_ARRAY|NV_NOSCOPE|NV_VARNAME|NV_IDENT); - if(argv[1]) - { - if(flag&NV_REF) - { - flag &= ~NV_REF; - ref=1; - if(aflag!='-') - nvflags |= NV_REF; - } - while(name = *++argv) - { - unsigned newflag; - Namval_t *np; - unsigned curflag; - if(troot == sh.fun_tree) - { - /* - *functions can be exported or - * traced but not set - */ - if(flag&NV_LTOU) - { - /* Function names cannot be special builtin */ - if((np=nv_search(name,sh.bltin_tree,0)) && nv_isattr(np,BLT_SPC)) - error(ERROR_exit(1),e_badfun,name); - np = nv_open(name,sh.fun_tree,NV_ARRAY|NV_IDENT|NV_NOSCOPE); - } - else - np = nv_search(name,sh.fun_tree,HASH_NOSCOPE); - if(np && ((flag&NV_LTOU) || !nv_isnull(np) || nv_isattr(np,NV_LTOU))) - { - if(flag==0) - { - print_namval(sfstdout,np,0); - continue; - } - if(sh.subshell) - sh_subfork(); - if(aflag=='-') - nv_onattr(np,flag|NV_FUNCTION); - else if(aflag=='+') - nv_offattr(np,flag); - } - else - r++; - continue; - } - np = nv_open(name,troot,nvflags); - /* tracked alias */ - if(troot==sh.track_tree && aflag=='-') - { - nv_onattr(np,NV_NOALIAS); - path_alias(np,path_absolute(nv_name(np),NIL(char*))); - continue; - } - if(flag==NV_ASSIGN && !ref && aflag!='-' && !strchr(name,'=')) - { - if(troot!=sh.var_tree && (nv_isnull(np) || !print_namval(sfstdout,np,0))) - { - sfprintf(sfstderr,e_noalias,name); - r++; - } - continue; - } - if(troot==sh.var_tree && (nvflags&NV_ARRAY)) - nv_setarray(np,nv_associative); -#ifdef SHOPT_OO - if(base) - { - Namval_t *nq, *nr; - nv_offattr(np,NV_IMPORT); - if(!(nq=nv_search(base,troot,0))) - error(ERROR_exit(1),e_badbase,base); - /* check for loop */ - for(nr=nq; nr; nr = nv_class(nr)) - { - if(nr==np) - error(ERROR_exit(1),e_loop,base); - } - np->nvenv = (char*)nq; - if(nq->nvfun && (nq->nvfun)->disc->create) - (*(nq->nvfun)->disc->create)(np,0,nq->nvfun); - } -#endif /* SHOPT_OO */ - curflag = np->nvflag; - if (aflag == '-') - { - if((flag&NV_EXPORT) && strchr(nv_name(np),'.')) - error(ERROR_exit(1),e_badexport,nv_name(np)); -#ifdef SHOPT_BSH - if(flag&NV_EXPORT) - nv_offattr(np,NV_IMPORT); -#endif /* SHOPT_BSH */ - newflag = curflag; - if(flag&~NV_NOCHANGE) - newflag &= NV_NOCHANGE; - newflag |= flag; - if (flag & (NV_LJUST|NV_RJUST)) - { - if (flag & NV_LJUST) - newflag &= ~NV_RJUST; - else - newflag &= ~NV_LJUST; - } - if (flag & NV_UTOL) - newflag &= ~NV_LTOU; - else if (flag & NV_LTOU) - newflag &= ~NV_UTOL; - } - else - { - if((flag&NV_RDONLY) && (curflag&NV_RDONLY)) - error(ERROR_exit(1),e_readonly,nv_name(np)); - newflag = curflag & ~flag; - } - if (aflag && (argnum>0 || (curflag!=newflag))) - { - if(sh.subshell) - sh_assignok(np,1); - if(troot!=sh.var_tree) - nv_setattr(np,newflag); - else - nv_newattr (np, newflag,argnum); - } - /* set or unset references */ - if(ref) - { - if(aflag=='-') - nv_setref(np); - else - unref(np); - } - nv_close(np); - } - } - else - { - if(aflag) - { - if(troot==sh.fun_tree) - { - flag |= NV_FUNCTION; - prefix = 0; - } - else if(troot==sh.var_tree) - flag |= (nvflags&NV_ARRAY); - print_scan(sfstdout,flag,troot,aflag=='+'); - } - else if(troot==sh.alias_tree) - print_scan(sfstdout,0,troot,0); - else - print_all(sfstdout,troot); - } - return(r); -} - -typedef int (*Fptr_t) __PROTO__((int, char*[], __V_*)); - -#define GROWLIB 4 -static __V_ **liblist; - -/* - * This allows external routines to load from the same library */ -__V_ **sh_getliblist __PARAM__((void), ()){ - return(liblist); -} - -/* - * add change or list built-ins - * adding builtins requires dlopen() interface - */ -int b_builtin __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - char *arg=0, *name; - int n, r=0, flag=0; - Namval_t *np; - int dlete=0; - static int maxlib, nlib; - Fptr_t addr; - __V_ *library=0; - char *errmsg; - NOT_USED(argc); - NOT_USED(extra); - while (n = optget(argv,sh_optbuiltin)) switch (n) - { - case 's': - flag = BLT_SPC; - break; - case 'd': - dlete=1; - break; - case 'f': -#ifdef SHOPT_DYNAMIC - arg = opt_arg; -#else - error(2, "adding built-ins not supported"); - error_info.errors++; -#endif /* SHOPT_DYNAMIC */ - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(2), opt_arg); - break; - } - argv += opt_index; - if(error_info.errors) - error(ERROR_usage(2),optusage(NIL(char*))); - if(arg || *argv) - { - if(sh_isoption(SH_RESTRICTED)) - error(ERROR_exit(1),e_restricted,argv[-opt_index]); - if(sh.subshell) - sh_subfork(); - } - if(arg) - { - if(!(library = dlopen(arg,DL_MODE))) - { - error(ERROR_exit(0),"%s: %s",arg,dlerror()); - return(1); - } - /* - * see if library is already on search list - * if it is, move to head of search list - */ - for(n=r=0; n < nlib; n++) - { - if(r) - liblist[n-1] = liblist[n]; - else if(liblist[n]==library) - r++; - } - if(r) - nlib--; - if(nlib >= maxlib) - { - /* add library to search list */ - maxlib += GROWLIB; - if(nlib>0) - liblist = (__V_**)realloc((__V_*)liblist,(maxlib+1)*sizeof(__V_**)); - else - liblist = (__V_**)malloc((maxlib+1)*sizeof(__V_**)); - } - liblist[nlib++] = library; - liblist[nlib] = 0; - } - else if(*argv==0 && !dlete) - { - print_scan(sfstdout, flag, sh.bltin_tree, 1); - return(0); - } - r = 0; - flag = staktell(); - while(arg = *argv) - { - name = path_basename(arg); - stakputs("b_"); - stakputs(name); - errmsg = 0; - addr = 0; - for(n=(nlib?nlib:dlete); --n>=0;) - { - /* (char*) added for some sgi-mips compilers */ - if(dlete || (addr = (Fptr_t)dlsym(liblist[n],stakptr(flag)))) - { - if(sh_addbuiltin(arg, addr,0) < 0) - errmsg = "restricted name"; - else - errmsg = 0; - break; - } - } - if(!dlete && !addr) - { - if(np=nv_search(name,sh.bltin_tree,0)) - { - if(sh_addbuiltin(arg, np->nvalue.bfp,0) < 0) - errmsg = "restricted name"; - } - else - errmsg = "not found"; - } - if(errmsg) - { - error(ERROR_exit(0),"%s: %s",*argv,errmsg); - r = 1; - } - stakseek(flag); - argv++; - } - return(r); -} - -int b_set __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - NOT_USED(extra); - prefix=0; - if(argv[1]) - { - if(sh_argopts(argc,argv) < 0) - return(2); - sh_offstate(SH_VERBOSE|SH_MONITOR); - sh_onstate(sh_isoption(SH_VERBOSE|SH_MONITOR)); - } - else - /*scan name chain and print*/ - print_scan(sfstdout,0,sh.var_tree,0); - return(0); -} - -/* - * The removing of Shell variable names, aliases, and functions - * is performed here. - * Unset functions with unset -f - * Non-existent items being deleted give non-zero exit status - */ - -int b_unalias __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - NOT_USED(extra); - return(b_unall(argc,argv,sh.alias_tree)); -} - -int b_unset __PARAM__((int argc,char *argv[],__V_ *extra), (argc, argv, extra)) __OTORP__(int argc;char *argv[];__V_ *extra;){ - NOT_USED(extra); - return(b_unall(argc,argv,sh.var_tree)); -} - -static int b_unall __PARAM__((int argc, char **argv, Hashtab_t *troot), (argc, argv, troot)) __OTORP__(int argc; char **argv; Hashtab_t *troot;){ - Namval_t *np; - struct slnod *slp; - const char *name; - int r; - int nflag = 0; - int all=0; - NOT_USED(argc); - if(troot!=sh.var_tree && sh.subshell) - sh_subfork(); - if(troot==sh.alias_tree) - name = sh_optunalias; - else - name = sh_optunset; - while(r = optget(argv,name)) switch(r) - { - case 'f': - troot = sh.fun_tree; - break; - case 'a': - all=1; - break; - case 'n': - nflag = NV_NOREF; - case 'v': - troot = sh.var_tree; - break; - case ':': - error(2, opt_arg); - break; - case '?': - error(ERROR_usage(0), opt_arg); - return(2); - } - argv += opt_index; - if(error_info.errors || (*argv==0 &&!all)) - error(ERROR_usage(2),optusage(NIL(char*))); - r = 0; - if(troot==sh.var_tree) - nflag |= NV_VARNAME; - if(all) - { - hashfree(troot); - sh.alias_tree = hashalloc(sh.var_tree,HASH_set,HASH_ALLOCATE,0); - } - else while(name = *argv++) - { - if(np=nv_open(name,troot,NV_NOADD|nflag)) - { - if(troot!=sh.var_tree) - { - if(is_abuiltin(np)) - { - r = 1; - continue; - } - else if(slp=(struct slnod*)(np->nvenv)) - { - /* free function definition */ - char *cp= strrchr(name,'.'); - if(cp) - { - Namval_t *npv; - *cp = 0; - npv = nv_open(name,sh.var_tree,NV_ARRAY|NV_VARNAME|NV_NOADD); - *cp++ = '.'; - if(npv) - nv_setdisc(npv,cp,NIL(Namval_t*),(Namfun_t*)npv); - } - stakdelete(slp->slptr); - np->nvenv = 0; - hashlook(troot,(char*)np,HASH_DELETE|HASH_BUCKET,(char*)0); - continue; - } - } - - if(sh.subshell) - np=sh_assignok(np,0); - nv_unset(np); - nv_close(np); - } - else - r = 1; - } - return(r); -} - - - -/* - * print out the name and value of a name-value pair - */ - -static int print_namval __PARAM__((Sfio_t *file,Namval_t *np,int flag), (file, np, flag)) __OTORP__(Sfio_t *file;Namval_t *np;int flag;){ - char *cp; - sh_sigcheck(); - if(flag) - flag = '\n'; - if(nv_isattr(np,NV_NOPRINT)==NV_NOPRINT) - { - if(is_abuiltin(np)) - sfputr(file,np->nvenv?np->nvenv:nv_name(np),'\n'); - return(0); - } - if(prefix) - sfputr(file,prefix,' '); - if(is_afunction(np)) - { - if(!flag && !np->nvalue.ip) - sfputr(file,"typeset -fu",' '); - else if(!flag && !nv_isattr(np,NV_FPOSIX)) - sfputr(file,"function",' '); - if(!np->nvalue.ip || np->nvalue.rp->hoffset<0) - flag = '\n'; - sfputr(file,nv_name(np),flag?flag:-1); - if(!flag) - { - sfputr(file,nv_isattr(np,NV_FPOSIX)?"()\n{":"\n{",'\n'); - hist_list(sh.hist_ptr,file,np->nvalue.rp->hoffset,0,"\n"); - } - return(nv_size(np)+1); - } - if(cp=nv_getval(np)) - { - Namarr_t *ap; - sfputr(file,sh_fmtq(nv_name(np)),-1); - if(!flag) - { - flag = '='; - if(ap = nv_arrayptr(np)) - sfprintf(file,"[%s]", sh_fmtq(nv_getsub(np))); - } - sfputc(file,flag); - if(flag != '\n') - sfputr(file,sh_fmtq(cp),'\n'); - return(1); - } - else if(scanmask && scanroot==sh.var_tree) - sfputr(file,nv_name(np),'\n'); - return(0); -} - -/* - * print attributes at all nodes - */ - -static void print_all __PARAM__((Sfio_t *file,Hashtab_t *root), (file, root)) __OTORP__(Sfio_t *file;Hashtab_t *root;){ - outfile = file; - nv_scan(root, print_attribute, 0, 0); -} - -#include -#include "argnod.h" - -/* - * format initialization list given a list of assignments - */ -static void genvalue __PARAM__((struct argnod *argp, const char *prefix, int n, int indent), (argp, prefix, n, indent)) __OTORP__(struct argnod *argp; const char *prefix; int n; int indent;){ - struct argnod *ap; - char *cp,*nextcp; - int m,isarray; - Namval_t *np; - if(n==0) - m = strlen(prefix); - else - m = strchr(prefix,'.')-prefix; - m++; - if(outfile) - { - sfwrite(outfile,"(\n",2); - indent++; - } - for(ap=argp; ap; ap=ap->argchn.ap) - { - if(ap->argflag==ARG_MAC) - continue; - cp = ap->argval+n; - if(n==0 && cp[m-1]!='.') - { - ap->argflag = ARG_MAC; - continue; - } - if(n && cp[n-1]==0) - continue; - if(n==0 || strncmp(ap->argval,prefix-n,m+n)==0) - { - cp +=m; - if(nextcp=strchr(cp,'.')) - { - if(outfile) - { - sfnputc(outfile,'\t',indent); - sfwrite(outfile,cp,nextcp-cp); - sfputc(outfile,'='); - } - genvalue(argp,cp,n+m ,indent); - if(outfile) - sfputc(outfile,'\n'); - continue; - } - ap->argflag = ARG_MAC; - if(!(np=nv_search(ap->argval,sh.var_tree,0))) - continue; - if(np->nvfun && np->nvfun->disc== &treedisc) - continue; - isarray=0; - if(nv_isattr(np,NV_ARRAY)) - { - nv_putsub(np,NIL(char*),ARRAY_SCAN); - isarray=1; - } - if(!outfile) - { - nv_close(np); - continue; - } - sfnputc(outfile,'\t',indent); - if(nv_isattr(np,~NV_DEFAULT)) - print_attribute(np); - sfputr(outfile,cp,'='); - if(isarray) - { - sfwrite(outfile,"(\n",2); - sfnputc(outfile,'\t',++indent); - } - while(1) - { - if(isarray) - { - sfprintf(outfile,"[%s]",sh_fmtq(nv_getsub(np))); - sfputc(outfile,'='); - } - sfputr(outfile,sh_fmtq(nv_getval(np)),'\n'); - if(!ap || !nv_nextsub(np)) - break; - sfnputc(outfile,'\t',indent); - } - if(isarray) - { - sfnputc(outfile,'\t',--indent); - sfwrite(outfile,")\n",2); - } - } - } - if(outfile) - { - if(indent > 1) - sfnputc(outfile,'\t',indent-1); - sfputc(outfile,')'); - } -} - -/* - * walk the virtual tree and print or delete name-value pairs - */ -static char *walk_tree __PARAM__((Namval_t *np, int dlete), (np, dlete)) __OTORP__(Namval_t *np; int dlete;){ - static Sfio_t *out; - int n; - Fcin_t save; - int savtop = staktell(); - char *savptr = stakfreeze(0); - struct argnod *ap; - struct argnod *arglist=0; - char *name = nv_name(np); - stakseek(ARGVAL); - stakputs("\"${!"); - stakputs(name); - stakputs("@}\""); - ap = (struct argnod*)stakfreeze(1); - ap->argflag = ARG_MAC; - fcsave(&save); - n = sh_macexpand(ap,&arglist); - fcrestore(&save); - ap = arglist; - if(dlete) - outfile = 0; - else if(!(outfile=out)) - outfile = out = sfnew((Sfio_t*)0,(char*)0,-1,-1,SF_WRITE|SF_STRING); - else - sfseek(outfile,0L,SEEK_SET); - prefix = "typeset"; - aflag = '='; - genvalue(ap,name,0,0); - stakset(savptr,savtop); - if(!outfile) - return((char*)0); - sfputc(out,0); - return((char*)out->data); -} - -/* - * get discipline for compound initializations - */ -static char *get_tree __PARAM__((Namval_t *np, Namfun_t *fp), (np, fp)) __OTORP__(Namval_t *np; Namfun_t *fp;){ - NOT_USED(fp); - return(walk_tree(np,0)); -} - -/* - * put discipline for compound initializations - */ -static void put_tree __PARAM__((Namval_t *np, const char *val, int flags,Namfun_t *fp), (np, val, flags, fp)) __OTORP__(Namval_t *np; const char *val; int flags;Namfun_t *fp;){ - walk_tree(np,1); - if(fp = nv_stack(np,NIL(Namfun_t*))) - { - free((__V_*)fp); - if(np->nvalue.cp && !nv_isattr(np,NV_NOFREE)) - free((__V_*)np->nvalue.cp); - } - if(val) - nv_putval(np,val,flags); -} - -/* - * Insert discipline to cause $x to print current tree - */ -void nv_setvtree __PARAM__((Namval_t *np), (np)) __OTORP__(Namval_t *np;){ - Namfun_t *nfp = newof(NIL(__V_*),Namfun_t,1,0); - nfp->disc = &treedisc; - nv_stack(np, nfp); -} - -/* - * print the attributes of name value pair give by - */ -static void print_attribute __PARAM__((Namval_t *np), (np)) __OTORP__(Namval_t *np;){ - const Shtable_t *tp; - char *cp; - unsigned val; - unsigned mask; -#ifdef SHOPT_OO - Namval_t *nq; - char *cclass=0; -#endif /* SHOPT_OO */ - if (nv_isattr(np,~NV_DEFAULT)) - { - if(prefix) - sfputr(outfile,prefix,' '); - for(tp = shtab_attributes; *tp->sh_name;tp++) - { - val = tp->sh_number; - mask = val; - if(val&NV_INTEGER) - mask |= NV_DOUBLE; - if(nv_isattr(np,mask)==val) - { - if(val==NV_ARRAY) - { - Namarr_t *ap = nv_arrayptr(np); - if(array_assoc(ap)) - cp = "associative"; - else - cp = "indexed"; - if(!prefix) - sfputr(outfile,cp,' '); - else if(*cp=='i') - continue; - } - if(prefix) - { - if(*tp->sh_name=='-') - sfprintf(outfile,"%.2s ",tp->sh_name); - } - else - sfputr(outfile,tp->sh_name+2,' '); - if ((val&(NV_LJUST|NV_RJUST|NV_ZFILL)) && !(val&NV_INTEGER)) - sfprintf(outfile,"%d ",nv_size(np)); - } - if(val == NV_INTEGER && nv_isattr(np,NV_INTEGER)) - { - if(nv_size(np) != 10) - { - if(nv_isattr(np, NV_DOUBLE)) - cp = "precision"; - else - cp = "base"; - if(!prefix) - sfputr(outfile,cp,' '); - sfprintf(outfile,"%d ",nv_size(np)); - } - break; - } - } -#ifdef SHOPT_OO - if(nq=nv_class(np)) - { - if(prefix && *prefix=='t') - cclass = "-C"; - else if(!prefix) - cclass = "class"; - if(cclass) - sfprintf(outfile,"%s %s ",cclass,nv_name(nq)); - - } -#endif /* SHOPT_OO */ - if(aflag) - return; - sfputr(outfile,nv_name(np),'\n'); - } -} - -/* - * print the nodes in tree which have attributes set - * of