[Bro] RPM package creation results in unlinked libraries when installed

bkeep bkeep at alias454studios.com
Thu Jul 12 18:57:20 PDT 2018


Thanks for the reply, that got me going the right direction I think, at 
least it works now. I created a file in /etc/ld.so.conf.d/ named 
bro-x86_64.conf with the path to /opt/bro/lib and ran ldconfig, which 
got everything working.

I notice there are pre/post install scripts in the build directory. Is 
this the right place to add commands to be executed during the 
deployment? Is there a different file that won't get mangled if the repo 
gets updated or should I just beware and copy changes back in every time 
I need to do a new build from source?

Regards,
Brandon


On 07/12/2018 09:06 AM, Jon Siwek wrote:
> On Thu, Jul 12, 2018 at 6:35 AM bkeep <bkeep at alias454studios.com> wrote:
>
>> The [root at bro00 ~]# ldd /opt/bro/bin/bro |grep libbroker
>>       libbroker.so.0 => not found
> Generally seems like you'll want to to teach ld to search inside the
> non-standard /opt/bro/lib/ path.
>
> e.g. look more into how to change /etc/ld.so.conf or
> /etc/ld.so.conf.d/ and running `ldconfig`.
>
> Or if you just wanted to restrict the search behavior to a shell and
> not the entire system, the LD_LIBRARY_PATH environment variable will
> do that.
>
>> Compiling BRO from source but leaving off the --binary-package flags
>> resulted in a working install on the build machine as well using make &&
>> make install. I am not sure what piece I am missing here so any advice
>> would be appreciated.
> One of the things the --binary-package flag does is prevent the use of
> RPATHs in the final binary.  Normally, an RPATH is like hard-coding
> the path to a shared library.  The thought behind disabling RPATHs
> when using the --binary-package is that it's generally more flexible
> to allow the linker to dynamically find it (e.g. via the configuration
> mentioned above), and I may recall that various Linux distros tend to
> frown upon using RPATHs in their packaging ecosystems anyway (so
> serves as good example to follow along).
>
> - Jon



More information about the Bro mailing list