$NetBSD$

Simplify a bit the installation of man pages and documentation and make it
consistent to every Unix-like systems.

TODO: Investigate if it's possible to simplify that even further!
TODO: (in order to make an upstreamable patch)

--- CMakeLists.txt.orig	2018-06-28 19:51:14.493572163 +0000
+++ CMakeLists.txt
@@ -236,30 +236,14 @@ endif ()
 ### 20180415 - Add man page gen, and install - also doc/usersguide.html
 if (UNIX)
     FILE (GLOB UnixManFile "doc/man-edbrowse-debian.1")
-    set (UnixManDir "/usr/share/man/man1")
-    set (UnixDocDir "/usr/share/doc/edbrowse")
-    if (${CMAKE_SYSTEM_NAME} STREQUAL  "FreeBSD")
-	FILE (GLOB UnixManFile "doc/man-edbrowse-freebsd.1")
-        set (UnixManDir "/usr/local/man/man1")
-        set (UnixDocDir "/usr/local/share/doc/edbrowse")
-    endif()
+    set (UnixManDir "@PREFIX@/@PKGMANDIR@/man1")
+    set (UnixDocDir "@PREFIX@/share/doc/edbrowse")
     # copy to build dir
     configure_file( ${UnixManFile} ${CMAKE_BINARY_DIR}/edbrowse.1 )
-    # find 'gzip' - warn if not...
-    find_program(GZIP_EXE gzip PATHS /bin )
-    if (GZIP_EXE)
-        # gzip it in place
-        execute_process(COMMAND ${GZIP_EXE} -f "edbrowse.1"
-            WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
-            INPUT_FILE edbrowse.1
-            OUTPUT_FILE edbrowse.1.gz )
-        # install it
-	install(FILES ${CMAKE_BINARY_DIR}/edbrowse.1.gz DESTINATION ${UnixManDir})
-    else ()
-        message(WARNING "Unable to locate 'gzip'! No man page...")
-    endif ()
+    # install man page
+    install(FILES ${CMAKE_BINARY_DIR}/edbrowse.1 DESTINATION ${UnixManDir})
     # install user guide
-    install(FILES doc/usersguide.html doc/usersguide_fr.html doc/sample.ebrc doc/sample_fr.ebrc doc/sample_it.ebrc DESTINATION ${UnixDocDir})
+    install(FILES doc/usersguide.html doc/sample.ebrc DESTINATION ${UnixDocDir})
 endif ()
 
 ###########################################################
