home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.linux
- Path: sparky!uunet!enterpoop.mit.edu!bloom-picayune.mit.edu!athena.mit.edu!jfc
- From: jfc@athena.mit.edu (John F Carr)
- Subject: Re: gcc 2.3.3 problem
- Message-ID: <1993Jan28.042809.12341@athena.mit.edu>
- Sender: news@athena.mit.edu (News system)
- Nntp-Posting-Host: achates.mit.edu
- Organization: Massachusetts Institute of Technology
- References: <1993Jan25.144702.4734@hp9000.csc.cuhk.hk> <SCT.93Jan26194220@ascrib.dcs.ed.ac.uk>
- Date: Thu, 28 Jan 1993 04:28:09 GMT
- Lines: 18
-
- In article <SCT.93Jan26194220@ascrib.dcs.ed.ac.uk>
- sct@dcs.ed.ac.uk (Stephen Tweedie) writes:
-
- >However, it uses the position of an option on the command line to
- >determine which options to pass to which program. Linking is done
- >after compilation, so linker options should come after compiler
- >options and arguments on the gcc command line.
-
- This is not true. Linker options can appear anywhere on the command line
- (.o files are also linker options). The compiler preserves the order of
- linker options. Most linkers are sensitive to the order of options. For
- object files (.o) the order isn't usually important, but for libraries it
- is. A library must follow the object file that depends on it.
-
- The only system I know of that does not behave this way is AIX version 3.
-
- --
- John Carr (jfc@athena.mit.edu)
-