home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.att
- Path: sparky!uunet!uunet.ca!canrem!telly!robohack!woods
- From: woods@robohack.UUCP (Greg A. Woods)
- Subject: Re: GCC 2.3.2 compile problem on 3B2/400
- Organization: Elegant Communications Inc.
- References: <1992Dec28.040206.24732@dartvax.dartmouth.edu> <1992Dec28.214904.107@serveme.chi.il.us>
- Message-ID: <1992Dec30.041024.299@robohack.UUCP>
- Date: Wed, 30 Dec 92 04:10:24 GMT
- Lines: 31
-
- In article <1992Dec28.214904.107@serveme.chi.il.us> greg@serveme.chi.il.us (Gregory Gulik) writes:
- > In article <1992Dec28.040206.24732@dartvax.dartmouth.edu> pete@othello.dartmouth.edu (Pete Schmitt) writes:
- > >[....]
- > >How can I fix this?
- >
- > I doubt this is the optimal fix, but I went through the source
- > and changed all references to index()/rindex() to strchr()/strrchr()
-
- Geez guy's -- what a waste of time, energy, etc.; as well as being a
- potential source of ugly errors....
-
- Haven't you ever heard of "#define"??????
-
- I.e.:
-
- #ifdef HAVE_STRCHR
- # define index strchr
- # define rindex strrchr
- #endif
-
- Or:
-
- cc ... -Dindex=strchr -Drindex=strrchr ...
-
- (as appropriate -- i.e. only use the former if there's already a
- global configuration header that you're expected to modify....)
- --
- Greg A. Woods
-
- woods@robohack.UUCP, woods@Elegant.COM VE3TCP UniForum Canada & ECI
- +1 416 443-1734 [home] +1 416 362-XRSA [work] Toronto, Ontario; CANADA
-