| cmake_minimum_required (VERSION 3.5) |
| |
| include (ExternalProject) |
| |
| file (MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/prefix) |
| file (MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/prefix/include) |
| |
| externalproject_add (host-ipmid |
| PREFIX ${CMAKE_BINARY_DIR}/prefix |
| GIT_REPOSITORY https://github.com/openbmc/phosphor-host-ipmid |
| SOURCE_DIR ${CMAKE_BINARY_DIR}/phosphor-host-ipmid-src |
| |
| CONFIGURE_COMMAND |
| cd ${CMAKE_BINARY_DIR}/phosphor-host-ipmid-src && |
| meson build |
| --prefix=${CMAKE_BINARY_DIR}/prefix |
| --libdir=${CMAKE_BINARY_DIR}/prefix/lib |
| |
| BUILD_COMMAND |
| cd ${CMAKE_BINARY_DIR}/phosphor-host-ipmid-src/build && |
| meson compile |
| |
| INSTALL_COMMAND |
| cd ${CMAKE_BINARY_DIR}/phosphor-host-ipmid-src/build && |
| meson install |
| |
| LOG_DOWNLOAD ON |
| ) |
| |