analogdevicesinc / gr-iio

IIO blocks for GNU Radio
GNU General Public License v3.0
94 stars 62 forks source link

WIP: Updates for GNU Radio version >= 3.9.0.0 compatibility. #96

Closed adamhorden closed 3 years ago

adamhorden commented 3 years ago

Updates for GNU Radio version >= 3.9.0.0 compatibility.

Use std::shared_ptr with GNU Radio 3.9.0.0

In the released GNU Radio version 3.9.0.0 release, GNU Radio has switched from boost::shared_ptr to std::shared_ptr.

Rebase changes

Rebase changes from:

https://github.com/gnuradio/gnuradio/pull/2840

Please see:

https://wiki.gnuradio.org/index.php/GNU_Radio_3.9_OOT_Module_Porting_Guide#C.2B.2B_Modernization

:boom:

Testing

I have tested these changes by building GNU Radio version 3.9.0.0 (master) from source and then compiling gr-iio from this feature branch. The build works as expected. I can supply a Docker container that allows this testing to happen in an automated manor.

I used the commit hash c40e82ae17a9dfefc95b15ab22eaf8dbf1a45d29 while building GNU Radio from source :nerd_face:.

Signed-off-by: Adam Horden adam.horden@horden.engineering

adamhorden commented 3 years ago

I expected upgrade-3.8 to be in master at this point. I need to rebase this feature branch with the changes from upgrade-3.8.

MountainLogic commented 3 years ago

Trying to build this on Ubuntu 20.04 and having issue with cmake

`scott@scott:~/wip/he_gr_iio$ cmake .

-- Build type not specified: defaulting to release. -- Using GMP. -- Found Boost: /usr/lib/x86_64-linux-gnu/cmake/Boost-1.71.0/BoostConfig.cmake (found suitable version "1.71.0", minimum required is "1.71.0") found components: date_time program_options system regex thread unit_test_framework -- User set python executable /usr/bin/python3 -- Extracting version information from git describe... -- Found Boost: /usr/lib/x86_64-linux-gnu/cmake/Boost-1.71.0/BoostConfig.cmake (found version "1.71.0") found components: date_time program_options system regex thread unit_test_framework -- Found libad9361-iio library: /usr/local/lib/libad9361.so -- Found libiio library: /usr/lib/x86_64-linux-gnu/libiio.so -- Using install prefix: /usr/local -- Building for version: v0.3-43-g62f2bb64 / 0.0.4git -- PYTHON and GRC components are enabled -- Python checking for pygccxml - found CMake Error at /usr/local/lib/cmake/gnuradio/GrPybind.cmake:203 (message): Python bindings for dds_control.h are out of sync Call Stack (most recent call first): python/bindings/CMakeLists.txt:40 (GR_PYBIND_MAKE_OOT) `

Tried getting pybynd up to date by following the Ubuntu 20.04 build from source instructions:

`curl -Lo pybind11.tar.gz https://github.com/pybind/pybind11/archive/v2.4.3.tar.gz

mkdir pybind11 && tar xzf pybind11.tar.gz -C pybind11 --strip-components=1 && cd pybind11 mkdir build && cd build cmake .. -DCMAKE_BUILD_TYPE=Release -DPYBIND11_TEST=OFF make && make install `

Also, a lot of wiki and readme pages need updating before this can be merged

adamhorden commented 3 years ago

@MountainLogic:

Please see:

https://github.com/gnuradio/gnuradio/pull/4277

I am working towards getting this integrated into GNU Radio, as per GNU RadioEnhancement Proposals 0017. In short it adds the gr-iio out of tree module in tree.

Currently my efforts are working towards bringing this in tree 🤓 .

This was a work in progress branch before this work started. I would expect this branch to produce build errors.

If you want to use gr-iio take a look at the above pull request, you should be able to check out that branch and compile from source instead of using the out of tree module here 😁 .

Adam Horden

adamhorden commented 3 years ago

Closing in favour of GNU RadioEnhancement Proposals 0017.

Please see:

https://github.com/gnuradio/gnuradio/pull/4277

Adam Horden