upm/examples/c/CMakeLists.txt
Noel Eck 0bd68e4e2b ANDROID: CMake/src changes to build on android-24
* Updated pom file generation: Generate pom files after all sensor
      library targets have been created - allows for dependencies
    * Changes for compiling on Android
    * Check for mraa build options: Look at symbols in mraa library to
      determine UPM build options (example: mraa_iio_init, mraa_firmata_init)
    * Add per target summary for C/C++/java/nodejs/python
    * Added hierarchy to fti include directory...
        old: #include "upm_voltage.h"
        new: #include "fti/upm_voltage.h"
    * Removed unimplemented methods from mpu9150 library and java example
    * Add utilities-c target for all c examples.  Most of the C examples
      rely on the upm_delay methods.  Add a dependency on the utilities-c
      target for all c examples.
    * Updated the examples/CMakeLists.txt to add dependencies passed via
      TARGETS to the target name parsed from the example name.  Also updated
      the interface example names to start with 'interfaces'.
    * Updated src/examples/CMakeLists.txt to ALWAYS remove examples from the
      example_src_list (moved this from end of function to beginning).

Signed-off-by: Noel Eck <noel.eck@intel.com>
2017-04-24 10:27:35 -07:00

12 lines
474 B
CMake

# Create an list of all C source files in this directory
file (GLOB example_src_list RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*.c")
# - Handle special cases here --------------------------------------------------
#add_example(humidity-sensor.c TARGETS si7005-c bmp280-c)
# - Create an executable for all other src files in this directory -------------
foreach (_example_src ${example_src_list})
add_example(${_example_src} TARGETS utilities-c SUFFIX "-c")
endforeach ()