discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] OOT adding c++ library


From: Martin Braun
Subject: Re: [Discuss-gnuradio] OOT adding c++ library
Date: Sun, 5 Mar 2017 21:42:20 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0

Santos,

this depends on a lot of things. Here's an example:
https://github.com/stwunsch/gr-nacl/blob/d6dd3c02dcda3f601979908b61b1595476f6bf95/CMakeLists.txt#L144-L152

gr-nacl uses libsodium as an external dependency. You can see all the
variables that contain SODIUM; they are in fact generated by this line:

https://github.com/stwunsch/gr-nacl/blob/d6dd3c02dcda3f601979908b61b1595476f6bf95/CMakeLists.txt#L111

...typically, that's a workflow you want. If your dependency doesn't
have a way to be picked up by CMake, you can point to the library files
directly.

-- M

On 03/03/2017 03:05 PM, Santos Campos wrote:
> Hello, all!
> 
> I'm trying to include a c++ library for an oot. It builds fine with
> using make, but trying to use it in grc throws an AttributeError. 
> 
> Someone over on the irc said that I needed to modify the cmakelists.txt
> by locating the library, add the headers to the include search path, and
> add the shared library file to the linking step. Could someone help me
> understand the syntax of what's going on in the cmakelists.txt?
> 
> For example I see some lines that sound like what I need, like:
> include_directories(${Boost_INCLUDE_DIR})
> link_directories(${Boost_LIBRARY_DIRS})
> ...
> add_library(gnuradio-"OOT Name" SHARED ${"OOT Name"_sources})
> 
> The arguments look like variables for paths, but I don't understand
> how/where they're defined or how I can make my own for the c++ library I
> want to use.
> 
> Any help or push in the right direction would be much appreciated!
> -Santos
> 
> 
> _______________________________________________
> Discuss-gnuradio mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]