My CMake modules, scripts, templates
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

GResourceCommonRules.cmake 664B

12345678910
  1. SET (REL_INSTALL_DIR "share/${PROJECT_LOWERCASE_NAME}-${MAJOR}")
  2. SET (ABS_INSTALL_DIR "${CMAKE_BINARY_DIR}/${REL_INSTALL_DIR}")
  3. FILE (MAKE_DIRECTORY "${ABS_INSTALL_DIR}")
  4. EXECUTE_PROCESS (COMMAND glib-compile-resources "--target=${ABS_INSTALL_DIR}/${PROJECT_LOWERCASE_NAME}.gresource"
  5. "--sourcedir=${CMAKE_CURRENT_SOURCE_DIR}"
  6. "--generate"
  7. "--c-name=${PROJECT_LOWERCASE_NAME}-${MAJOR}"
  8. "${CMAKE_CURRENT_SOURCE_DIR}/${PROJECT_LOWERCASE_NAME}.gresource.xml"
  9. )
  10. INSTALL (FILES "${ABS_INSTALL_DIR}/${PROJECT_LOWERCASE_NAME}.gresource" DESTINATION "${REL_INSTALL_DIR}")