- The tclpkg Makefile no longer suppresses `-fstack-clash-protection` nor
other compiler options containing `-x`
- Lefty is no longer enabled in the portable source tarball.
+- on Linux, the CMake build system uses the standard `GNUInstallDirs` to locate
+ target installation paths
### Fixed
- expr misinterprets `<<` and `>>` #2103
- stdout and stderr are not flushed at exit on MinGW #2178
- Gvedit on macOS now understands the `-?` help command line argument
+- CMAKE_LIBRARY_PATH is not honored #1973
## [2.50.0] – 2021-12-04
find_program(GZIP gzip)
# ================== Convenient values for CMake configuration =================
-set(BINARY_INSTALL_DIR bin)
-set(LIBRARY_INSTALL_DIR lib)
+if(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
+ include(GNUInstallDirs)
+ set(BINARY_INSTALL_DIR "${CMAKE_INSTALL_BINDIR}")
+ set(LIBRARY_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}")
+ set(HEADER_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}/graphviz")
+ set(MAN_INSTALL_DIR "${CMAKE_INSTALL_MANDIR}")
+ set(libdir "${CMAKE_INSTALL_FULL_LIBDIR}")
+ set(includedir "${CMAKE_INSTALL_FULL_INCLUDEDIR}")
+else()
+ set(BINARY_INSTALL_DIR bin)
+ set(LIBRARY_INSTALL_DIR lib)
+ set(HEADER_INSTALL_DIR include/graphviz)
+ set(MAN_INSTALL_DIR share/man)
+ set(libdir "${CMAKE_INSTALL_PREFIX}/${LIBRARY_INSTALL_DIR}")
+ set(includedir "${CMAKE_INSTALL_PREFIX}/include")
+endif()
+
set(PLUGIN_INSTALL_DIR ${LIBRARY_INSTALL_DIR}/graphviz)
-set(HEADER_INSTALL_DIR include/graphviz)
-set(MAN_INSTALL_DIR share/man)
-set(PKGCONFIG_DIR lib/pkgconfig)
+set(PKGCONFIG_DIR ${LIBRARY_INSTALL_DIR}/pkgconfig)
# TODO: Find a way to check for groff and ps2pdf for manpage pdf generation
# set(MAN_PDF_INSTALL_DIR share/graphviz/doc/pdf)
set(TOP_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
set(VERSION "${GRAPHVIZ_VERSION_STRING}")
set(prefix "${CMAKE_INSTALL_PREFIX}")
set(exec_prefix "${CMAKE_INSTALL_PREFIX}")
-set(libdir "${CMAKE_INSTALL_PREFIX}/lib")
-set(includedir "${CMAKE_INSTALL_PREFIX}/include")
set(PACKAGE "graphviz")
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/lib/cdt/libcdt.pc.in ${CMAKE_CURRENT_SOURCE_DIR}/libcdt.pc @ONLY)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/lib/cgraph/libcgraph.pc.in ${CMAKE_CURRENT_SOURCE_DIR}/libcgraph.pc @ONLY)