summaryrefslogtreecommitdiff
path: root/docs/CMakeLists.txt
diff options
context:
space:
mode:
authorcyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2008-12-23 07:38:22 +0000
committercyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2008-12-23 07:38:22 +0000
commite802b6dfe8ef0105389b69e17e7faa2e4c92d756 (patch)
tree7556cf902a0f943cb4bbc3b47b89fb13797ad4e1 /docs/CMakeLists.txt
parent40ec6f0854c2210e670199f701636d9d78ffa6c0 (diff)
Some more Windows fixes, both in CMake and in the code itself. (I don't like the const casting for the latter, but it's only until we get rid of use of strchr)
Added CPack setup to automate generation of source package for *nix and NSIS installer for Windows. Some other minor CMake fixes. Converted docs/README and docs/WIN32.txt from Unix linefeeds to DOS linefeeds so they show up right in Notepad under Windows. Added small fix for Visual Studio 2008, CMake doesn't detect the Express version correctly and it must be explicitly defined. git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1861 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'docs/CMakeLists.txt')
-rw-r--r--docs/CMakeLists.txt15
1 files changed, 15 insertions, 0 deletions
diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt
new file mode 100644
index 000000000..24b4eb85d
--- /dev/null
+++ b/docs/CMakeLists.txt
@@ -0,0 +1,15 @@
+# We only need to install these docs on Windows as most Windows installations will be binary, not source
+if(WIN32)
+ # Only install given files from this directory
+ # NOTE: I would've had this just find all files in the directory, but that would include files not needed (like this file)
+ execute_process(COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/README ${CMAKE_CURRENT_BINARY_DIR}/README.txt)
+ if(IN_SOURCE)
+ # Add README.txt to list of files for CPack to ignore
+ add_to_cpack_ignored_files("README.txt$" TRUE)
+ endif(IN_SOURCE)
+ set(DOCS DEFCON FAQ INSTALL MODULES NEWS OLDCHANGES PROXY ${CMAKE_CURRENT_BINARY_DIR}/README.txt WIN32.txt)
+ install(FILES ${DOCS}
+ DESTINATION docs
+ )
+ set_directory_properties(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${CMAKE_CURRENT_BINARY_DIR}/README.txt")
+endif(WIN32)