Skip to content

Commit

Permalink
Automatically fetch EnTT from GitHub when not found system-wide
Browse files Browse the repository at this point in the history
  • Loading branch information
unkn0t committed Jan 28, 2025
1 parent 79f6dcb commit a55c9f8
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,14 @@ find_package(ZLIB REQUIRED)
find_package(PNG REQUIRED)
find_package(CURL REQUIRED)
if(NOT APPLE)
find_package(EnTT REQUIRED)
include(FetchContent)
FetchContent_Declare(
entt
GIT_REPOSITORY https://github.com/skypjack/entt.git
GIT_TAG 4a2d1a8541228a90e02a873dba6a980506c42c03 # v3.14.0
FIND_PACKAGE_ARGS NAMES EnTT
)
FetchContent_MakeAvailable(entt)
endif()

set(LIBS "")
Expand Down Expand Up @@ -82,6 +89,7 @@ target_link_libraries(
ZLIB::ZLIB
PNG::PNG
CURL::libcurl
EnTT::EnTT
${VORBISLIB}
${LUA_LIBRARIES}
${CMAKE_DL_LIBS})

0 comments on commit a55c9f8

Please sign in to comment.