From bbaec9bd88b309fbeec80d6d0118997f5b32def3 Mon Sep 17 00:00:00 2001 From: Albrecht Schlosser Date: Mon, 15 Feb 2021 19:45:20 +0100 Subject: [PATCH] Update CMake and make files, minor edits only There are no functional changes to be expected, mostly formatting and comments. --- CMake/FLTK-Functions.cmake | 6 +---- CMake/install-symlinks.cmake.in | 46 ++++++++++++++++++++++----------- CMakeLists.txt | 3 +-- FL/Makefile.in | 4 +-- Makefile | 4 +-- README.CMake.txt | 4 +-- cairo/Makefile | 1 + documentation/CMakeLists.txt | 5 +++- examples/CMakeLists.txt | 2 +- png/CMakeLists.txt | 4 ++- src/xutf8/utils/Makefile | 3 --- 11 files changed, 48 insertions(+), 34 deletions(-) diff --git a/CMake/FLTK-Functions.cmake b/CMake/FLTK-Functions.cmake index 14e96d7cc..2c29efe73 100644 --- a/CMake/FLTK-Functions.cmake +++ b/CMake/FLTK-Functions.cmake @@ -2,7 +2,7 @@ # FLTK-Functions.cmake # Written by Michael Surette # -# Copyright 1998-2020 by Bill Spitzak and others. +# Copyright 1998-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this @@ -49,7 +49,3 @@ function (FLTK_SET_BUNDLE_ICON TARGET ICON_PATH) RESOURCE "${ICON_PATH}" ) endfunction (FLTK_SET_BUNDLE_ICON TARGET ICON_PATH) - -# -# End of file -# diff --git a/CMake/install-symlinks.cmake.in b/CMake/install-symlinks.cmake.in index fe33bc271..b338163f1 100644 --- a/CMake/install-symlinks.cmake.in +++ b/CMake/install-symlinks.cmake.in @@ -1,17 +1,33 @@ +# +# Installation script to create symlinks for the FLTK project using CMake +# +# Copyright 1998-2021 by Bill Spitzak and others. +# +# This library is free software. Distribution and use rights are outlined in +# the file "COPYING" which should have been included with this file. If this +# file is missing or damaged, see the license at: +# +# https://www.fltk.org/COPYING.php +# +# Please see the following page on how to report bugs and issues: +# +# https://www.fltk.org/bugs.php -# On unix create backward compatibility symlinks -if(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl) - EXECUTE_PROCESS(COMMAND ln -s FL Fl - WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@ - ) -endif(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl) +# On UNIX create backward compatibility symlinks +if (NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl) + EXECUTE_PROCESS( + COMMAND ln -s FL Fl + WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@ + ) +endif (NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl) -file(GLOB FLTK_HEADER_FILES $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/*.H) -foreach(file ${FLTK_HEADER_FILES}) - GET_FILENAME_COMPONENT(nameWE ${file} NAME_WE) - if(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h) - EXECUTE_PROCESS(COMMAND ln -s ${nameWE}.H ${nameWE}.h - WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@/FL - ) - endif(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h) -endforeach(file) +file (GLOB FLTK_HEADER_FILES $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/*.H) +foreach (file ${FLTK_HEADER_FILES}) + GET_FILENAME_COMPONENT(nameWE ${file} NAME_WE) + if (NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h) + EXECUTE_PROCESS( + COMMAND ln -s ${nameWE}.H ${nameWE}.h + WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@/FL + ) + endif (NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h) +endforeach (file) diff --git a/CMakeLists.txt b/CMakeLists.txt index 191d0cf42..001f94088 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,7 +19,7 @@ # set CMake minimum version (must be before `project()` ####################################################################### -# Note: previous (1.3.x) minimum version +# Note: previous (1.3.5) minimum version # cmake_minimum_required (VERSION 2.6.3) # Note: minimum CMake version required by GNUInstallDirs @@ -55,7 +55,6 @@ if (false) fl_debug_var (FLTK_VERSION_MINOR) fl_debug_var (FLTK_VERSION_PATCH) fl_debug_var (FLTK_VERSION) - fl_debug_var (FLTK_VERSION) endif (false) ####################################################################### diff --git a/FL/Makefile.in b/FL/Makefile.in index b34b55db6..04a115c9d 100644 --- a/FL/Makefile.in +++ b/FL/Makefile.in @@ -1,7 +1,7 @@ # -# Header makefile for the Fast Light Tool Kit (FLTK). +# Header Makefile for the Fast Light Tool Kit (FLTK). # -# Copyright 1998-2010 by Bill Spitzak and others. +# Copyright 1998-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this diff --git a/Makefile b/Makefile index eb5e19585..d70bfcd45 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # -# Top-level makefile for the Fast Light Tool Kit (FLTK). +# Top-level Makefile for the Fast Light Tool Kit (FLTK). # -# Copyright 1998-2010 by Bill Spitzak and others. +# Copyright 1998-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this diff --git a/README.CMake.txt b/README.CMake.txt index abba89fbd..67ebc2e03 100644 --- a/README.CMake.txt +++ b/README.CMake.txt @@ -61,7 +61,7 @@ More information on CMake can be found on its web site http://www.cmake.org. -------------------- The prerequisites for building FLTK with CMake are staightforward: -CMake 3.2.3 or later and a recent FLTK 1.3 release, snapshot, or subversion +CMake 3.2.3 or later and a recent FLTK 1.3 release, snapshot, or Git download (working copy). Installation of CMake is covered on its web site. This howto will cover building FLTK with the default options using CMake @@ -107,7 +107,7 @@ OPTION_APPLE_X11 - default OFF Use this only if you know what you do, and if you have installed X11. OPTION_USE_POLL - default OFF - Don't use this one either, it is deprecated. + Don't use this one, it is deprecated. OPTION_BUILD_SHARED_LIBS - default OFF Normally FLTK is built as static libraries which makes more portable diff --git a/cairo/Makefile b/cairo/Makefile index c933f8504..3d7f79ec5 100644 --- a/cairo/Makefile +++ b/cairo/Makefile @@ -2,6 +2,7 @@ # CAIRO library makefile for the Fast Light Toolkit (FLTK). # # Copyright 1997-2009 by Easy Software Products. +# Copyright 2010-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this diff --git a/documentation/CMakeLists.txt b/documentation/CMakeLists.txt index acbdc6aeb..1fa54e1a3 100644 --- a/documentation/CMakeLists.txt +++ b/documentation/CMakeLists.txt @@ -1,7 +1,7 @@ # # CMakeLists.txt to build docs for the FLTK project using CMake (www.cmake.org) # -# Copyright 1998-2020 by Bill Spitzak and others. +# Copyright 1998-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this @@ -74,6 +74,7 @@ if (OPTION_BUILD_PDF_DOCUMENTATION) # strip potential " (Git-hash)" from the original version string (REGEX REPLACE " .*$" "" DOXY_VERSION ${DOXYGEN_VERSION}) + execute_process (COMMAND date +%Y OUTPUT_VARIABLE YEAR ) @@ -84,6 +85,8 @@ if (OPTION_BUILD_PDF_DOCUMENTATION) @ONLY ) + # generate LaTeX title fltk-title.tex + configure_file ( ${CMAKE_CURRENT_SOURCE_DIR}/src/fltk-title.tex.in ${CMAKE_CURRENT_BINARY_DIR}/fltk-title.tex diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 6dadb17af..e04722006 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -1,7 +1,7 @@ # # CMakeLists.txt used to build example apps by the CMake build system # -# Copyright 2020 by Bill Spitzak and others. +# Copyright 2020-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this diff --git a/png/CMakeLists.txt b/png/CMakeLists.txt index 597f996e7..faf7062a9 100644 --- a/png/CMakeLists.txt +++ b/png/CMakeLists.txt @@ -1,7 +1,7 @@ # # PNG library CMake configuration for the Fast Light Toolkit (FLTK). # -# Copyright 1998-2020 by Bill Spitzak and others. +# Copyright 1998-2021 by Bill Spitzak and others. # # This library is free software. Distribution and use rights are outlined in # the file "COPYING" which should have been included with this file. If this @@ -31,6 +31,8 @@ set(PNG_SRCS pngwrite.c pngwtran.c pngwutil.c + + # build on ARM (Apple M1 systems) arm/arm_init.c arm/filter_neon_intrinsics.c arm/palette_neon_intrinsics.c diff --git a/src/xutf8/utils/Makefile b/src/xutf8/utils/Makefile index 8c6f1de74..024783db9 100644 --- a/src/xutf8/utils/Makefile +++ b/src/xutf8/utils/Makefile @@ -17,6 +17,3 @@ create_table: create_table.c clean: rm -f *.o convert_map create_table conv_gen euc_tw - - -