This fixes the following warning shown while configuring:
[cmake] CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
[cmake] Compatibility with CMake < 3.10 will be removed from a future version of
[cmake] CMake.
We don't have a clearly defined supported distro/versions list, so I
took Ubuntu 22.04 as arguably the oldest one we'd want to support for
the reference point. It has CMake 3.22, released in July 2022.
Signed-off-by: Alex T <alext.mkrs@gmail.com>
When compiling mraa on Debian 13, the following error occurs:
```
/usr/include/node/node.h:696:8: error: ‘optional’ in namespace ‘std’ does not name a template type
696 | std::optional<std::string> builder_script_path;
| ^~~~~~~~
/usr/include/node/node.h:696:3: note: ‘std::optional’ is only available from C++17 onwards
696 | std::optional<std::string> builder_script_path;
| ^~~
```
Root cause: Node.js version on Debian 13 is 20+, which requires C++17 feature support.
Signed-off-by: Chun Jiao Zhao <chunjiao.zhao@siemens.com>
in OE we use i686 for qemux86 and this results in
-- INFO - Target arch is i686
CMake Error at CMakeLists.txt:191 (message):
Only x86, arm, mips, PERIPHERALMAN and mock platforms currently supported
So using a wildcard helps in using any x86 arch
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Disables node.js wrapper generation and builds by default as latest versions of node.js do not build with latest SWIG. An official patch for SWIG should revert this, community pointed out a workaround exists already but requires manual patching. This may affect packaging jobs and builders not using BUILDSWIGNODE explicitly, e.g. NPM and external to the project.
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
C++ is a mandatory dependency since version 1.4.0 and
122cab1f1e
As a result, build on embedded toolchains that do not support C++ fails
on:
CMake Error at CMakeLists.txt:2 (project):
The CMAKE_CXX_COMPILER:
/home/naourr/work/instance-1/output-1/per-package/mraa/host/bin/arm-linux-g++
is not a full path to an existing compiler tool.
Fixes:
- http://autobuild.buildroot.org/results/31086422e03611c16ab59c4418e3669b580bc0c0
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Multiple changes necessary to enable this. The main goal is to build
and run the C++ ioinit unit tests (which require c++11)
* Updated mraa required CMake version to 2.8.11 (this is needed for
the target_xxx_xxx CMake syntax.
* Added function for adding the c++11 flag give a CMake target.
* Updated unit tests for range of CMake versions (tested on 2.8.11,
3.8.2, 3.9.6, and 3.12.0).
* Added C++ unit test file (more needed here).)
Signed-off-by: Noel Eck <noel.eck@intel.com>
This is the start of the series of commits focussed on
cleaning up the exmaples/ directory.
This commit moves mraa-gpio, mraa-i2c, mraa-uart files
out of examples directory into new tools directory. Moved
files are the good cadidates to be treated as tools
instead of examples.
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
* Update documentation for C methods
* Update documentation for CXX methods
* Update build instructions for building on AT Peripheral Manager Client
Signed-off-by: Noel Eck <noel.eck@intel.com>
This is removed to make building in buildsystems like ubuntu's or yocto's
easier. Bugs reported from old versions haven't been that annoying so this is
probably be ok
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
Mock platform allows one to use mraa without having any real HW.
This commit makes necessary foundational changes and implements
GPIO functionality as well as adds respective tests.
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
LIB_SUFFIX is no longer used. Replaced with LIB_INSTALL_DIR
which provides the correct lib dir with arch suffix.
Moved the call to include(GNUInstallDirs) prior to checking the
CMAKE_INSTALL_LIBDIR - which is set by include(GNUInstallDirs).
Tested with cmake 2.8 and cmake 3.5.
Signed-off-by: Noel Eck <noel.eck@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>