home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume16 / ecu3 / patch01 < prev    next >
Encoding:
Internet Message Format  |  1991-01-06  |  52.6 KB

  1. From: wht@n4hgf.uucp (Warren Tucker)
  2. Newsgroups: comp.sources.misc
  3. Subject: v16i060:  ECU async comm package rev 3.0, Patch01
  4. Message-ID: <1991Jan6.054607.29263@sparky.IMD.Sterling.COM>
  5. Date: 6 Jan 91 05:46:07 GMT
  6. Approved: kent@sparky.imd.sterling.com
  7. X-Checksum-Snefru: 31bc0f4d b453da28 71da10b2 aa6b936f
  8.  
  9. Submitted-by: wht@n4hgf.uucp (Warren Tucker)
  10. Posting-number: Volume 16, Issue 60
  11. Archive-name: ecu3/patch01
  12. Patch-To: ecu3: Volume 16, Issue 25-59
  13.  
  14. This is patch 1 to ECU 3.  It provides speed improvements
  15. and fixes for non-ANSI terminal support.  Also provided is an
  16. experimental make file for GCC 1.37.1 on UNIX systems.
  17.  
  18. To apply, place this shar in the ECU distribution directory
  19. and unshar it. Then:
  20. 1. patch < PATCH01
  21. 2. make -or- make -f Make.xgcc
  22. 3. rm .orig or ~ files from patch when you are satisfied all is well
  23.  
  24. #!/bin/sh
  25. # This is ecu3_PATCH01, a shell archive (shar 3.46)
  26. # made 01/02/1991 04:02 UTC by wht@n4hgf
  27. # Source directory /u1/src/ecu
  28. #
  29. # existing files WILL be overwritten
  30. #
  31. # This shar contains:
  32. # length  mode       name
  33. # ------ ---------- ------------------------------------------
  34. #  36829 -rw-r--r-- PATCH01
  35. #     21 -rw-r--r-- patchlevel.h
  36. #  12403 -rw-r--r-- Make.xgcc
  37. #
  38. # ============= PATCH01 ==============
  39. echo 'x - extracting PATCH01 (Text)'
  40. sed 's/^X//' << 'SHAR_EOF' > 'PATCH01' &&
  41. X:
  42. X#+-------------------------------------------------------------------------
  43. X# ECU 3.0 PATCH # 1 - Speed Improvements and Non-ANSI Fixes
  44. X#
  45. X# 1.  Speed improvements in the receiver process have been made.
  46. X#     a.  memmove is used in mem_cpy (ecuutil.c); Duff's Device may be
  47. X#         used if you do not have memmove (add a #define DUFF)
  48. X#     b.  memset is used in spaces (ecurcvr.c)
  49. X#     c.  #pragma intrinsic is used throughout for memset and memcpy
  50. X#         (I am still suspicious/superstitious about intrinsics:
  51. X#         they break badly with all but simple pointer arguments;
  52. X#         I know how I use memset and memcpy; changers beware).
  53. X#
  54. X# 2.  Attribute mapping with non-ANSI terminals works muuuch better
  55. X#     now, as does ruling character->printable character mapping.
  56. X#
  57. X# 3.  "bell notify" has been fixed to exclude the current terminal
  58. X#     from getting the alarm (this used to work, but fell out somewhere)
  59. X#
  60. X# 4.  various changes to make GCC happier
  61. X#     
  62. X# created by gendiff x1.03 on 02 Jan 1991 03:55 UTC
  63. X#--------------------------------------------------------------------------
  64. X*** /u4/src/ecu3/ecu.c    Wed Dec 26 04:44:00 1990
  65. X--- ecu.c    Tue Jan  1 20:46:59 1991
  66. X***************
  67. X*** 121,126
  68. X    main() program forks to create rcvr process; then main()
  69. X    becomes the xmtr process
  70. X  ------------------------------------------------------------------------*/
  71. X  main(argc,argv,envp)
  72. X  int argc;
  73. X  char **argv;
  74. X
  75. X--- 121,127 -----
  76. X    main() program forks to create rcvr process; then main()
  77. X    becomes the xmtr process
  78. X  ------------------------------------------------------------------------*/
  79. X+ int
  80. X  main(argc,argv,envp)
  81. X  int argc;
  82. X  char **argv;
  83. X*** /u4/src/ecu3/ecu.h    Mon Dec 24 22:26:00 1990
  84. X--- ecu.h    Tue Jan  1 22:52:04 1991
  85. X***************
  86. X*** 3,8
  87. X      wht@n4hgf.Mt-Park.GA.US
  88. X  ------------------------------------------------------------------------*/
  89. X  /*+:EDITS:*/
  90. X  /*:08-14-1990-20:39-wht@n4hgf-ecu3.00-flush old edit history */
  91. X  
  92. X  #define ECULIBDIR "/usr/local/lib/ecu"
  93. X
  94. X--- 3,9 -----
  95. X      wht@n4hgf.Mt-Park.GA.US
  96. X  ------------------------------------------------------------------------*/
  97. X  /*+:EDITS:*/
  98. X+ /*:01-01-1991-21:36-wht@n4hgf-add GCC implies STDC */
  99. X  /*:08-14-1990-20:39-wht@n4hgf-ecu3.00-flush old edit history */
  100. X  
  101. X  #define ECULIBDIR "/usr/local/lib/ecu"
  102. X***************
  103. X*** 7,12
  104. X  
  105. X  #define ECULIBDIR "/usr/local/lib/ecu"
  106. X  
  107. X  #if defined(__STDC__)    /* sigh ... malloc and such types */
  108. X  #define VTYPE void
  109. X  #else
  110. X
  111. X--- 8,17 -----
  112. X  
  113. X  #define ECULIBDIR "/usr/local/lib/ecu"
  114. X  
  115. X+ #if defined(__GCC__) && !defined(__STDC__)
  116. X+ #define  __STDC__
  117. X+ #endif
  118. X+ 
  119. X  #if defined(__STDC__)    /* sigh ... malloc and such types */
  120. X  #define VTYPE void
  121. X  #else
  122. X***************
  123. X*** 13,31
  124. X  #define VTYPE char
  125. X  #endif
  126. X  
  127. X- #if defined(M_UNIX)
  128. X- #undef M_XENIX        /* we don't want this defined in UNIX world */
  129. X- #undef NO_SELECT    /* UNIX select(S) works */
  130. X- #endif
  131. X- 
  132. X- #if defined(M_I286) && !defined(NO_SELECT)
  133. X- #define NO_SELECT    /* the last 286 XENIX I saw (2.2.1) had no select */
  134. X- #endif
  135. X- 
  136. X- #ifndef ECULIBDIR
  137. X- #define ECULIBDIR "/usr/lib/ecu"
  138. X- #endif
  139. X- 
  140. X  #if !defined(STDIO_H_INCLUDED)
  141. X  #include <stdio.h>
  142. X  #endif
  143. X
  144. X--- 18,23 -----
  145. X  #define VTYPE char
  146. X  #endif
  147. X  
  148. X  #if !defined(STDIO_H_INCLUDED)
  149. X  #include <stdio.h>
  150. X  #endif
  151. X***************
  152. X*** 43,48
  153. X  #include <termio.h>
  154. X  #endif
  155. X  
  156. X  #include "ecuhangup.h"
  157. X  #include "ecushm.h"
  158. X  
  159. X
  160. X--- 35,55 -----
  161. X  #include <termio.h>
  162. X  #endif
  163. X  
  164. X+ #if defined(M_UNIX)
  165. X+ #undef M_XENIX        /* we don't want this defined in UNIX world */
  166. X+ #undef NO_SELECT    /* UNIX select(S) works */
  167. X+ #pragma intrinsic(memcpy)    /* trust these intrinsics ... */
  168. X+ #pragma intrinsic(memset)    /* ... because we know how we use them */
  169. X+ #endif
  170. X+ 
  171. X+ #if defined(M_I286) && !defined(NO_SELECT)
  172. X+ #define NO_SELECT    /* the last 286 XENIX I saw (2.2.1) had no select */
  173. X+ #endif
  174. X+ 
  175. X+ #ifndef ECULIBDIR
  176. X+ #define ECULIBDIR "/usr/lib/ecu"
  177. X+ #endif
  178. X+ 
  179. X  #include "ecuhangup.h"
  180. X  #include "ecushm.h"
  181. X  
  182. X***************
  183. X*** 134,140
  184. X      char *delim;    /* ending string for lgets_timeout_or_delim */
  185. X      int echo;        /* echo incdoming chars to screen */
  186. X  }    LRWT;
  187. X- 
  188. X  #include "stdio_lint.h"
  189. X  #include "lint_args.h"
  190. X  /* vi: set tabstop=4 shiftwidth=4: */
  191. X
  192. X--- 141,146 -----
  193. X      char *delim;    /* ending string for lgets_timeout_or_delim */
  194. X      int echo;        /* echo incdoming chars to screen */
  195. X  }    LRWT;
  196. X  #include "stdio_lint.h"
  197. X  #include "lint_args.h"
  198. X  /* vi: set tabstop=4 shiftwidth=4: */
  199. X*** /u4/src/ecu3/ecuDCE.c    Mon Dec 24 22:27:00 1990
  200. X--- ecuDCE.c    Tue Jan  1 21:43:59 1991
  201. X***************
  202. X*** 656,661
  203. X              goto START_RCVR_PROCESS;
  204. X          }
  205. X          setcolor(colors_error);
  206. X  CONNECT_FAILED:
  207. X          pprintf("%s\n",result);
  208. X          iv[0] = 1;
  209. X
  210. X--- 656,662 -----
  211. X              goto START_RCVR_PROCESS;
  212. X          }
  213. X          setcolor(colors_error);
  214. X+ #ifdef WHT
  215. X  CONNECT_FAILED:
  216. X  #endif
  217. X          pprintf("%s\n",result);
  218. X***************
  219. X*** 657,662
  220. X          }
  221. X          setcolor(colors_error);
  222. X  CONNECT_FAILED:
  223. X          pprintf("%s\n",result);
  224. X          iv[0] = 1;
  225. X          DCE_report_iv_set(0);
  226. X
  227. X--- 658,664 -----
  228. X          setcolor(colors_error);
  229. X  #ifdef WHT
  230. X  CONNECT_FAILED:
  231. X+ #endif
  232. X          pprintf("%s\n",result);
  233. X          iv[0] = 1;
  234. X          DCE_report_iv_set(0);
  235. X***************
  236. X*** 749,755
  237. X      DCE_hangup();
  238. X      while(retries--)
  239. X      {
  240. X-     register itmp;
  241. X  
  242. X  #ifdef AUTO_DIAL_PROC
  243. X          if(!isdigit(shm->Llogical[0]) && find_procedure(shm->Llogical))
  244. X
  245. X--- 751,756 -----
  246. X      DCE_hangup();
  247. X      while(retries--)
  248. X      {
  249. X  
  250. X  #ifdef AUTO_DIAL_PROC
  251. X          if(!isdigit(shm->Llogical[0]) && find_procedure(shm->Llogical))
  252. X*** /u4/src/ecu3/ecufinsert.c    Mon Dec 24 22:28:00 1990
  253. X--- ecufinsert.c    Tue Jan  1 21:43:01 1991
  254. X***************
  255. X*** 62,67
  256. X  file_insert_clear_xoff()
  257. X  {
  258. X  #ifdef USE_XON_XOFF
  259. X  ulong colors_at_entry = colors_current;
  260. X  
  261. X      lclear_xmtr_xoff();
  262. X
  263. X--- 62,68 -----
  264. X  file_insert_clear_xoff()
  265. X  {
  266. X  #ifdef USE_XON_XOFF
  267. X+ #ifdef SAY_CLEARED_XOFF
  268. X  ulong colors_at_entry = colors_current;
  269. X  
  270. X      setcolor(colors_alert);
  271. X***************
  272. X*** 64,71
  273. X  #ifdef USE_XON_XOFF
  274. X  ulong colors_at_entry = colors_current;
  275. X  
  276. X-     lclear_xmtr_xoff();
  277. X- #ifdef SAY_CLEARED_XOFF
  278. X      setcolor(colors_alert);
  279. X      fputs("--> local XOFF cleared\r",se);
  280. X      setcolor(colors_at_entry);
  281. X
  282. X--- 65,70 -----
  283. X  #ifdef SAY_CLEARED_XOFF
  284. X  ulong colors_at_entry = colors_current;
  285. X  
  286. X      setcolor(colors_alert);
  287. X      fputs("--> local XOFF cleared\r",se);
  288. X      setcolor(colors_at_entry);
  289. X***************
  290. X*** 70,75
  291. X      fputs("--> local XOFF cleared\r",se);
  292. X      setcolor(colors_at_entry);
  293. X  #endif
  294. X  #endif
  295. X  }    /* end of file_insert_clear_xoff */
  296. X  
  297. X
  298. X--- 69,75 -----
  299. X      fputs("--> local XOFF cleared\r",se);
  300. X      setcolor(colors_at_entry);
  301. X  #endif
  302. X+     lclear_xmtr_xoff();
  303. X  #endif
  304. X  }    /* end of file_insert_clear_xoff */
  305. X  
  306. X*** /u4/src/ecu3/ecufork.c    Mon Dec 24 22:29:00 1990
  307. X--- ecufork.c    Tue Jan  1 20:49:09 1991
  308. X***************
  309. X*** 59,64
  310. X  register shellpid;
  311. X  register itmp;
  312. X  register char *cptr;
  313. X  char s40[40];
  314. X  int wait_status;
  315. X  
  316. X
  317. X--- 59,65 -----
  318. X  register shellpid;
  319. X  register itmp;
  320. X  register char *cptr;
  321. X+ #if defined(FORK_DEBUG)
  322. X  char s40[40];
  323. X  #endif
  324. X  int wait_status;
  325. X***************
  326. X*** 60,65
  327. X  register itmp;
  328. X  register char *cptr;
  329. X  char s40[40];
  330. X  int wait_status;
  331. X  
  332. X  int rcvr_alive = (rcvr_pid > 0);
  333. X
  334. X--- 61,67 -----
  335. X  register char *cptr;
  336. X  #if defined(FORK_DEBUG)
  337. X  char s40[40];
  338. X+ #endif
  339. X  int wait_status;
  340. X  
  341. X  int rcvr_alive = (rcvr_pid > 0);
  342. X***************
  343. X*** 237,243
  344. X  int rcvr_alive = (rcvr_pid > 0);
  345. X  int old_ttymode = get_ttymode();
  346. X  int wait_status = 0;
  347. X- extern int errno;
  348. X  char *strrchr();
  349. X  
  350. X  #if defined(FORK_DEBUG)
  351. X
  352. X--- 239,244 -----
  353. X  int rcvr_alive = (rcvr_pid > 0);
  354. X  int old_ttymode = get_ttymode();
  355. X  int wait_status = 0;
  356. X  char *strrchr();
  357. X  
  358. X  #if defined(FORK_DEBUG)
  359. X*** /u4/src/ecu3/ecuicmhelp.c    Mon Dec 24 22:29:00 1990
  360. X--- ecuicmhelp.c    Tue Jan  1 21:51:29 1991
  361. X***************
  362. X*** 318,324
  363. X  char **arg;
  364. X  {
  365. X  register char *cptr;
  366. X- char s128[128];
  367. X  char *getenv();
  368. X  
  369. X      ff(se,"\r\n");
  370. X
  371. X--- 318,323 -----
  372. X  char **arg;
  373. X  {
  374. X  register char *cptr;
  375. X  char *getenv();
  376. X  
  377. X      ff(se,"\r\n");
  378. X*** /u4/src/ecu3/ecuicmhist.c    Mon Dec 24 22:29:00 1990
  379. X--- ecuicmhist.c    Tue Jan  1 21:51:30 1991
  380. X***************
  381. X*** 52,58
  382. X  
  383. X      if(!icmdh)
  384. X          return;
  385. X!     if(!(icmdh->icmd = strdup(icmd_buf)))
  386. X      {
  387. X          free((char *)icmdh);
  388. X          return;
  389. X
  390. X--- 52,58 -----
  391. X  
  392. X      if(!icmdh)
  393. X          return;
  394. X!     if(!(icmdh->icmd = (uchar *)strdup(icmd_buf)))
  395. X      {
  396. X          free((char *)icmdh);
  397. X          return;
  398. X*** /u4/src/ecu3/eculine.c    Mon Dec 24 22:30:00 1990
  399. X--- eculine.c    Tue Jan  1 21:44:36 1991
  400. X***************
  401. X*** 69,78
  402. X  uint rchar;
  403. X  register int echo;
  404. X  {
  405. X- extern int rcvr_log;
  406. X- extern FILE *rcvr_log_fp;
  407. X- extern char rcvr_log_file[];    /* if rcvr_log!= 0,log filename */
  408. X- 
  409. X      if(process_rcvd_char(rchar))
  410. X          return;
  411. X  
  412. X
  413. X--- 69,74 -----
  414. X  uint rchar;
  415. X  register int echo;
  416. X  {
  417. X      if(process_rcvd_char(rchar))
  418. X          return;
  419. X  
  420. X*** /u4/src/ecu3/ecuphone.c    Mon Dec 24 22:32:00 1990
  421. X--- ecuphone.c    Tue Jan  1 21:51:31 1991
  422. X***************
  423. X*** 588,593
  424. X              (pde_marked_for_redial_count == 1) ? "y" : "ies");
  425. X          wstandend(dirw);
  426. X      }
  427. X  }    /* end of dirw_display_config */
  428. X  
  429. X  /*+-----------------------------------------------------------------------
  430. X
  431. X--- 588,594 -----
  432. X              (pde_marked_for_redial_count == 1) ? "y" : "ies");
  433. X          wstandend(dirw);
  434. X      }
  435. X+     return(0);
  436. X  }    /* end of dirw_display_config */
  437. X  
  438. X  /*+-----------------------------------------------------------------------
  439. X***************
  440. X*** 1010,1016
  441. X  void
  442. X  pde_cmd_down()
  443. X  {
  444. X- register itmp;
  445. X  register PDE *tpde;
  446. X  
  447. X      if((!curr_pde) || (curr_pde->next == (PDE *)0))
  448. X
  449. X--- 1011,1016 -----
  450. X  void
  451. X  pde_cmd_down()
  452. X  {
  453. X  register PDE *tpde;
  454. X  
  455. X      if((!curr_pde) || (curr_pde->next == (PDE *)0))
  456. X***************
  457. X*** 1051,1056
  458. X      pde_add_or_edit_read(prompt,edit,x,buf,max,delim)
  459. X  max must not wrap around to another line
  460. X  --------------------------------------------------------------------------*/
  461. X  pde_add_or_edit_read(prompt,edit,x,buf,max,delim)
  462. X  char *prompt;
  463. X  int edit;
  464. X
  465. X--- 1051,1057 -----
  466. X      pde_add_or_edit_read(prompt,edit,x,buf,max,delim)
  467. X  max must not wrap around to another line
  468. X  --------------------------------------------------------------------------*/
  469. X+ void
  470. X  pde_add_or_edit_read(prompt,edit,x,buf,max,delim)
  471. X  char *prompt;
  472. X  int edit;
  473. X***************
  474. X*** 1115,1121
  475. X  register PDE *tpde;
  476. X  int edit;
  477. X  {
  478. X- register itmp;
  479. X  int input_state = 0;
  480. X  int changed;
  481. X  char s50[50];
  482. X
  483. X--- 1116,1121 -----
  484. X  register PDE *tpde;
  485. X  int edit;
  486. X  {
  487. X  int input_state = 0;
  488. X  int changed;
  489. X  char s50[50];
  490. X***************
  491. X*** 1320,1327
  492. X  pde_cmd_add(tpde)
  493. X  register PDE *tpde;
  494. X  {
  495. X- register itmp;
  496. X- 
  497. X      if(tpde)
  498. X      {
  499. X          pde_list_add(tpde);
  500. X
  501. X--- 1320,1325 -----
  502. X  pde_cmd_add(tpde)
  503. X  register PDE *tpde;
  504. X  {
  505. X      if(tpde)
  506. X      {
  507. X          pde_list_add(tpde);
  508. X***************
  509. X*** 1436,1443
  510. X  void
  511. X  pde_cmd_remove()
  512. X  {
  513. X- register itmp;
  514. X- register PDE *tpde;
  515. X  char s80[80];
  516. X  
  517. X      if(!check_curr_pde())
  518. X
  519. X--- 1434,1439 -----
  520. X  void
  521. X  pde_cmd_remove()
  522. X  {
  523. X  char s80[80];
  524. X  
  525. X      if(!check_curr_pde())
  526. X***************
  527. X*** 1466,1472
  528. X  void
  529. X  pde_cmd_find()
  530. X  {
  531. X- register itmp;
  532. X  register PDE *tpde;
  533. X  char findname[12];
  534. X  char delim;
  535. X
  536. X--- 1462,1467 -----
  537. X  void
  538. X  pde_cmd_find()
  539. X  {
  540. X  register PDE *tpde;
  541. X  char findname[12];
  542. X  char delim;
  543. X***************
  544. X*** 1495,1500
  545. X  /*+-------------------------------------------------------------------------
  546. X      pde_cmd_change_dir()
  547. X  --------------------------------------------------------------------------*/
  548. X  pde_cmd_change_dir()
  549. X  {
  550. X  register itmp;
  551. X
  552. X--- 1490,1496 -----
  553. X  /*+-------------------------------------------------------------------------
  554. X      pde_cmd_change_dir()
  555. X  --------------------------------------------------------------------------*/
  556. X+ void
  557. X  pde_cmd_change_dir()
  558. X  {
  559. X  int itmp;
  560. X***************
  561. X*** 1497,1504
  562. X  --------------------------------------------------------------------------*/
  563. X  pde_cmd_change_dir()
  564. X  {
  565. X! register itmp;
  566. X! register PDE *tpde;
  567. X  char newdirname[256];
  568. X  char buf[256];
  569. X  char delim;
  570. X
  571. X--- 1493,1499 -----
  572. X  void
  573. X  pde_cmd_change_dir()
  574. X  {
  575. X! int itmp;
  576. X  char newdirname[256];
  577. X  char buf[256];
  578. X  char delim;
  579. X***************
  580. X*** 1528,1535
  581. X      }
  582. X      if(find_shell_chars(newdirname))
  583. X      {
  584. X-     char *expcmd;
  585. X- 
  586. X          if(expand_cmd_with_wildlist(newdirname,&expcmd))
  587. X          {
  588. X              dirw_bot_msg(expcmd);
  589. X
  590. X--- 1523,1528 -----
  591. X      }
  592. X      if(find_shell_chars(newdirname))
  593. X      {
  594. X          if(expand_cmd_with_wildlist(newdirname,&expcmd))
  595. X          {
  596. X              dirw_bot_msg(expcmd);
  597. X***************
  598. X*** 1724,1729
  599. X  /*+-------------------------------------------------------------------------
  600. X      pde_cmd_set_wait()
  601. X  --------------------------------------------------------------------------*/
  602. X  pde_cmd_set_wait()
  603. X  {
  604. X  char buf[64];
  605. X
  606. X--- 1717,1723 -----
  607. X  /*+-------------------------------------------------------------------------
  608. X      pde_cmd_set_wait()
  609. X  --------------------------------------------------------------------------*/
  610. X+ void
  611. X  pde_cmd_set_wait()
  612. X  {
  613. X  char buf[64];
  614. X*** /u4/src/ecu3/ecurcvr.c    Wed Dec 26 05:15:00 1990
  615. X--- ecurcvr.c    Tue Jan  1 21:02:41 1991
  616. X***************
  617. X*** 8,20
  618. X  /* #define ANSI_DEBUG_NOBUF */    /* unbufferred logging */
  619. X  /* #define ANSI_DEBUG_LOGFILE    "/dev/tty2h" */
  620. X  /* #define DEBUG_CURSOR */
  621. X- #ifdef TEMP_HACK
  622. X- #define ANSI_DEBUG
  623. X- #define ANSI_DEBUG_2
  624. X- #define ANSI_DEBUG_3
  625. X- #define ANSI_DEBUG_LOGFILE    "/t/ansi.log"
  626. X- #endif
  627. X- 
  628. X  /*+-------------------------------------------------------------------------
  629. X      ecurcvr.c - rcvr process + ANSI filter + non-ANSI<->ANSI hoop jumping
  630. X      wht@n4hgf.Mt-Park.GA.US
  631. X
  632. X--- 8,13 -----
  633. X  /* #define ANSI_DEBUG_NOBUF */    /* unbufferred logging */
  634. X  /* #define ANSI_DEBUG_LOGFILE    "/dev/tty2h" */
  635. X  /* #define DEBUG_CURSOR */
  636. X  /*+-------------------------------------------------------------------------
  637. X      ecurcvr.c - rcvr process + ANSI filter + non-ANSI<->ANSI hoop jumping
  638. X      wht@n4hgf.Mt-Park.GA.US
  639. X***************
  640. X*** 56,61
  641. X  
  642. X  --------------------------------------------------------------------------*/
  643. X  /*+:EDITS:*/
  644. X  /*:12-21-1990-21:06-wht@n4hgf-CUF and CUB set non-ansi cursor incorrectly */
  645. X  /*:12-20-1990-16:27-wht@n4hgf-had SU and SD swapped */
  646. X  /*:11-30-1990-18:39-wht@n4hgf-non-ansi console rcvr appears to be working */
  647. X
  648. X--- 49,55 -----
  649. X  
  650. X  --------------------------------------------------------------------------*/
  651. X  /*+:EDITS:*/
  652. X+ /*:12-26-1990-14:32-wht@n4hgf-use memset in spaces() */
  653. X  /*:12-21-1990-21:06-wht@n4hgf-CUF and CUB set non-ansi cursor incorrectly */
  654. X  /*:12-20-1990-16:27-wht@n4hgf-had SU and SD swapped */
  655. X  /*:11-30-1990-18:39-wht@n4hgf-non-ansi console rcvr appears to be working */
  656. X***************
  657. X*** 100,105
  658. X  FILE *wfp = (FILE *)0;
  659. X  #endif
  660. X  
  661. X  /*+-------------------------------------------------------------------------
  662. X      redisplay_rcvr_screen() - redisplay logical receiver screen
  663. X  As of writing, this function is called only by the XMTR process
  664. X
  665. X--- 94,120 -----
  666. X  FILE *wfp = (FILE *)0;
  667. X  #endif
  668. X  
  669. X+ extern int tty_is_multiscreen;
  670. X+ uchar non_multiscreen_hi_map[128] =
  671. X+ {
  672. X+ /*80*/    'c','u','e','a','a','a','a','c',  /* the main purpose of this ... */
  673. X+ /*88*/    'e','e','e','i','i','i','a','a',  /* ... is to map ruling ... */
  674. X+ /*90*/    'e','e','a','a','a','o','u','u',  /* ... characters, but as ...*/
  675. X+ /*98*/    'y','o','u','X','#','Y','P','f',  /* ... a side effect, also map ... */
  676. X+ /*A0*/    'a','i','o','u','n','n','a','o',  /* ... others to reasonable, ... */
  677. X+ /*A8*/    '?','-','-','%','%','|','<','>',  /* ... near, amusing, or random ... */
  678. X+ /*B0*/    '#','#','#','|','+','+','+','.',  /* ... printing characters as well */
  679. X+ /*B8*/    '.','+','|','.','\'','\'','\'','.',
  680. X+ /*C0*/    '`','+','+','+','-','+','+','+',
  681. X+ /*C8*/    '`','.','+','+','+','=','+','+',
  682. X+ /*D0*/    '+','+','+','`','`','.','.','+',
  683. X+ /*D8*/    '+','\'','.','#','_','|','|','-',
  684. X+ /*E0*/    'a','b','F','T','E','o','u','t',
  685. X+ /*E8*/    'I','0','O','o','o','o','e','n',
  686. X+ /*F0*/    '=','+','>','<','f','j','%','=',
  687. X+ /*F8*/    'o','.','.','V','n','2','*',' '
  688. X+ };
  689. X+ 
  690. X  /*+-------------------------------------------------------------------------
  691. X      redisplay_rcvr_screen() - redisplay logical receiver screen
  692. X  As of writing, this function is called only by the XMTR process
  693. X***************
  694. X*** 115,122
  695. X      {
  696. X          tcap_cursor(y,0);
  697. X          fwrite(&shm->screen[y][0],
  698. X!             ((y != tcap_LINES - 1) ? tcap_COLS : tcap_COLS - 1),
  699. X!             1,se);
  700. X      }
  701. X      tcap_eeol();
  702. X      tcap_cursor(shm->cursor_y,shm->cursor_x);
  703. X
  704. X--- 130,136 -----
  705. X      {
  706. X          tcap_cursor(y,0);
  707. X          fwrite(&shm->screen[y][0],
  708. X!             ((y != tcap_LINES - 1) ? tcap_COLS : tcap_COLS - 1),1,se);
  709. X      }
  710. X      tcap_eeol();
  711. X      tcap_cursor(shm->cursor_y,shm->cursor_x);
  712. X***************
  713. X*** 143,148
  714. X  
  715. X  /*+-------------------------------------------------------------------------
  716. X      spaces(buf,buflen) - fill with spaces
  717. X  --------------------------------------------------------------------------*/
  718. X  void
  719. X  spaces(buf,buflen)
  720. X
  721. X--- 157,164 -----
  722. X  
  723. X  /*+-------------------------------------------------------------------------
  724. X      spaces(buf,buflen) - fill with spaces
  725. X+ 
  726. X+   use Duff's Device
  727. X  --------------------------------------------------------------------------*/
  728. X  void
  729. X  spaces(buf,buflen)
  730. X***************
  731. X*** 147,153
  732. X  void
  733. X  spaces(buf,buflen)
  734. X  register uchar *buf;
  735. X! register uint buflen;
  736. X  {
  737. X  #ifdef DEBUG_CURSOR
  738. X      if((ulong)buf > (((ulong)shm->screen) + LINESxCOLS))
  739. X
  740. X--- 163,169 -----
  741. X  void
  742. X  spaces(buf,buflen)
  743. X  register uchar *buf;
  744. X! uint buflen;
  745. X  {
  746. X  #ifdef DEBUG_CURSOR
  747. X      if((ulong)buf > (((ulong)shm->screen) + LINESxCOLS))
  748. X***************
  749. X*** 170,177
  750. X          return;
  751. X  #endif
  752. X  
  753. X!     while(buflen--)
  754. X!         *buf++ = ' ';
  755. X  }    /* end of spaces */
  756. X  
  757. X  /*+-------------------------------------------------------------------------
  758. X
  759. X--- 186,193 -----
  760. X          return;
  761. X  #endif
  762. X  
  763. X!     memset(buf,SPACE,buflen);
  764. X! 
  765. X  }    /* end of spaces */
  766. X  
  767. X  /*+-------------------------------------------------------------------------
  768. X***************
  769. X*** 235,241
  770. X  
  771. X      if(!tty_is_ansi)
  772. X      {
  773. X!         cptr = ansibuf;
  774. X          while(token = str_token(cptr,";"))
  775. X          {
  776. X              cptr = (char *)0;    /* further calls to str_token need NULL */
  777. X
  778. X--- 251,260 -----
  779. X  
  780. X      if(!tty_is_ansi)
  781. X      {
  782. X!         ansibuf[ansilen - 1] = 0;    /* get rid of 'm' */
  783. X!         cptr = ansibuf + 1;            /* get rid of '[' */
  784. X!         if(!strlen(cptr))
  785. X!             goto SGR_0;
  786. X          while(token = str_token(cptr,";"))
  787. X          {
  788. X              cptr = (char *)0;    /* further calls to str_token need NULL */
  789. X***************
  790. X*** 242,247
  791. X              switch(atoi(token))
  792. X              {
  793. X                  case 0:        /* normal */
  794. X                      tcap_stand_end();
  795. X                      tcap_blink_off();
  796. X                      tcap_underscore_off();
  797. X
  798. X--- 261,267 -----
  799. X              switch(atoi(token))
  800. X              {
  801. X                  case 0:        /* normal */
  802. X+ SGR_0:
  803. X                      tcap_stand_end();
  804. X                      tcap_blink_off();
  805. X                      tcap_underscore_off();
  806. X***************
  807. X*** 1069,1074
  808. X  /*+-------------------------------------------------------------------------
  809. X      process_rcvd_char(rchar)
  810. X  --------------------------------------------------------------------------*/
  811. X  process_rcvd_char(rchar)
  812. X  register uint rchar;
  813. X  {
  814. X
  815. X--- 1089,1095 -----
  816. X  /*+-------------------------------------------------------------------------
  817. X      process_rcvd_char(rchar)
  818. X  --------------------------------------------------------------------------*/
  819. X+ int
  820. X  process_rcvd_char(rchar)
  821. X  register uint rchar;
  822. X  {
  823. X***************
  824. X*** 1213,1219
  825. X  void
  826. X  rcvr()
  827. X  {
  828. X- register itmp;
  829. X  uchar rchar;
  830. X  uchar nlchar = NL;
  831. X  char *cptr;
  832. X
  833. X--- 1234,1239 -----
  834. X  void
  835. X  rcvr()
  836. X  {
  837. X  uchar rchar;
  838. X  uchar nlchar = NL;
  839. X  
  840. X***************
  841. X*** 1216,1222
  842. X  register itmp;
  843. X  uchar rchar;
  844. X  uchar nlchar = NL;
  845. X- char *cptr;
  846. X  
  847. X  #ifdef ANSI_DEBUG
  848. X  char s80[80];
  849. X
  850. X--- 1236,1241 -----
  851. X  {
  852. X  uchar rchar;
  853. X  uchar nlchar = NL;
  854. X  
  855. X  #ifdef ANSI_DEBUG
  856. X  char s80[80];
  857. X***************
  858. X*** 1255,1261
  859. X      saved_cursor_y = shm->cursor_y;
  860. X      saved_cursor_x = shm->cursor_x;
  861. X  
  862. X!     while(1)        /* receive loop - keep tight as possible! */
  863. X      {
  864. X          rchar = lgetc_rcvr();
  865. X  
  866. X
  867. X--- 1274,1281 -----
  868. X      saved_cursor_y = shm->cursor_y;
  869. X      saved_cursor_x = shm->cursor_x;
  870. X  
  871. X! /* receive loop - keep tight as possible! */
  872. X!     if(tty_is_multiscreen)
  873. X      {
  874. X          while(1)
  875. X          {
  876. X***************
  877. X*** 1257,1263
  878. X  
  879. X      while(1)        /* receive loop - keep tight as possible! */
  880. X      {
  881. X!         rchar = lgetc_rcvr();
  882. X  
  883. X          if(process_rcvd_char(rchar))
  884. X              continue;
  885. X
  886. X--- 1277,1285 -----
  887. X  /* receive loop - keep tight as possible! */
  888. X      if(tty_is_multiscreen)
  889. X      {
  890. X!         while(1)
  891. X!         {
  892. X!             rchar = lgetc_rcvr();
  893. X  
  894. X              if(process_rcvd_char(rchar))
  895. X                  continue;
  896. X***************
  897. X*** 1259,1266
  898. X      {
  899. X          rchar = lgetc_rcvr();
  900. X  
  901. X!         if(process_rcvd_char(rchar))
  902. X!             continue;
  903. X  
  904. X          write(TTYERR,&rchar,1);
  905. X  
  906. X
  907. X--- 1281,1288 -----
  908. X          {
  909. X              rchar = lgetc_rcvr();
  910. X  
  911. X!             if(process_rcvd_char(rchar))
  912. X!                 continue;
  913. X  
  914. X              write(TTYERR,&rchar,1);
  915. X  
  916. X***************
  917. X*** 1262,1268
  918. X          if(process_rcvd_char(rchar))
  919. X              continue;
  920. X  
  921. X!         write(TTYERR,&rchar,1);
  922. X  
  923. X          if(shm->Ladd_nl_incoming && (rchar == CR))
  924. X              write(TTYERR,&nlchar,1);
  925. X
  926. X--- 1284,1290 -----
  927. X              if(process_rcvd_char(rchar))
  928. X                  continue;
  929. X  
  930. X!             write(TTYERR,&rchar,1);
  931. X  
  932. X              if(shm->Ladd_nl_incoming && (rchar == CR))
  933. X                  write(TTYERR,&nlchar,1);
  934. X***************
  935. X*** 1264,1271
  936. X  
  937. X          write(TTYERR,&rchar,1);
  938. X  
  939. X!         if(shm->Ladd_nl_incoming && (rchar == CR))
  940. X!             write(TTYERR,&nlchar,1);
  941. X  
  942. X      }
  943. X  }    /* end of rcvr */
  944. X
  945. X--- 1286,1300 -----
  946. X  
  947. X              write(TTYERR,&rchar,1);
  948. X  
  949. X!             if(shm->Ladd_nl_incoming && (rchar == CR))
  950. X!                 write(TTYERR,&nlchar,1);
  951. X!         }
  952. X!     }
  953. X!     else
  954. X!     {
  955. X!         while(1)
  956. X!         {
  957. X!             rchar = lgetc_rcvr();
  958. X  
  959. X              if(rchar >= 0x80)
  960. X                  rchar = non_multiscreen_hi_map[rchar - 0x80];
  961. X***************
  962. X*** 1267,1272
  963. X          if(shm->Ladd_nl_incoming && (rchar == CR))
  964. X              write(TTYERR,&nlchar,1);
  965. X  
  966. X      }
  967. X  }    /* end of rcvr */
  968. X  
  969. X
  970. X--- 1296,1312 -----
  971. X          {
  972. X              rchar = lgetc_rcvr();
  973. X  
  974. X+             if(rchar >= 0x80)
  975. X+                 rchar = non_multiscreen_hi_map[rchar - 0x80];
  976. X+ 
  977. X+             if(process_rcvd_char(rchar))
  978. X+                 continue;
  979. X+ 
  980. X+             write(TTYERR,&rchar,1);
  981. X+ 
  982. X+             if(shm->Ladd_nl_incoming && (rchar == CR))
  983. X+                 write(TTYERR,&nlchar,1);
  984. X+         }
  985. X      }
  986. X  }    /* end of rcvr */
  987. X  
  988. X*** /u4/src/ecu3/ecushm.c    Mon Dec 24 22:33:00 1990
  989. X--- ecushm.c    Tue Jan  1 21:03:03 1991
  990. X***************
  991. X*** 108,113
  992. X      shmx_rc_report(prcvr_chars,prcvr_chars_this_connect)
  993. X   xmtr calls to get rcvr stats
  994. X  --------------------------------------------------------------------------*/
  995. X  shmx_rc_report(prcvd_chars,prcvd_chars_this_connect)
  996. X  long *prcvd_chars;
  997. X  long *prcvd_chars_this_connect;
  998. X
  999. X--- 108,114 -----
  1000. X      shmx_rc_report(prcvr_chars,prcvr_chars_this_connect)
  1001. X   xmtr calls to get rcvr stats
  1002. X  --------------------------------------------------------------------------*/
  1003. X+ void
  1004. X  shmx_rc_report(prcvd_chars,prcvd_chars_this_connect)
  1005. X  long *prcvd_chars;
  1006. X  long *prcvd_chars_this_connect;
  1007. X*** /u4/src/ecu3/ecusighdl.c    Mon Dec 24 22:33:00 1990
  1008. X--- ecusighdl.c    Tue Jan  1 21:06:57 1991
  1009. X***************
  1010. X*** 73,78
  1011. X  start_rcvr_process(notify_flag)
  1012. X  int notify_flag;
  1013. X  {
  1014. X  char s40[40];
  1015. X  extern ulong colors_current;
  1016. X  ulong colors_at_entry = colors_current;
  1017. X
  1018. X--- 73,79 -----
  1019. X  start_rcvr_process(notify_flag)
  1020. X  int notify_flag;
  1021. X  {
  1022. X+ #if defined(FORK_DEBUG)
  1023. X  char s40[40];
  1024. X  #endif
  1025. X  extern ulong colors_current;
  1026. X***************
  1027. X*** 74,79
  1028. X  int notify_flag;
  1029. X  {
  1030. X  char s40[40];
  1031. X  extern ulong colors_current;
  1032. X  ulong colors_at_entry = colors_current;
  1033. X  
  1034. X
  1035. X--- 75,81 -----
  1036. X  {
  1037. X  #if defined(FORK_DEBUG)
  1038. X  char s40[40];
  1039. X+ #endif
  1040. X  extern ulong colors_current;
  1041. X  ulong colors_at_entry = colors_current;
  1042. X  
  1043. X***************
  1044. X*** 115,127
  1045. X          xmtr_signals();
  1046. X          return(rcvr_pid);
  1047. X      }
  1048. X!     else
  1049. X!     {
  1050. X!         rcvr_pid = -1;        /* no receiver active */
  1051. X!         ff(se,"\r\n\ncould not fork for receive\r\n");
  1052. X!         hangup(HANGUP_NO_FORK_FOR_RCVR);
  1053. X!         /*NOTREACHED*/
  1054. X!     }
  1055. X  }    /* end of start_rcvr_process */
  1056. X  
  1057. X  /*+-----------------------------------------------------------------------
  1058. X
  1059. X--- 117,127 -----
  1060. X          xmtr_signals();
  1061. X          return(rcvr_pid);
  1062. X      }
  1063. X!     rcvr_pid = -1;        /* no receiver active */
  1064. X!     ff(se,"\r\n\ncould not fork for receive\r\n");
  1065. X!     hangup(HANGUP_NO_FORK_FOR_RCVR);
  1066. X!     /*NOTREACHED*/
  1067. X! 
  1068. X  }    /* end of start_rcvr_process */
  1069. X  
  1070. X  /*+-----------------------------------------------------------------------
  1071. X*** /u4/src/ecu3/ecutty.c    Mon Dec 24 22:34:00 1990
  1072. X--- ecutty.c    Tue Jan  1 22:08:07 1991
  1073. X***************
  1074. X*** 69,75
  1075. X      XFhome        /* KDEk_HOME */
  1076. X  };
  1077. X  
  1078. X! static char *dole_out_rd_char = (char *)0;
  1079. X  
  1080. X  extern int interrupt;
  1081. X  extern uint tcap_LINES;
  1082. X
  1083. X--- 69,75 -----
  1084. X      XFhome        /* KDEk_HOME */
  1085. X  };
  1086. X  
  1087. X! static uchar *dole_out_rd_char = (uchar *)0;
  1088. X  
  1089. X  extern int interrupt;
  1090. X  extern uint tcap_LINES;
  1091. X***************
  1092. X*** 561,567
  1093. X      ioctl(TTYIN,TCXONC,(char *)1);    /* restart tty output */
  1094. X  
  1095. X  #if defined(M_XENIX) || defined(M_UNIX)
  1096. X!     dole_out_rd_char = (char *)0;    /* see ttygetc() */
  1097. X  #endif
  1098. X  
  1099. X  }    /* end of ttyflush */
  1100. X
  1101. X--- 561,567 -----
  1102. X      ioctl(TTYIN,TCXONC,(char *)1);    /* restart tty output */
  1103. X  
  1104. X  #if defined(M_XENIX) || defined(M_UNIX)
  1105. X!     dole_out_rd_char = (uchar *)0;    /* see ttygetc() */
  1106. X  #endif
  1107. X  
  1108. X  }    /* end of ttyflush */
  1109. X***************
  1110. X*** 590,596
  1111. X  
  1112. X      if(dole_out_rd_char)        /* handle (very unlikely) FAST typist */
  1113. X      {
  1114. X!         if(itmp = *dole_out_rd_char++)
  1115. X              return(itmp);
  1116. X          else
  1117. X              dole_out_rd_char = (char *)0;
  1118. X
  1119. X--- 590,596 -----
  1120. X  
  1121. X      if(dole_out_rd_char)        /* handle (very unlikely) FAST typist */
  1122. X      {
  1123. X!         if(itmp = (uint)*dole_out_rd_char++)
  1124. X              return(itmp);
  1125. X          else
  1126. X              dole_out_rd_char = (uchar *)0;
  1127. X***************
  1128. X*** 593,599
  1129. X          if(itmp = *dole_out_rd_char++)
  1130. X              return(itmp);
  1131. X          else
  1132. X!             dole_out_rd_char = (char *)0;
  1133. X      }
  1134. X  
  1135. X  GET_KEY:
  1136. X
  1137. X--- 593,599 -----
  1138. X          if(itmp = (uint)*dole_out_rd_char++)
  1139. X              return(itmp);
  1140. X          else
  1141. X!             dole_out_rd_char = (uchar *)0;
  1142. X      }
  1143. X  
  1144. X  GET_KEY:
  1145. X*** /u4/src/ecu3/ecuutil.c    Mon Dec 24 22:35:00 1990
  1146. X--- ecuutil.c    Tue Jan  1 22:18:37 1991
  1147. X***************
  1148. X*** 31,36
  1149. X  
  1150. X  ------------------------------------------------------------------------*/
  1151. X  /*+:EDITS:*/
  1152. X  /*:12-04-1990-00:58-wht@n4hgf-allow alternating between str/arg_token */
  1153. X  /*:08-14-1990-20:40-wht@n4hgf-ecu3.00-flush old edit history */
  1154. X  
  1155. X
  1156. X--- 31,37 -----
  1157. X  
  1158. X  ------------------------------------------------------------------------*/
  1159. X  /*+:EDITS:*/
  1160. X+ /*:12-26-1990-14:32-wht@n4hgf-use memmove or Duff's Device in mem_cpy() */
  1161. X  /*:12-04-1990-00:58-wht@n4hgf-allow alternating between str/arg_token */
  1162. X  /*:08-14-1990-20:40-wht@n4hgf-ecu3.00-flush old edit history */
  1163. X  
  1164. X***************
  1165. X*** 52,57
  1166. X  
  1167. X  /*+-------------------------------------------------------------------------
  1168. X      mem_cpy(dest,src,len) - memcpy() with non-destructive overlapping copy
  1169. X  --------------------------------------------------------------------------*/
  1170. X  void
  1171. X  mem_cpy(dest,src,len)
  1172. X
  1173. X--- 53,60 -----
  1174. X  
  1175. X  /*+-------------------------------------------------------------------------
  1176. X      mem_cpy(dest,src,len) - memcpy() with non-destructive overlapping copy
  1177. X+ 
  1178. X+   use Duff's device for speed if memmove not available
  1179. X  --------------------------------------------------------------------------*/
  1180. X  void
  1181. X  mem_cpy(dest,src,len)
  1182. X***************
  1183. X*** 59,64
  1184. X  register char *src;
  1185. X  register len;
  1186. X  {
  1187. X      if(dest > src)
  1188. X      {
  1189. X          dest += len;
  1190. X
  1191. X--- 62,71 -----
  1192. X  register char *src;
  1193. X  register len;
  1194. X  {
  1195. X+ #ifndef DUFF
  1196. X+     memmove(dest,src,len);
  1197. X+ #else    /* for systems without memmove */
  1198. X+     register itmp = (len + 7) / 8;
  1199. X      if(dest > src)
  1200. X      {
  1201. X          dest += len;
  1202. X***************
  1203. X*** 63,70
  1204. X      {
  1205. X          dest += len;
  1206. X          src += len;
  1207. X!         while(len--)
  1208. X!             *--dest = *--src;
  1209. X      }
  1210. X      else
  1211. X      {
  1212. X
  1213. X--- 70,87 -----
  1214. X      {
  1215. X          dest += len;
  1216. X          src += len;
  1217. X!         switch(len % 8)
  1218. X!         {
  1219. X!         case 0:    do{    *--dest = *--src;
  1220. X!         case 7:        *--dest = *--src;
  1221. X!         case 6:        *--dest = *--src;
  1222. X!         case 5:        *--dest = *--src;
  1223. X!         case 4:        *--dest = *--src;
  1224. X!         case 3:        *--dest = *--src;
  1225. X!         case 2:        *--dest = *--src;
  1226. X!         case 1:        *--dest = *--src;
  1227. X!                  }while (--itmp > 0);
  1228. X!         }
  1229. X      }
  1230. X      else
  1231. X      {
  1232. X***************
  1233. X*** 68,75
  1234. X      }
  1235. X      else
  1236. X      {
  1237. X!         while(len--)
  1238. X!             *dest++ = *src++;
  1239. X      }
  1240. X  }    /* end of mem_cpy */
  1241. X  
  1242. X
  1243. X--- 85,102 -----
  1244. X      }
  1245. X      else
  1246. X      {
  1247. X!         switch(len % 8)
  1248. X!         {
  1249. X!         case 0:    do{    *dest++ = *src++;
  1250. X!         case 7:        *dest++ = *src++;
  1251. X!         case 6:        *dest++ = *src++;
  1252. X!         case 5:        *dest++ = *src++;
  1253. X!         case 4:        *dest++ = *src++;
  1254. X!         case 3:        *dest++ = *src++;
  1255. X!         case 2:        *dest++ = *src++;
  1256. X!         case 1:        *dest++ = *src++;
  1257. X!                  }while (--itmp > 0);
  1258. X!         }
  1259. X      }
  1260. X  #endif
  1261. X  }    /* end of mem_cpy */
  1262. X***************
  1263. X*** 71,76
  1264. X          while(len--)
  1265. X              *dest++ = *src++;
  1266. X      }
  1267. X  }    /* end of mem_cpy */
  1268. X  
  1269. X  /*+-------------------------------------------------------------------------
  1270. X
  1271. X--- 98,104 -----
  1272. X                   }while (--itmp > 0);
  1273. X          }
  1274. X      }
  1275. X+ #endif
  1276. X  }    /* end of mem_cpy */
  1277. X  
  1278. X  /*+-------------------------------------------------------------------------
  1279. X***************
  1280. X*** 74,80
  1281. X  }    /* end of mem_cpy */
  1282. X  
  1283. X  /*+-------------------------------------------------------------------------
  1284. X!     errno_text(errno)
  1285. X  --------------------------------------------------------------------------*/
  1286. X  char *
  1287. X  errno_text(errno)
  1288. X
  1289. X--- 102,108 -----
  1290. X  }    /* end of mem_cpy */
  1291. X  
  1292. X  /*+-------------------------------------------------------------------------
  1293. X!     errno_text(err_no)
  1294. X  --------------------------------------------------------------------------*/
  1295. X  char *
  1296. X  errno_text(err_no)
  1297. X***************
  1298. X*** 77,84
  1299. X      errno_text(errno)
  1300. X  --------------------------------------------------------------------------*/
  1301. X  char *
  1302. X! errno_text(errno)
  1303. X! int errno;
  1304. X  {
  1305. X  static char errant[16];
  1306. X  
  1307. X
  1308. X--- 105,112 -----
  1309. X      errno_text(err_no)
  1310. X  --------------------------------------------------------------------------*/
  1311. X  char *
  1312. X! errno_text(err_no)
  1313. X! int err_no;
  1314. X  {
  1315. X  static char errant[16];
  1316. X  
  1317. X***************
  1318. X*** 82,88
  1319. X  {
  1320. X  static char errant[16];
  1321. X  
  1322. X!     switch(errno)
  1323. X      {
  1324. X          case 0: return("0");
  1325. X          case EPERM: return("EPERM");
  1326. X
  1327. X--- 110,116 -----
  1328. X  {
  1329. X  static char errant[16];
  1330. X  
  1331. X!     switch(err_no)
  1332. X      {
  1333. X          case 0: return("0");
  1334. X          case EPERM: return("EPERM");
  1335. X***************
  1336. X*** 195,202
  1337. X  char *parsestr;
  1338. X  char *termchars;
  1339. X  {
  1340. X- register int first = 1;
  1341. X- register char *termptr;
  1342. X  register char *parseptr;
  1343. X  char *token;
  1344. X  
  1345. X
  1346. X--- 223,228 -----
  1347. X  char *parsestr;
  1348. X  char *termchars;
  1349. X  {
  1350. X  register char *parseptr;
  1351. X  char *token;
  1352. X  
  1353. X*** /u4/src/ecu3/ecuwinutil.c    Mon Dec 24 22:36:00 1990
  1354. X--- ecuwinutil.c    Tue Jan  1 21:51:32 1991
  1355. X***************
  1356. X*** 113,131
  1357. X  #endif
  1358. X      windows_active = 1;
  1359. X  
  1360. X- #ifdef WHT
  1361. X-     if(!tty_is_ansi)
  1362. X-     {
  1363. X-         sTL = vanilla_TL;
  1364. X-         sTR = vanilla_TR;
  1365. X-         sBL = vanilla_BL;
  1366. X-         sBR = vanilla_BR;
  1367. X-         sLT = vanilla_LT;
  1368. X-         sRT = vanilla_RT;
  1369. X-         sVR = vanilla_VR;
  1370. X-         sHR = vanilla_HR;
  1371. X-     }
  1372. X- #else
  1373. X      if(!tty_is_multiscreen)
  1374. X      {
  1375. X          sTL = vanilla_TL;
  1376. X
  1377. X--- 113,118 -----
  1378. X  #endif
  1379. X      windows_active = 1;
  1380. X  
  1381. X      if(!tty_is_multiscreen)
  1382. X      {
  1383. X          sTL = vanilla_TL;
  1384. X***************
  1385. X*** 137,143
  1386. X          sVR = vanilla_VR;
  1387. X          sHR = vanilla_HR;
  1388. X      }
  1389. X- #endif
  1390. X  
  1391. X  }    /* end of windows_start */
  1392. X  
  1393. X
  1394. X--- 124,129 -----
  1395. X          sVR = vanilla_VR;
  1396. X          sHR = vanilla_HR;
  1397. X      }
  1398. X  
  1399. X  }    /* end of windows_start */
  1400. X  
  1401. X*** /u4/src/ecu3/ecuxenix.c    Mon Dec 24 22:36:00 1990
  1402. X--- ecuxenix.c    Tue Jan  1 21:35:04 1991
  1403. X***************
  1404. X*** 327,333
  1405. X  int morse_frequency = 600;
  1406. X  char morse_char;
  1407. X  static int morse_ticks = 0;
  1408. X- extern int errno;
  1409. X  
  1410. X      if(!tty_is_multiscreen)
  1411. X      {
  1412. X
  1413. X--- 327,332 -----
  1414. X  int morse_frequency = 600;
  1415. X  char morse_char;
  1416. X  static int morse_ticks = 0;
  1417. X  
  1418. X      if(!tty_is_multiscreen)
  1419. X      {
  1420. X***************
  1421. X*** 332,338
  1422. X      if(!tty_is_multiscreen)
  1423. X      {
  1424. X          ring_bell();
  1425. X!         return;
  1426. X      }
  1427. X  
  1428. X      if(!morse_ticks)
  1429. X
  1430. X--- 331,337 -----
  1431. X      if(!tty_is_multiscreen)
  1432. X      {
  1433. X          ring_bell();
  1434. X!         return(0);
  1435. X      }
  1436. X  
  1437. X      if(!morse_ticks)
  1438. X***************
  1439. X*** 403,410
  1440. X  
  1441. X  /*+-------------------------------------------------------------------------
  1442. X      bell_alarm(xbell_type)
  1443. X!   Under XENIX 2.2.1, ring bell on multiscreens;
  1444. X!   if morse driver included, use it
  1445. X  --------------------------------------------------------------------------*/
  1446. X  int
  1447. X  bell_alarm(xbell_type)
  1448. X
  1449. X--- 402,408 -----
  1450. X  
  1451. X  /*+-------------------------------------------------------------------------
  1452. X      bell_alarm(xbell_type)
  1453. X!   ring bell on multiscreens; if morse driver included, use it instead
  1454. X  --------------------------------------------------------------------------*/
  1455. X  int
  1456. X  bell_alarm(xbell_type)
  1457. X***************
  1458. X*** 413,419
  1459. X  register notify_fd;
  1460. X  register fork_pid;
  1461. X  static long notify_time = 0L;
  1462. X! char *ttname;
  1463. X  char devname[64];
  1464. X  int devnum;
  1465. X  int ttnum;
  1466. X
  1467. X--- 411,417 -----
  1468. X  register notify_fd;
  1469. X  register fork_pid;
  1470. X  static long notify_time = 0L;
  1471. X! char *get_ttyname();
  1472. X  char devname[64];
  1473. X  int devnum;
  1474. X  int ttnum;
  1475. X***************
  1476. X*** 422,428
  1477. X      if(!tty_is_multiscreen)
  1478. X      {
  1479. X          ring_bell();
  1480. X!         return;
  1481. X      }
  1482. X  
  1483. X  /* if happened less than 15 secs ago, forget it */
  1484. X
  1485. X--- 420,426 -----
  1486. X      if(!tty_is_multiscreen)
  1487. X      {
  1488. X          ring_bell();
  1489. X!         return(0);
  1490. X      }
  1491. X  
  1492. X      ttnum = atoi(get_ttyname() + 8);
  1493. X***************
  1494. X*** 425,430
  1495. X          return;
  1496. X      }
  1497. X  
  1498. X  /* if happened less than 15 secs ago, forget it */
  1499. X      if((time((long *)0) - notify_time) < 15L)
  1500. X          return(0);
  1501. X
  1502. X--- 423,430 -----
  1503. X          return(0);
  1504. X      }
  1505. X  
  1506. X+     ttnum = atoi(get_ttyname() + 8);
  1507. X+ 
  1508. X  /* if happened less than 15 secs ago, forget it */
  1509. X      if((time((long *)0) - notify_time) < 15L)
  1510. X          return(0);
  1511. X***************
  1512. X*** 460,465
  1513. X  #if defined(MORSE)
  1514. X      }
  1515. X  #endif
  1516. X  }    /* end of bell_alarm */
  1517. X  
  1518. X  /*+-------------------------------------------------------------------------
  1519. X
  1520. X--- 460,466 -----
  1521. X  #if defined(MORSE)
  1522. X      }
  1523. X  #endif
  1524. X+     /*NOTREACHED*/
  1525. X  }    /* end of bell_alarm */
  1526. X  
  1527. X  /*+-------------------------------------------------------------------------
  1528. X***************
  1529. X*** 570,576
  1530. X  {
  1531. X  register itmp;
  1532. X  register char *cptr;
  1533. X- int iarg;
  1534. X  int mode = atoi(arg[1]);
  1535. X  LRWT lr;
  1536. X  char buf[1024];
  1537. X
  1538. X--- 571,576 -----
  1539. X  {
  1540. X  register itmp;
  1541. X  register char *cptr;
  1542. X  int mode = atoi(arg[1]);
  1543. X  LRWT lr;
  1544. X  char buf[1024];
  1545. X*** /u4/src/ecu3/ecuxfer.c    Mon Dec 24 22:37:00 1990
  1546. X--- ecuxfer.c    Tue Jan  1 21:51:33 1991
  1547. X***************
  1548. X*** 212,218
  1549. X  }    /* end of xfrw_get_single */
  1550. X  
  1551. X  /*+-------------------------------------------------------------------------
  1552. X!     xfer_title_fragment(xfertype)
  1553. X  --------------------------------------------------------------------------*/
  1554. X  char *
  1555. X  xfer_title_fragment()
  1556. X
  1557. X--- 212,218 -----
  1558. X  }    /* end of xfrw_get_single */
  1559. X  
  1560. X  /*+-------------------------------------------------------------------------
  1561. X!     xfer_title_fragment()
  1562. X  --------------------------------------------------------------------------*/
  1563. X  char *
  1564. X  xfer_title_fragment()
  1565. X***************
  1566. X*** 866,872
  1567. X  {
  1568. X  register itmp;
  1569. X  char execcmd[256];
  1570. X- int xfertype;
  1571. X  char bottom_label[64];
  1572. X  
  1573. X      sprintf(bottom_label,"-C 'Connected to %s' ",
  1574. X
  1575. X--- 866,871 -----
  1576. X  {
  1577. X  register itmp;
  1578. X  char execcmd[256];
  1579. X  char bottom_label[64];
  1580. X  
  1581. X      sprintf(bottom_label,"-C 'Connected to %s' ",
  1582. X*** /u4/src/ecu3/hdbintf.c    Mon Dec 24 22:39:00 1990
  1583. X--- hdbintf.c    Tue Jan  1 22:22:14 1991
  1584. X***************
  1585. X*** 65,70
  1586. X  ungetty_get_line()
  1587. X  {
  1588. X  int itmp;
  1589. X  char ungetty_log[80];
  1590. X  int ungetty_pid;
  1591. X  int (*original_sighdlr)();
  1592. X
  1593. X--- 65,71 -----
  1594. X  ungetty_get_line()
  1595. X  {
  1596. X  int itmp;
  1597. X+ #if defined(LOG_UNGETTY)
  1598. X  char ungetty_log[80];
  1599. X  #endif
  1600. X  int ungetty_pid;
  1601. X***************
  1602. X*** 66,71
  1603. X  {
  1604. X  int itmp;
  1605. X  char ungetty_log[80];
  1606. X  int ungetty_pid;
  1607. X  int (*original_sighdlr)();
  1608. X  int wait_status;
  1609. X
  1610. X--- 67,73 -----
  1611. X  int itmp;
  1612. X  #if defined(LOG_UNGETTY)
  1613. X  char ungetty_log[80];
  1614. X+ #endif
  1615. X  int ungetty_pid;
  1616. X  int (*original_sighdlr)();
  1617. X  int wait_status;
  1618. X***************
  1619. X*** 354,360
  1620. X  getdlent()
  1621. X  {
  1622. X  int itmp;
  1623. X- char *cptr;
  1624. X  #define MAX_DL_TOKENS 3
  1625. X  char *tokens[MAX_DL_TOKENS];
  1626. X  static struct dlent dle;
  1627. X
  1628. X--- 356,361 -----
  1629. X  getdlent()
  1630. X  {
  1631. X  int itmp;
  1632. X  #define MAX_DL_TOKENS 3
  1633. X  char *tokens[MAX_DL_TOKENS];
  1634. X  static struct dlent dle;
  1635. X*** /u4/src/ecu3/lint_args.h    Mon Dec 24 22:47:00 1990
  1636. X--- lint_args.h    Tue Jan  1 21:03:21 1991
  1637. X***************
  1638. X*** 135,143
  1639. X  int dirw_display_config(void);
  1640. X  int lookup_logical_telno(void);
  1641. X  int pde_add_or_edit(struct phone_directory_entry *,int );
  1642. X! int pde_add_or_edit_read(char *,int ,int ,char *,int ,char *);
  1643. X! int pde_cmd_change_dir(void);
  1644. X! int pde_cmd_set_wait(void);
  1645. X  int pde_dial(struct phone_directory_entry *);
  1646. X  int pde_dial_cycle(void);
  1647. X  int pde_display(int ,struct phone_directory_entry *,int );
  1648. X
  1649. X--- 135,143 -----
  1650. X  int dirw_display_config(void);
  1651. X  int lookup_logical_telno(void);
  1652. X  int pde_add_or_edit(struct phone_directory_entry *,int );
  1653. X! void pde_add_or_edit_read(char *,int ,int ,char *,int ,char *);
  1654. X! void pde_cmd_change_dir(void);
  1655. X! void pde_cmd_set_wait(void);
  1656. X  int pde_dial(struct phone_directory_entry *);
  1657. X  int pde_dial_cycle(void);
  1658. X  int pde_display(int ,struct phone_directory_entry *,int );
  1659. X***************
  1660. X*** 224,230
  1661. X  void setw_msg(char *,int ,char ,int *);
  1662. X  /* ecushm.c */
  1663. X  int shm_init(void);
  1664. X! int shmx_rc_report(long *,long *);
  1665. X  void shm_done(void);
  1666. X  void shmr_process_rcvr_SIGUSR2(void);
  1667. X  void shmr_set_xmtr_bn_1(void);
  1668. X
  1669. X--- 224,230 -----
  1670. X  void setw_msg(char *,int ,char ,int *);
  1671. X  /* ecushm.c */
  1672. X  int shm_init(void);
  1673. X! void shmx_rc_report(long *,long *);
  1674. X  void shm_done(void);
  1675. X  void shmr_process_rcvr_SIGUSR2(void);
  1676. X  void shmr_set_xmtr_bn_1(void);
  1677. SHAR_EOF
  1678. chmod 0644 PATCH01 ||
  1679. echo 'restore of PATCH01 failed'
  1680. Wc_c="`wc -c < 'PATCH01'`"
  1681. test 36829 -eq "$Wc_c" ||
  1682.     echo 'PATCH01: original size 36829, current size' "$Wc_c"
  1683. # ============= patchlevel.h ==============
  1684. echo 'x - extracting patchlevel.h (Text)'
  1685. sed 's/^X//' << 'SHAR_EOF' > 'patchlevel.h' &&
  1686. X#define PATCHLEVEL 1
  1687. SHAR_EOF
  1688. chmod 0644 patchlevel.h ||
  1689. echo 'restore of patchlevel.h failed'
  1690. Wc_c="`wc -c < 'patchlevel.h'`"
  1691. test 21 -eq "$Wc_c" ||
  1692.     echo 'patchlevel.h: original size 21, current size' "$Wc_c"
  1693. # ============= Make.xgcc ==============
  1694. echo 'x - extracting Make.xgcc (Text)'
  1695. sed 's/^X//' << 'SHAR_EOF' > 'Make.xgcc' &&
  1696. X#  CHK=0xF880
  1697. X#+-------------------------------------------------------------------
  1698. X# GCC Make.xgcc for ecu and related programs
  1699. X# wht@n4hgf.Mt-Park.GA.US
  1700. X#
  1701. X# This is an experimental make file for GCC 1.37.1 for UNIX 386 only
  1702. X# only ECU is made with GCC; the other make files will use (MSC) cc
  1703. X#
  1704. X# -traditional is used over -ansi because of at least the following
  1705. X# 1. SCO's curses.h file contains an apostrophe in a #error
  1706. X#    pseudo-statement and gcc barfs on it (even though the statement
  1707. X#    is not included)
  1708. X#
  1709. X# 2. gcc complains about passing an unsigned char * to strlen(); yuk
  1710. X#--------------------------------------------------------------------
  1711. X#+:EDITS:*/
  1712. X#:01-01-1991-20:30-wht@n4hgf-creation
  1713. X
  1714. XSHELL=/bin/sh
  1715. XCC = gcc
  1716. X
  1717. X#-------------------- configurable parameters -----------------------
  1718. X#--> set LBIN to your local bin directory path
  1719. XLBIN = /usr/local/bin
  1720. X
  1721. X#--> set ECUBINDIR to the desired location of the ecu library
  1722. X#    directory (normally /usr/lib/ecu)
  1723. X#ECULIBDIR = /usr/lib/ecu
  1724. XECULIBDIR = /usr/local/lib/ecu
  1725. X
  1726. X#--> leave commented unless you have my morse speaker driver
  1727. X#MORSE=-DMORSE
  1728. X
  1729. X#--> uncomment if you have the crypt library. NOTE: minimal use is
  1730. X#    made of crypt ... Read the note in README.  You probably want
  1731. X#    to leave this commented unless you want the best protection you
  1732. X#    can get against deviant mutant ninja hackers :-)
  1733. X#CRYPT=-DCRYPT
  1734. X#LCRYPT=-lcrypt
  1735. X
  1736. X#--> comment out if you have a working select(S) (for serial lines;
  1737. X#    2.3.1 has a broken one that may be fixable: see README; 2.3.2
  1738. X#    has a working select(S) for serial lines and a fix from SCO
  1739. X#    for pipes [ecu doesn't select() on pipes])
  1740. X#NOSEL=-DNO_SELECT
  1741. X
  1742. X#--> comment out if you do not want the automatic procedure execution
  1743. X#    feature when connecting to a system (see ecu.man dial command)
  1744. XADPROC=-DAUTO_DIAL_PROC
  1745. X#--------------------------------------------------------------------
  1746. X
  1747. X#make some composites based on above
  1748. XSYSTEM = UNIX/386
  1749. XU3C = -O -Wunused -Wswitch -Wcomment\
  1750. X      -Wshadow -Wpointer-arith -Wcast-qual\
  1751. X      -traditional -fstrength-reduce -fforce-mem -fforce-addr\
  1752. X      -DM_I386 -DM_UNIX -DM_SYSV
  1753. XCURSES = -DM_TERMCAP
  1754. XCURSES_LIB = -ltcap -ltermlib
  1755. X#ESIO=-DHAVE_ESIO
  1756. XCOMFLAGS = $(U3C)
  1757. XCFLAGS  = -g $(CURSES) $(CRYPT) $(MORSE) $(NOSEL) $(ADPROC) $(COMFLAGS) $(ESIO)
  1758. XLDFLAGS = -g -lx -lmalloc $(LCRYPT) $(CURSES_LIB)
  1759. X
  1760. XECUSHARNAME=ecu3
  1761. XMANSHARNAME=ecuman3
  1762. X
  1763. X.SUFFIXES:
  1764. X.SUFFIXES: .o .c .h .l
  1765. XSHELL = /bin/sh
  1766. X
  1767. X.c.o:;    /bin/time $(CC) -c $(CFLAGS) $*.c 
  1768. X
  1769. XSHARFLS = \
  1770. XREADME \
  1771. XANCIENTHISTORY \
  1772. XESOTERIC \
  1773. XMake.ecu *.c *.h \
  1774. Xhelp/Make.xgcc  help/*.{h,c,src} \
  1775. Xecufriend/{Make.xgcc,*.{c,h}} \
  1776. Xecuungetty/Make.xgcc ecuungetty/*.{c,h} \
  1777. Xmapkey/README mapkey/keys.usa.ecu.d\
  1778. Xbperr/bperr.c \
  1779. Xz/Make.xgcc z/*.{c,h} sea/Make.xgcc sea/*.{c,h,doc,imp} \
  1780. Xgendial/Make.xgcc  gendial/*.{h,c} \
  1781. Xxsel386/* \
  1782. Xshar.fls */*.fls \
  1783. Xckermit/* doc/{*.txt,runoff} models/* zgcc mkoldproto.l'
  1784. X
  1785. XSRC    = \
  1786. X    bamboozle.c\
  1787. X    cmdtbl.c\
  1788. X    expresp.c\
  1789. X    ecu.c\
  1790. X    ecuLCK.c\
  1791. X    ecuchdir.c\
  1792. X    ecudump.c\
  1793. X    ecufinsert.c\
  1794. X    ecufkey.c\
  1795. X    ecufork.c\
  1796. X    ecuDCE.c\
  1797. X    eculine.c\
  1798. X    eculock.c\
  1799. X    ecunumrev.c\
  1800. X    ecuicmaux.c\
  1801. X    ecuicmhelp.c\
  1802. X    ecuicmhist.c\
  1803. X    ecuicmd.c\
  1804. X    ecuphone.c\
  1805. X    ecuphrase.c\
  1806. X    ecurcvr.c\
  1807. X    ecuscrdump.c\
  1808. X    ecusetup.c\
  1809. X    ecushm.c\
  1810. X    ecusighdl.c\
  1811. X    ecutcap.c\
  1812. X    ecutime.c\
  1813. X    ecutty.c\
  1814. X    ecuuclc.c\
  1815. X    ecuusage.c\
  1816. X    ecuutil.c\
  1817. X    ecuwinutil.c\
  1818. X    ecuxenix.c\
  1819. X    ecuxfer.c\
  1820. X    esdutil.c\
  1821. X    feval.c\
  1822. X    gint.c\
  1823. X    gstr.c\
  1824. X    hdbintf.c\
  1825. X    logevent.c\
  1826. X    nonansikey.c\
  1827. X    pcmd.c\
  1828. X    pcmdif.c\
  1829. X    pcmdfile.c\
  1830. X    pcmdtty.c\
  1831. X    pcmdwhile.c\
  1832. X    pcmdxfer.c\
  1833. X    poutput.c\
  1834. X    pprintf.c\
  1835. X    proc.c\
  1836. X    proc_error.c\
  1837. X    procframe.c\
  1838. X    regexp.c\
  1839. X    utmpstat.c\
  1840. X    var.c
  1841. X
  1842. XOBJ    = \
  1843. X    bamboozle.o\
  1844. X    cmdtbl.o\
  1845. X    expresp.o\
  1846. X    ecu.o\
  1847. X    ecuLCK.o\
  1848. X    ecudump.o\
  1849. X    ecuchdir.o\
  1850. X    ecufinsert.o\
  1851. X    ecufkey.o\
  1852. X    ecufork.o\
  1853. X    ecuDCE.o\
  1854. X    eculine.o\
  1855. X    eculock.o\
  1856. X    ecunumrev.o\
  1857. X    ecuicmaux.o\
  1858. X    ecuicmhelp.o\
  1859. X    ecuicmhist.o\
  1860. X    ecuicmd.o\
  1861. X    ecuphone.o\
  1862. X    ecuphrase.o\
  1863. X    ecurcvr.o\
  1864. X    ecuscrdump.o\
  1865. X    ecusetup.o\
  1866. X    ecushm.o\
  1867. X    ecusighdl.o\
  1868. X    ecutcap.o\
  1869. X    ecutime.o\
  1870. X    ecutty.o\
  1871. X    ecuuclc.o\
  1872. X    ecuusage.o\
  1873. X    ecuutil.o\
  1874. X    ecuwinutil.o\
  1875. X    ecuxenix.o\
  1876. X    ecuxfer.o\
  1877. X    esdutil.o\
  1878. X    esiointf.o\
  1879. X    feval.o\
  1880. X    gint.o\
  1881. X    gstr.o\
  1882. X    hdbintf.o\
  1883. X    logevent.o\
  1884. X    nonansikey.o\
  1885. X    pcmd.o\
  1886. X    pcmdif.o\
  1887. X    pcmdfile.o\
  1888. X    pcmdtty.o\
  1889. X    pcmdwhile.o\
  1890. X    pcmdxfer.o\
  1891. X    poutput.o\
  1892. X    pprintf.o\
  1893. X    proc.o\
  1894. X    proc_error.o\
  1895. X    procframe.o\
  1896. X    regexp.o\
  1897. X    utmpstat.o\
  1898. X    var.o
  1899. X
  1900. Xall: check_tools ecuhelp ecu ecuug ecuz ecus
  1901. X
  1902. Xtools: $(LBIN)/sysdep $(LBIN)/afterlint $(LBIN)/mkoldproto
  1903. X
  1904. Xcheck_tools:
  1905. X    @[ -x $(LBIN)/sysdep ] || echo '"make tools" first, with write access to $(LBIN)'
  1906. X    @[ -x $(LBIN)/sysdep ] || exit 1
  1907. X    touch check_tools
  1908. X
  1909. Xecuhelp: check_tools
  1910. X    cd help;make
  1911. X
  1912. Xecuz: check_tools
  1913. X    cd z;make
  1914. X
  1915. Xecus: check_tools
  1916. X    cd sea;make
  1917. X
  1918. Xbperr/bperr: check_tools bperr/bperr.c
  1919. X    cd bperr;make bperr
  1920. X
  1921. Xecu: check_tools $(OBJ)
  1922. X    echo 'char *makedate="'`date` $(SYSTEM)'";'  >makedate.c
  1923. X    $(CC) -c $(CFLAGS) makedate.c; rm makedate.c
  1924. X    rm -rf $@
  1925. X    $(CC) -o $@ $(COMFLAGS) makedate.o $(OBJ) $(LDFLAGS)
  1926. X    rm makedate.o
  1927. X
  1928. Xecuug: check_tools
  1929. X    cd ecuungetty;make CRYPT=$(CRYPT) LCRYPT=$(LCRYPT)
  1930. X
  1931. Xproc_error.c: ecuerror.h
  1932. X    make bperr/bperr
  1933. X    bperr/bperr
  1934. X
  1935. X$(OBJ): ecushm.h
  1936. X
  1937. Xecu.fls: $(SRC) Make.xgcc
  1938. X    ls $(SRC) >ecu.fls
  1939. X
  1940. Xlint: ecu.fls
  1941. X    echo ' ' > lint_args.h
  1942. X    csh zgcc ecu.fls lint_args.h $(CFLAGS)
  1943. X
  1944. XLint:
  1945. X    lint -ux *.c > ecu.lint
  1946. X
  1947. Xinstall: all ecuhelp ecuz ecus #run as root
  1948. X    cp ecu z/ecusz z/ecurz sea/ecusea $(LBIN)
  1949. X    -mkdir $(ECULIBDIR)
  1950. X    cd ecuungetty;make CRYPT=$(CRYPT) LCRYPT=$(LCRYPT) ECULIBDIR=$(ECULIBDIR)\
  1951. X        install
  1952. X    cp models/*.mi help/ecuhelp.data $(ECULIBDIR)
  1953. X    @echo "--------------------------------------------------------------------"
  1954. X    @echo "| edit $(ECULIBDIR)/*.mi for your tty lines per ecu.man"
  1955. X    @echo "--------------------------------------------------------------------"
  1956. X
  1957. Xshar.fls: Make.xgcc
  1958. X    csh -c 'ls $(SHARFLS) | sort > shar.fls'
  1959. X
  1960. X# for shar 3.40
  1961. Xshar:
  1962. X    csh -c 'shar -x -F -m -c -s "wht@n4hgf.Mt-Park.GA.US" -a \
  1963. X-n$(ECUSHARNAME) -l55 -o/tmp/$(ECUSHARNAME) $(SHARFLS) 
  1964. X    shar -x -F -m -c -s "wht%n4hgf@gatech.ecu" -a \
  1965. X-n$(MANSHARNAME) -L55 -o/tmp/$(MANSHARNAME) doc/ecu.man
  1966. X
  1967. XsharZ:
  1968. X    csh -c 'shar -x -F -m -C -c -s "wht@n4hgf.Mt-Park.GA.US" -a \
  1969. X-n$(ECUSHARNAME) -L50 -o/tmp/$(ECUSHARNAME)Z $(SHARFLS) 
  1970. X
  1971. X$(LBIN)/sysdep: sysdep.c    # uname -p undocumented on UNIX but works
  1972. X    @echo 'building sysdep for' `uname -p`
  1973. X    [ `uname -p` != i80286 ] || $(CC) -O -M2 sysdep.c -o $@
  1974. X    [ `uname -p`  = i80286 ] || $(CC) -O     sysdep.c -o $@
  1975. X
  1976. X$(LBIN)/afterlint: afterlint.c
  1977. X    $(CC) -O afterlint.c -o $@
  1978. X
  1979. X$(LBIN)/mkoldproto: mkoldproto.l
  1980. X    lex mkoldproto.l
  1981. X    $(CC) lex.yy.c -ll -o $@
  1982. X    rm lex.yy.?
  1983. X
  1984. X#
  1985. X#
  1986. X#
  1987. X# MAKE DEPEND: regenerate .o:.h dependencies automatically
  1988. X#
  1989. Xdepend:
  1990. X        rm -f depend.tmp
  1991. X        if test '$(SRC)' ;\
  1992. X        then (grep '^#include' $(SRC) \
  1993. X        | sed    -e 's?:[^<]*<\([^>]*\)>.*?: /usr/include/\1?'\
  1994. X            -e 's?:[^"]*"\([^"]*\)".*?: \1?'\
  1995. X            -e 's?\(.*\)\.c?\1.o?'\
  1996. X            -e 's?ecuerror.h?ecu.h?'\
  1997. X         >> depend.tmp) ;\
  1998. X        fi
  1999. X
  2000. X        echo '/^# DO NOT DELETE THIS LINE' >exdep.tmp
  2001. X        echo '.+1,$$d' >>exdep.tmp
  2002. X        echo 'r depend.tmp' >> exdep.tmp
  2003. X        echo 'w' >> exdep.tmp
  2004. X        cp Make.xgcc Make.xgcc.new
  2005. X        ex Make.xgcc.new < exdep.tmp
  2006. X        rm exdep.tmp depend.tmp
  2007. X        echo '#    DEPENDENCIES MUST END AT END OF    FILE' >>Make.xgcc.new
  2008. X        echo '#    IF YOU PUT STUFF HERE IT WILL GO AWAY'>>Make.xgcc.new
  2009. X        echo '#    see make depend    above'>>Make.xgcc.new
  2010. X        mv Make.xgcc Make.xgcc.bak
  2011. X        mv Make.xgcc.new Make.xgcc
  2012. X
  2013. X# DO NOT DELETE THIS LINE
  2014. Xcmdtbl.o: ecucmd.h
  2015. Xexpresp.o: ecu.h
  2016. Xexpresp.o: ecu.h
  2017. Xexpresp.o: esd.h
  2018. Xexpresp.o: var.h
  2019. Xexpresp.o: proc.h
  2020. Xecu.o: ecu.h
  2021. Xecu.o: esd.h
  2022. Xecu.o: proc.h
  2023. Xecu.o: ecukey.h
  2024. Xecu.o: ecuxkey.h
  2025. Xecu.o: ecuhangup.h
  2026. Xecu.o: patchlevel.h
  2027. Xecu.o: /usr/include/sys/param.h
  2028. XecuLCK.o: ecu.h
  2029. XecuLCK.o: utmpstatus.h
  2030. Xecuchdir.o: ecu.h
  2031. Xecuchdir.o: ecukey.h
  2032. Xecuchdir.o: /usr/include/pwd.h
  2033. Xecudump.o: ecu.h
  2034. Xecufinsert.o: ecu.h
  2035. Xecufinsert.o: ecukey.h
  2036. Xecufkey.o: ecu.h
  2037. Xecufkey.o: ecukey.h
  2038. Xecufkey.o: ecufkey.h
  2039. Xecufkey.o: ecuxkey.h
  2040. Xecufkey.o: ecufork.h
  2041. Xecufork.o: ecu.h
  2042. Xecufork.o: ecufork.h
  2043. XecuDCE.o: ecu.h
  2044. XecuDCE.o: ecukey.h
  2045. XecuDCE.o: esd.h
  2046. XecuDCE.o: var.h
  2047. XecuDCE.o: ecupde.h
  2048. XecuDCE.o: ecu.h
  2049. XecuDCE.o: relop.h
  2050. Xeculine.o: ecu.h
  2051. Xeculine.o: ecukey.h
  2052. Xeculine.o: ecuhangup.h
  2053. Xeculock.o: ecu.h
  2054. Xeculock.o: utmpstatus.h
  2055. Xecuicmaux.o: ecu.h
  2056. Xecuicmaux.o: ecu.h
  2057. Xecuicmaux.o: ecucmd.h
  2058. Xecuicmhelp.o: /usr/include/curses.h
  2059. Xecuicmhelp.o: ecu.h
  2060. Xecuicmhelp.o: ecucmd.h
  2061. Xecuicmhelp.o: ecukey.h
  2062. Xecuicmhelp.o: pc_scr.h
  2063. Xecuicmhelp.o: stdio_lint.h
  2064. Xecuicmhist.o: /usr/include/curses.h
  2065. Xecuicmhist.o: pc_scr.h
  2066. Xecuicmhist.o: ecu.h
  2067. Xecuicmhist.o: ecukey.h
  2068. Xecuicmhist.o: ecuxkey.h
  2069. Xecuicmd.o: ecu.h
  2070. Xecuicmd.o: esd.h
  2071. Xecuicmd.o: ecufkey.h
  2072. Xecuicmd.o: patchlevel.h
  2073. Xecuicmd.o: ecucmd.h
  2074. Xecuphone.o: /usr/include/curses.h
  2075. Xecuphone.o: ecu.h
  2076. Xecuphone.o: pc_scr.h
  2077. Xecuphone.o: ecupde.h
  2078. Xecuphone.o: ecukey.h
  2079. Xecuphone.o: ecuxkey.h
  2080. Xecuphone.o: ecuhangup.h
  2081. Xecuphone.o: utmpstatus.h
  2082. Xecuphone.o: dvent.h
  2083. Xecuphone.o: esd.h
  2084. Xecuphone.o: var.h
  2085. Xecuphrase.o: ecu.h
  2086. Xecurcvr.o: ecu.h
  2087. Xecurcvr.o: ecukey.h
  2088. Xecuscrdump.o: ecu.h
  2089. Xecuscrdump.o: ecukey.h
  2090. Xecuscrdump.o: pc_scr.h
  2091. Xecusetup.o: /usr/include/curses.h
  2092. Xecusetup.o: patchlevel.h
  2093. Xecusetup.o: ecu.h
  2094. Xecusetup.o: ecukey.h
  2095. Xecusetup.o: ecuxkey.h
  2096. Xecusetup.o: pc_scr.h
  2097. Xecushm.o: ecu.h
  2098. Xecushm.o: /usr/include/sys/ipc.h
  2099. Xecushm.o: /usr/include/sys/shm.h
  2100. Xecusighdl.o: ecu.h
  2101. Xecusighdl.o: ecufork.h
  2102. Xecutcap.o: ecu.h
  2103. Xecutcap.o: ecukey.h
  2104. Xecutcap.o: pc_scr.h
  2105. Xecutime.o: /usr/include/sys/types.h
  2106. Xecutime.o: /usr/include/time.h
  2107. Xecutime.o: /usr/include/sys/timeb.h
  2108. Xecutty.o: ecu.h
  2109. Xecutty.o: esd.h
  2110. Xecutty.o: ecufkey.h
  2111. Xecutty.o: ecukey.h
  2112. Xecutty.o: ecuxkey.h
  2113. Xecutty.o: ecu.h
  2114. Xecutty.o: ecuhangup.h
  2115. Xecutty.o: /usr/include/sys/machdep.h
  2116. Xecutty.o: ecutty.h
  2117. Xecuusage.o: /usr/include/stdio.h
  2118. Xecuusage.o: ecuhangup.h
  2119. Xecuutil.o: ecu.h
  2120. Xecuutil.o: ecuhangup.h
  2121. Xecuutil.o: ecufork.h
  2122. Xecuutil.o: /usr/include/pwd.h
  2123. Xecuwinutil.o: /usr/include/curses.h
  2124. Xecuwinutil.o: ecukey.h
  2125. Xecuwinutil.o: ecuxkey.h
  2126. Xecuwinutil.o: ecuhangup.h
  2127. Xecuwinutil.o: pc_scr.h
  2128. Xecuxenix.o: ecu.h
  2129. Xecuxenix.o: ecukey.h
  2130. Xecuxenix.o: ecufkey.h
  2131. Xecuxenix.o: ecuxkey.h
  2132. Xecuxenix.o: ecufork.h
  2133. Xecuxenix.o: esd.h
  2134. Xecuxfer.o: /usr/include/curses.h
  2135. Xecuxfer.o: ecu.h
  2136. Xecuxfer.o: ecukey.h
  2137. Xecuxfer.o: ecuxkey.h
  2138. Xecuxfer.o: ecu.h
  2139. Xecuxfer.o: pc_scr.h
  2140. Xesdutil.o: /usr/include/ctype.h
  2141. Xesdutil.o: ecu.h
  2142. Xesdutil.o: ecu.h
  2143. Xesdutil.o: esd.h
  2144. Xfeval.o: ecu.h
  2145. Xfeval.o: ecu.h
  2146. Xfeval.o: esd.h
  2147. Xfeval.o: proc.h
  2148. Xfeval.o: var.h
  2149. Xgint.o: ecu.h
  2150. Xgint.o: ecu.h
  2151. Xgint.o: esd.h
  2152. Xgint.o: var.h
  2153. Xgstr.o: ecu.h
  2154. Xgstr.o: ecu.h
  2155. Xgstr.o: esd.h
  2156. Xgstr.o: var.h
  2157. Xhdbintf.o: ecu.h
  2158. Xhdbintf.o: esd.h
  2159. Xhdbintf.o: var.h
  2160. Xhdbintf.o: ecuhangup.h
  2161. Xhdbintf.o: utmpstatus.h
  2162. Xhdbintf.o: ecuungetty.h
  2163. Xhdbintf.o: dvent.h
  2164. Xhdbintf.o: dlent.h
  2165. Xhdbintf.o: dialprog.h
  2166. Xhdbintf.o: /usr/include/errno.h
  2167. Xhdbintf.o: /usr/include/utmp.h
  2168. Xlogevent.o: /usr/include/stdio.h
  2169. Xlogevent.o: /usr/include/sys/locking.h
  2170. Xlogevent.o: stdio_lint.h
  2171. Xlogevent.o: lint_args.h
  2172. Xnonansikey.o: ecu.h
  2173. Xnonansikey.o: ecukey.h
  2174. Xnonansikey.o: ecufkey.h
  2175. Xnonansikey.o: ecuxkey.h
  2176. Xnonansikey.o: ecufork.h
  2177. Xpcmd.o: ecu.h
  2178. Xpcmd.o: ecu.h
  2179. Xpcmd.o: ecuhangup.h
  2180. Xpcmd.o: ecukey.h
  2181. Xpcmd.o: esd.h
  2182. Xpcmd.o: var.h
  2183. Xpcmd.o: proc.h
  2184. Xpcmdif.o: /usr/include/ctype.h
  2185. Xpcmdif.o: ecu.h
  2186. Xpcmdif.o: ecu.h
  2187. Xpcmdif.o: esd.h
  2188. Xpcmdif.o: var.h
  2189. Xpcmdif.o: proc.h
  2190. Xpcmdif.o: relop.h
  2191. Xpcmdfile.o: ecu.h
  2192. Xpcmdfile.o: ecukey.h
  2193. Xpcmdfile.o: ecu.h
  2194. Xpcmdfile.o: esd.h
  2195. Xpcmdfile.o: var.h
  2196. Xpcmdfile.o: proc.h
  2197. Xpcmdtty.o: ecu.h
  2198. Xpcmdtty.o: ecu.h
  2199. Xpcmdtty.o: esd.h
  2200. Xpcmdtty.o: ecutty.h
  2201. Xpcmdwhile.o: /usr/include/ctype.h
  2202. Xpcmdwhile.o: ecu.h
  2203. Xpcmdwhile.o: ecu.h
  2204. Xpcmdwhile.o: esd.h
  2205. Xpcmdwhile.o: var.h
  2206. Xpcmdwhile.o: proc.h
  2207. Xpcmdwhile.o: relop.h
  2208. Xpcmdxfer.o: ecu.h
  2209. Xpcmdxfer.o: ecukey.h
  2210. Xpcmdxfer.o: ecu.h
  2211. Xpcmdxfer.o: esd.h
  2212. Xpcmdxfer.o: var.h
  2213. Xpcmdxfer.o: proc.h
  2214. Xpoutput.o: ecu.h
  2215. Xpoutput.o: ecukey.h
  2216. Xpoutput.o: ecu.h
  2217. Xpoutput.o: esd.h
  2218. Xpprintf.o: /usr/include/stdio.h
  2219. Xpprintf.o: /usr/include/varargs.h
  2220. Xproc.o: /usr/include/ctype.h
  2221. Xproc.o: ecu.h
  2222. Xproc.o: ecu.h
  2223. Xproc.o: esd.h
  2224. Xproc.o: var.h
  2225. Xproc.o: proc.h
  2226. Xproc.o: ecucmd.h
  2227. Xproc_error.o: ecu.h
  2228. Xproc_error.o: ecu.h
  2229. Xprocframe.o: /usr/include/ctype.h
  2230. Xprocframe.o: ecu.h
  2231. Xprocframe.o: ecukey.h
  2232. Xprocframe.o: ecu.h
  2233. Xprocframe.o: esd.h
  2234. Xprocframe.o: var.h
  2235. Xprocframe.o: proc.h
  2236. Xregexp.o: /usr/include/stdio.h
  2237. Xregexp.o: stdio_lint.h
  2238. Xregexp.o: lint_args.h
  2239. Xregexp.o: ecu.h
  2240. Xregexp.o: esd.h
  2241. Xregexp.o: var.h
  2242. Xregexp.o: /usr/include/setjmp.h
  2243. Xutmpstat.o: ecu.h
  2244. Xutmpstat.o: ecuhangup.h
  2245. Xutmpstat.o: utmpstatus.h
  2246. Xutmpstat.o: ecuungetty.h
  2247. Xutmpstat.o: dialprog.h
  2248. Xutmpstat.o: /usr/include/errno.h
  2249. Xutmpstat.o: /usr/include/utmp.h
  2250. Xvar.o: ecu.h
  2251. Xvar.o: esd.h
  2252. Xvar.o: var.h
  2253. Xvar.o: proc.h
  2254. Xvar.o: ecukey.h
  2255. Xvar.o: ecu.h
  2256. X#    DEPENDENCIES MUST END AT END OF    FILE
  2257. X#    IF YOU PUT STUFF HERE IT WILL GO AWAY
  2258. X#    see make depend    above
  2259. SHAR_EOF
  2260. chmod 0644 Make.xgcc ||
  2261. echo 'restore of Make.xgcc failed'
  2262. Wc_c="`wc -c < 'Make.xgcc'`"
  2263. test 12403 -eq "$Wc_c" ||
  2264.     echo 'Make.xgcc: original size 12403, current size' "$Wc_c"
  2265. exit 0
  2266.  
  2267. exit 0 # Just in case...
  2268. -- 
  2269. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  2270. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  2271. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  2272. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  2273.