-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix enum translation; refactor .mo installation (#218)
- Loading branch information
1 parent
b2c7d39
commit 1696a50
Showing
4 changed files
with
202 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# | ||
# C++ i18n through gettext | ||
# Use 'pot' to generate the POT file. | ||
# | ||
set(TRANSLATABLE_CXX_SOURCES | ||
macosfrontend/macosfrontend.h | ||
macosnotifications/macosnotifications.h | ||
webpanel/webpanel.h | ||
) | ||
|
||
list(TRANSFORM TRANSLATABLE_CXX_SOURCES PREPEND "${PROJECT_SOURCE_DIR}/" OUTPUT_VARIABLE TRANSLATABLE_CXX_SOURCES_FULL_PATH) | ||
|
||
add_custom_command( | ||
OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/base.pot | ||
COMMAND xgettext --c++ --keyword=_ --keyword=N_ ${TRANSLATABLE_CXX_SOURCES} -o ${CMAKE_CURRENT_SOURCE_DIR}/base.pot | ||
DEPENDS ${TRANSLATABLE_CXX_SOURCES_FULL_PATH} | ||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} | ||
COMMENT "Generating base.pot..." | ||
) | ||
add_custom_target(pot | ||
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/base.pot | ||
) | ||
|
||
set(FCITX_INSTALL_LOCALEDIR "${CMAKE_INSTALL_PREFIX}/share/locale") | ||
fcitx5_install_translation(fcitx5-macos) |
Oops, something went wrong.