This repository has been archived on 2026-04-17. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
bhlib-old/unit/CMakeLists.txt

29 lines
601 B
CMake
Raw Normal View History

2024-04-13 14:52:29 +03:00
cmake_minimum_required(VERSION 3.10)
# Project and C standard configuration
project(bhunit LANGUAGES C)
set(CMAKE_C_STANDARD 90)
set(CMAKE_C_STANDARD_REQUIRED ON)
# Disable extensions
set(CMAKE_C_EXTENSIONS OFF)
# Library code
set(BHUNIT_SOURCE
src/unit.c
)
set(BHUNIT_HEADER
include/bh/unit.h
)
# Library
add_library(bhunit STATIC ${BHUNIT_SOURCE} ${BHUNIT_HEADER})
target_include_directories(bhunit PUBLIC include)
2024-06-16 12:23:21 +03:00
# Enable warnings and pedantics
if(MSVC)
target_compile_options(bhunit PRIVATE /W4)
else()
target_compile_options(bhunit PRIVATE -Wall -Wextra -Wpedantic)
endif()