Skip to content

Commit

Permalink
build: only enable CXX if needed
Browse files Browse the repository at this point in the history
This allows building Zycore when only a C compiler is installed
  • Loading branch information
Tachi107 committed Sep 30, 2022
1 parent feef843 commit 2f77b8a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ endif ()

cmake_minimum_required(VERSION 3.9 FATAL_ERROR)

project(Zycore VERSION 1.2.0.0 LANGUAGES C CXX)
project(Zycore VERSION 1.2.0.0 LANGUAGES C)

include(GNUInstallDirs)
include(CMakePackageConfigHelpers)
Expand Down Expand Up @@ -223,7 +223,7 @@ if (DOXYGEN_FOUND)
doxygen_add_docs(doc "include/Zycore/" ALL)
install(
DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html/"
DESTINATION "${CMAKE_INSTALL_DOCDIR}"
DESTINATION "${CMAKE_INSTALL_DOCDIR}/api/"
COMPONENT Documentation
)
endif()
Expand Down Expand Up @@ -276,6 +276,7 @@ function (zyan_add_test test)
endfunction ()

if (ZYCORE_BUILD_TESTS)
enable_language(CXX)
enable_testing()
zyan_add_test("String")
zyan_add_test("Vector")
Expand Down

0 comments on commit 2f77b8a

Please sign in to comment.