-if(EMBED_DATA)
- set(CLIENT_RCS ${CLIENT_RCS} ../icons/hicolor.qrc ../icons/oxygen.qrc PARENT_SCOPE)
-else(EMBED_DATA)
- install(DIRECTORY hicolor DESTINATION ${DATA_INSTALL_DIR}/quassel/icons)
- install(DIRECTORY oxygen DESTINATION ${DATA_INSTALL_DIR}/quassel/icons)
-endif(EMBED_DATA)
+if (WANT_MONO OR WANT_QTCLIENT)
+ set(ICON_RCS ${CMAKE_CURRENT_SOURCE_DIR}/hicolor.qrc) # always embed those
+
+ if (EMBED_DATA)
+ if (WITH_OXYGEN)
+ message(STATUS "Embedding bundled Oxygen icons")
+ set(ICON_RCS ${ICON_RCS} ${CMAKE_CURRENT_SOURCE_DIR}/oxygen.qrc)
+ endif()
+ else()
+ install(DIRECTORY hicolor DESTINATION ${CMAKE_INSTALL_ICONDIR})
+ if (WITH_OXYGEN)
+ message(STATUS "Installing bundled Oxygen icons")
+ install(DIRECTORY oxygen DESTINATION ${CMAKE_INSTALL_DATADIR}/quassel/icons)
+ endif()
+ endif()
+
+ if (NOT WITH_OXYGEN)
+ message(STATUS "Not installing bundled Oxygen icons")
+ endif()
+
+ set(CLIENT_RCS ${CLIENT_RCS} ${ICON_RCS} PARENT_SCOPE)
+endif()