home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / gnu / gcc / help / 3054 < prev    next >
Encoding:
Text File  |  1993-01-28  |  1.5 KB  |  44 lines

  1. Newsgroups: gnu.gcc.help
  2. Path: sparky!uunet!ferkel.ucsb.edu!taco!gatech!darwin.sura.net!newsserver.jvnc.net!yale.edu!ira.uka.de!math.fu-berlin.de!news.netmbx.de!Germany.EU.net!mcsun!sunic!sics.se!eua.ericsson.se!ericom!eos.ericsson.se!etxmesa
  3. From: etxmesa@eos.ericsson.se (Michael Salmon)
  4. Subject: Re: Can gcc produce position-independent object code for shared libraries?
  5. Message-ID: <1993Jan28.093317.2547@ericsson.se>
  6. Keywords: gcc gnu shared -pic
  7. Sender: news@ericsson.se
  8. Nntp-Posting-Host: eos6c02.ericsson.se
  9. Reply-To: etxmesa@eos.ericsson.se (Michael Salmon)
  10. Organization: Ericsson Telecom AB
  11. References:  <1993Jan26.214222.3324@is.morgan.com>
  12. Date: Thu, 28 Jan 1993 09:33:17 GMT
  13. Lines: 29
  14.  
  15. In article <1993Jan26.214222.3324@is.morgan.com>
  16. jlieb@is.morgan.com (Jerry Liebelson) writes:
  17. |> Or, what's the gcc equivalent of the cc -pic option for use with
  18. |> compiling modules for subsequent linking into a SunOS 4.11 shared library?
  19. |> 
  20. |> Please answer from actual experience, thank you.
  21.  
  22. From the man page (and actual experience with SunOS 4.1.1):
  23.  
  24.      -fpic
  25.           If  supported  for  the   target   machines,   generate
  26.           position-independent code, suitable for use in a shared
  27.           library.
  28.  
  29.      -fPIC
  30.           If supported for the  target  machine,  emit  position-
  31.           independent code, suitable for dynamic linking, even if
  32.           branches need large displacements.
  33.  
  34. -- 
  35.  
  36. Michael Salmon
  37.  
  38. #include    <standard.disclaimer>
  39. #include    <witty.saying>
  40. #include    <fancy.pseudo.graphics>
  41.  
  42. Ericsson Telecom AB
  43. Stockholm
  44.