home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.unix.solaris:422 comp.windows.x:20372 comp.unix.programmer:5733
- Newsgroups: comp.unix.solaris,comp.windows.x,comp.unix.programmer
- Path: sparky!uunet!walter!dino!dana
- From: dana@dino.bellcore.com (Dana Chee)
- Subject: Re: Solaris 2: how do I get rid of -lucb ?
- Message-ID: <1992Dec18.133818.19160@walter.bellcore.com>
- Keywords: SVR4, shared libraries, Solaris 2
- Sender: news@walter.bellcore.com
- Nntp-Posting-Host: dino.bellcore.com
- Reply-To: dana@thumper.bellcore.com
- Organization: Packet Communications Research Group (Bellcore)
- References: <1992Dec18.094738.15038@sunbim.be>
- Date: Fri, 18 Dec 92 13:38:18 GMT
- Lines: 53
-
- In article <1992Dec18.094738.15038@sunbim.be>, db@sunbim.be (Danny Backx) writes:
- |> Hi,
- |>
- |> I am using Solaris 2.* on my SPARC, and many of the home-brew applications
- |> I have compiled on it (with Motif, Xt, and Xlib libraries) have the habit
- |> of trying to load libucb at run time.
- |>
- |> What happens in fact is I compile the applications with commands like this :
- |> cc -o prog *.o -lXm -lXt -lX11
- |> without any references to /usr/ucbinclude or /usr/ucblib around. That is, I
- |> do NOT have an LD_LIBRARY_PATH or an LD_RUN_PATH set, and none of the sources
- |> require /usr/ucbinclude.
- |>
- |> When after linking I use "ldd" on the executable, it will tell me that the
- |> UCB library is linked in. E.g.
- |> whitney!db 90 % ldd phone
-
- ...
-
- |> libelf.so.1 => /usr/lib/libelf.so.1
- |> --> libucb.so.1 => /usr/ucblib/libucb.so.1
- |> libdl.so.1 => /usr/lib/libdl.so.1
- |>
-
- ...
-
- |> How can I find out exactly what is causing this ? I would like to know how
- |> to generate applications that can run without the binary compatibility
- |> package.
- |>
- |> Thanks,
- |> Danny
- |> --
-
- Danny,
- What compiler are you using? If its the one in /usr/ucb/cc,
- then you are getting the expected behaviour. /usr/ucb/cc is a shell
- script that adds -lucb -lsocket -lnsl -lelf -laio to your load path
- and /usr/ucbinclude to your include path. What you probably want to
- do is get gcc, this will remove any of the above. (I've not tried
- running /usr/ucb/cc without doing the above, since its designed to
- compile things in compatability mode). The Cygnus distribution is
- available anon ftp from uunet, or you can get the source and build it
- yourself.
-
- --
- +*************************************************************************+
- * Dana Chee (201) 829-4488 *
- * Bellcore *
- * Room 2P-298 *
- * 445 South Street ARPA: dana@bellcore.com *
- * Morristown, NJ 07960-1910 UUCP: {gateways}!bellcore!dana *
- +*************************************************************************+
-