<?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: ld: Unsatisfied symbol &amp;quot;getopt_long&amp;quot; in file in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980389#M495589</link>
    <description>&lt;P&gt;&amp;gt; [...] I have tried multiple things [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; That's not very informative.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; I know nothing, but isn't getopt_long() a GNU libc feature?&lt;BR /&gt;Presumably, one could extract some getopt_long()-containing C source&lt;BR /&gt;code from the glibc source collection, rather than trying to build/find&lt;BR /&gt;the whole thing.&lt;/P&gt;</description>
    <pubDate>Tue, 17 Oct 2017 15:16:26 GMT</pubDate>
    <dc:creator>Steven Schweda</dc:creator>
    <dc:date>2017-10-17T15:16:26Z</dc:date>
    <item>
      <title>ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980380#M495588</link>
      <description>&lt;P&gt;I am compling from source code. I am getting the below error. I have tried multiple things but nothing has worked.&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;ld: Unsatisfied symbol "getopt_long" in file ./.libs/liboathtool_cmd.a[liboathtool_cmd_la-oathtool_cmd.o]&lt;BR /&gt;1 error.&lt;BR /&gt;collect2: ld returned 1 exit status&lt;BR /&gt;*** Error exit code 1&lt;/P&gt;&lt;P&gt;Stop.&lt;BR /&gt;*** Error exit code 1&lt;/P&gt;&lt;P&gt;Stop.&lt;BR /&gt;*** Error exit code 1&lt;/P&gt;&lt;P&gt;Stop.&lt;BR /&gt;*** Error exit code 1&lt;/P&gt;&lt;P&gt;Stop.&lt;BR /&gt;*** Error exit code 1&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Oct 2017 13:45:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980380#M495588</guid>
      <dc:creator>badversion</dc:creator>
      <dc:date>2017-10-17T13:45:21Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980389#M495589</link>
      <description>&lt;P&gt;&amp;gt; [...] I have tried multiple things [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; That's not very informative.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; I know nothing, but isn't getopt_long() a GNU libc feature?&lt;BR /&gt;Presumably, one could extract some getopt_long()-containing C source&lt;BR /&gt;code from the glibc source collection, rather than trying to build/find&lt;BR /&gt;the whole thing.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Oct 2017 15:16:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980389#M495589</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2017-10-17T15:16:26Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980402#M495590</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.hpe.com/t5/user/viewprofilepage/user-id/586411"&gt;@Steven Schweda&lt;/a&gt; wrote:&lt;BR /&gt;&lt;P&gt;&amp;gt; [...] I have tried multiple things [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; That's not very informative.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; I know nothing, but isn't getopt_long() a GNU libc feature?&lt;BR /&gt;Presumably, one could extract some getopt_long()-containing C source&lt;BR /&gt;code from the glibc source collection, rather than trying to build/find&lt;BR /&gt;the whole thing.&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I am sorry for the useless information I gave. I'll Describe my problem in Breif.&lt;/P&gt;&lt;P&gt;I am trying to compile&amp;nbsp;&lt;STRONG&gt;oathtool&lt;/STRONG&gt; from source code in HP-UX 11.31. While Compling I am getting the error&amp;nbsp;&lt;STRONG&gt;ld: Unsatisfied symbol "getopt_long" in file.&amp;nbsp;&lt;/STRONG&gt;I am &lt;STRONG&gt;not&lt;/STRONG&gt; trying to compile &lt;STRONG&gt;getopt_long.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Things to note -&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I manually copy pasted the getopt.h from the web. As I couldn't find it in the HP-UX machine and had put it in the lib directory.&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Things I tried -&lt;/P&gt;&lt;P&gt;Tried Hashing it out in the Makefile.&lt;/P&gt;&lt;P&gt;tried manually running it with aCC&lt;/P&gt;&lt;P&gt;aclocal autoheader autoconf autoreconf and none worked till now.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Oct 2017 15:41:20 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980402#M495590</guid>
      <dc:creator>badversion</dc:creator>
      <dc:date>2017-10-17T15:41:20Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980414#M495591</link>
      <description>&lt;P&gt;&amp;gt; [...] I am not trying to compile getopt_long.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; You may need to.&amp;nbsp; If it's not in the HP-UX C RTL, and you don't have&lt;BR /&gt;the GNU C RTL, then compiling the source seems to me like the thing to&lt;BR /&gt;do.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; I manually copy pasted the getopt.h from the web.&amp;nbsp; [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; That's a start.&amp;nbsp; Keep going.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; [...] had put it in the lib directory.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; I'd keep it separate from the standard HP-UX files.&amp;nbsp; That may force&lt;BR /&gt;you to play with your compile (-I) and/or link (-L,-l) options, but I&lt;BR /&gt;wouldn't mess with the standard files.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Things I tried -&lt;BR /&gt;&amp;gt; [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; If the code wants getopt_long(), then you need to change the code, or&lt;BR /&gt;else give it a getopt_long().&amp;nbsp; On a GNU/Linux system, you'd have the GNU&lt;BR /&gt;C RTL (glibc), which should include it.&amp;nbsp; On HP-UX, if it's not already&lt;BR /&gt;there, then you need to get it.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Oct 2017 18:45:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980414#M495591</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2017-10-17T18:45:09Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980448#M495592</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.hpe.com/t5/user/viewprofilepage/user-id/586411"&gt;@Steven Schweda&lt;/a&gt; wrote:&lt;BR /&gt;&lt;P&gt;&amp;gt; [...] I am not trying to compile getopt_long.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; You may need to.&amp;nbsp; If it's not in the HP-UX C RTL, and you don't have&lt;BR /&gt;the GNU C RTL, then compiling the source seems to me like the thing to&lt;BR /&gt;do.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; I manually copy pasted the getopt.h from the web.&amp;nbsp; [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; That's a start.&amp;nbsp; Keep going.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; [...] had put it in the lib directory.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; I'd keep it separate from the standard HP-UX files.&amp;nbsp; That may force&lt;BR /&gt;you to play with your compile (-I) and/or link (-L,-l) options, but I&lt;BR /&gt;wouldn't mess with the standard files.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Things I tried -&lt;BR /&gt;&amp;gt; [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; If the code wants getopt_long(), then you need to change the code, or&lt;BR /&gt;else give it a getopt_long().&amp;nbsp; On a GNU/Linux system, you'd have the GNU&lt;BR /&gt;C RTL (glibc), which should include it.&amp;nbsp; On HP-UX, if it's not already&lt;BR /&gt;there, then you need to get it.&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I am not a developer. I just downloaded the source code from the website and compiled the code. It would be helpful if you could help elobrate on the solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Edit - So, I did do a little digging and found that the Makefile was excuting the below command&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;./libtool --silent --tag=CC --mode=link gcc -std=gnu99&amp;nbsp; -g -O2 -o oathtool oathtool.o gl/libgnu.la liboathtool_cmd.la&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;and throwing the exact below error while make-"ing".&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;libtool: link: gcc -std=gnu99 -g -O2 -o .libs/oathtool oathtool.o -L../liboath/.libs -loath gl/.libs/libgnu.a ./.libs/liboathtool_cmd.a -Wl,+b -Wl,/usr/local/lib&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;ld: Unsatisfied symbol "getopt_long" in file ./.libs/liboathtool_cmd.a[liboathtool_cmd_la-oathtool_cmd.o]&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;1 error.&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;collect2: ld returned 1 exit status&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Oct 2017 12:05:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980448#M495592</guid>
      <dc:creator>badversion</dc:creator>
      <dc:date>2017-10-18T12:05:00Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long" in file</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980504#M495593</link>
      <description>&lt;P&gt;&amp;gt; I am not a developer.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Find one?&amp;nbsp; Become one?&lt;BR /&gt;&lt;BR /&gt;&amp;gt;&amp;nbsp; I just downloaded the source code from the website and compiled the&lt;BR /&gt;&amp;gt; code.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Complain to the people who provide this package?&lt;BR /&gt;&lt;BR /&gt;&amp;gt; It would be helpful if you could help elobrate on the solution.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; There's not much to elaborate.&amp;nbsp; The program uses getopt_long().&amp;nbsp; If&lt;BR /&gt;that's not provided in the HP-UX run-time libraries, then you would need&lt;BR /&gt;to provide it yourself.&amp;nbsp; You found getopt.h.&amp;nbsp; I'd guess that something.c&lt;BR /&gt;with getopt_long() in it shouldn't be far away.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Assuming that "the website" is &lt;A href="http://www.nongnu.org/oath-toolkit/" target="_blank"&gt;http://www.nongnu.org/oath-toolkit/&lt;/A&gt; ,&lt;BR /&gt;I didn't notice anything there about operating systems where the program&lt;BR /&gt;is expected to run, so they may assume that if GNU/Linux has it, then&lt;BR /&gt;everyone else must have it, too.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Edit - So, I did do a little digging [...]&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Yes, that's where it would happen.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Oct 2017 17:47:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980504#M495593</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2017-10-18T17:47:32Z</dc:date>
    </item>
    <item>
      <title>Re: ld: Unsatisfied symbol "getopt_long", missing Linux feature</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980787#M495594</link>
      <description>&lt;P&gt;&amp;gt; isn't getopt_long() a GNU libc feature?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes.&amp;nbsp; It would have to be ported.&amp;nbsp; Or converted to use getopt(3).&lt;/P&gt;</description>
      <pubDate>Mon, 23 Oct 2017 10:18:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ld-unsatisfied-symbol-quot-getopt-long-quot-in-file/m-p/6980787#M495594</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2017-10-23T10:18:13Z</dc:date>
    </item>
  </channel>
</rss>

