summaryrefslogtreecommitdiff
path: root/app/doc/CMakeLists.txt
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2017-04-29 12:11:08 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2017-04-29 12:11:08 +0200
commit16e9630b79f0a7a90c6cedb6781175bb8b337dc1 (patch)
treee1b09d277dec2057e6b995ec099dd2b1f2129b35 /app/doc/CMakeLists.txt
parent09795a01ef859f072920de9df974d1b03b9ab9a4 (diff)
New upstream version 4.3.0upstream/4.3.0
Diffstat (limited to 'app/doc/CMakeLists.txt')
-rw-r--r--app/doc/CMakeLists.txt34
1 files changed, 31 insertions, 3 deletions
diff --git a/app/doc/CMakeLists.txt b/app/doc/CMakeLists.txt
index dcee056..03ac14b 100644
--- a/app/doc/CMakeLists.txt
+++ b/app/doc/CMakeLists.txt
@@ -38,7 +38,11 @@ ADD_CUSTOM_TARGET(clean-html
# If we're using the GTK back-end, just generate "vanilla" HTML help files for use with gtkhtml
IF(XTRKCAD_USE_GTK)
- SET(HALIBUT_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/linconf.but ${HALIBUT_SOURCES})
+ IF (APPLE)
+ SET(HALIBUT_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/osxconf.but ${HALIBUT_SOURCES})
+ ELSE(APPLE)
+ SET(HALIBUT_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/linconf.but ${HALIBUT_SOURCES})
+ ENDIF(APPLE)
ADD_CUSTOM_COMMAND(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/html/index.html
@@ -63,7 +67,31 @@ IF(XTRKCAD_USE_GTK)
INSTALL(
FILES xtrkcad_lin.css
DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}/html
- )
+ )
+# Copy the help files to the Help bundle if Apple
+ IF (APPLE)
+ ADD_CUSTOM_COMMAND(
+ OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/html/XTrackCAD.helpindex
+ DEPENDS help-html ${HALIBUT_SOURCES}
+ WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html
+ COMMAND hiutil -Cf XTrackCAD.helpindex -gva -e "IndexPage.html" -e "toc.html" ${CMAKE_CURRENT_BINARY_DIR}/html
+ )
+
+ ADD_CUSTOM_TARGET(help-index ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/html/XTrackCAD.helpindex)
+
+ INSTALL(
+ DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/
+ DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}/XTrackCAD.help/Contents/Resources/en.lproj
+ )
+ INSTALL(
+ DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/png.d
+ DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}/XTrackCAD.help/Contents/Resources/en.lproj
+ )
+ INSTALL(
+ FILES xtrkcad_osx.css
+ DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}/XTrackCAD.help/Contents/Resources/en.lproj
+ )
+ ENDIF(APPLE)
# Otherwise, we're using the Win32 back-end, so generate a compiled HTML help file
ELSE(XTRKCAD_USE_GTK)
@@ -86,7 +114,7 @@ ELSE(XTRKCAD_USE_GTK)
INSTALL(
FILES ${CMAKE_CURRENT_BINARY_DIR}/html/xtrkcad.chm
- DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}
+ DESTINATION ${XTRKCAD_SHARE_INSTALL_DIR}
)
ENDIF(XTRKCAD_USE_GTK)