Dynamic linking: Solaris 2.3 and 2.4

Dynamic linking: Solaris 2.3 and 2.4

Post by Tony Wi » Thu, 03 Aug 1995 04:00:00

Hi all, I have a question about dynamic linking and running on
Solaris 2.3 and Solaris 2.4 (Sun). It is this:

    Is it possible to build an executable under Solaris 2.3 with
    various dynamic libraries and then run it under Solaris 2.4?
    OR is it 'accepted' that the executable be relinked for
    each Solaris release?

Some more detail about my particular problem: Our Co. is releasing
a Solaris 2.3 based application with various dynamically linked
libraries (Xm, X11, etc). We would like to be able to build and
run on both Solaris 2.3 and 2.4 with one executable.

To be specific and show the problem we are having lets take the
Motif library:

Under Solaris 2.3:

i) We are linking with the -lXm statement.
ii) This resolves to /lib/libXm.so which is a link to
    /lib/libXm.so.2.3 which in turn is a link to

Now under Solaris 2.4:

i) We are linking with -lXm statement.
ii) This resolves to /usr/dt/libXm.so which is a link
    to /usr/dt/libXm.so.3

I was expecting the executable to remember libXm.so but
it seems to remember the 'actual' library name not the
link. i.e. libXm.so.2.3 (2.3) and libXm.so.3 (2.4).

This leads to unresolved libraries when executing the 2.4
under 2.3 and when executing 2.3 under 2.4.

Is there anyway to get the final executable remember the
libXm.so name as the dynamic library to link. Then hopefully
it'll just pick up whatever libXm.so is installed (via
LD_LIBRARY_PATH probably)?

Thanks, please email the below address with any info. Tony.
Tony Wise                          NETRIX Corporation
                                   13595 Dulles Technology Drive


1. HELP: Solaris 2.3 <---> Solaris 2.3 PPP link problems

Hi all,

We are attempting to link up two Solaris 2.3 networks via PPP and we are
running into some problems.  The link initialy comes up and we are able to ping
both sides for about 30 seconds or so and then nothing.  Does anyone have a
clue what could be hapening? We are stumped here.


- Steve
 Always going where no one has gone before...


2. Problems creating clusters with Solaris Packaging

3. HELP: Solaris 2.3 <---> Solaris 2.3 PPP link Problems

4. Help find LINUX CDROM's

5. PPP dynamic poin to point link don't hang the modem on Solaris 2.3

6. ms busmouse problem +

7. Solaris 2.3: combining dynamic and static linking

8. 2.5.17 Module woes

9. Solaris 2.4 vs. Solaris 2.3

10. moving from SPARC solaris 2.3 to x86 solaris 2.4

11. SLIP for Solaris 2.3 or 2.4

12. Passing Sockets under Solaris 2.3/2.4

13. "textedit" under Solaris 2.3 and 2.4