[CMake] Incorporating cmake dir into configure.ac, but it depends on a autconf-managed in-tree library
Alexander Neundorf
a.neundorf-work at gmx.net
Wed Feb 17 16:04:24 EST 2016
On Thursday, February 11, 2016 13:11:29 Ron wrote:
> Hi,
>
> I am working on a project that requires libevent and libevhtp.
> The latter is cmake managed, my project and libevent are autoconf managed.
>
> (Note that libevhtp depends on libevent, both depend on openssl, which I
> rely
> on the system to provide.)
>
> The problem is that I run cmake during the configure step, but during that
> time libevent has not been built yet, so libevhtp complains about not
> finding
> the libevent library.
>
> I have to use in-tree libevent and libevhtp due to features I need, and
> libevhtp
> not being distributed by the linux distro I use.
>
> What is the best way to approach this?
you should have a look how libevhtp searches for libevent.
If it does a bunch of find_library()/find_path() calls, those set cmake cacge
variables, but only if they are not set yet.
So if you know where libevent will put its stuff, you can preset those cmake
cache variables (e.g. using cmake -D ...)
Alex
More information about the CMake
mailing list