<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Hi,<br>Thanks for the hint. I have already compiled the code but still have problems when run. I compiled using: <br><br><font style="" face="Times New Roman,sans-serif">g++ -g -Wall hs071_nlp.cpp mio.cpp -o mio -I/home/max/CoinIpopt/build/include/coin -L/home/max/CoinIpopt/build/lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8 -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../lib -L/lib/../lib -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../.. -L/usr/local/lib -lipopt -llapack -ldl -lcoinmumps -lblas -lgfortran -lm -lquadmath -lcoinhsl -lcoinmetis </font><font style="" face="Times New Roman,sans-serif"><br></font><br>But when do the run I get this error<br><br><font style="" face="Times New Roman,sans-serif">max@max-Satellite-C845:~/workspace/Prueba/src$ ./mio</font><font style="" face="Times New Roman,sans-serif"><br></font><font style="" face="Times New Roman,sans-serif">./mio: error while loading shared libraries: libipopt.so.0: cannot open shared object file: No such file or directory</font><br><br>I don't know why this error because libipopt.so.0 is located in the include path /home/max/CoinIpopt/build/lib. Any idea what's wrong?<br>Thanks in advance<br><br>Max<br><br><br><br><div>&gt; Subject: Re: [Ipopt] Help: build hs071_cpp example<br>&gt; To: max-leo-19@hotmail.com; gregmainland@gmail.com; ipopt@list.coin-or.org<br>&gt; From: stefan@math.hu-berlin.de<br>&gt; Date: Thu, 9 Jul 2015 16:36:49 +0200<br>&gt; <br>&gt; Hi,<br>&gt; <br>&gt; try with an additional -I/home/max/CoinIpopt/build/include/coin  when <br>&gt; you compile the source.<br>&gt; <br>&gt; Stefan<br>&gt; <br>&gt; On 07/09/2015 08:27 AM, max leo correa cordova wrote:<br>&gt; &gt; Hi,<br>&gt; &gt; sorry for the lack of infomation. well I have installed Ipopt following the installation instruction. I made the 'make', 'make check' and 'make install'. Then try the hs071_cpp example using the 'Makefile' created duing the installation and all worked fine, the problem was solved. But I want to use Ipopt with other libreries like 'openmi' and so I first tried to build the example program from the terminal of linux. I have read the 'ipopt_add_libs.txt' file:<br>&gt; &gt;<br>&gt; &gt; -L/home/max/CoinIpopt/build/lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8<br>&gt; &gt; -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu<br>&gt; &gt; -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../lib -L/lib/../lib<br>&gt; &gt; -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../..<br>&gt; &gt; -L/usr/local/lib -lipopt -llapack -ldl -lcoinmumps -lblas -lgfortran -lm<br>&gt; &gt;   -lquadmath -lcoinhsl -lcoinmetis<br>&gt; &gt;<br>&gt; &gt; and well i create a new folder and the hs071_nlp.hpp, hs071_nlp.cpp, and mio.cpp (main) in ~/workspace/Prueba/ and made the following comand (i am not sure if it is ok):<br>&gt; &gt;<br>&gt; &gt; max@max-Satellite-C845:~/workspace/Prueba$ g++ -g -Wall hs071_nlp.cpp<br>&gt; &gt; mio.cpp -o mio -L/home/max/CoinIpopt/build/lib<br>&gt; &gt; -L/usr/lib/gcc/x86_64-linux-gnu/4.8<br>&gt; &gt; -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu<br>&gt; &gt; -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../lib -L/lib/../lib<br>&gt; &gt; -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../..<br>&gt; &gt; -L/usr/local/lib -lipopt -llapack -ldl -lcoinmumps -lblas -lgfortran -lm<br>&gt; &gt;   -lquadmath -lcoinhsl -lcoinmetis<br>&gt; &gt;<br>&gt; &gt; but i get the error:<br>&gt; &gt;<br>&gt; &gt; In file included from hs071_nlp.cpp:9:0:<br>&gt; &gt; hs071_nlp.hpp:12:22: fatal error: IpTNLP.hpp: No such file or directory<br>&gt; &gt;   #include "IpTNLP.hpp"<br>&gt; &gt;                        ^<br>&gt; &gt; compilation terminated.<br>&gt; &gt; mio.cpp:2:34: fatal error: IpIpoptApplication.hpp: No such file or directory<br>&gt; &gt;   #include "IpIpoptApplication.hpp"<br>&gt; &gt;                                    ^<br>&gt; &gt; compilation terminated.<br>&gt; &gt;<br>&gt; &gt; I was stack here. Please could you give me any hint? I would be so grateful.<br>&gt; &gt;<br>&gt; &gt; Max<br>&gt; &gt;<br>&gt; &gt;&gt; Subject: Re: [Ipopt] Help: build hs071_cpp example<br>&gt; &gt;&gt; To: max-leo-19@hotmail.com; gregmainland@gmail.com; ipopt@list.coin-or.org<br>&gt; &gt;&gt; From: stefan@math.hu-berlin.de<br>&gt; &gt;&gt; Date: Thu, 9 Jul 2015 00:03:48 +0200<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; Hi,<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; did you do a make install in Ipopt before this?<br>&gt; &gt;&gt; If so, include more information than "it doesn't work".<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; Stefan<br>&gt; &gt;&gt;<br>&gt; &gt;<br>&gt; &gt;                                               <br>&gt; &gt;<br>&gt; <br></div>                                               </div></body>
</html>