<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Hi,<br>
      <br>
      I commited a new version of 'cyipot' where I cleaned the setup.py
      file. I have tested it on a similar ubuntu platform. To test it
      yourself, you need to clone the latest version from: <br>
      <a class="moz-txt-link-freetext" href="https://bitbucket.org/amitibo/cyipopt/">https://bitbucket.org/amitibo/cyipopt/</a> (I am yet to update the
      download file). Note that you will need to install ipopt system
      wide (for example in /usr/local) or else the python setup.py
      script will not find its package configuration file.<br>
      <br>
      Best,<br>
      Amit<br>
      <br>
      On 21/11/2014 17:52, Vyacheslav Kungurtsev wrote:<br>
    </div>
    <blockquote
cite="mid:CADVHvvOnik5CMWu8hp==O3dekU752fnczAzAB81Y4uarL0_V_g@mail.gmail.com"
      type="cite">
      <meta http-equiv="Content-Type" content="text/html;
        charset=ISO-8859-1">
      <div dir="ltr">
        <div>
          <div>OK. I tried this, but the error from pyipopt remains.<br>
            <br>
          </div>
          Thanks<br>
        </div>
        ~Vyacheslav<br>
      </div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Fri, Nov 21, 2014 at 4:44 PM, Tony
          Kelman <span dir="ltr">&lt;<a moz-do-not-send="true"
              href="mailto:kelman@berkeley.edu" target="_blank">kelman@berkeley.edu</a>&gt;</span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div dir="ltr">
              <div dir="ltr">
                <div
                  style="FONT-SIZE:12pt;FONT-FAMILY:'Calibri';COLOR:#000000">
                  <div>I don&#8217;t know the Python interfaces to Ipopt very
                    well. One thing you might try is configuring Ipopt
                    with --enable-dependency-linking, I think that can
                    be necessary to dlopen Ipopt shared libraries
                    including their dependencies from Python or Julia or
                    other languages. You won&#8217;t have dll&#8217;s on Ubuntu,
                    you&#8217;ll have .so shared libraries.</div>
                  <div>&nbsp;</div>
                  <div>-Tony</div>
                  <div>&nbsp;</div>
                  <div
style="FONT-SIZE:small;TEXT-DECORATION:none;FONT-FAMILY:&quot;Calibri&quot;;FONT-WEIGHT:normal;COLOR:#000000;FONT-STYLE:normal;DISPLAY:inline">
                    <div style="FONT:10pt tahoma">
                      <div>&nbsp;</div>
                      <div style="BACKGROUND:#f5f5f5">
                        <div><b>From:</b> <a moz-do-not-send="true"
                            title="vyacheslav.kungurtsev@esat.kuleuven.be"
href="mailto:vyacheslav.kungurtsev@esat.kuleuven.be" target="_blank">Vyacheslav
                            Kungurtsev</a> </div>
                        <div><b>Sent:</b> Friday, November 21, 2014 7:32
                          AM</div>
                        <div><b>To:</b> <a moz-do-not-send="true"
                            title="kelman@berkeley.edu"
                            href="mailto:kelman@berkeley.edu"
                            target="_blank">Tony Kelman</a> </div>
                        <div><b>Cc:</b> <a moz-do-not-send="true"
                            title="ipopt@list.coin-or.org"
                            href="mailto:ipopt@list.coin-or.org"
                            target="_blank">ipopt@list.coin-or.org</a> </div>
                        <div><b>Subject:</b> ipopt with python</div>
                      </div>
                    </div>
                    <div>&nbsp;</div>
                  </div>
                  <div>
                    <div class="h5">
                      <div
style="FONT-SIZE:small;TEXT-DECORATION:none;FONT-FAMILY:&quot;Calibri&quot;;FONT-WEIGHT:normal;COLOR:#000000;FONT-STYLE:normal;DISPLAY:inline">
                        <div dir="ltr">
                          <div>
                            <div>Hello,<br>
                              <br>
                            </div>
                            <div>Somehow after the weekend I tried again
                              and ipopt installed just fine and the
                              examples ran OK. I have no idea what
                              happened.<br>
                              <br>
                              <br>
                              <br>
                            </div>
                            <div>Now I am trying to run ipopt with
                              python, and having trouble with both
                              pyipopt and cyipopt<br>
                              <br>
                              With pyipopt:<br>
                              <br>
                              <br>
                              the error appears as:<br>
                              <br>
                              ~/pyipopt/examples$ python hs071.py<br>
                              Traceback (most recent call last):<br>
                              &nbsp; File "hs071.py", line 6, in
                              &lt;module&gt;<br>
                              &nbsp;&nbsp;&nbsp; import pyipopt<br>
                              &nbsp; File "/usr/local/lib/python2.7/
                              <div>dist-packages/pyipopt/__init__.py",
                                line 16, in &lt;module&gt;<br>
                                &nbsp;&nbsp;&nbsp; from pyipoptcore import *<br>
                                ImportError:
                                /usr/local/lib/python2.7/dist-packages/pyipopt/pyipoptcore.so:
                                undefined symbol:
                                _ZTVN10__cxxabiv117__class_type_infoE<br>
                                <br>
                                <br>
                              </div>
                              Indeed, it so happens that:<br>
                              <br>
                              $ nm /usr/local/lib/python2.7/dist-
                              <div>packages/pyipopt/pyipoptcore.so |
                                grep
                                _ZTVN10__cxxabiv117__class_type_infoE<br>
                                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; U
                                _ZTVN10__cxxabiv117__class_type_infoE<br>
                                <br>
                                <br>
                              </div>
                              the symbol arises from libstdc++ and I
                              have tried adding it to setup.py as such:<br>
                              &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; extra_link_args=['-libstdc++']
                              <div>, <br>
                                <br>
                              </div>
                              or<br>
                              <br>
                              &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; extra_link_args=['-libstdc++', +
                              IPOPT_LIB], <br>
                              <br>
                              or<br>
                              <br>
                              &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; libraries=[ <br>
                              ...<br>
                              &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 'coinmetis','libstdc++',<br>
                              <div>...<br>
                                <br>
                              </div>
                              <div>and in all cases setup.py installs
                                with no error, but the import error
                                remains when I try to run the example. <br>
                                <br>
                              </div>
                              Do you have any suggestions? Am I linking
                              it improperly in the setup file?<br>
                              <br>
                            </div>
                            <div>&nbsp;</div>
                            <div>&nbsp;</div>
                            <div>With cyipopt the setup.py requires:<br>
                              these<br>
                              &nbsp;&nbsp;&nbsp; IPOPT_ICLUDE_DIRS=['include_mt/coin',
                              np.get_include()]<br>
                              &nbsp;&nbsp;&nbsp; IPOPT_LIBS=['Ipopt39', 'IpoptFSS']<br>
                              &nbsp;&nbsp;&nbsp; IPOPT_LIB_DIRS=['lib_mt/x64/release']<br>
                              &nbsp;&nbsp;&nbsp; IPOPT_DLL=['Ipopt39.dll',
                              'IpoptFSS39.dll']<br>
                            </div>
                            <div>to be set correctly. I am not quite
                              sure how to find the proper directories.
                              Would I even have dll files given that I
                              am running ubuntu?<br>
                              <br>
                            </div>
                            <div>Sorry if the question is rather basic.
                              <br>
                            </div>
                            <div><br>
                              <br>
                              some info about my computer, if it helps:<br>
                            </div>
                            Ubuntu 14.04<br>
                            gcc (Ubuntu 4.8.2-19ubuntu1) 4.8.2<br>
                            g++ (Ubuntu 4.8.2-19ubuntu1) 4.8.2<br>
                            <br>
                            <br>
                            <br>
                            <br>
                          </div>
                          <div>Thank you<br>
                            <br>
                          </div>
                          <div class="gmail_extra">
                            <div>&nbsp;</div>
                          </div>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Ipopt mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Ipopt@list.coin-or.org">Ipopt@list.coin-or.org</a>
<a class="moz-txt-link-freetext" href="http://list.coin-or.org/mailman/listinfo/ipopt">http://list.coin-or.org/mailman/listinfo/ipopt</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>