Skip to content

Commit

Permalink
build: run glib-compile-schemas after install
Browse files Browse the repository at this point in the history
  • Loading branch information
kanru committed Feb 10, 2024
1 parent d1e9c9c commit 214ec6d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ pkg_check_modules(GTK4 REQUIRED IMPORTED_TARGET gtk4)
pkg_check_modules(LIBADWAITA REQUIRED IMPORTED_TARGET libadwaita-1)

find_program(GLIB_COMPILE_RESOURCES NAMES glib-compile-resources REQUIRED)
find_program(GLIB_COMPILE_SCHEMAS NAMES glib-compile-schemas)

set(CMAKE_C_STANDARD 99)
add_compile_definitions(_XOPEN_SOURCE)
Expand Down
3 changes: 3 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ set(GSETTINGS_SCHEMAS_DIR ${CMAKE_INSTALL_DATADIR}/glib-2.0/schemas)
install(FILES setup/${PROJECT_GSCHEMA_XML}
DESTINATION ${GSETTINGS_SCHEMAS_DIR}
)
if(GLIB_COMPILE_SCHEMAS)
install(CODE "execute_process(COMMAND glib-compile-schemas ${CMAKE_INSTALL_PREFIX}/${GSETTINGS_SCHEMAS_DIR})")
endif()

install(TARGETS ibus-engine-chewing ibus-setup-chewing
DESTINATION ${CMAKE_INSTALL_LIBEXECDIR})

0 comments on commit 214ec6d

Please sign in to comment.