[Cbc] Building CBC statically

Jeffrey Milloy jeffrey.a.milloy at gmail.com
Thu Nov 13 14:07:29 EST 2014


In fact, not only does it look like cbc is still loading shared libraries,
it looks like it is still loading them from the src
(/usr/local/src/CoinMP), rather than the installation location (/opt/cbc)

$ ldd /opt/cbc/bin/cbc

linux-vdso.so.1 =>  (0x00007fff2beb0000)

libCgl.so.0 => /usr/local/src/CoinMP/Cgl/src/.libs/libCgl.so.0
(0x00007fb4de838000)

libOsiClp.so.0 => /usr/local/src/CoinMP/Clp/src/OsiClp/.libs/libOsiClp.so.0
(0x00007fb4de5f0000)

libClp.so.0 => /usr/local/src/CoinMP/Clp/src/.libs/libClp.so.0
(0x00007fb4de250000)

libOsi.so.0 => /usr/local/src/CoinMP/Osi/src/Osi/.libs/libOsi.so.0
(0x00007fb4ddff8000)

libCoinUtils.so.0 =>
/usr/local/src/CoinMP/CoinUtils/src/.libs/libCoinUtils.so.0
(0x00007fb4ddcc0000)

libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6
(0x00007fb4dd9a8000)

libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fb4dd6a0000)

libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fb4dd488000)

libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fb4dd0c0000)

/lib64/ld-linux-x86-64.so.2 (0x00007fb4deb50000)

On Thu, Nov 13, 2014 at 1:53 PM, Jeffrey Milloy <jeffrey.a.milloy at gmail.com>
wrote:

> I just tried that, still no success.
>
> I built all of coin-or:
>
> ./configure --enable-static --disable-shared --prefix=/opt/coin-or
> make
> make test
> sudo make install
>
> The cbc binary is 1.7M, so it seems like it should work. It works on the
> machine I built on, but I copied the binary to my EC2 instance and got the
> missing shared library (libCgl) message again.
>
> On Thu, Nov 13, 2014 at 1:48 PM, Ted Ralphs <ted at lehigh.edu> wrote:
>
>> Try also doing --disable-shared. I think that should get rid of the
>> dependence on the COIN libraries.
>>
>> Cheers,
>>
>> Ted
>>
>> On Thu, Nov 13, 2014 at 10:14 AM, Jeffrey Milloy <
>> jeffrey.a.milloy at gmail.com> wrote:
>>
>>> Hello
>>>
>>> I am trying to run CBC through AWS EMR. I think I need to build CBC
>>> statically so that I can put a standalone binary onto S3 storage. Is it
>>> possible?
>>>
>>> I tried with ./configure --enable-static but the cbc resulting cbc
>>> binary still tried to load the shared library libCgl.so.0.
>>>
>>> Jeff
>>>
>>> _______________________________________________
>>> Cbc mailing list
>>> Cbc at list.coin-or.org
>>> http://list.coin-or.org/mailman/listinfo/cbc
>>>
>>>
>>
>>
>> --
>> Dr. Ted Ralphs
>> Professor, Lehigh University
>> (610) 628-1280
>> ted 'at' lehigh 'dot' edu
>> coral.ie.lehigh.edu/~ted
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/cbc/attachments/20141113/437af73f/attachment-0001.html>


More information about the Cbc mailing list