0
0
mirror of https://github.com/obsproject/obs-studio.git synced 2024-09-20 04:42:18 +02:00

cmake: Improve OBS_VERSION undefined failure

If someone tries to build without git they need to set
OBS_VERSION_OVERRIDE, this makes the error message occur before things
like string parsing on the OBS_VERSION which look like missing
parameters.
This commit is contained in:
Kurt Kartaltepe 2021-03-19 12:16:15 -07:00 committed by Jim
parent 44c38e71cc
commit 058f009746

View File

@ -28,6 +28,9 @@ else()
set(OBS_VERSION "${OBS_VERSION_OVERRIDE}")
endif()
if("${OBS_VERSION}" STREQUAL "")
message(FATAL_ERROR "Failed to configure OBS_VERSION. Either set OBS_VERSION_OVERRIDE or ensure `git describe` succeeds.")
endif()
MESSAGE(STATUS "OBS_VERSION: ${OBS_VERSION}")
if(INSTALLER_RUN)