kicad/CMakeLists.txt

21 lines
588 B
CMake

cmake_minimum_required( VERSION 2.8.4 FATAL_ERROR )
project( kicad-i18n NONE )
find_package( Gettext REQUIRED )
file(STRINGS LINGUAS LANG_ARRAY REGEX "^[^#].*")
foreach( LANG ${LANG_ARRAY} )
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/${LANG})
execute_process( COMMAND ${GETTEXT_MSGFMT_EXECUTABLE}
${CMAKE_SOURCE_DIR}/${LANG}/kicad.po
-o ${CMAKE_BINARY_DIR}/${LANG}/kicad.mo )
install( FILES ${CMAKE_BINARY_DIR}/${LANG}/kicad.mo
DESTINATION share/kicad/internat/${LANG}
COMPONENT resources )
endforeach()