Skip to content

Commit

Permalink
cmake: turn HWMON on by default, and SERIAL ON for CI
Browse files Browse the repository at this point in the history
This turns HWMON on by default, and turns on serial backends in the CI
systems so the default binaries include it.

Signed-off-by: Robin Getz <rgetz@mathworks.com>
  • Loading branch information
rgetz authored and pcercuei committed Jun 8, 2023
1 parent 1753dbc commit 0b14634
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion CI/azure/ci-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ set -x
uname -a
echo "$PWD"
mkdir build && cd build
cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DWITH_HWMON=ON -DWITH_SERIAL_BACKEND=ON -DWITH_EXAMPLES=ON -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -DENABLE_PACKAGING=ON -DCPACK_SYSTEM_NAME="${ARTIFACTNAME}"
cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DWITH_SERIAL_BACKEND=ON -DWITH_EXAMPLES=ON -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -DENABLE_PACKAGING=ON -DCPACK_SYSTEM_NAME="${ARTIFACTNAME}"
make
make package
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ if(WITH_LOCAL_BACKEND)
endif()

option(WITH_LOCAL_MMAP_API "Use the mmap API provided in Analog Devices' kernel (not upstream)" ON)
option(WITH_HWMON "Add compatibility with the hardware monitoring (hwmon) subsystem" OFF)
option(WITH_HWMON "Add compatibility with the hardware monitoring (hwmon) subsystem" ON)

list(APPEND LIBIIO_SCAN_BACKENDS local)
endif()
Expand Down
2 changes: 1 addition & 1 deletion README_BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Cmake Options | Default | Target | Description
`INSTALL_UDEV_RULE` | ON | Linux | Install a Linux udev rule for detection of USB devices |
`UDEV_RULES_INSTALL_DIR` | /lib/udev/rules.d | Linux | default install path for udev rules |
`WITH_LOCAL_CONFIG` | ON | Linux | Read local context attributes from /etc/libiio.ini |
`WITH_HWMON` | OFF | Linux | Add compatibility with the hwmon subsystem |
`WITH_HWMON` | ON | Linux | Add compatibility with the hwmon subsystem |
`WITH_GCOV` | OFF | Linux | Build with gcov profiling flags |
`OSX_FRAMEWORK` | ON | Mac | OS X frameworks provide the interfaces you need to write software for Mac. |
`OSX_PACKAGE` | ON | Mac | Create a OSX package for installation on local and other machines |
Expand Down
4 changes: 2 additions & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@ stages:
set -e
mkdir build && cd build
if [ "$ARTIFACTNAME" != "Linux-CentOS-7" ]; then
cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DENABLE_PACKAGING=ON -DPYTHON_BINDINGS=ON -DWITH_DOC=ON -DWITH_MAN=ON -DCPACK_SYSTEM_NAME=${ARTIFACTNAME}
cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DENABLE_PACKAGING=ON -DPYTHON_BINDINGS=ON -DWITH_DOC=ON -DWITH_SERIAL_BACKEND=ON -DWITH_MAN=ON -DCPACK_SYSTEM_NAME=${ARTIFACTNAME}
else
# CentOS 7 does not have new enough kernel headers to support modern libusb
# CentOS 7 does not have new enough kernel headers to support modern libusb. nor libserialport
cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DENABLE_PACKAGING=ON -DPYTHON_BINDINGS=ON -DWITH_DOC=ON -DWITH_MAN=ON -DCPACK_SYSTEM_NAME=${ARTIFACTNAME} -DWITH_USB_BACKEND=OFF -DWITH_IIOD_USBD=OFF
fi
make
Expand Down

0 comments on commit 0b14634

Please sign in to comment.