<?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: error: 'rexec' was not declared in this scope in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842553#M638726</link>
    <description />
    <pubDate>Tue, 23 Oct 2012 21:14:45 GMT</pubDate>
    <dc:creator>Steven Schweda</dc:creator>
    <dc:date>2012-10-23T21:14:45Z</dc:date>
    <item>
      <title>error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841323#M638718</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Simple program:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;#include &amp;lt;sys/types.h&amp;gt;
#include &amp;lt;sys/socket.h&amp;gt;
#include &amp;lt;sys/ioctl.h&amp;gt;
#include &amp;lt;netinet/in.h&amp;gt;
#include &amp;lt;netdb.h&amp;gt;

int main(int argc, char **argv)
{
    int ret = rexec((char**) 0, "", "", "", 0);

    return 0;
}&lt;/PRE&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN&gt;g++ -o rexec -D_XOPEN_SOURCE_EXTENDED rexec.cpp&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;rexec.cpp: In function 'int main(int, char**)':
rexec.cpp:10:49: error: 'rexec' was not declared in this scope&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ref:&amp;nbsp;&lt;A target="_blank" href="http://stackoverflow.com/questions/12955644/rexec-not-found-in-hp-ux"&gt;http://stackoverflow.com/questions/12955644/rexec-not-found-in-hp-ux&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;where is 'rexec' ?&lt;/P&gt;</description>
      <pubDate>Mon, 22 Oct 2012 20:49:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841323#M638718</guid>
      <dc:creator>chilabot</dc:creator>
      <dc:date>2012-10-22T20:49:33Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841421#M638719</link>
      <description>&lt;P&gt;&amp;gt;where is rexec ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's in &amp;lt;sys/socket.h&amp;gt; but you can't compile with &lt;SPAN&gt;&lt;SPAN&gt;-D_XOPEN_SOURCE_EXTENDED since rexec(3) isn't in that namespace.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN&gt;And you have the wrong number/type of parms.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Oct 2012 23:04:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841421#M638719</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2012-10-22T23:04:05Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841423#M638720</link>
      <description />
      <pubDate>Mon, 22 Oct 2012 23:01:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5841423#M638720</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2012-10-22T23:01:53Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842181#M638721</link>
      <description>&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[gimenero@rx8km ~]$ uname -a &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;HP-UX rx8km B.11.31 U ia64 2229485251 unlimited-user license &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[gimenero@rx8km ~]$ g++ -v &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Using built-in specs. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;COLLECT_GCC=g++ &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;COLLECT_LTO_WRAPPER=/opt/hp-gcc-4.7.0/libexec/gcc/ia64-hp-hpux11.23/4.7.0/lto-wrapper &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Target: ia64-hp-hpux11.23 &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Configured with: /tmp/gcc-4.7.0.tar.gz/gcc-4.7.0/configure --host=ia64-hp-hpux11.23 --target=ia64-hp-hpux11.23 --build=ia64-hp-hpux11.23 --prefix=/opt/hp-gcc-4.7.0 --with-gnu-as --without-gnu-ld --enable-threads=posix --enable-languages=c,c++ --with-gmp=/proj/opensrc/be/ia64-hp-hpux11.23 --with-mpfr=/proj/opensrc/be/ia64-hp-hpux11.23 &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;SED=/usr/bin/sed &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Thread model: posix &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;gcc version 4.7.0 (GCC)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;i'm compiling with -D_XOPEN_SOURCE_EXTENDED because that compiles most of my ported code (from solaris). What flag should I use so the code can be portable between linux, solaris and hp-ux?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Oct 2012 13:26:10 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842181#M638721</guid>
      <dc:creator>chilabot</dc:creator>
      <dc:date>2012-10-23T13:26:10Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842199#M638722</link>
      <description />
      <pubDate>Tue, 23 Oct 2012 13:40:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842199#M638722</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2012-10-23T13:40:53Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842241#M638723</link>
      <description>&lt;P&gt;the problem is that with _XOPEN_SOURCE_EXTENDED i can compile all my code but this, is there a flag that i can add so 'rexec' whould appear? i mostly use the boost libraries so i save a lot of portability issues with it.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Oct 2012 14:11:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842241#M638723</guid>
      <dc:creator>chilabot</dc:creator>
      <dc:date>2012-10-23T14:11:54Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842279#M638724</link>
      <description />
      <pubDate>Tue, 23 Oct 2012 14:35:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842279#M638724</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2012-10-23T14:35:50Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842503#M638725</link>
      <description>&lt;P&gt;i've just declared it myself:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;int rexec (char **, int, const char *,&lt;/FONT&gt;&amp;nbsp;&lt;FONT face="courier new,courier"&gt;const char *, const char *, int *);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in that particular program, it compiles, but in another bigger one, the symbol is missing:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;ld: Unsatisfied symbol "rexec(char**, int, char const*, char const*, char const*, int*)" in file ...&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;do you know in which library is 'rexec' ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Oct 2012 19:41:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842503#M638725</guid>
      <dc:creator>chilabot</dc:creator>
      <dc:date>2012-10-23T19:41:33Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842553#M638726</link>
      <description />
      <pubDate>Tue, 23 Oct 2012 21:14:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842553#M638726</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2012-10-23T21:14:45Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842561#M638727</link>
      <description>&lt;P&gt;&amp;gt;I'm compiling with -D_XOPEN_SOURCE_EXTENDED because that compiles most of my ported code (from solaris).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does the default -D_HPUX_SOURCE compile everything?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;but "#ifndef _XOPEN_SOURCE_EXTENDED" looks to me to be rather rigid.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Right, rexec isn't part of that namespace.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;do you know in which library is 'rexec' ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;libc.so.1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;&lt;FONT face="courier new,courier"&gt;ld: Unsatisfied symbol "rexec(char**, int, char const*, char const*, char const*, int*)" in file ...&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As Steven said, you forgot to C++ify your source with extern "C".&amp;nbsp; You have an unsat with a mangled name.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Oct 2012 21:27:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5842561#M638727</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2012-10-23T21:27:17Z</dc:date>
    </item>
    <item>
      <title>Re: error: 'rexec' was not declared in this scope</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5843687#M638728</link>
      <description>&lt;P&gt;you're right, I forgot to extern "C" it. Now it compiles. Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 24 Oct 2012 19:25:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/error-rexec-was-not-declared-in-this-scope/m-p/5843687#M638728</guid>
      <dc:creator>chilabot</dc:creator>
      <dc:date>2012-10-24T19:25:28Z</dc:date>
    </item>
  </channel>
</rss>

