<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: linking problem in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686140#M723313</link>
    <description>&lt;BR /&gt;Hi again.&lt;BR /&gt;&lt;BR /&gt;Seems I did not get the script attached.&lt;BR /&gt;Try to include it here:&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;#&lt;BR /&gt;# Filename: /home/olav/scripts/findsym&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# DESCRIPTION:&lt;BR /&gt;#    This scripts runs through files in a given directory  searching&lt;BR /&gt;#    for a given symbol.&lt;BR /&gt;#&lt;BR /&gt;#    It uses the odump command&lt;BR /&gt;#    (not suported under  hp-ux 10.x,  but is found in the&lt;BR /&gt;#    filset USRCONTRB. No man-page on 10.x&lt;BR /&gt;#    Supported under hp-ux 11.x  (with man-page)&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# WRITTEN BY:&lt;BR /&gt;#    This is an unsupported script written by:&lt;BR /&gt;#    Olav Baadsvik  12/4-94&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# Last modified:16/10-01&lt;BR /&gt;#            &lt;BR /&gt;SCRIPT_NAME=`basename $0`&lt;BR /&gt;#  10.20 ODUMPPATH=/usr/contrib/bin&lt;BR /&gt;ODUMPPATH=/usr/ccs/bin&lt;BR /&gt;&lt;BR /&gt;REQ_ARGUMENTS=3    # minumum number of arguments required&lt;BR /&gt;MAX_ARGUMENTS=3    # maximum number of arguments&lt;BR /&gt;&lt;BR /&gt;print_usage()&lt;BR /&gt;{&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "Usage:"&lt;BR /&gt;  echo " $SCRIPT_NAME  directory  extension   symbol"&lt;BR /&gt;  echo " "&lt;BR /&gt;  echo "  directory  - directory to search in."&lt;BR /&gt;  echo "  extension  - checks files matching  *.extension"&lt;BR /&gt;  echo "               extension will normally be one of sl, o, a,  1,  2"&lt;BR /&gt;  echo "  symbol     - symbol to search for"&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "  Example of use:"&lt;BR /&gt;  echo "    $SCRIPT_NAME /usr/lib  sl  xdr_char"&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "  An OB-product"   &lt;BR /&gt;   echo ""&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;##########################################################&lt;BR /&gt;# Section for testing of arguments&lt;BR /&gt;&lt;BR /&gt;if [ $# -lt $REQ_ARGUMENTS -o $# -gt $MAX_ARGUMENTS ]&lt;BR /&gt;  then&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "Wrong number of arguments"&lt;BR /&gt;  echo "Minimum number of arguments: $REQ_ARGUMENTS"&lt;BR /&gt;  echo "Maximum number of arguments: $MAX_ARGUMENTS"&lt;BR /&gt;  print_usage&lt;BR /&gt;  exit 1&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;if [ ! -d $1 ]&lt;BR /&gt;  then&lt;BR /&gt;   echo ""&lt;BR /&gt;   echo "$1 is not a directory"&lt;BR /&gt;   print_usage   &lt;BR /&gt;   exit 1&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;# end of section for testing arguments&lt;BR /&gt;#########################################################&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;STARTDIR=$1&lt;BR /&gt;cd $STARTDIR&lt;BR /&gt;filer=`ls -d *.$2 2&amp;gt; /dev/null`&lt;BR /&gt;if [ $? -ne 0 ]&lt;BR /&gt;  then&lt;BR /&gt;    echo ""&lt;BR /&gt;    echo "No  .$2-files found in  $STARTDIR"&lt;BR /&gt;    echo ""&lt;BR /&gt;    print_usage&lt;BR /&gt;    exit 1&lt;BR /&gt;fi&lt;BR /&gt;for i in $filer&lt;BR /&gt;do&lt;BR /&gt; if  test -d $i  # skip if directory&lt;BR /&gt;   then&lt;BR /&gt;   continue    &lt;BR /&gt; fi&lt;BR /&gt; echo "Checking file $STARTDIR/$i"&lt;BR /&gt; if $ODUMPPATH/odump -symbols $i|grep Entry|grep Univ | grep -i $3&lt;BR /&gt;  then&lt;BR /&gt;    echo "Symbol $3 found in file  $STARTDIR/$i"&lt;BR /&gt;    if  test -L $i&lt;BR /&gt;     then&lt;BR /&gt;       echo "NOTE!!! $i is a link:"&lt;BR /&gt;       LINKTEXT=$(ls -l $i)  # to avoid tab-expansion&lt;BR /&gt;       echo $LINKTEXT&lt;BR /&gt;    fi&lt;BR /&gt;    echo ""&lt;BR /&gt; fi&lt;BR /&gt;done  &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Olav&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Tue, 19 Mar 2002 20:50:29 GMT</pubDate>
    <dc:creator>Olav Baadsvik</dc:creator>
    <dc:date>2002-03-19T20:50:29Z</dc:date>
    <item>
      <title>linking problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686137#M723310</link>
      <description>Hi guys,&lt;BR /&gt;&lt;BR /&gt;I am trying to build httpd binary and I get the following undefined symbols.&lt;BR /&gt;&lt;BR /&gt;/usr/ccs/bin/ld: (Warning) At least one PA 2.0 object file (buildmark.o) was detected. The linked output may not run on a PA 1.x system.&lt;BR /&gt;/usr/ccs/bin/ld: Unsatisfied symbols:&lt;BR /&gt;   __eprintf (code)&lt;BR /&gt;   __udivdi3 (code)&lt;BR /&gt;   __umoddi3 (code)&lt;BR /&gt;*** Error exit code 1&lt;BR /&gt;&lt;BR /&gt;How can I find out where are those symbols are coming from? (nm -p doesn't give this information)&lt;BR /&gt;&lt;BR /&gt;Also, is it possible to remove the above symbols from the generated binary file? The file is actually generated even though errors were encountered. When use the file, it core-dumps.&lt;BR /&gt;&lt;BR /&gt;Thank you.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Mar 2002 15:17:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686137#M723310</guid>
      <dc:creator>andi_1</dc:creator>
      <dc:date>2002-03-19T15:17:54Z</dc:date>
    </item>
    <item>
      <title>Re: linking problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686138#M723311</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Let me give you my standard method for finding where these symbols are defined.&lt;BR /&gt;&lt;BR /&gt;1) Cd to desired library directly, e.g. /usr/lib&lt;BR /&gt;&lt;BR /&gt;2) nm lib* &amp;gt; /tmp/list&lt;BR /&gt;&lt;BR /&gt;3) Search /tmp/list using grep or vi for your symbols. The file name listed immediately above these symbols (which may be only a few lines above or many lines above) will be the library that you need to include in your link.&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Mar 2002 15:39:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686138#M723311</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2002-03-19T15:39:02Z</dc:date>
    </item>
    <item>
      <title>Re: linking problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686139#M723312</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Here is a script  I use to find where&lt;BR /&gt;a symbol is defined.  It uses the &lt;BR /&gt;odump command.  You will understand how&lt;BR /&gt;to use it by trying it (and reading the&lt;BR /&gt;script)&lt;BR /&gt;&lt;BR /&gt;It comes as an attachment as I am afraid&lt;BR /&gt;lines will be messed up otherwise.&lt;BR /&gt;&lt;BR /&gt;Olav</description>
      <pubDate>Tue, 19 Mar 2002 20:46:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686139#M723312</guid>
      <dc:creator>Olav Baadsvik</dc:creator>
      <dc:date>2002-03-19T20:46:53Z</dc:date>
    </item>
    <item>
      <title>Re: linking problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686140#M723313</link>
      <description>&lt;BR /&gt;Hi again.&lt;BR /&gt;&lt;BR /&gt;Seems I did not get the script attached.&lt;BR /&gt;Try to include it here:&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;#&lt;BR /&gt;# Filename: /home/olav/scripts/findsym&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# DESCRIPTION:&lt;BR /&gt;#    This scripts runs through files in a given directory  searching&lt;BR /&gt;#    for a given symbol.&lt;BR /&gt;#&lt;BR /&gt;#    It uses the odump command&lt;BR /&gt;#    (not suported under  hp-ux 10.x,  but is found in the&lt;BR /&gt;#    filset USRCONTRB. No man-page on 10.x&lt;BR /&gt;#    Supported under hp-ux 11.x  (with man-page)&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# WRITTEN BY:&lt;BR /&gt;#    This is an unsupported script written by:&lt;BR /&gt;#    Olav Baadsvik  12/4-94&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;#&lt;BR /&gt;# Last modified:16/10-01&lt;BR /&gt;#            &lt;BR /&gt;SCRIPT_NAME=`basename $0`&lt;BR /&gt;#  10.20 ODUMPPATH=/usr/contrib/bin&lt;BR /&gt;ODUMPPATH=/usr/ccs/bin&lt;BR /&gt;&lt;BR /&gt;REQ_ARGUMENTS=3    # minumum number of arguments required&lt;BR /&gt;MAX_ARGUMENTS=3    # maximum number of arguments&lt;BR /&gt;&lt;BR /&gt;print_usage()&lt;BR /&gt;{&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "Usage:"&lt;BR /&gt;  echo " $SCRIPT_NAME  directory  extension   symbol"&lt;BR /&gt;  echo " "&lt;BR /&gt;  echo "  directory  - directory to search in."&lt;BR /&gt;  echo "  extension  - checks files matching  *.extension"&lt;BR /&gt;  echo "               extension will normally be one of sl, o, a,  1,  2"&lt;BR /&gt;  echo "  symbol     - symbol to search for"&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "  Example of use:"&lt;BR /&gt;  echo "    $SCRIPT_NAME /usr/lib  sl  xdr_char"&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "  An OB-product"   &lt;BR /&gt;   echo ""&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;##########################################################&lt;BR /&gt;# Section for testing of arguments&lt;BR /&gt;&lt;BR /&gt;if [ $# -lt $REQ_ARGUMENTS -o $# -gt $MAX_ARGUMENTS ]&lt;BR /&gt;  then&lt;BR /&gt;  echo ""&lt;BR /&gt;  echo "Wrong number of arguments"&lt;BR /&gt;  echo "Minimum number of arguments: $REQ_ARGUMENTS"&lt;BR /&gt;  echo "Maximum number of arguments: $MAX_ARGUMENTS"&lt;BR /&gt;  print_usage&lt;BR /&gt;  exit 1&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;if [ ! -d $1 ]&lt;BR /&gt;  then&lt;BR /&gt;   echo ""&lt;BR /&gt;   echo "$1 is not a directory"&lt;BR /&gt;   print_usage   &lt;BR /&gt;   exit 1&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;# end of section for testing arguments&lt;BR /&gt;#########################################################&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;STARTDIR=$1&lt;BR /&gt;cd $STARTDIR&lt;BR /&gt;filer=`ls -d *.$2 2&amp;gt; /dev/null`&lt;BR /&gt;if [ $? -ne 0 ]&lt;BR /&gt;  then&lt;BR /&gt;    echo ""&lt;BR /&gt;    echo "No  .$2-files found in  $STARTDIR"&lt;BR /&gt;    echo ""&lt;BR /&gt;    print_usage&lt;BR /&gt;    exit 1&lt;BR /&gt;fi&lt;BR /&gt;for i in $filer&lt;BR /&gt;do&lt;BR /&gt; if  test -d $i  # skip if directory&lt;BR /&gt;   then&lt;BR /&gt;   continue    &lt;BR /&gt; fi&lt;BR /&gt; echo "Checking file $STARTDIR/$i"&lt;BR /&gt; if $ODUMPPATH/odump -symbols $i|grep Entry|grep Univ | grep -i $3&lt;BR /&gt;  then&lt;BR /&gt;    echo "Symbol $3 found in file  $STARTDIR/$i"&lt;BR /&gt;    if  test -L $i&lt;BR /&gt;     then&lt;BR /&gt;       echo "NOTE!!! $i is a link:"&lt;BR /&gt;       LINKTEXT=$(ls -l $i)  # to avoid tab-expansion&lt;BR /&gt;       echo $LINKTEXT&lt;BR /&gt;    fi&lt;BR /&gt;    echo ""&lt;BR /&gt; fi&lt;BR /&gt;done  &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Olav&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Mar 2002 20:50:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686140#M723313</guid>
      <dc:creator>Olav Baadsvik</dc:creator>
      <dc:date>2002-03-19T20:50:29Z</dc:date>
    </item>
    <item>
      <title>Re: linking problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686141#M723314</link>
      <description>l1:/usr/lib 103 &amp;gt; grep eprintf defs.nm &lt;BR /&gt;t 0x000BB5B8 ./libdce.sl:rpc__svc_eprintf&lt;BR /&gt;l1:/usr/lib 104 &amp;gt; &lt;BR /&gt;&lt;BR /&gt;the defs.nm, which lists the symbols that are *defined* in any module, is created - alongside libs.nm, which contains a list of *all* symbols, and libs.ar, which contains an object listing - by the attached perl script. I should run it after every system upgrade, either patches or applications, but I tend to forget, so maybe the umoddi3 is int there already.</description>
      <pubDate>Tue, 19 Mar 2002 20:57:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/linking-problem/m-p/2686141#M723314</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2002-03-19T20:57:18Z</dc:date>
    </item>
  </channel>
</rss>

