home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume20 / perl / patch04 next >
Encoding:
Text File  |  1991-06-19  |  55.1 KB  |  1,951 lines

  1. Newsgroups: comp.sources.misc
  2. From: Larry Wall <lwall@netlabs.com>
  3. Subject:  v20i056:  perl - The perl programming language, Patch04
  4. Message-ID: <csm-v20i056=perl.220122@sparky.imd.sterling.com>
  5. X-Md4-Signature: 6e5a8c800bf0a070ab9b3971547c1f12
  6. Date: Thu, 20 Jun 1991 03:02:33 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: Larry Wall <lwall@netlabs.com>
  10. Posting-number: Volume 20, Issue 56
  11. Archive-name: perl/patch04
  12. Patch-To: perl: Volume 18, Issue 19-54
  13.  
  14. System: perl version 4.0
  15. Patch #: 4
  16. Priority: High
  17. Subject: many, many itty-bitty portability fixes
  18. Subject: there's now a separate doSH script
  19. Subject: new copyright notice
  20. Subject: new files
  21. Subject: cflags now emits entire cc command except for the filename
  22. Subject: alternate make programs are now semi-supported
  23. Subject: uperl.o no longer tries to link in libraries prematurely
  24. Subject: installperl now installs x2p stuff too
  25. Subject: length($`), length($&), length($') now optimized to avoid string copy
  26. Subject: cflags.SH now spits out cflags for execution
  27. Subject: Configure can now propagate arbitrary variables from old config.sh
  28. Subject: cflags can now heed config variables on a file by file basis
  29. Subject: made some allowances for "semi-standard" C
  30. Subject: added global modifier for pattern matches
  31. Subject: // wouldn't use previous pattern if it started with a null character
  32. Subject: //o and s///o now optimize themselves fully at runtime
  33. Subject: undef @array disabled "@array" interpolation
  34. Subject: chop("") was returning "\0" rather than ""
  35. Subject: vector logical operations &, | and ^ sometimes returned null string
  36. Subject: syscall couldn't pass numbers with most significant bit set on sparcs
  37. Subject: system fd's are now treated specially
  38. Subject: added $^F variable to specify maximum system fd, default 2
  39. Subject: character special files now opened with bidirectional stdio buffers
  40. Subject: taintchecks could improperly modify parent in vfork()
  41. Subject: $` was busted inside s///
  42. Subject: caller($arg) didn't work except under debugger
  43. Subject: perl-mode.el now does better with formats
  44. Subject: assignment wasn't correctly de-tainting the assigned variable.
  45. Subject: default top-of-form format is now FILEHANDLE_TOP
  46. Subject: added $^P variable to control calling of perldb routines
  47. Subject: debugger sometimes listed wrong number of lines for a statement
  48. Subject: Makefile is no longer self-modifying code under makedepend
  49. Subject: debugger lost track of lines in eval
  50. Subject: changed old $^P to $^X
  51. Subject: /(x+) \1/ incorrectly optimized to not match "xxx xx"
  52. Subject: $^D |= 1024 now does syntax tree dump at run-time
  53. Subject: taint check on undefined string could cause core dump
  54. Subject: t/TEST now tells you number of tests executed
  55. Subject: t/op/stat.t no longer depends on certain devices being in /dev
  56. Subject: index() could blow up searching for null string
  57. Subject: exec would close files even if you cleared close-on-exec flag
  58. Subject: find2perl now makes use of find.pl and finddepth.pl
  59. Subject: find2perl now optimizes -exec rm -f {} to an unlink
  60. Subject: s2p now handles embedded newlines better and optimizes common idioms
  61. Subject: a2p didn't correctly implement -n switch
  62.  
  63. Description:
  64.     Random patches, mostly bugs and portability stuff.  //g is the
  65.     only major new feature.  Additionally, there is now an alternate
  66.     license you can distribute Perl under.
  67.  
  68. Fix:    From rn, say "| patch -p -N -d DIR", where DIR is your perl source
  69.     directory.  Outside of rn, say "cd DIR; patch -p -N <thisarticle".
  70.     If you don't have the patch program, apply the following by hand,
  71.     or get patch (version 2.0, latest patchlevel).
  72.  
  73.     After patching:
  74.         *** DO NOTHING--INSTALL ALL PATCHES UP THROUGH #09 FIRST ***
  75.  
  76.     If patch indicates that patchlevel is the wrong version, you may need
  77.     to apply one or more previous patches, or the patch may already
  78.     have been applied.  See the patchlevel.h file to find out what has or
  79.     has not been applied.  In any event, don't continue with the patch.
  80.  
  81.     If you are missing previous patches they can be obtained from me:
  82.  
  83.     Larry Wall
  84.     lwall@netlabs.com
  85.  
  86.     If you send a mail message of the following form it will greatly speed
  87.     processing:
  88.  
  89.     Subject: Command
  90.     @SH mailpatch PATH perl 4.0 LIST
  91.            ^ note the c
  92.  
  93.     where PATH is a return path FROM ME TO YOU either in Internet notation,
  94.     or in bang notation from some well-known host, and LIST is the number
  95.     of one or more patches you need, separated by spaces, commas, and/or
  96.     hyphens.  Saying 35- says everything from 35 to the end.
  97.  
  98.  
  99. Index: patchlevel.h
  100. Prereq: 3
  101. 1c1
  102. < #define PATCHLEVEL 3
  103. ---
  104. > #define PATCHLEVEL 4
  105.  
  106. Index: hints/3b1.sh
  107. *** hints/3b1.sh.old    Fri Jun  7 12:24:17 1991
  108. --- hints/3b1.sh    Fri Jun  7 12:24:18 1991
  109. ***************
  110. *** 0 ****
  111. --- 1,4 ----
  112. + d_voidsig='undef'
  113. + d_tosignal='int';
  114. + echo "If you're going to use shared libraries, don't include -lmalloc, and"
  115. + echo "change cc to '/bin/ccc' when editing config.sh at the end."
  116.  
  117. Index: Artistic
  118. *** Artistic.old    Fri Jun  7 12:22:09 1991
  119. --- Artistic    Fri Jun  7 12:22:10 1991
  120. ***************
  121. *** 0 ****
  122. --- 1,117 ----
  123. +              The "Artistic License"
  124. +                 Preamble
  125. + The intent of this document is to state the conditions under which a
  126. + Package may be copied, such that the Copyright Holder maintains some
  127. + semblance of artistic control over the development of the package,
  128. + while giving the users of the package the right to use and distribute
  129. + the Package in a more-or-less customary fashion, plus the right to make
  130. + reasonable modifications.
  131. + Definitions:
  132. +     "Package" refers to the collection of files distributed by the
  133. +     Copyright Holder, and derivatives of that collection of files
  134. +     created through textual modification.
  135. +     "Standard Version" refers to such a Package if it has not been
  136. +     modified, or has been modified in accordance with the wishes
  137. +     of the Copyright Holder.
  138. +     "Copyright Holder" is whoever is named in the copyright or
  139. +     copyrights for the package.
  140. +     "You" is you, if you're thinking about copying or distributing
  141. +     this Package.
  142. +     "Reasonable copying fee" is whatever you can justify on the
  143. +     basis of media cost, duplication charges, time of people involved,
  144. +     and so on.  (You will not be required to justify it to the
  145. +     Copyright Holder, but only to the computing community at large
  146. +     as a market that must bear the fee.)
  147. +     "Freely Available" means that no fee is charged for the item
  148. +     itself, though there may be fees involved in handling the item.
  149. +     It also means that recipients of the item may redistribute it
  150. +     under the same conditions they received it.
  151. + 1. You may make and give away verbatim copies of the source form of the
  152. + Standard Version of this Package without restriction, provided that you
  153. + duplicate all of the original copyright notices and associated disclaimers.
  154. + 2. You may apply bug fixes, portability fixes and other modifications
  155. + derived from the Public Domain or from the Copyright Holder.  A Package
  156. + modified in such a way shall still be considered the Standard Version.
  157. + 3. You may otherwise modify your copy of this Package in any way, provided
  158. + that you insert a prominent notice in each changed file stating how and
  159. + when you changed that file, and provided that you do at least ONE of the
  160. + following:
  161. +     a) place your modifications in the Public Domain or otherwise make them
  162. +     Freely Available, such as by posting said modifications to Usenet or
  163. +     an equivalent medium, or placing the modifications on a major archive
  164. +     site such as uunet.uu.net, or by allowing the Copyright Holder to include
  165. +     your modifications in the Standard Version of the Package.
  166. +     b) use the modified Package only within your corporation or organization.
  167. +     c) rename any non-standard executables so the names do not conflict
  168. +     with standard executables, which must also be provided, and provide
  169. +     a separate manual page for each non-standard executable that clearly
  170. +     documents how it differs from the Standard Version.
  171. +     d) make other distribution arrangements with the Copyright Holder.
  172. + 4. You may distribute the programs of this Package in object code or
  173. + executable form, provided that you do at least ONE of the following:
  174. +     a) distribute a Standard Version of the executables and library files,
  175. +     together with instructions (in the manual page or equivalent) on where
  176. +     to get the Standard Version.
  177. +     b) accompany the distribution with the machine-readable source of
  178. +     the Package with your modifications.
  179. +     c) accompany any non-standard executables with their corresponding
  180. +     Standard Version executables, giving the non-standard executables
  181. +     non-standard names, and clearly documenting the differences in manual
  182. +     pages (or equivalent), together with instructions on where to get
  183. +     the Standard Version.
  184. +     d) make other distribution arrangements with the Copyright Holder.
  185. + 5. You may charge a reasonable copying fee for any distribution of this
  186. + Package.  You may charge any fee you choose for support of this Package.
  187. + You may not charge a fee for this Package itself.  However,
  188. + you may distribute this Package in aggregate with other (possibly
  189. + commercial) programs as part of a larger (possibly commercial) software
  190. + distribution provided that you do not advertise this Package as a
  191. + product of your own.
  192. + 6. The scripts and library files supplied as input to or produced as
  193. + output from the programs of this Package do not automatically fall
  194. + under the copyright of this Package, but belong to whomever generated
  195. + them, and may be sold commercially, and may be aggregated with this
  196. + Package.
  197. + 7. C subroutines supplied by you and linked into this Package in order
  198. + to emulate subroutines and variables of the language defined by this
  199. + Package shall not be considered part of this Package, but are the
  200. + equivalent of input as in Paragraph 6, provided these subroutines do
  201. + not change the language in any way that would cause it to fail the
  202. + regression tests for the language.
  203. + 8. The name of the Copyright Holder may not be used to endorse or promote
  204. + products derived from this software without specific prior written permission.
  205. + 9. THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
  206. + IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  207. + WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  208. +                 The End
  209.  
  210. Index: Configure
  211. Prereq: 4.0.1.1
  212. *** Configure.old    Fri Jun  7 12:22:15 1991
  213. --- Configure    Fri Jun  7 12:22:17 1991
  214. ***************
  215. *** 8,14 ****
  216.   # and edit it to reflect your system.  Some packages may include samples
  217.   # of config.h for certain machines, so you might look for one of those.)
  218.   #
  219. ! # $RCSfile: Configure,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:26:42 $
  220.   #
  221.   # Yes, you may rip this off to use in other distribution packages.
  222.   # (Note: this Configure script was generated automatically.  Rather than
  223. --- 8,14 ----
  224.   # and edit it to reflect your system.  Some packages may include samples
  225.   # of config.h for certain machines, so you might look for one of those.)
  226.   #
  227. ! # $RCSfile: Configure,v $$Revision: 4.0.1.2 $$Date: 91/06/07 10:09:34 $
  228.   #
  229.   # Yes, you may rip this off to use in other distribution packages.
  230.   # (Note: this Configure script was generated automatically.  Rather than
  231. ***************
  232. *** 189,194 ****
  233. --- 189,195 ----
  234.   d_setruid=''
  235.   d_shm=''
  236.   d_shmat=''
  237. + d_voidshmat=''
  238.   d_shmctl=''
  239.   d_shmdt=''
  240.   d_shmget=''
  241. ***************
  242. *** 263,268 ****
  243. --- 264,270 ----
  244.   cppflags=''
  245.   ldflags=''
  246.   cc=''
  247. + nativegcc=''
  248.   libs=''
  249.   n=''
  250.   c=''
  251. ***************
  252. *** 269,274 ****
  253. --- 271,277 ----
  254.   package=''
  255.   randbits=''
  256.   scriptdir=''
  257. + installscr=''
  258.   sig_name=''
  259.   spitshell=''
  260.   shsharp=''
  261. ***************
  262. *** 338,345 ****
  263.   d_ndir=ndir
  264.   voidwant=1
  265.   voidwant=7
  266. ! libswanted="net_s net nsl_s nsl socket nm ndir ndbm dbm malloc sun m bsd BSD x c_s posix"
  267. ! inclwanted='/usr/include /usr/netinclude /usr/include/sun /usr/include/bsd /usr/include/lan'
  268.   
  269.   : Now test for existence of everything in MANIFEST
  270.   
  271. --- 341,348 ----
  272.   d_ndir=ndir
  273.   voidwant=1
  274.   voidwant=7
  275. ! libswanted="c_s net_s net nsl_s nsl socket nm ndir ndbm dbm malloc sun m bsd BSD x posix ucb"
  276. ! inclwanted='/usr/include /usr/netinclude /usr/include/sun /usr/include/bsd /usr/include/lan /usr/ucbinclude'
  277.   
  278.   : Now test for existence of everything in MANIFEST
  279.   
  280. ***************
  281. *** 712,725 ****
  282.   hint=default
  283.   if test -f ../config.sh; then
  284.       echo " "
  285. !     eval `grep lastuname ../config.sh`
  286. !     uname=`(uname -a || hostname) 2>&1`
  287. !     if test "X$uname" = "X$lastuname"; then
  288.       dflt=y
  289.       else
  290.       dflt=n
  291.       fi
  292. !     lastuname="$uname"
  293.       rp="I see a config.sh file.  Did Configure make it on THIS system? [$dflt]"
  294.       echo $n "$rp $c"
  295.       . myread
  296. --- 715,728 ----
  297.   hint=default
  298.   if test -f ../config.sh; then
  299.       echo " "
  300. !     eval "`grep lastuname ../config.sh`"
  301. !     tmp=`(uname -a) 2>&1`
  302. !     if test "X$tmp" = "X$lastuname"; then
  303.       dflt=y
  304.       else
  305.       dflt=n
  306.       fi
  307. !     lastuname="$tmp"
  308.       rp="I see a config.sh file.  Did Configure make it on THIS system? [$dflt]"
  309.       echo $n "$rp $c"
  310.       . myread
  311. ***************
  312. *** 746,751 ****
  313. --- 749,755 ----
  314.       test -f /dynix && dflt="$dflt dynix"
  315.       test -f /dnix && dflt="$dflt dnix"
  316.       test -f /bin/mips && /bin/mips && dflt="$dflt mips"
  317. +     test -d /NextApps && test -f /usr/adm/software_version && dflt="$dflt next"
  318.       if test -f /bin/uname || test -f /usr/bin/uname; then
  319.       set `uname -a | tr '[A-Z]' '[a-z]'`
  320.   
  321. ***************
  322. *** 798,804 ****
  323.       case "$dflt" in
  324.       '') dflt=none;;
  325.       esac
  326. !     echo '(You may give one or more space-separated answers, or "none" if appropriate.)'
  327.       rp="Which of these apply, if any? [$dflt]"
  328.       echo $n "$rp $c"
  329.       . myread
  330. --- 802,809 ----
  331.       case "$dflt" in
  332.       '') dflt=none;;
  333.       esac
  334. !     echo '(You may give one or more space-separated answers, or "none" if appropriate.'
  335. !     echo 'If your OS version has no hints, do not give a wrong version--say "none".)'
  336.       rp="Which of these apply, if any? [$dflt]"
  337.       echo $n "$rp $c"
  338.       . myread
  339. ***************
  340. *** 805,810 ****
  341. --- 810,816 ----
  342.       for file in $ans; do
  343.       if test -f ../hints/$file.sh; then
  344.           . ../hints/$file.sh
  345. +         cat ../hints/$file.sh >>../config.sh
  346.           hint=recommended
  347.       fi
  348.       done
  349. ***************
  350. *** 1238,1244 ****
  351.       cc="$ans"
  352.   fi
  353.   case "$cc" in
  354. ! gcc*) cpp=`./loc gcc-cpp $cpp $pth`;;
  355.   esac
  356.   
  357.   : determine optimize, if desired, or use for debug flag also
  358. --- 1244,1268 ----
  359.       cc="$ans"
  360.   fi
  361.   case "$cc" in
  362. ! gcc*) cpp=`./loc gcc-cpp $cpp $pth`
  363. !     case "$nativegcc" in
  364. !     '') case "$ccflags" in
  365. !     *-fpcc-struct-return*) dflt=n;;
  366. !     *) dflt=y;;
  367. !     esac
  368. !     ;;
  369. !     undef) dflt=n;;
  370. !     *) dflt=y;;
  371. !     esac
  372. !     echo " "
  373. !     rp="Are your system (especially dbm) libraries compiled with gcc? [$dflt]"
  374. !     $echo $n "$rp $c"
  375. !     . myread
  376. !     case "$ans" in
  377. !     n*) nativegcc="$undef"; gccflags='-fpcc-struct-return';;
  378. !     *) nativegcc="$define"; gccflags='';;
  379. !     esac
  380. !     ;;
  381.   esac
  382.   
  383.   : determine optimize, if desired, or use for debug flag also
  384. ***************
  385. *** 1270,1280 ****
  386.   
  387.   case "$ccflags" in
  388.   '') case "$cc" in
  389. !     *gcc*) dflt='-fpcc-struct-return';;
  390.       *) dflt='';;
  391.       esac
  392.       ;;
  393. ! *) dflt="$ccflags";;
  394.   esac
  395.   for thisincl in $inclwanted; do
  396.       if test -d $thisincl; then
  397. --- 1294,1309 ----
  398.   
  399.   case "$ccflags" in
  400.   '') case "$cc" in
  401. !     *gcc*) dflt="$gccflags";;
  402.       *) dflt='';;
  403.       esac
  404.       ;;
  405. ! *-fpcc-struct-return*) dflt="$ccflags";;
  406. ! *) case "$cc" in
  407. !     *gcc*) dflt="$ccflags $gccflags";;
  408. !     *) dflt="$ccflags";;
  409. !     esac
  410. !     ;;
  411.   esac
  412.   for thisincl in $inclwanted; do
  413.       if test -d $thisincl; then
  414. ***************
  415. *** 1336,1342 ****
  416.       cppflags=''
  417.       for flag do
  418.       case $flag in
  419. !     -D*|-I*|-traditional|-ansi|-nostdinc) cppflags="$cppflags $flag";;
  420.       esac
  421.       done
  422.       case "$cppflags" in
  423. --- 1365,1371 ----
  424.       cppflags=''
  425.       for flag do
  426.       case $flag in
  427. !     -D*|-U*|-I*|-traditional|-ansi|-nostdinc) cppflags="$cppflags $flag";;
  428.       esac
  429.       done
  430.       case "$cppflags" in
  431. ***************
  432. *** 1524,1529 ****
  433. --- 1553,1559 ----
  434.   case "$installbin" in
  435.   '')
  436.       dflt=`echo $bin | sed 's#^/afs/#/afs/.#'`
  437. +     test -d $dflt || dflt="$bin"
  438.       ;;
  439.   *)  dflt="$installbin"
  440.       ;;
  441. ***************
  442. *** 1611,1616 ****
  443. --- 1641,1648 ----
  444.   $cat >try.c <<'EOCP'
  445.   #include <signal.h>
  446.   
  447. + blech() { exit(3); }
  448.   main()
  449.   {
  450.       double f = -123;
  451. ***************
  452. *** 1619,1625 ****
  453.       unsigned short ashort;
  454.       int result = 0;
  455.   
  456. !     signal(SIGFPE, SIG_IGN);
  457.       along = (unsigned long)f;
  458.       aint = (unsigned int)f;
  459.       ashort = (unsigned short)f;
  460. --- 1651,1657 ----
  461.       unsigned short ashort;
  462.       int result = 0;
  463.   
  464. !     signal(SIGFPE, blech);
  465.       along = (unsigned long)f;
  466.       aint = (unsigned int)f;
  467.       ashort = (unsigned short)f;
  468. ***************
  469. *** 1674,1776 ****
  470.   #define XYZ xyz
  471.   ABC.XYZ
  472.   EOT
  473. ! echo 'Maybe "'"$cc"' -E" will work...'
  474. ! $cc -E <testcpp.c >testcpp.out 2>&1
  475. ! : try to force gcc preprocessor if that is the compiler they are using
  476. ! case $? in
  477. ! 0) cppstdin="$cc -E";;
  478. ! *) case "$cc" in
  479. !     *gcc*)
  480. !     cd ..
  481. !     echo 'Trying (cat >/tmp/$$.c; '"$cc"' -E /tmp/$$.c; rm /tmp/$$.c)'
  482. !     echo 'cat >/tmp/$$.c; '"$cc"' -E /tmp/$$.c; rm /tmp/$$.c' >cppstdin
  483. !     chmod 755 cppstdin
  484. !     cppstdin=`pwd`/cppstdin
  485. !     cppminus='';
  486. !     cd UU
  487. !     $cppstdin <testcpp.c >testcpp.out 2>&1
  488. !     ;;
  489. !     esac
  490. !     ;;
  491. ! esac
  492. ! if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  493.       echo "Yup, it does."
  494.       cppstdin="$cc -E"
  495.       cppminus='';
  496.   else
  497. !     echo 'Nope...maybe "'"$cc"' -E -" will work...'
  498. !     $cc -E - <testcpp.c >testcpp.out 2>&1
  499.       if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  500. !     echo "Yup, it does."
  501. !     cppstdin="$cc -E"
  502. !     cppminus='-';
  503.       else
  504. !     echo 'No such luck, maybe "'$cpp'" will work...'
  505. !     $cpp <testcpp.c >testcpp.out 2>&1
  506. !     if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  507. !         echo "It works!"
  508. !         cppstdin="$cpp"
  509. !         cppminus='';
  510. !     else
  511. !         echo 'Nixed again...maybe "'$cpp' -" will work...'
  512. !         $cpp - <testcpp.c >testcpp.out 2>&1
  513. !         if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  514. !         echo "Hooray, it works!  I was beginning to wonder."
  515. !         cppstdin="$cpp"
  516. !         cppminus='-';
  517. !         else
  518. !         echo 'Nope...maybe "'"$cc"' -P" will work...'
  519. !         $cc -P <testcpp.c >testcpp.out 2>&1
  520. !         if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  521. !             echo "Yup, that does."
  522. !             cppstdin="$cc -P"
  523. !             cppminus='';
  524. !         else
  525. !             echo 'Nope...maybe "'"$cc"' -P -" will work...'
  526. !             $cc -P - <testcpp.c >testcpp.out 2>&1
  527. !             if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  528. !             echo "Yup, that does."
  529. !             cppstdin="$cc -P"
  530. !             cppminus='-';
  531. !             else
  532. !             echo 'Hmm...perhaps you already told me...'
  533. !             case "$cppstdin" in
  534. !             '') ;;
  535. !             *) $cppstdin $cppminus <testcpp.c >testcpp.out 2>&1;;
  536. !             esac
  537. !             if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  538. !                 echo "Hooray, you did!  I was beginning to wonder."
  539. !             else
  540. !                 echo 'Uh-uh.  Time to get fancy...'
  541. !                 cd ..
  542. !                 echo 'Trying (cat >/tmp/$$.c; '"$cc"' -E /tmp/$$.c; rm /tmp/$$.c)'
  543. !                 echo 'cat >/tmp/$$.c; '"$cc"' -E /tmp/$$.c; rm /tmp/$$.c' >cppstdin
  544. !                 chmod 755 cppstdin
  545. !                 cppstdin=`pwd`/cppstdin
  546. !                 cppminus='';
  547. !                 cd UU
  548. !                 $cppstdin <testcpp.c >testcpp.out 2>&1
  549. !                 if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  550. !                 echo "Eureka!."
  551. !                 else
  552. !                 dflt=blurfl
  553. !                 $echo $n "No dice.  I can't find a C preprocessor.  Name one: $c"
  554. !                 rp='Name a C preprocessor:'
  555. !                 . myread
  556. !                 cppstdin="$ans"
  557. !                 $cppstdin <testcpp.c >testcpp.out 2>&1
  558. !                 if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  559. !                     echo "OK, that will do."
  560. !                 else
  561. !                     echo "Sorry, I can't get that to work.  Go find one."
  562. !                     exit 1
  563. !                 fi
  564. !                 fi
  565. !             fi
  566. !             fi
  567. !         fi
  568. !         fi
  569. !     fi
  570.       fi
  571.   fi
  572.   
  573. --- 1706,1783 ----
  574.   #define XYZ xyz
  575.   ABC.XYZ
  576.   EOT
  577. ! cd ..
  578. ! echo 'cat >.$$.c; '"$cc"' -E ${1+"$@"} .$$.c; rm .$$.c' >cppstdin
  579. ! chmod 755 cppstdin
  580. ! wrapper=`pwd`/cppstdin
  581. ! cd UU
  582. ! if test "X$cppstdin" != "X" && \
  583. !   $cppstdin $cppminus <testcpp.c >testcpp.out 2>&1 && \
  584. !   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  585. !     echo "You used to use $cppstdin $cppminus so we'll use that again."
  586. ! elif test "$cc" = gcc && \
  587. !   (echo "Using gcc, eh?  We'll try to force gcc -E using a wrapper..."; \
  588. !   $wrapper <testcpp.c >testcpp.out 2>&1; \
  589. !   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1) ; then
  590. !     echo "Yup, we can."
  591. !     cppstdin="$wrapper"
  592. !     cppminus='';
  593. ! elif echo 'Maybe "'"$cc"' -E" will work...'; \
  594. !   $cc -E <testcpp.c >testcpp.out 2>&1; \
  595. !   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  596.       echo "Yup, it does."
  597.       cppstdin="$cc -E"
  598.       cppminus='';
  599. + elif echo 'Nope...maybe "'"$cc"' -E -" will work...'; \
  600. +   $cc -E - <testcpp.c >testcpp.out 2>&1; \
  601. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  602. +     echo "Yup, it does."
  603. +     cppstdin="$cc -E"
  604. +     cppminus='-';
  605. + elif echo 'Uh-uh.  Time to get fancy.  Trying a wrapper...'; \
  606. +   $wrapper <testcpp.c >testcpp.out 2>&1; \
  607. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  608. +     cppstdin="$wrapper"
  609. +     cppminus=''
  610. +     echo "Eureka!."
  611. + elif echo 'No such luck, maybe "'$cpp'" will work...'; \
  612. +   $cpp <testcpp.c >testcpp.out 2>&1; \
  613. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  614. +     echo "It works!"
  615. +     cppstdin="$cpp"
  616. +     cppminus='';
  617. + elif echo 'Nixed again...maybe "'$cpp' -" will work...'; \
  618. +   $cpp - <testcpp.c >testcpp.out 2>&1; \
  619. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  620. +     echo "Hooray, it works!  I was beginning to wonder."
  621. +     cppstdin="$cpp"
  622. +     cppminus='-';
  623. + elif echo 'Nope...maybe "'"$cc"' -P" will work...'; \
  624. +   $cc -P <testcpp.c >testcpp.out 2>&1; \
  625. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  626. +     echo "Yipee, that works!"
  627. +     cppstdin="$cc -P"
  628. +     cppminus='';
  629. + elif echo 'Nope...maybe "'"$cc"' -P -" will work...'; \
  630. +   $cc -P - <testcpp.c >testcpp.out 2>&1; \
  631. +   $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  632. +     echo "At long last!"
  633. +     cppstdin="$cc -P"
  634. +     cppminus='-';
  635.   else
  636. !     dflt=blurfl
  637. !     $echo $n "No dice.  I can't find a C preprocessor.  Name one: $c"
  638. !     rp='Name a C preprocessor:'
  639. !     . myread
  640. !     cppstdin="$ans"
  641. !     $cppstdin <testcpp.c >testcpp.out 2>&1
  642.       if $contains 'abc.*xyz' testcpp.out >/dev/null 2>&1 ; then
  643. !     echo "OK, that will do."
  644.       else
  645. !     echo "Sorry, I can't get that to work.  Go find one and rerun Configure."
  646. !     exit 1
  647.       fi
  648.   fi
  649.   
  650. ***************
  651. *** 1834,1845 ****
  652.   test -f $1 || set /lib/libsys_s.a
  653.   eval set \$$#
  654.   if test -f "$1"; then
  655. !     echo "Your shared C library is in $1."
  656.       libc="$1"
  657.   elif test -f "$libc"; then
  658. !     echo "Your C library is in $libc."
  659.   elif test -f /lib/libc.a; then
  660. !     echo "Your C library is in /lib/libc.a.  You're normal."
  661.       libc=/lib/libc.a
  662.   else
  663.       if   ans=`./loc libc.a  blurfl/dyick $libpth`; test -f "$ans"; then
  664. --- 1841,1852 ----
  665.   test -f $1 || set /lib/libsys_s.a
  666.   eval set \$$#
  667.   if test -f "$1"; then
  668. !     echo "Your (shared) C library seems to be in $1."
  669.       libc="$1"
  670.   elif test -f "$libc"; then
  671. !     echo "Your C library seems to be in $libc."
  672.   elif test -f /lib/libc.a; then
  673. !     echo "Your C library seems to be in /lib/libc.a.  You're normal."
  674.       libc=/lib/libc.a
  675.   else
  676.       if   ans=`./loc libc.a  blurfl/dyick $libpth`; test -f "$ans"; then
  677. ***************
  678. *** 1856,1862 ****
  679.       :
  680.       fi
  681.       if test -f "$ans"; then
  682. !     echo "Your C library is in $ans, of all places."
  683.       libc=$ans
  684.       else
  685.       cat <<EOM
  686. --- 1863,1869 ----
  687.       :
  688.       fi
  689.       if test -f "$ans"; then
  690. !     echo "Your C library seems to be in $ans, of all places."
  691.       libc=$ans
  692.       else
  693.       cat <<EOM
  694. ***************
  695. *** 1878,1885 ****
  696.   if test $libc = "/lib/libc"; then
  697.       libc="$libc /lib/clib"
  698.   fi
  699. ! set `echo $libc $libnames | tr ' ' '\012' | sort | uniq`
  700. ! $echo $n "Extracting names from $* for later perusal...$c"
  701.   nm $nm_opts $* 2>/dev/null >libc.tmp
  702.   $sed -n -e 's/^.* [ATDS]  *[_.]*//p' -e 's/^.* [ATDS] //p' <libc.tmp >libc.list
  703.   if $contains '^printf$' libc.list >/dev/null 2>&1; then
  704. --- 1885,1907 ----
  705.   if test $libc = "/lib/libc"; then
  706.       libc="$libc /lib/clib"
  707.   fi
  708. ! cat <<END
  709. !  
  710. ! If the guess above is wrong (which it might be if you're using a strange
  711. ! compiler, or your machine supports multiple models), you can override it here.
  712. ! END
  713. ! dflt="$libc";
  714. ! rp="Your C library is where? [$dflt]"
  715. ! $echo $n "$rp $c"
  716. ! . myread
  717. ! libc="$ans"
  718. ! echo " "
  719. ! echo $libc $libnames | tr ' ' '\012' | sort | uniq >libnames
  720. ! $echo "Extracting names from the following files for later perusal:"
  721. ! sed 's/^/    /' libnames
  722. ! echo $n "This may take a while...$c"
  723. ! set X `cat libnames`
  724. ! shift
  725.   nm $nm_opts $* 2>/dev/null >libc.tmp
  726.   $sed -n -e 's/^.* [ATDS]  *[_.]*//p' -e 's/^.* [ATDS] //p' <libc.tmp >libc.list
  727.   if $contains '^printf$' libc.list >/dev/null 2>&1; then
  728. ***************
  729. *** 1898,1904 ****
  730.           <libc.tmp >libc.list; \
  731.     $contains '^printf$' libc.list >/dev/null 2>&1; then
  732.       echo done
  733. ! elif $grep '|' <libc.tmp | $sed -n -e '/|COMMON/d' -e '/|DATA/d' \
  734.                                      -e 's/^\([^     ]*\).*/\1/p' >libc.list
  735.     $contains '^printf$' libc.list >/dev/null 2>&1; then
  736.       echo done
  737. --- 1920,1926 ----
  738.           <libc.tmp >libc.list; \
  739.     $contains '^printf$' libc.list >/dev/null 2>&1; then
  740.       echo done
  741. ! elif $grep '|' <libc.tmp | $sed -n -e '/|COMMON/d' -e '/|DATA/d' -e '/ file/d' \
  742.                                      -e 's/^\([^     ]*\).*/\1/p' >libc.list
  743.     $contains '^printf$' libc.list >/dev/null 2>&1; then
  744.       echo done
  745. ***************
  746. *** 1939,1954 ****
  747.       fi
  748.       fi
  749.   fi
  750.   
  751. - : old version
  752. - inlibc='echo " ";
  753. - if $contains "^$1\$" libc.list >/dev/null 2>&1;
  754. - then echo "$1() found"; eval "$2=$define";
  755. - else echo "$1() not found"; eval "$2=$undef"; fi'
  756. - : new version
  757.   inlibc='echo " "; td=$define; tu=$undef;
  758.   if $contains "^$1\$" libc.list >/dev/null 2>&1;
  759.   then echo "$1() found";
  760. --- 1961,1971 ----
  761.       fi
  762.       fi
  763.   fi
  764. + if test -f /lib/syscalls.exp; then
  765. +     echo "Also extracting names from /lib/syscalls.exp for good ole AIX..."
  766. +     sed -n 's/^\([^     ]*\)[     ]*syscall$/\1/p' /lib/syscalls.exp >>libc.list
  767. + fi
  768.   
  769.   inlibc='echo " "; td=$define; tu=$undef;
  770.   if $contains "^$1\$" libc.list >/dev/null 2>&1;
  771.   then echo "$1() found";
  772. ***************
  773. *** 2615,2620 ****
  774. --- 2632,2650 ----
  775.   set shmat d_shmat
  776.   eval $inlibc
  777.   
  778. + d_voidshmat="$undef"
  779. + case "$d_shmat" in
  780. + define)
  781. +     $cppstdin $cppflags $cppminus < $usrinclude/sys/shm.h >voidshmat.txt 2>/dev/null
  782. +     if $contains "void.*shmat" voidshmat.txt >/dev/null 2>&1; then
  783. +     echo "and shmat returns (void*)"
  784. +     d_voidshmat="$define"
  785. +     else
  786. +     echo "and shmat returns (char*)"
  787. +     fi
  788. +     ;;
  789. + esac
  790.   : see if shmdt exists
  791.   set shmdt d_shmdt
  792.   eval $inlibc
  793. ***************
  794. *** 2854,2870 ****
  795.   : see if signal is declared as pointer to function returning int or void
  796.   echo " "
  797.   $cppstdin $cppflags $cppminus < $usrinclude/signal.h >d_voidsig.txt
  798. ! if $contains 'int.*signal' d_voidsig.txt >/dev/null 2>&1 ; then
  799.       echo "You have int (*signal())() instead of void."
  800.       val="$undef"
  801. -     d_tosignal=int
  802.   else
  803.       echo "You have void (*signal())() instead of int."
  804.       val="$define"
  805. -     d_tosignal=void
  806.   fi
  807.   set d_voidsig
  808.   eval $setvar
  809.   
  810.   : see if truncate exists
  811.   set truncate d_truncate
  812. --- 2884,2902 ----
  813.   : see if signal is declared as pointer to function returning int or void
  814.   echo " "
  815.   $cppstdin $cppflags $cppminus < $usrinclude/signal.h >d_voidsig.txt
  816. ! if $contains 'int[^A-Za-z]*signal' d_voidsig.txt >/dev/null 2>&1 ; then
  817.       echo "You have int (*signal())() instead of void."
  818.       val="$undef"
  819.   else
  820.       echo "You have void (*signal())() instead of int."
  821.       val="$define"
  822.   fi
  823.   set d_voidsig
  824.   eval $setvar
  825. + case $voidsig in
  826. + define) d_tosignal=void;;
  827. + *) d_tosignal=int;;
  828. + esac
  829.   
  830.   : see if truncate exists
  831.   set truncate d_truncate
  832. ***************
  833. *** 2929,2934 ****
  834. --- 2961,3004 ----
  835.   . myread
  836.   gidtype="$ans"
  837.   
  838. + : see what type gids are returned by getgroups
  839. + echo " "
  840. + case "$groupstype" in
  841. + '')
  842. +     if $contains 'getgroups.*short' /usr/lib/lint/llib-lc >/dev/null 2>&1; then
  843. +     dflt='short'
  844. +     elif $contains 'getgroups.*int' /usr/lib/lint/llib-lc >/dev/null 2>&1; then
  845. +     dflt='int'
  846. +     elif $contains 'getgroups.*short' /usr/include/libc.h >/dev/null 2>&1; then
  847. +     dflt='short'
  848. +     elif $contains 'getgroups.*int' /usr/include/libc.h >/dev/null 2>&1; then
  849. +     dflt='int'
  850. +     elif $contains 'getgroups.*short' /usr/lib/lint/llib-lbsd >/dev/null 2>&1; then
  851. +     dflt='short'
  852. +     elif $contains 'getgroups.*int' /usr/lib/lint/llib-lbsd >/dev/null 2>&1; then
  853. +     dflt='int'
  854. +     elif $contains 'int.*gidset' /usr/man/man2/getgroups.2 >/dev/null 2>&1; then
  855. +     dflt='int'
  856. +     elif $contains 'gid_t;' $usrinclude/sys/types.h >/dev/null 2>&1 ; then
  857. +     dflt='gid_t'
  858. +     else
  859. +     set `grep 'groups\[NGROUPS\];' $usrinclude/sys/user.h 2>/dev/null` unsigned short
  860. +     case $1 in
  861. +     unsigned) dflt="$1 $2" ;;
  862. +     *) dflt="$1" ;;
  863. +     esac
  864. +     fi
  865. +     ;;
  866. + *)  dflt="$groupstype"
  867. +     ;;
  868. + esac
  869. + cont=true
  870. + echo "(The following only matters if you have getgroups().)"
  871. + rp="What type are the group ids returned by getgroups()? [$dflt]"
  872. + $echo $n "$rp $c"
  873. + . myread
  874. + groupstype="$ans"
  875.   : check for length of integer
  876.   echo " "
  877.   case "$intsize" in
  878. ***************
  879. *** 2983,2989 ****
  880. --- 3053,3063 ----
  881.       case "$mallocptrtype" in
  882.       '')
  883.       cat >usemymalloc.c <<'END'
  884. + #ifdef __STDC__
  885. + #include <stdlib.h>
  886. + #else
  887.   #include <malloc.h>
  888. + #endif
  889.   void *malloc();
  890.   END
  891.       if $cc $ccflags -c usemymalloc.c >/dev/null 2>&1; then
  892. ***************
  893. *** 3021,3026 ****
  894. --- 3095,3101 ----
  895.   case "$installprivlib" in
  896.   '')
  897.       dflt=`echo $privlib | sed 's#^/afs/#/afs/.#'`
  898. +     test -d $dflt || dflt="$privlib"
  899.       ;;
  900.   *)  dflt="$installprivlib"
  901.       ;;
  902. ***************
  903. *** 3073,3079 ****
  904.   . myread
  905.   randbits="$ans"
  906.   
  907. ! : determine where public executables go
  908.   case "$scriptdir" in
  909.   '')
  910.       dflt="$bin"
  911. --- 3148,3154 ----
  912.   . myread
  913.   randbits="$ans"
  914.   
  915. ! : determine where publicly executable scripts go
  916.   case "$scriptdir" in
  917.   '')
  918.       dflt="$bin"
  919. ***************
  920. *** 3094,3100 ****
  921.    
  922.   EOM
  923.   while $test "$cont" ; do
  924. !     rp="Where do you keep publicly executable scripts (~name ok)? [$dflt]"
  925.       $echo $n "$rp $c"
  926.       . myread
  927.       scriptdir="$ans"
  928. --- 3169,3175 ----
  929.    
  930.   EOM
  931.   while $test "$cont" ; do
  932. !     rp="Where will publicly executable scripts reside (~name ok)? [$dflt]"
  933.       $echo $n "$rp $c"
  934.       . myread
  935.       scriptdir="$ans"
  936. ***************
  937. *** 3116,3121 ****
  938. --- 3191,3233 ----
  939.       fi
  940.   done
  941.   
  942. + case "$installscr" in
  943. + '')
  944. +     dflt=`echo $scriptdir | sed 's#^/afs/#/afs/.#'`
  945. +     test -d $dflt || dflt="$scriptdir"
  946. +     ;;
  947. + *)  dflt="$scriptdir"
  948. +     ;;
  949. + esac
  950. + cont=true
  951. + $cat <<EOM
  952. +  
  953. + Some installations must install scripts in a different directory than where
  954. + they will eventually reside.  On most systems they're the same directory.
  955. + EOM
  956. + while $test "$cont" ; do
  957. +     rp="Where do you install publicly executable scripts (~name ok)? [$dflt]"
  958. +     $echo $n "$rp $c"
  959. +     . myread
  960. +     installscr="$ans"
  961. +     installscr=`./filexp "$installscr"`
  962. +     if test -d $installscr; then
  963. +     cont=''
  964. +     else
  965. +     case "$fastread" in
  966. +     yes) dflt=y;;
  967. +     *) dflt=n;;
  968. +     esac
  969. +     rp="Directory $installscr doesn't exist.  Use that name anyway? [$dflt]"
  970. +     $echo $n "$rp $c"
  971. +     . myread
  972. +     dflt=''
  973. +     case "$ans" in
  974. +     y*) cont='';;
  975. +     esac
  976. +     fi
  977. + done
  978.   : generate list of signal names
  979.   echo " "
  980.   case "$sig_name" in
  981. ***************
  982. *** 3159,3165 ****
  983.   
  984.   : see what type of char stdio uses.
  985.   echo " "
  986. ! if $contains 'unsigned.*char.*_ptr;' $usrinclude/stdio.h >/dev/null 2>&1 ; then
  987.       echo "Your stdio uses unsigned chars."
  988.       stdchar="unsigned char"
  989.   else
  990. --- 3271,3277 ----
  991.   
  992.   : see what type of char stdio uses.
  993.   echo " "
  994. ! if $contains 'unsigned.*char.*\*.*_ptr.*;' $usrinclude/stdio.h >/dev/null 2>&1 ; then
  995.       echo "Your stdio uses unsigned chars."
  996.       stdchar="unsigned char"
  997.   else
  998. ***************
  999. *** 3223,3229 ****
  1000.       exit(0);
  1001.   }
  1002.   EOCP
  1003. !     if $cc -S -DTRY=$voidwant void.c >void.out 2>&1 ; then
  1004.       voidhave=$voidwant
  1005.       echo "It appears to support void to the level $package wants ($voidwant)."
  1006.       if $contains warning void.out >/dev/null 2>&1; then
  1007. --- 3335,3341 ----
  1008.       exit(0);
  1009.   }
  1010.   EOCP
  1011. !     if $cc -c -DTRY=$voidwant void.c >void.out 2>&1 ; then
  1012.       voidhave=$voidwant
  1013.       echo "It appears to support void to the level $package wants ($voidwant)."
  1014.       if $contains warning void.out >/dev/null 2>&1; then
  1015. ***************
  1016. *** 3232,3245 ****
  1017.       fi
  1018.       else
  1019.       echo "Hmm, your compiler has some difficulty with void.  Checking further..."
  1020. !     if $cc -S -DTRY=1 void.c >/dev/null 2>&1 ; then
  1021.           echo "It supports 1..."
  1022. !         if $cc -S -DTRY=3 void.c >/dev/null 2>&1 ; then
  1023.           voidhave=3
  1024.           echo "And it supports 2 but not 4."
  1025.           else
  1026.           echo "It doesn't support 2..."
  1027. !         if $cc -S -DTRY=5 void.c >/dev/null 2>&1 ; then
  1028.               voidhave=5
  1029.               echo "But it supports 4."
  1030.           else
  1031. --- 3344,3357 ----
  1032.       fi
  1033.       else
  1034.       echo "Hmm, your compiler has some difficulty with void.  Checking further..."
  1035. !     if $cc -c -DTRY=1 void.c >/dev/null 2>&1 ; then
  1036.           echo "It supports 1..."
  1037. !         if $cc -c -DTRY=3 void.c >/dev/null 2>&1 ; then
  1038.           voidhave=3
  1039.           echo "And it supports 2 but not 4."
  1040.           else
  1041.           echo "It doesn't support 2..."
  1042. !         if $cc -c -DTRY=5 void.c >/dev/null 2>&1 ; then
  1043.               voidhave=5
  1044.               echo "But it supports 4."
  1045.           else
  1046. ***************
  1047. *** 3292,3331 ****
  1048.   esac
  1049.   yacc="$ans"
  1050.   
  1051. - : see what type gids are returned by getgroups
  1052. - echo " "
  1053. - case "$groupstype" in
  1054. - '')
  1055. -     if $contains 'getgroups.*short' /usr/lib/lint/llib-lc >/dev/null 2>&1; then
  1056. -     dflt='short'
  1057. -     elif $contains 'getgroups.*int' /usr/lib/lint/llib-lc >/dev/null 2>&1; then
  1058. -     dflt='int'
  1059. -     elif $contains 'getgroups.*short' /usr/lib/lint/llib-lbsd >/dev/null 2>&1; then
  1060. -     dflt='short'
  1061. -     elif $contains 'getgroups.*int' /usr/lib/lint/llib-lbsd >/dev/null 2>&1; then
  1062. -     dflt='int'
  1063. -     elif $contains 'int gidset' /usr/man/man2/getgroups.2 >/dev/null 2>&1 ; then
  1064. -     dflt='int'
  1065. -     elif $contains 'gid_t;' $usrinclude/sys/types.h >/dev/null 2>&1 ; then
  1066. -     dflt='gid_t'
  1067. -     else
  1068. -     set `grep 'groups\[NGROUPS\];' $usrinclude/sys/user.h 2>/dev/null` unsigned short
  1069. -     case $1 in
  1070. -     unsigned) dflt="$1 $2" ;;
  1071. -     *) dflt="$1" ;;
  1072. -     esac
  1073. -     fi
  1074. -     ;;
  1075. - *)  dflt="$groupstype"
  1076. -     ;;
  1077. - esac
  1078. - cont=true
  1079. - echo "(The following only matters if you have getgroups().)"
  1080. - rp="What type are the group ids returned by getgroups()? [$dflt]"
  1081. - $echo $n "$rp $c"
  1082. - . myread
  1083. - groupstype="$ans"
  1084.   : see if we can include fcntl.h
  1085.   echo " "
  1086.   if $h_fcntl; then
  1087. --- 3404,3409 ----
  1088. ***************
  1089. *** 3463,3473 ****
  1090.       cd ..
  1091.   fi
  1092.   echo "Creating config.sh..."
  1093.   $spitshell <<EOT >config.sh
  1094.   $startsh
  1095.   # config.sh
  1096.   # This file was produced by running the Configure script.
  1097.   d_eunice='$d_eunice'
  1098.   define='$define'
  1099.   eunicefix='$eunicefix'
  1100. --- 3541,3551 ----
  1101.       cd ..
  1102.   fi
  1103.   echo "Creating config.sh..."
  1104. + test -f config.sh && cp config.sh UU/oldconfig.sh
  1105.   $spitshell <<EOT >config.sh
  1106.   $startsh
  1107.   # config.sh
  1108.   # This file was produced by running the Configure script.
  1109.   d_eunice='$d_eunice'
  1110.   define='$define'
  1111.   eunicefix='$eunicefix'
  1112. ***************
  1113. *** 3596,3601 ****
  1114. --- 3674,3680 ----
  1115.   d_setruid='$d_setruid'
  1116.   d_shm='$d_shm'
  1117.   d_shmat='$d_shmat'
  1118. + d_voidshmat='$d_voidshmat'
  1119.   d_shmctl='$d_shmctl'
  1120.   d_shmdt='$d_shmdt'
  1121.   d_shmget='$d_shmget'
  1122. ***************
  1123. *** 3670,3675 ****
  1124. --- 3749,3755 ----
  1125.   cppflags='$cppflags'
  1126.   ldflags='$ldflags'
  1127.   cc='$cc'
  1128. + nativegcc='$nativegcc'
  1129.   libs='$libs'
  1130.   n='$n'
  1131.   c='$c'
  1132. ***************
  1133. *** 3676,3681 ****
  1134. --- 3756,3762 ----
  1135.   package='$package'
  1136.   randbits='$randbits'
  1137.   scriptdir='$scriptdir'
  1138. + installscr='$installscr'
  1139.   sig_name='$sig_name'
  1140.   spitshell='$spitshell'
  1141.   shsharp='$shsharp'
  1142. ***************
  1143. *** 3695,3708 ****
  1144.   lib='$lib'
  1145.   privlib='$privlib'
  1146.   installprivlib='$installprivlib'
  1147. - CONFIG=true
  1148.   EOT
  1149.   
  1150.   : Finish up
  1151.   CONFIG=true
  1152.   
  1153.   echo " "
  1154. - test -f patchlevel.h && awk '{printf "%s=%s\n",$2,$3}' patchlevel.h >>config.sh
  1155.   dflt=''
  1156.   fastread=''
  1157.   echo "If you didn't make any mistakes, then just type a carriage return here."
  1158. --- 3776,3808 ----
  1159.   lib='$lib'
  1160.   privlib='$privlib'
  1161.   installprivlib='$installprivlib'
  1162.   EOT
  1163.   
  1164. + test -f patchlevel.h && awk '{printf "%s=%s\n",$2,$3}' patchlevel.h >>config.sh
  1165. + echo "CONFIG=true" >>config.sh
  1166. + if test -f UU/oldconfig.sh; then
  1167. +     sed -n 's/^\([a-zA-Z_0-9]*\)=.*/\1/p' config.sh config.sh UU/oldconfig.sh |\
  1168. +       sort | uniq -u >UU/oldsyms
  1169. +     set X `cat UU/oldsyms`
  1170. +     shift
  1171. +     case $# in
  1172. +     0) ;;
  1173. +     *)  echo "Hmm...You had some extra variables I don't know about...I'll try to keep 'em..."
  1174. +     for sym in `cat UU/oldsyms`; do
  1175. +         echo "    Propagating $hint variable "'$'"$sym..."
  1176. +         eval 'tmp="$'"${sym}"'"'
  1177. +         echo "$tmp" | \
  1178. +           sed -e "s/'/'\"'\"'/g" -e "s/^/$sym='/" -e "s/$/'/" >>config.sh
  1179. +     done
  1180. +     ;;
  1181. +     esac
  1182. + fi
  1183.   : Finish up
  1184.   CONFIG=true
  1185.   
  1186.   echo " "
  1187.   dflt=''
  1188.   fastread=''
  1189.   echo "If you didn't make any mistakes, then just type a carriage return here."
  1190. ***************
  1191. *** 3714,3754 ****
  1192.   *) : in case they cannot read
  1193.       eval $ans;;
  1194.   esac
  1195. ! : if this fails, just run all the .SH files by hand
  1196. ! . ./config.sh
  1197.   
  1198. - echo " "
  1199. - echo "Doing variable substitutions on .SH files..."
  1200. - set x `awk '{print $1}' <MANIFEST | $grep '\.SH'`
  1201. - shift
  1202. - case $# in
  1203. - 0) set x *.SH; shift;;
  1204. - esac
  1205. - if test ! -f $1; then
  1206. -     shift
  1207. - fi
  1208. - for file in $*; do
  1209. -     set X
  1210. -     shift
  1211. -     chmod +x $file
  1212. -     case "$file" in
  1213. -     */*)
  1214. -     dir=`$expr X$file : 'X\(.*\)/'`
  1215. -     file=`$expr X$file : 'X.*/\(.*\)'`
  1216. -     (cd $dir && . $file)
  1217. -     ;;
  1218. -     *)
  1219. -     . $file
  1220. -     ;;
  1221. -     esac
  1222. - done
  1223. - if test -f config.h.SH; then
  1224. -     if test ! -f config.h; then
  1225. -     : oops, they left it out of MANIFEST, probably, so do it anyway.
  1226. -     . config.h.SH
  1227. -     fi
  1228. - fi
  1229.   if $contains '^depend:' [Mm]akefile >/dev/null 2>&1; then
  1230.       dflt=n
  1231.       $cat <<EOM
  1232. --- 3814,3822 ----
  1233.   *) : in case they cannot read
  1234.       eval $ans;;
  1235.   esac
  1236. ! chmod +x doSH
  1237. ! ./doSH
  1238.   
  1239.   if $contains '^depend:' [Mm]akefile >/dev/null 2>&1; then
  1240.       dflt=n
  1241.       $cat <<EOM
  1242. ***************
  1243. *** 3775,3779 ****
  1244.   fi
  1245.   
  1246.   $rm -f kit*isdone
  1247. ! cd .. && $rm -rf UU
  1248.   : end of Configure
  1249. --- 3843,3847 ----
  1250.   fi
  1251.   
  1252.   $rm -f kit*isdone
  1253. ! $rm -rf UU
  1254.   : end of Configure
  1255.  
  1256. Index: EXTERN.h
  1257. Prereq: 4.0
  1258. *** EXTERN.h.old    Fri Jun  7 12:22:23 1991
  1259. --- EXTERN.h    Fri Jun  7 12:22:24 1991
  1260. ***************
  1261. *** 1,11 ****
  1262. ! /* $Header: EXTERN.h,v 4.0 91/03/20 00:58:26 lwall Locked $
  1263.    *
  1264. !  *    Copyright (c) 1989, Larry Wall
  1265.    *
  1266. !  *    You may distribute under the terms of the GNU General Public License
  1267. !  *    as specified in the README file that comes with the perl 3.0 kit.
  1268.    *
  1269.    * $Log:    EXTERN.h,v $
  1270.    * Revision 4.0  91/03/20  00:58:26  lwall
  1271.    * 4.0 baseline.
  1272.    * 
  1273. --- 1,14 ----
  1274. ! /* $RCSfile: EXTERN.h,v $$Revision: 4.0.1.1 $$Date: 91/06/07 10:10:32 $
  1275.    *
  1276. !  *    Copyright (c) 1991, Larry Wall
  1277.    *
  1278. !  *    You may distribute under the terms of either the GNU General Public
  1279. !  *    License or the Artistic License, as specified in the README file.
  1280.    *
  1281.    * $Log:    EXTERN.h,v $
  1282. +  * Revision 4.0.1.1  91/06/07  10:10:32  lwall
  1283. +  * patch4: new copyright notice
  1284. +  * 
  1285.    * Revision 4.0  91/03/20  00:58:26  lwall
  1286.    * 4.0 baseline.
  1287.    * 
  1288.  
  1289. Index: x2p/EXTERN.h
  1290. Prereq: 4.0
  1291. *** x2p/EXTERN.h.old    Fri Jun  7 12:27:34 1991
  1292. --- x2p/EXTERN.h    Fri Jun  7 12:27:35 1991
  1293. ***************
  1294. *** 1,11 ****
  1295. ! /* $Header: EXTERN.h,v 4.0 91/03/20 01:56:53 lwall Locked $
  1296.    *
  1297. !  *    Copyright (c) 1989, Larry Wall
  1298.    *
  1299. !  *    You may distribute under the terms of the GNU General Public License
  1300. !  *    as specified in the README file that comes with the perl 3.0 kit.
  1301.    *
  1302.    * $Log:    EXTERN.h,v $
  1303.    * Revision 4.0  91/03/20  01:56:53  lwall
  1304.    * 4.0 baseline.
  1305.    * 
  1306. --- 1,14 ----
  1307. ! /* $RCSfile: EXTERN.h,v $$Revision: 4.0.1.1 $$Date: 91/06/07 12:11:15 $
  1308.    *
  1309. !  *    Copyright (c) 1991, Larry Wall
  1310.    *
  1311. !  *    You may distribute under the terms of either the GNU General Public
  1312. !  *    License or the Artistic License, as specified in the README file.
  1313.    *
  1314.    * $Log:    EXTERN.h,v $
  1315. +  * Revision 4.0.1.1  91/06/07  12:11:15  lwall
  1316. +  * patch4: new copyright notice
  1317. +  * 
  1318.    * Revision 4.0  91/03/20  01:56:53  lwall
  1319.    * 4.0 baseline.
  1320.    * 
  1321.  
  1322. Index: INTERN.h
  1323. Prereq: 4.0
  1324. *** INTERN.h.old    Fri Jun  7 12:22:26 1991
  1325. --- INTERN.h    Fri Jun  7 12:22:27 1991
  1326. ***************
  1327. *** 1,11 ****
  1328. ! /* $Header: INTERN.h,v 4.0 91/03/20 00:58:35 lwall Locked $
  1329.    *
  1330. !  *    Copyright (c) 1989, Larry Wall
  1331.    *
  1332. !  *    You may distribute under the terms of the GNU General Public License
  1333. !  *    as specified in the README file that comes with the perl 3.0 kit.
  1334.    *
  1335.    * $Log:    INTERN.h,v $
  1336.    * Revision 4.0  91/03/20  00:58:35  lwall
  1337.    * 4.0 baseline.
  1338.    * 
  1339. --- 1,14 ----
  1340. ! /* $RCSfile: INTERN.h,v $$Revision: 4.0.1.1 $$Date: 91/06/07 10:10:42 $
  1341.    *
  1342. !  *    Copyright (c) 1991, Larry Wall
  1343.    *
  1344. !  *    You may distribute under the terms of either the GNU General Public
  1345. !  *    License or the Artistic License, as specified in the README file.
  1346.    *
  1347.    * $Log:    INTERN.h,v $
  1348. +  * Revision 4.0.1.1  91/06/07  10:10:42  lwall
  1349. +  * patch4: new copyright notice
  1350. +  * 
  1351.    * Revision 4.0  91/03/20  00:58:35  lwall
  1352.    * 4.0 baseline.
  1353.    * 
  1354.  
  1355. Index: x2p/INTERN.h
  1356. Prereq: 4.0
  1357. *** x2p/INTERN.h.old    Fri Jun  7 12:27:37 1991
  1358. --- x2p/INTERN.h    Fri Jun  7 12:27:37 1991
  1359. ***************
  1360. *** 1,11 ****
  1361. ! /* $Header: INTERN.h,v 4.0 91/03/20 01:56:58 lwall Locked $
  1362.    *
  1363. !  *    Copyright (c) 1989, Larry Wall
  1364.    *
  1365. !  *    You may distribute under the terms of the GNU General Public License
  1366. !  *    as specified in the README file that comes with the perl 3.0 kit.
  1367.    *
  1368.    * $Log:    INTERN.h,v $
  1369.    * Revision 4.0  91/03/20  01:56:58  lwall
  1370.    * 4.0 baseline.
  1371.    * 
  1372. --- 1,14 ----
  1373. ! /* $RCSfile: INTERN.h,v $$Revision: 4.0.1.1 $$Date: 91/06/07 12:11:20 $
  1374.    *
  1375. !  *    Copyright (c) 1991, Larry Wall
  1376.    *
  1377. !  *    You may distribute under the terms of either the GNU General Public
  1378. !  *    License or the Artistic License, as specified in the README file.
  1379.    *
  1380.    * $Log:    INTERN.h,v $
  1381. +  * Revision 4.0.1.1  91/06/07  12:11:20  lwall
  1382. +  * patch4: new copyright notice
  1383. +  * 
  1384.    * Revision 4.0  91/03/20  01:56:58  lwall
  1385.    * 4.0 baseline.
  1386.    * 
  1387.  
  1388. Index: MANIFEST
  1389. *** MANIFEST.old    Fri Jun  7 12:22:30 1991
  1390. --- MANIFEST    Fri Jun  7 12:22:31 1991
  1391. ***************
  1392. *** 1,3 ****
  1393. --- 1,4 ----
  1394. + Artistic        The "Artistic License"
  1395.   Configure        Run this first
  1396.   Copying            The GNU General Public License
  1397.   EXTERN.h        Included before foreign .h files
  1398. ***************
  1399. *** 20,25 ****
  1400. --- 21,27 ----
  1401.   config_h.SH        Produces config.h
  1402.   cons.c            Routines to construct cmd nodes of a parse tree
  1403.   consarg.c        Routines to construct arg nodes of a parse tree
  1404. + doSH            Script to run all the *.SH files
  1405.   doarg.c            Scalar expression evaluation
  1406.   doio.c            I/O operations
  1407.   dolist.c        Array expression evaluation
  1408. ***************
  1409. *** 87,92 ****
  1410. --- 89,95 ----
  1411.   handy.h            Handy definitions
  1412.   hash.c            Associative arrays
  1413.   hash.h            Public declarations for the above
  1414. + hints/3b1.sh
  1415.   hints/3b2.sh
  1416.   hints/aix_rs.sh
  1417.   hints/aix_rt.sh
  1418. ***************
  1419. *** 114,122 ****
  1420. --- 117,127 ----
  1421.   hints/sunos_3_5.sh
  1422.   hints/sunos_4_0_1.sh
  1423.   hints/sunos_4_0_2.sh
  1424. + hints/svr4.sh
  1425.   hints/ultrix_3.sh
  1426.   hints/ultrix_4.sh
  1427.   hints/uts.sh
  1428. + hints/vax.sh
  1429.   installperl        Perl script to do "make install" dirty work
  1430.   ioctl.pl        Sample ioctl.pl
  1431.   lib/abbrev.pl        An abbreviation table builder
  1432. ***************
  1433. *** 127,139 ****
  1434. --- 132,148 ----
  1435.   lib/complete.pl        A command completion subroutine
  1436.   lib/ctime.pl        A ctime workalike
  1437.   lib/dumpvar.pl        A variable dumper
  1438. + lib/find.pl        A find emulator--used by find2perl
  1439. + lib/finddepth.pl    A depth-first find emulator--used by find2perl
  1440.   lib/flush.pl        Routines to do single flush
  1441.   lib/getopt.pl        Perl library supporting option parsing
  1442.   lib/getopts.pl        Perl library supporting option parsing
  1443.   lib/importenv.pl    Perl routine to get environment into variables
  1444.   lib/look.pl        A "look" equivalent
  1445. + lib/newgetopt.pl    A perl library supporting long option parsing
  1446.   lib/perldb.pl        Perl debugging routines
  1447.   lib/pwd.pl        Routines to keep track of PWD environment variable
  1448. + lib/shellwords.pl    Perl library to split into words with shell quoting
  1449.   lib/stat.pl        Perl library supporting stat function
  1450.   lib/syslog.pl        Perl library supporting syslogging
  1451.   lib/termcap.pl        Perl library supporting termcap usage
  1452. ***************
  1453. *** 296,301 ****
  1454. --- 305,311 ----
  1455.   x2p/a2p.man        Manual page for awk to perl translator
  1456.   x2p/a2p.y        A yacc grammer for awk
  1457.   x2p/a2py.c        Awk compiler, sort of
  1458. + x2p/cflags.SH        A script that emits C compilation flags per file
  1459.   x2p/find2perl.SH    A find to perl translator
  1460.   x2p/handy.h        Handy definitions
  1461.   x2p/hash.c        Associative arrays again
  1462.  
  1463. Index: usub/Makefile
  1464. *** usub/Makefile.old    Fri Jun  7 12:27:23 1991
  1465. --- usub/Makefile    Fri Jun  7 12:27:23 1991
  1466. ***************
  1467. *** 1,10 ****
  1468. ! SRC = /usr/local/src/perl
  1469.   GLOBINCS = 
  1470.   LOCINCS = 
  1471. ! LIBS = -lcurses -ltermlib
  1472.   
  1473.   curseperl: $(SRC)/uperl.o usersub.o curses.o
  1474. !     cc $(SRC)/uperl.o usersub.o curses.o $(LIBS) -lm -o curseperl
  1475.   
  1476.   usersub.o: usersub.c
  1477.       cc -c -I$(SRC) $(GLOBINCS) -DDEBUGGING -g usersub.c
  1478. --- 1,10 ----
  1479. ! SRC = ..
  1480.   GLOBINCS = 
  1481.   LOCINCS = 
  1482. ! LIBS = -lcurses -ltermlib `. $(SRC)/config.sh; echo $$libs`
  1483.   
  1484.   curseperl: $(SRC)/uperl.o usersub.o curses.o
  1485. !     cc $(SRC)/uperl.o usersub.o curses.o $(LIBS) -o curseperl
  1486.   
  1487.   usersub.o: usersub.c
  1488.       cc -c -I$(SRC) $(GLOBINCS) -DDEBUGGING -g usersub.c
  1489.  
  1490. Index: Makefile.SH
  1491. *** Makefile.SH.old    Fri Jun  7 12:22:33 1991
  1492. --- Makefile.SH    Fri Jun  7 12:22:34 1991
  1493. ***************
  1494. *** 25,33 ****
  1495.   
  1496.   echo "Extracting Makefile (with variable substitutions)"
  1497.   cat >Makefile <<!GROK!THIS!
  1498. ! # $RCSfile: Makefile.SH,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:30:39 $
  1499.   #
  1500.   # $Log:    Makefile.SH,v $
  1501.   # Revision 4.0.1.1  91/04/11  17:30:39  lwall
  1502.   # patch1: C flags are now settable on a per-file basis
  1503.   # 
  1504. --- 25,39 ----
  1505.   
  1506.   echo "Extracting Makefile (with variable substitutions)"
  1507.   cat >Makefile <<!GROK!THIS!
  1508. ! # $RCSfile: Makefile.SH,v $$Revision: 4.0.1.2 $$Date: 91/06/07 10:14:43 $
  1509.   #
  1510.   # $Log:    Makefile.SH,v $
  1511. + # Revision 4.0.1.2  91/06/07  10:14:43  lwall
  1512. + # patch4: cflags now emits entire cc command except for the filename
  1513. + # patch4: alternate make programs are now semi-supported
  1514. + # patch4: uperl.o no longer tries to link in libraries prematurely
  1515. + # patch4: installperl now installs x2p stuff too
  1516. + # 
  1517.   # Revision 4.0.1.1  91/04/11  17:30:39  lwall
  1518.   # patch1: C flags are now settable on a per-file basis
  1519.   # 
  1520. ***************
  1521. *** 55,72 ****
  1522.   
  1523.   public = perl taintperl $suidperl
  1524.   
  1525.   !GROK!THIS!
  1526.   
  1527.   cat >>Makefile <<'!NO!SUBS!'
  1528.   
  1529. ! CFLAGS = `sh cflags.SH $@`
  1530.   
  1531.   private = 
  1532.   
  1533.   scripts = h2ph
  1534.   
  1535. - MAKE = make
  1536.   manpages = perl.man h2ph.man
  1537.   
  1538.   util =
  1539. --- 61,79 ----
  1540.   
  1541.   public = perl taintperl $suidperl
  1542.   
  1543. + # To use an alternate make, set $altmake in config.sh.
  1544. + MAKE = ${altmake-make}
  1545.   !GROK!THIS!
  1546.   
  1547.   cat >>Makefile <<'!NO!SUBS!'
  1548.   
  1549. ! CCCMD = `sh cflags $@`
  1550.   
  1551.   private = 
  1552.   
  1553.   scripts = h2ph
  1554.   
  1555.   manpages = perl.man h2ph.man
  1556.   
  1557.   util =
  1558. ***************
  1559. *** 104,110 ****
  1560.   SHELL = /bin/sh
  1561.   
  1562.   .c.o:
  1563. !     $(CC) -c $(CFLAGS) $*.c
  1564.   
  1565.   all: $(public) $(private) $(util) uperl.o $(scripts)
  1566.       cd x2p; $(MAKE) all
  1567. --- 111,117 ----
  1568.   SHELL = /bin/sh
  1569.   
  1570.   .c.o:
  1571. !     $(CCCMD) $*.c
  1572.   
  1573.   all: $(public) $(private) $(util) uperl.o $(scripts)
  1574.       cd x2p; $(MAKE) all
  1575. ***************
  1576. *** 119,125 ****
  1577.       $(CC) $(LARGE) $(CLDFLAGS) $(obj) perly.o usersub.o $(libs) -o perl
  1578.   
  1579.   uperl.o: $& perly.o $(obj)
  1580. !     -ld $(LARGE) $(LDFLAGS) -r $(obj) perly.o $(libs) -o uperl.o
  1581.   
  1582.   saber: perly.c
  1583.       # load $(c) perly.c
  1584. --- 126,132 ----
  1585.       $(CC) $(LARGE) $(CLDFLAGS) $(obj) perly.o usersub.o $(libs) -o perl
  1586.   
  1587.   uperl.o: $& perly.o $(obj)
  1588. !     -ld $(LARGE) $(LDFLAGS) -r $(obj) perly.o -o uperl.o
  1589.   
  1590.   saber: perly.c
  1591.       # load $(c) perly.c
  1592. ***************
  1593. *** 147,267 ****
  1594.   tperly.o: perly.c perly.h $(h)
  1595.       /bin/rm -f tperly.c
  1596.       $(SLN) perly.c tperly.c
  1597. !     $(CC) -c -DTAINT $(CFLAGS) tperly.c
  1598.       /bin/rm -f tperly.c
  1599.   
  1600.   tperl.o: perl.c perly.h patchlevel.h perl.h $(h)
  1601.       /bin/rm -f tperl.c
  1602.       $(SLN) perl.c tperl.c
  1603. !     $(CC) -c -DTAINT $(CFLAGS) tperl.c
  1604.       /bin/rm -f tperl.c
  1605.   
  1606.   sperl.o: perl.c perly.h patchlevel.h $(h)
  1607.       /bin/rm -f sperl.c
  1608.       $(SLN) perl.c sperl.c
  1609. !     $(CC) -c -DTAINT -DIAMSUID $(CFLAGS) sperl.c
  1610.       /bin/rm -f sperl.c
  1611.   
  1612.   tarray.o: array.c $(h)
  1613.       /bin/rm -f tarray.c
  1614.       $(SLN) array.c tarray.c
  1615. !     $(CC) -c -DTAINT $(CFLAGS) tarray.c
  1616.       /bin/rm -f tarray.c
  1617.   
  1618.   tcmd.o: cmd.c $(h)
  1619.       /bin/rm -f tcmd.c
  1620.       $(SLN) cmd.c tcmd.c
  1621. !     $(CC) -c -DTAINT $(CFLAGS) tcmd.c
  1622.       /bin/rm -f tcmd.c
  1623.   
  1624.   tcons.o: cons.c $(h) perly.h
  1625.       /bin/rm -f tcons.c
  1626.       $(SLN) cons.c tcons.c
  1627. !     $(CC) -c -DTAINT $(CFLAGS) tcons.c
  1628.       /bin/rm -f tcons.c
  1629.   
  1630.   tconsarg.o: consarg.c $(h)
  1631.       /bin/rm -f tconsarg.c
  1632.       $(SLN) consarg.c tconsarg.c
  1633. !     $(CC) -c -DTAINT $(CFLAGS) tconsarg.c
  1634.       /bin/rm -f tconsarg.c
  1635.   
  1636.   tdoarg.o: doarg.c $(h)
  1637.       /bin/rm -f tdoarg.c
  1638.       $(SLN) doarg.c tdoarg.c
  1639. !     $(CC) -c -DTAINT $(CFLAGS) tdoarg.c
  1640.       /bin/rm -f tdoarg.c
  1641.   
  1642.   tdoio.o: doio.c $(h)
  1643.       /bin/rm -f tdoio.c
  1644.       $(SLN) doio.c tdoio.c
  1645. !     $(CC) -c -DTAINT $(CFLAGS) tdoio.c
  1646.       /bin/rm -f tdoio.c
  1647.   
  1648.   tdolist.o: dolist.c $(h)
  1649.       /bin/rm -f tdolist.c
  1650.       $(SLN) dolist.c tdolist.c
  1651. !     $(CC) -c -DTAINT $(CFLAGS) tdolist.c
  1652.       /bin/rm -f tdolist.c
  1653.   
  1654.   tdump.o: dump.c $(h)
  1655.       /bin/rm -f tdump.c
  1656.       $(SLN) dump.c tdump.c
  1657. !     $(CC) -c -DTAINT $(CFLAGS) tdump.c
  1658.       /bin/rm -f tdump.c
  1659.   
  1660.   teval.o: eval.c $(h)
  1661.       /bin/rm -f teval.c
  1662.       $(SLN) eval.c teval.c
  1663. !     $(CC) -c -DTAINT $(CFLAGS) teval.c
  1664.       /bin/rm -f teval.c
  1665.   
  1666.   tform.o: form.c $(h)
  1667.       /bin/rm -f tform.c
  1668.       $(SLN) form.c tform.c
  1669. !     $(CC) -c -DTAINT $(CFLAGS) tform.c
  1670.       /bin/rm -f tform.c
  1671.   
  1672.   thash.o: hash.c $(h)
  1673.       /bin/rm -f thash.c
  1674.       $(SLN) hash.c thash.c
  1675. !     $(CC) -c -DTAINT $(CFLAGS) thash.c
  1676.       /bin/rm -f thash.c
  1677.   
  1678.   tregcomp.o: regcomp.c $(h)
  1679.       /bin/rm -f tregcomp.c
  1680.       $(SLN) regcomp.c tregcomp.c
  1681. !     $(CC) -c -DTAINT $(CFLAGS) tregcomp.c
  1682.       /bin/rm -f tregcomp.c
  1683.   
  1684.   tregexec.o: regexec.c $(h)
  1685.       /bin/rm -f tregexec.c
  1686.       $(SLN) regexec.c tregexec.c
  1687. !     $(CC) -c -DTAINT $(CFLAGS) tregexec.c
  1688.       /bin/rm -f tregexec.c
  1689.   
  1690.   tstab.o: stab.c $(h)
  1691.       /bin/rm -f tstab.c
  1692.       $(SLN) stab.c tstab.c
  1693. !     $(CC) -c -DTAINT $(CFLAGS) tstab.c
  1694.       /bin/rm -f tstab.c
  1695.   
  1696.   tstr.o: str.c $(h) perly.h
  1697.       /bin/rm -f tstr.c
  1698.       $(SLN) str.c tstr.c
  1699. !     $(CC) -c -DTAINT $(CFLAGS) tstr.c
  1700.       /bin/rm -f tstr.c
  1701.   
  1702.   ttoke.o: toke.c $(h) perly.h
  1703.       /bin/rm -f ttoke.c
  1704.       $(SLN) toke.c ttoke.c
  1705. !     $(CC) -c -DTAINT $(CFLAGS) ttoke.c
  1706.       /bin/rm -f ttoke.c
  1707.   
  1708.   tutil.o: util.c $(h)
  1709.       /bin/rm -f tutil.c
  1710.       $(SLN) util.c tutil.c
  1711. !     $(CC) -c -DTAINT $(CFLAGS) tutil.c
  1712.       /bin/rm -f tutil.c
  1713.   
  1714.   perly.h: perly.c
  1715. --- 154,274 ----
  1716.   tperly.o: perly.c perly.h $(h)
  1717.       /bin/rm -f tperly.c
  1718.       $(SLN) perly.c tperly.c
  1719. !     $(CCCMD) -DTAINT tperly.c
  1720.       /bin/rm -f tperly.c
  1721.   
  1722.   tperl.o: perl.c perly.h patchlevel.h perl.h $(h)
  1723.       /bin/rm -f tperl.c
  1724.       $(SLN) perl.c tperl.c
  1725. !     $(CCCMD) -DTAINT tperl.c
  1726.       /bin/rm -f tperl.c
  1727.   
  1728.   sperl.o: perl.c perly.h patchlevel.h $(h)
  1729.       /bin/rm -f sperl.c
  1730.       $(SLN) perl.c sperl.c
  1731. !     $(CCCMD) -DTAINT -DIAMSUID sperl.c
  1732.       /bin/rm -f sperl.c
  1733.   
  1734.   tarray.o: array.c $(h)
  1735.       /bin/rm -f tarray.c
  1736.       $(SLN) array.c tarray.c
  1737. !     $(CCCMD) -DTAINT tarray.c
  1738.       /bin/rm -f tarray.c
  1739.   
  1740.   tcmd.o: cmd.c $(h)
  1741.       /bin/rm -f tcmd.c
  1742.       $(SLN) cmd.c tcmd.c
  1743. !     $(CCCMD) -DTAINT tcmd.c
  1744.       /bin/rm -f tcmd.c
  1745.   
  1746.   tcons.o: cons.c $(h) perly.h
  1747.       /bin/rm -f tcons.c
  1748.       $(SLN) cons.c tcons.c
  1749. !     $(CCCMD) -DTAINT tcons.c
  1750.       /bin/rm -f tcons.c
  1751.   
  1752.   tconsarg.o: consarg.c $(h)
  1753.       /bin/rm -f tconsarg.c
  1754.       $(SLN) consarg.c tconsarg.c
  1755. !     $(CCCMD) -DTAINT tconsarg.c
  1756.       /bin/rm -f tconsarg.c
  1757.   
  1758.   tdoarg.o: doarg.c $(h)
  1759.       /bin/rm -f tdoarg.c
  1760.       $(SLN) doarg.c tdoarg.c
  1761. !     $(CCCMD) -DTAINT tdoarg.c
  1762.       /bin/rm -f tdoarg.c
  1763.   
  1764.   tdoio.o: doio.c $(h)
  1765.       /bin/rm -f tdoio.c
  1766.       $(SLN) doio.c tdoio.c
  1767. !     $(CCCMD) -DTAINT tdoio.c
  1768.       /bin/rm -f tdoio.c
  1769.   
  1770.   tdolist.o: dolist.c $(h)
  1771.       /bin/rm -f tdolist.c
  1772.       $(SLN) dolist.c tdolist.c
  1773. !     $(CCCMD) -DTAINT tdolist.c
  1774.       /bin/rm -f tdolist.c
  1775.   
  1776.   tdump.o: dump.c $(h)
  1777.       /bin/rm -f tdump.c
  1778.       $(SLN) dump.c tdump.c
  1779. !     $(CCCMD) -DTAINT tdump.c
  1780.       /bin/rm -f tdump.c
  1781.   
  1782.   teval.o: eval.c $(h)
  1783.       /bin/rm -f teval.c
  1784.       $(SLN) eval.c teval.c
  1785. !     $(CCCMD) -DTAINT teval.c
  1786.       /bin/rm -f teval.c
  1787.   
  1788.   tform.o: form.c $(h)
  1789.       /bin/rm -f tform.c
  1790.       $(SLN) form.c tform.c
  1791. !     $(CCCMD) -DTAINT tform.c
  1792.       /bin/rm -f tform.c
  1793.   
  1794.   thash.o: hash.c $(h)
  1795.       /bin/rm -f thash.c
  1796.       $(SLN) hash.c thash.c
  1797. !     $(CCCMD) -DTAINT thash.c
  1798.       /bin/rm -f thash.c
  1799.   
  1800.   tregcomp.o: regcomp.c $(h)
  1801.       /bin/rm -f tregcomp.c
  1802.       $(SLN) regcomp.c tregcomp.c
  1803. !     $(CCCMD) -DTAINT tregcomp.c
  1804.       /bin/rm -f tregcomp.c
  1805.   
  1806.   tregexec.o: regexec.c $(h)
  1807.       /bin/rm -f tregexec.c
  1808.       $(SLN) regexec.c tregexec.c
  1809. !     $(CCCMD) -DTAINT tregexec.c
  1810.       /bin/rm -f tregexec.c
  1811.   
  1812.   tstab.o: stab.c $(h)
  1813.       /bin/rm -f tstab.c
  1814.       $(SLN) stab.c tstab.c
  1815. !     $(CCCMD) -DTAINT tstab.c
  1816.       /bin/rm -f tstab.c
  1817.   
  1818.   tstr.o: str.c $(h) perly.h
  1819.       /bin/rm -f tstr.c
  1820.       $(SLN) str.c tstr.c
  1821. !     $(CCCMD) -DTAINT tstr.c
  1822.       /bin/rm -f tstr.c
  1823.   
  1824.   ttoke.o: toke.c $(h) perly.h
  1825.       /bin/rm -f ttoke.c
  1826.       $(SLN) toke.c ttoke.c
  1827. !     $(CCCMD) -DTAINT ttoke.c
  1828.       /bin/rm -f ttoke.c
  1829.   
  1830.   tutil.o: util.c $(h)
  1831.       /bin/rm -f tutil.c
  1832.       $(SLN) util.c tutil.c
  1833. !     $(CCCMD) -DTAINT tutil.c
  1834.       /bin/rm -f tutil.c
  1835.   
  1836.   perly.h: perly.c
  1837. ***************
  1838. *** 268,287 ****
  1839.       @ echo Dummy dependency for dumb parallel make
  1840.       touch perly.h
  1841.   
  1842. ! perly.c: perly.y
  1843.       @ echo 'Expect either' 29 shift/reduce and 59 reduce/reduce conflicts...
  1844.       @ echo '           or' 27 shift/reduce and 61 reduce/reduce conflicts...
  1845.       $(YACC) -d perly.y
  1846. !     sh perly.fixer y.tab.c perly.c
  1847.       mv y.tab.h perly.h
  1848.       echo 'extern YYSTYPE yylval;' >>perly.h
  1849.   
  1850.   perly.o: perly.c perly.h $(h)
  1851. !     $(CC) -c $(CFLAGS) perly.c
  1852.   
  1853.   install: all
  1854.       ./perl installperl
  1855. -     cd x2p; $(MAKE) install
  1856.   
  1857.   clean:
  1858.       rm -f *.o all perl taintperl suidperl
  1859. --- 275,293 ----
  1860.       @ echo Dummy dependency for dumb parallel make
  1861.       touch perly.h
  1862.   
  1863. ! perly.c: perly.y perly.fixer
  1864.       @ echo 'Expect either' 29 shift/reduce and 59 reduce/reduce conflicts...
  1865.       @ echo '           or' 27 shift/reduce and 61 reduce/reduce conflicts...
  1866.       $(YACC) -d perly.y
  1867. !     sh ./perly.fixer y.tab.c perly.c
  1868.       mv y.tab.h perly.h
  1869.       echo 'extern YYSTYPE yylval;' >>perly.h
  1870.   
  1871.   perly.o: perly.c perly.h $(h)
  1872. !     $(CCCMD) perly.c
  1873.   
  1874.   install: all
  1875.       ./perl installperl
  1876.   
  1877.   clean:
  1878.       rm -f *.o all perl taintperl suidperl
  1879. ***************
  1880. *** 291,297 ****
  1881.       cd x2p; $(MAKE) realclean
  1882.       rm -f *.orig */*.orig *~ */*~ core $(addedbyconf) h2ph h2ph.man
  1883.       rm -f perly.c perly.h t/perl Makefile config.h makedepend makedir
  1884. !     rm -f x2p/Makefile
  1885.   
  1886.   # The following lint has practically everything turned on.  Unfortunately,
  1887.   # you have to wade through a lot of mumbo jumbo that can't be suppressed.
  1888. --- 297,303 ----
  1889.       cd x2p; $(MAKE) realclean
  1890.       rm -f *.orig */*.orig *~ */*~ core $(addedbyconf) h2ph h2ph.man
  1891.       rm -f perly.c perly.h t/perl Makefile config.h makedepend makedir
  1892. !     rm -f makefile x2p/Makefile x2p/makefile cflags x2p/cflags
  1893.   
  1894.   # The following lint has practically everything turned on.  Unfortunately,
  1895.   # you have to wade through a lot of mumbo jumbo that can't be suppressed.
  1896.  
  1897. *** End of Patch 4 ***
  1898. exit 0 # Just in case...
  1899. -- 
  1900. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  1901. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  1902. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  1903. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  1904.