home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / os / linux / 9739 < prev    next >
Encoding:
Text File  |  1992-09-03  |  1.9 KB  |  61 lines

  1. Path: sparky!uunet!mcsun!corton!jussieu!card
  2. From: card@masi.ibp.fr (Remy CARD)
  3. Newsgroups: comp.os.linux
  4. Subject: Re: GNU shell utils 1.7: date(1) dumps core (with easy solution:)
  5. Message-ID: <1992Sep3.135118.21625@jussieu.fr>
  6. Date: 3 Sep 92 13:51:18 GMT
  7. References: <9209013094@gandalf.moria>
  8. Sender: news@jussieu.fr (Le Facteur)
  9. Organization: Laboratoire MASI - Universite Pierre et Marie Curie - Paris - France
  10. Lines: 48
  11. Nntp-Posting-Host: ares.ibp.fr
  12.  
  13. In article <9209013094@gandalf.moria> u31b3hs@pool.informatik.rwth-aachen.de (Michael Haardt) writes:
  14. >I have just installed the GNU shell utilities 1.7 on Linux 0.96c-pl1,
  15. >using GCC 2.2.2.  They compile on first try without changes, but the
  16. >first program I tried crashed: "date"
  17. >
  18. >The fix is simple, after the configure run just add -DHAVE_TZNAME.
  19. >Otherwise, a function char *timezone() is used, and in Linux,
  20. >timezone is a long int variable!
  21. >
  22. >People who are interested in it may improve configure (or Linux), I
  23. >don't have the time for it.
  24.  
  25.     In fact, the fix to configure is pretty small.  configure tries
  26. to compile a program defining 'extern char **tzname' and gcc complains
  27. because tzname is declared as 'extern char *tzname[]' so configure assumes
  28. that tzname does not exist in Linux.
  29.  
  30.     You can apply this patch to correct configure :
  31.  
  32. *** configure.old    Thu Sep  3 15:44:35 1992
  33. --- configure    Thu Sep  3 15:44:47 1992
  34. ***************
  35. *** 606,612 ****
  36.   echo checking for tzname
  37.   echo "#include <time.h>
  38.   #ifndef tzname /* For SGI.  */
  39. ! extern char **tzname;
  40.   #endif
  41.   main() { exit(0); } t() { atoi(*tzname); }" > conftest.c
  42.   if eval $compile; then
  43. --- 606,612 ----
  44.   echo checking for tzname
  45.   echo "#include <time.h>
  46.   #ifndef tzname /* For SGI.  */
  47. ! extern char *tzname[];
  48.   #endif
  49.   main() { exit(0); } t() { atoi(*tzname); }" > conftest.c
  50.   if eval $compile; then
  51.  
  52. >
  53. >Michael
  54.  
  55.  
  56.     Remy
  57. --
  58.  
  59.     Remy Card
  60.     card@masi.ibp.fr
  61.