Remove the need for a temporary script file to compile gschemas

I opted for this temporary script to be able to print a message while compiling
as glib-compile-schemas is totally silent. Turns out printing the message can equally
be done directly in the install command.
This commit is contained in:
Geert Janssens 2018-02-17 20:16:11 +01:00
parent de4b72dc11
commit fbdacae610

View File

@ -32,13 +32,9 @@ add_custom_command(
add_custom_target(compiled-schemas ALL DEPENDS ${SCHEMADIR_BUILD}/gschemas.compiled)
file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/compile_schemas.sh
"set -e
echo \"Compiling gschema files in $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas\"
${GLIB_COMPILE_SCHEMAS} $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas")
install(CODE "execute_process(COMMAND ${SHELL} ${CMAKE_CURRENT_BINARY_DIR}/compile_schemas.sh)")
install(CODE "execute_process(
COMMAND ${SHELL} -c \"echo Compiling gschema files in $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas ;
${GLIB_COMPILE_SCHEMAS} $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas\")")
SET(gschemas_DIST_local "")
FOREACH(file ${gschema_SOURCES})