1 From: hasufell <julian.ospald@googlemail.com>
2 Date: Sun Apr 8 18:48:34 UTC 2012
4 add proper install rules
9 option(USE_MPG123 "use mpg123 + libsndfile for sound" ON)
11 find_program(DPKG_PROGRAM dpkg DOC "dpkg program of Debian-based systems")
14 +set(BINDIR "bin" CACHE PATH "Where to install binaries")
15 +set(DATAROOTDIR "${CMAKE_INSTALL_PREFIX}/share" CACHE PATH "Sets the root of data directories to a non-default location")
16 +set(DATADIR "${CMAKE_INSTALL_PREFIX}/share/openmw" CACHE PATH "Sets the openmw data directories to a non-default location")
17 +set(DOCDIR "${DATAROOTDIR}/doc/openmw" CACHE PATH "Sets the doc directory to a non-default location.")
18 +set(MANDIR "${DATAROOTDIR}/man" CACHE PATH "Where to install manpages")
19 +set(SYSCONFDIR "" CACHE PATH "Set config dir")
21 # Location of morrowind data files
24 set(MORROWIND_DATA_FILES "./data" CACHE PATH "location of Morrowind data files")
25 set(MORROWIND_RESOURCE_FILES "./resources" CACHE PATH "location of OpenMW resources files")
27 - set(MORROWIND_DATA_FILES "data" CACHE PATH "location of Morrowind data files")
28 - set(MORROWIND_RESOURCE_FILES "resources" CACHE PATH "location of OpenMW resources files")
29 + set(MORROWIND_DATA_FILES "/usr/share/games/openmw/data/" CACHE PATH "location of Morrowind data files")
30 + set(MORROWIND_RESOURCE_FILES "${DATADIR}/resources" CACHE PATH "location of OpenMW resources files")
35 set(CMAKE_CXX_FLAGS "-arch i386")
43 +INSTALL(PROGRAMS "${OpenMW_BINARY_DIR}/openmw" DESTINATION ${BINDIR} )
44 +INSTALL(PROGRAMS "${OpenMW_BINARY_DIR}/omwlauncher" DESTINATION ${BINDIR} )
45 +INSTALL(PROGRAMS "${OpenMW_BINARY_DIR}/esmtool" DESTINATION ${BINDIR} )
48 +INSTALL(FILES "${OpenMW_SOURCE_DIR}/apps/launcher/resources/images/openmw.png" DESTINATION "share/pixmaps/")
50 +# Install global configuration files
51 +INSTALL(FILES "${OpenMW_BINARY_DIR}/openmw.cfg.install" DESTINATION ${SYSCONFDIR} RENAME "openmw.cfg" )
52 +INSTALL(FILES "${OpenMW_BINARY_DIR}/plugins.cfg" DESTINATION ${SYSCONFDIR} )
53 +INSTALL(FILES "${OpenMW_SOURCE_DIR}/files/launcher.cfg" DESTINATION ${SYSCONFDIR} )
56 +INSTALL(DIRECTORY "${OpenMW_BINARY_DIR}/resources" DESTINATION ${DATADIR} )
57 +INSTALL(FILES "${OpenMW_BINARY_DIR}/launcher.qss" DESTINATION "${DATADIR}/resources" )