discuss-gnuradio
[Top][All Lists]
Advanced

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

Re: [Discuss-gnuradio] Testers needed: Updated CMake syntax


From: Volker Schroer
Subject: Re: [Discuss-gnuradio] Testers needed: Updated CMake syntax
Date: Thu, 14 Feb 2019 17:44:26 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0

Hi,
I tried [1] on Ubuntu 18.10 and it build without problems.
Starting to build some of mine OOT's I found, that FindUSB.cmake is missing. I think this was used to build gr-fcd which is not part of gnuradio 3.8.
But that's no problem.
Will the new cmake be part of gnuradio-3.8 ?

I'll keep on testing some more OOT's

-- Volker


Hi all,

in the last weeks I have been pursuing the quest of reworking the
current CMake build tooling in GNU Radio to use "modern CMake" syntax.
This work has mainly completed and now is the time to fix bugs you
encounter.

The work on the updated CMake can be found here
[0]/[1] and should compile just fine using the cmake & make/ninja
commands you are used to.
Support for static libraries might be still broken, but static linking
can be enabled using `-DBUILD_SHARED_LIBS=OFF` on the command line. No
shared library will be built using that flag.

Linking Out-of-Tree modules should be way easier using the new syntax
(but still old modules have to be updated). Mainly the `find_package`
call now follows the convention of specifying components in the
function call e.g. `find_package(Gnuradio COMPONENTS fft audio)`. After
the correct components are specified on in the `find_package` call the
corresponding build targets are available in your CMake project.  e.g.
you can `target_link_libraries(foo gnuradio::gnuradio-fft)`. Several
core build targets are always available (gnuradio::gnuradio-runtime,
gnuradio::gnuradio-pmt).

Instead of linking to all GNU Radio libraries in the
`target_link_libraries` call in `lib/CMakeLists.txt` now only the
targets needed should be linked with. An example for changes needed in
a OOT can be found at [2].
Mostly removing almost everything from `cmake/Modules` and removing a
lot of manual dependency finding from your own `CMakeLists.txt` is a
good step forward.
Necessary changes to `gr_modtool` have been incorporated to work with
the new CMake syntax.

If you encounter bugs or have suggestions for further improvements do
not hesitate to contact me through the pull request [0] or email. I'll
help with build problems updating your OOT as well.

Cheers
Andrej

[0] https://github.com/gnuradio/gnuradio/pull/2230
[1] https://github.com/noc0lour/gnuradio/tree/update_cmake
[2] https://github.com/noc0lour/gr-grnet/tree/3.8


_______________________________________________
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]