mirror of
https://github.com/git/git
synced 2024-08-27 19:49:21 +00:00
cmake: add warning for ignored MSGFMT_EXE
It does not make sense to attempt to set MSGFMT_EXE when NO_GETTEXT is configured, as such add a check for NO_GETTEXT before attempting to set it. Suggested-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Matthew Rogers <mattr94@gmail.com> Acked-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
409047a2b3
commit
ce24797d38
|
@ -185,14 +185,18 @@ if(WIN32 AND NOT MSVC)#not required for visual studio builds
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_program(MSGFMT_EXE msgfmt)
|
if(NO_GETTEXT)
|
||||||
if(NOT MSGFMT_EXE)
|
message(STATUS "msgfmt not used under NO_GETTEXT")
|
||||||
if (USE_VCPKG)
|
else()
|
||||||
set(MSGFMT_EXE ${CMAKE_SOURCE_DIR}/compat/vcbuild/vcpkg/downloads/tools/msys2/msys64/usr/bin/msgfmt.exe)
|
find_program(MSGFMT_EXE msgfmt)
|
||||||
endif()
|
if(NOT MSGFMT_EXE)
|
||||||
if(NOT EXISTS ${MSGFMT_EXE})
|
if(USE_VCPKG)
|
||||||
message(WARNING "Text Translations won't be built")
|
set(MSGFMT_EXE ${CMAKE_SOURCE_DIR}/compat/vcbuild/vcpkg/downloads/tools/msys2/msys64/usr/bin/msgfmt.exe)
|
||||||
unset(MSGFMT_EXE)
|
endif()
|
||||||
|
if(NOT EXISTS ${MSGFMT_EXE})
|
||||||
|
message(WARNING "Text Translations won't be built")
|
||||||
|
unset(MSGFMT_EXE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue