Skip to content

iiod: CMakeLists: make sure to log usb-dmabuf support #1275

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

nunojsa
Copy link
Contributor

@nunojsa nunojsa commented Apr 18, 2025

Make sure to log if IIO usb DMABUF support is enabled or not.

PR Type

  • Bug fix (a change that fixes an issue)
  • New feature (a change that adds new functionality)
  • Breaking change (a change that affects other repos or cause CIs to fail)

PR Checklist

  • I have conducted a self-review of my own code changes
  • I have commented new code, particulary complex or unclear areas
  • I have checked that I did not intoduced new warnings or errors (CI output)
  • I have checked that components that use libiio did not get broken
  • I have updated the documentation accordingly (GitHub Pages, READMEs, etc)

@rgetz
Copy link
Contributor

rgetz commented Apr 18, 2025

If you are going to fix one, might as well fix them all - checking on main, that would include:

This patch fixes:

./iiod/CMakeLists.txt
WITH_IIOD_USB_DMABUF : 

but these aren't included:

./CMakeLists.txt
BUILD_SHARED_LIBS : 
COMPILE_WARNING_AS_ERROR : 
OSX_FRAMEWORK : 
WITH_GCOV : 
WITH_LOCAL_CONFIG : 

list generated with:

for f in $(find ./ -name CMakeLists.txt | grep -v deps) ; do echo ${f} ; for i in $(grep option[[:space:]]*\( ${f} | sed -e "s/^[[:space:]]*//g" -e "s/(/ /g" | awk '{print $2}' | sort | uniq) ; do echo -n "$i : " ; a=$(grep toggle_iio_feature ${f} | grep "{$i}"); if [ -z "${a}" ] ; then grep ${i} $(find ./ -name CMakeLists.txt | grep -v deps) | grep toggle_iio_feature; echo "";  else echo ${a} ; fi;  done | sed '/^[[:space:]]*$/d' |  grep -v toggle_iio_feature;  done

@nunojsa nunojsa force-pushed the staging/cmakelog-usb-dmabuf branch from 93a2a31 to ef2851c Compare April 21, 2025 13:52
@nunojsa
Copy link
Contributor Author

nunojsa commented Apr 21, 2025

v2:

  • Added missing options (and changes commit message accordingly)

The following CMake options were not being logged by
toggle_iio_feature():

 * WITH_IIOD_USB_DMABUF;
 * BUILD_SHARED_LIBS;
 * COMPILE_WARNING_AS_ERROR;
 * OSX_FRAMEWORK;
 * WITH_GCOV;
 * WITH_LOCAL_CONFIG

Signed-off-by: Nuno Sá <nuno.sa@analog.com>
@nunojsa nunojsa force-pushed the staging/cmakelog-usb-dmabuf branch from ef2851c to 0f8bdf8 Compare April 21, 2025 13:53
@rgetz
Copy link
Contributor

rgetz commented Apr 22, 2025

Looks good to me. Thanks

@rgetz
Copy link
Contributor

rgetz commented Apr 22, 2025

Only other thing to do - would be to add check into: ./CI/azure/check_README_BUILD.sh (which already checks options).
if you feel so inclined.... Totally not necessary...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants