home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / unix / solaris / 422 < prev    next >
Encoding:
Internet Message Format  |  1992-12-21  |  2.6 KB

  1. Xref: sparky comp.unix.solaris:422 comp.windows.x:20372 comp.unix.programmer:5733
  2. Newsgroups: comp.unix.solaris,comp.windows.x,comp.unix.programmer
  3. Path: sparky!uunet!walter!dino!dana
  4. From: dana@dino.bellcore.com (Dana Chee)
  5. Subject: Re: Solaris 2: how do I get rid of -lucb ?
  6. Message-ID: <1992Dec18.133818.19160@walter.bellcore.com>
  7. Keywords: SVR4, shared libraries, Solaris 2
  8. Sender: news@walter.bellcore.com
  9. Nntp-Posting-Host: dino.bellcore.com
  10. Reply-To: dana@thumper.bellcore.com
  11. Organization: Packet Communications Research Group (Bellcore)
  12. References:  <1992Dec18.094738.15038@sunbim.be>
  13. Date: Fri, 18 Dec 92 13:38:18 GMT
  14. Lines: 53
  15.  
  16. In article <1992Dec18.094738.15038@sunbim.be>, db@sunbim.be (Danny Backx) writes:
  17. |> Hi,
  18. |> 
  19. |> I am using Solaris 2.* on my SPARC, and many of the home-brew applications
  20. |> I have compiled on it (with Motif, Xt, and Xlib libraries) have the habit
  21. |> of trying to load libucb at run time.
  22. |> 
  23. |> What happens in fact is I compile the applications with commands like this :
  24. |>     cc -o prog *.o -lXm -lXt -lX11
  25. |> without any references to /usr/ucbinclude or /usr/ucblib around. That is, I
  26. |> do NOT have an LD_LIBRARY_PATH or an LD_RUN_PATH set, and none of the sources
  27. |> require /usr/ucbinclude.
  28. |> 
  29. |> When after linking I use "ldd" on the executable, it will tell me that the
  30. |> UCB library is linked in. E.g.
  31. |>     whitney!db 90 % ldd phone
  32.  
  33. ...
  34.  
  35. |>         libelf.so.1 =>   /usr/lib/libelf.so.1
  36. |> -->        libucb.so.1 =>   /usr/ucblib/libucb.so.1
  37. |>         libdl.so.1 =>    /usr/lib/libdl.so.1
  38. |>
  39.  
  40. ...
  41.  
  42. |> How can I find out exactly what is causing this ? I would like to know how
  43. |> to generate applications that can run without the binary compatibility
  44. |> package.
  45. |> 
  46. |> Thanks,
  47. |>     Danny
  48. |> --
  49.  
  50. Danny,
  51.     What compiler are you using?  If its the one in /usr/ucb/cc,
  52. then you are getting the expected behaviour.  /usr/ucb/cc is a shell
  53. script that adds -lucb -lsocket -lnsl -lelf -laio to your load path
  54. and /usr/ucbinclude to your include path.  What you probably want to
  55. do is get gcc, this will remove any of the above.  (I've not tried
  56. running /usr/ucb/cc without doing the above, since its designed to
  57. compile things in compatability mode).  The Cygnus distribution is
  58. available anon ftp from uunet, or you can get the source and build it
  59. yourself.
  60.  
  61. --
  62. +*************************************************************************+
  63. *  Dana Chee                (201) 829-4488              *
  64. *  Bellcore                                  *
  65. *  Room 2P-298                                  *
  66. *  445 South Street            ARPA: dana@bellcore.com          *
  67. *  Morristown,  NJ  07960-1910        UUCP: {gateways}!bellcore!dana      *
  68. +*************************************************************************+
  69.