in lib/Makefile Make the same change to<br><br><br>stackio: stackio.c libxymon.a<br>        $(CC) $(CFLAGS) -DSTANDALONE -o $@ stackio.c ./libxymon.a $(LIBRTDEF)<br><br>change it to <br><br> $(CC) $(CFLAGS) -DSTANDALONE -o $@ stackio.c ./libxymon.a $(NETLIBS) $(LIBRTDEF)<br>
<br><br><br><div class="gmail_quote">On Tue, Sep 20, 2011 at 8:06 PM, Roland Soderstrom <span dir="ltr"><<a href="mailto:rolands@logicaltech.com.au">rolands@logicaltech.com.au</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    Hi,<br>
    <br>
    Thanks Ralph, Henrik.<br>
    <br>
    Got over the first hurdle...<br>
    Adding $(NETLIBS) worked just fine.<br>
    <br>
    Now I failed on the next... stackio.c<br>
    <br>
    gcc -g -O2 -Wall -Wno-unused -D_REENTRANT  -DSunOS -I.
    -I/var/tmp/xymon-4.3.5/include -I/usr/local/include -I.
    -I../include  -DSTANDALONE -o loadhosts loadhosts.c ./libxymon.a
    -lresolv -lsocket -lnsl -lrt<br>
    loadhosts_file.c: In function `load_hostnames':<br>
    loadhosts_file.c:131: warning: 'insavchar' might be used
    uninitialized in this function<br>
    gcc -g -O2 -Wall -Wno-unused -D_REENTRANT  -DSunOS -I.
    -I/var/tmp/xymon-4.3.5/include -I/usr/local/include -I.
    -I../include  -DSTANDALONE -o stackio stackio.c ./libxymon.a -lrt<br>
    stackio.c: In function `stackfgets':<br>
    stackio.c:424: warning: 'eolchar' might be used uninitialized in
    this function<br>
    stackio.c:440: warning: 'eolchar' might be used uninitialized in
    this function<br>
    Undefined                       first referenced<br>
     symbol                             in file<br>
    recv                                ./libxymon.a(sendmsg.o)<br>
    getservbyname                       ./libxymon.a(sendmsg.o)<br>
    gethostbyname                       ./libxymon.a(sendmsg.o)<br>
    socket                              ./libxymon.a(sendmsg.o)<br>
    getsockopt                          ./libxymon.a(sendmsg.o)<br>
    connect                             ./libxymon.a(sendmsg.o)<br>
    inet_aton                           ./libxymon.a(sendmsg.o)<br>
    inet_ntoa                           ./libxymon.a(sendmsg.o)<br>
    shutdown                            ./libxymon.a(sendmsg.o)<br>
    ld: fatal: Symbol referencing errors. No output written to stackio<br>
    collect2: ld returned 1 exit status<br>
    make[1]: *** [stackio] Error 1<br>
    make[1]: Leaving directory `/var/tmp/xymon-4.3.5/lib'<br>
    make: *** [lib-build] Error 2<br>
    <br>
    <br>
    - Roland<br>
    <div>
      
      
      <br>
      <br>
    </div>
    On 20/09/11 03:46 PM, Henrik Størner wrote:
    <blockquote type="cite">On
      20-09-2011 02:03, Roland Soderstrom wrote:
      <br>
      <blockquote type="cite">
        <br>
        gcc -g -O2 -Wall -Wno-unused -D_REENTRANT -DSunOS -I.
        <br>
        -I/var/tmp/xymon-4.3.5/include -I/usr/local/include -I.
        -I../include
        <br>
        -DSTANDALONE -o loadhosts loadhosts.c ./libxymon.a -lrt
        <br>
        Undefined first referenced
        <br>
        symbol in file
        <br>
        recv ./libxymon.a(sendmsg.o)
        <br>
        getservbyname ./libxymon.a(sendmsg.o)
        <br>
      </blockquote>
      <br>
      Oh dear - those Solaris network libraries ...
      <br>
      <br>
      In lib/Makefile, you need to add "$(NETLIBS)" to the list of
      libraries used for the "loadhosts" tool. It is line 66:
      <br>
      <br>
      loadhosts: loadhosts.c libxymon.a
      <br>
              $(CC) $(CFLAGS) -DSTANDALONE -o $@ loadhosts.c
      ./libxymon.a $(LIBRTDEF)
      <br>
      <br>
      Change it to
      <br>
      <br>
      loadhosts: loadhosts.c libxymon.a
      <br>
              $(CC) $(CFLAGS) -DSTANDALONE -o $@ loadhosts.c
      ./libxymon.a $(NETLIBS) $(LIBRTDEF)
      <br>
      <br>
      I'll have to dig up a Solaris box to see if the same has to be
      done elsewhere.
      <br>
      <br>
      <br>
      Regards,
      <br>
      Henrik
      <br>
      _______________________________________________
      <br>
      Xymon mailing list
      <br>
      <a href="mailto:Xymon@xymon.com" target="_blank">Xymon@xymon.com</a>
      <br>
      <a href="http://lists.xymon.com/mailman/listinfo/xymon" target="_blank">http://lists.xymon.com/mailman/listinfo/xymon</a>
      <br>
    </blockquote>
  </div>

<br>_______________________________________________<br>
Xymon mailing list<br>
<a href="mailto:Xymon@xymon.com">Xymon@xymon.com</a><br>
<a href="http://lists.xymon.com/mailman/listinfo/xymon" target="_blank">http://lists.xymon.com/mailman/listinfo/xymon</a><br>
<br></blockquote></div><br>