commit c06a47cce7bfe3e3878b4cf927d9c4ab595c2b2c parent 156880b266120ef77c8f776e31ab999eaa88e8e7 Author: Vincent Forest <vincent.forest@meso-star.com> Date: Mon, 30 Oct 2023 11:01:56 +0100 Remove CMake support POSIX make is now the only supported build system. Diffstat:
| D | cmake/CMakeLists.txt | | | 108 | ------------------------------------------------------------------------------- |
1 file changed, 0 insertions(+), 108 deletions(-)
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt @@ -1,108 +0,0 @@ -# Copyright (C) 2021-2023 |Méso|Star> (contact@meso-star.com) -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -cmake_minimum_required(VERSION 3.1) -project(scam C) -enable_testing() - -set(SCAM_SOURCE_DIR ${PROJECT_SOURCE_DIR}/../src) -option(NO_TEST "Do not build tests" OFF) - -################################################################################ -# Check dependencies -################################################################################ -find_package(RCMake 0.4 REQUIRED) -find_package(RSys 0.9 REQUIRED) -find_package(Star3D 0.8 QUIET) - -set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${RCMAKE_SOURCE_DIR}) -include(rcmake) -include(rcmake_runtime) - -include_directories(${RSys_INCLUDE_DIR}) - -################################################################################ -# Configure and define targets -################################################################################ -set(VERSION_MAJOR 0) -set(VERSION_MINOR 1) -set(VERSION_PATCH 0) -set(VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}) - -set(SCAM_FILES_SRC - scam.c - scam_log.c - scam_orthographic.c - scam_perspective.c) -set(SCAM_FILES_INC - scam_c.h - scam_log.h) -set(SCAM_FILES_INC_API scam.h) -set(SCAM_FILES_DOC COPYING README.md) - -# Prepend each file in the `SCAM_FILES_<SRC|INC>' list by `SCAM_SOURCE_DIR' -rcmake_prepend_path(SCAM_FILES_SRC ${SCAM_SOURCE_DIR}) -rcmake_prepend_path(SCAM_FILES_INC ${SCAM_SOURCE_DIR}) -rcmake_prepend_path(SCAM_FILES_INC_API ${SCAM_SOURCE_DIR}) -rcmake_prepend_path(SCAM_FILES_DOC ${PROJECT_SOURCE_DIR}/../) - -add_library(scam SHARED ${SCAM_FILES_SRC} ${SCAM_FILES_INC} ${SCAM_FILES_INC_API}) -target_link_libraries(scam RSys m) - -set_target_properties(scam PROPERTIES - DEFINE_SYMBOL SCAM_SHARED_BUILD - VERSION ${VERSION} - SOVERSION ${VERSION_MAJOR}) - -rcmake_setup_devel(scam StarCamera ${VERSION} star/scam_version.h) - -################################################################################ -# Add tests -################################################################################ -if(NOT NO_TEST) - function(build_test _name) - add_executable(${_name} ${SCAM_SOURCE_DIR}/${_name}.c) - target_link_libraries(${_name} scam RSys) - endfunction() - - function(new_test _name) - build_test(${_name}) - add_test(${_name} ${_name}) - endfunction() - - new_test(test_scam_orthographic) - new_test(test_scam_perspective_pinhole) - new_test(test_scam_perspective_thin_lens) - - if(Star3D_FOUND) - build_test(test_scam_cbox) - target_link_libraries(test_scam_cbox Star3D) - - add_test(test_scam_cbox_orthographic test_scam_cbox orthographic pinhole) - add_test(test_scam_cbox_perspective_pinhole test_scam_cbox perspective pinhole) - add_test(test_scam_cbox_perspective_thin_lens test_scam_cbox perspective thin-lens) - endif() -endif() - -################################################################################ -# Define output & install directories -################################################################################ -install(TARGETS scam - ARCHIVE DESTINATION bin - LIBRARY DESTINATION lib - RUNTIME DESTINATION bin) -install(FILES ${SCAM_FILES_INC_API} DESTINATION include/star) -install(FILES ${SCAM_FILES_DOC} DESTINATION share/doc/star-camera) -