--- CMakeLists.txt.orig 2013-09-27 12:59:06.000000000 +0000 +++ CMakeLists.txt 2013-09-27 17:45:20.000000000 +0000 @@ -84,6 +84,7 @@ opt(VORO3D "Enable Voro3D (for hex meshing, experimental)" ${DEFAULT}) opt(WRAP_JAVA "Enable generation of Java wrappers (experimental)" OFF) opt(WRAP_PYTHON "Enable generation of Python wrappers" OFF) +opt(INSTALL_DOCS "Install the docs (FreeBSD only)" ON) set(GMSH_MAJOR_VERSION 2) set(GMSH_MINOR_VERSION 8) @@ -1318,7 +1319,7 @@ set(GMSH_BIN bin) set(GMSH_LIB lib) set(GMSH_DOC share/doc/gmsh) - set(GMSH_MAN share/man/man1) + set(GMSH_MAN man/man1) endif(ENABLE_OS_SPECIFIC_INSTALL) if(CYGWIN) unix2dos(GMSH_API) @@ -1339,7 +1340,7 @@ set(GMSH_BIN bin) set(GMSH_LIB lib) set(GMSH_DOC share/doc/gmsh) - set(GMSH_MAN share/man/man1) + set(GMSH_MAN man/man1) endif(WIN32 OR CYGWIN) # mark targets as optional so we can install them separately if needed @@ -1394,11 +1395,13 @@ if(ENABLE_BUILD_LIB OR ENABLE_BUILD_SHARED OR ENABLE_BUILD_DYNAMIC) install(FILES ${GMSH_API} DESTINATION include/gmsh) endif(ENABLE_BUILD_LIB OR ENABLE_BUILD_SHARED OR ENABLE_BUILD_DYNAMIC) -install(FILES ${WELCOME_FILE} DESTINATION ${GMSH_DOC} RENAME README.txt) -install(FILES ${LICENSE_FILE} DESTINATION ${GMSH_DOC}) -install(FILES ${CREDITS_FILE} DESTINATION ${GMSH_DOC}) -install(FILES ${TUTORIAL_FILES} DESTINATION ${GMSH_DOC}/tutorial) -install(FILES ${DEMO_FILES} DESTINATION ${GMSH_DOC}/demos) +if(ENABLE_INSTALL_DOCS) + install(FILES ${WELCOME_FILE} DESTINATION ${GMSH_DOC} RENAME README.txt) + install(FILES ${LICENSE_FILE} DESTINATION ${GMSH_DOC}) + install(FILES ${CREDITS_FILE} DESTINATION ${GMSH_DOC}) + install(FILES ${TUTORIAL_FILES} DESTINATION ${GMSH_DOC}/tutorial) + install(FILES ${DEMO_FILES} DESTINATION ${GMSH_DOC}/demos) +endif(ENABLE_INSTALL_DOCS) if(UNIX AND NOT CYGWIN) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/doc/gmsh.1 DESTINATION ${GMSH_MAN}) endif(UNIX AND NOT CYGWIN)