Combined patches from git.
--- /dev/null
+++ fltk1.4-1.4.4/.gitignore
@@ -0,0 +1,292 @@
+# Start Debian additions
+/.pc
+/obj-*
+# End Debian additions
+
+# ignore file for git - generated from subversion with:
+# git svn show-ignore
+
+*.o
+*.exe
+
+# /
+/autom4te*.cache
+/clang
+/config.cache
+/config.guess
+/config.h
+/config.log
+/config.status
+/config.sub
+/configure
+/fltk-config
+/fltk.list
+/fltk.spec
+/makeinclude
+/*.bck
+/TAGS
+
+# /FL
+/FL/abi-version.h
+/FL/Makefile
+/FL/*.bck
+
+# /documentation/
+/documentation/.xvpics
+/documentation/blocks.0
+/documentation/blocks.6
+/documentation/blocks.z
+/documentation/checkers.0
+/documentation/checkers.6
+/documentation/checkers.z
+/documentation/Doxybook
+/documentation/Doxyfile
+/documentation/fltk.0
+/documentation/fltk.3
+/documentation/fltk-config.0
+/documentation/fltk-config.1
+/documentation/fltk-config.z
+/documentation/fltk.d
+/documentation/fltk.pdf
+/documentation/fltk.z
+/documentation/fluid.0
+/documentation/fluid.1
+/documentation/fluid.z
+/documentation/html
+/documentation/latex
+/documentation/sudoku.0
+/documentation/sudoku.6
+/documentation/sudoku.z
+/documentation/*.bck
+/documentation/*.bak
+/documentation/*.log
+
+# /documentation/src/
+/documentation/src/*.0
+/documentation/src/*.1
+/documentation/src/*.3
+/documentation/src/*.6
+/documentation/src/*.z
+/documentation/src/fltk-book.tex
+
+# /examples/
+/examples/*.exe
+/examples/clipboard
+/examples/fltk-versions
+/examples/howto-add_fd-and-popen
+/examples/howto-browser-with-icons
+/examples/howto-drag-and-drop
+/examples/howto-parse-args
+/examples/howto-text-over-image-button
+/examples/menubar-add
+/examples/nativefilechooser-simple-app
+/examples/progress-simple
+/examples/shapedwindow
+/examples/table-as-container
+/examples/table-simple
+/examples/table-sort
+/examples/table-spreadsheet
+/examples/table-spreadsheet-with-keyboard-nav
+/examples/table-with-keynav
+/examples/tabs-simple
+/examples/textdisplay-with-colors
+/examples/texteditor-simple
+/examples/tree-as-container
+/examples/tree-custom-draw-items
+/examples/tree-custom-sort
+/examples/tree-of-tables
+/examples/tree-simple
+/examples/wizard-simple
+
+# /fluid/
+/fluid/fluid
+/fluid/fluid-shared
+/fluid/*.bck
+/fluid/*.exe
+/fluid/*.ilk
+/fluid/*.pdb
+/fluid/TAGS
+
+# /fluid/fluid.app/Contents/MacOS/
+/fluid/fluid.app/Contents/MacOS/fluid
+
+# /fluid/pixmaps/
+/fluid/pixmaps/*.bck
+
+# /ide/VisualC2008/
+/ide/VisualC2008/fltk.ncb
+/ide/VisualC2008/*.pdb
+/ide/VisualC2008/*.user
+/ide/VisualC2008/*_/
+/ide/VisualC2008/*__0/
+/ide/VisualC2008/fltkdll/
+/ide/VisualC2008/fltkdlld/
+/ide/VisualC2008/Debug/
+/ide/VisualC2008/Debug Cairo/
+/ide/VisualC2008/Release/
+/ide/VisualC2008/Release Cairo/
+
+# /ide/VisualC2010/
+/ide/VisualC2010/*.user
+/ide/VisualC2010/*_debug/
+/ide/VisualC2010/*_release/
+/ide/VisualC2010/fltk.*sdf
+/ide/VisualC2010/fltk.suo
+/ide/VisualC2010/fltkdlld.pdb
+/ide/VisualC2010/fltkdll/
+/ide/VisualC2010/fltkdlld/
+/ide/VisualC2010/Debug/
+/ide/VisualC2010/Debug Cairo/
+/ide/VisualC2010/Release/
+/ide/VisualC2010/Release Cairo/
+
+# /ide/Xcode3/
+/ide/Xcode3/build
+
+# /ide/Xcode3/FLTK.xcodeproj/
+/ide/Xcode3/FLTK.xcodeproj/*.pbxuser
+/ide/Xcode3/FLTK.xcodeproj/*.perspectivev3
+
+# /ide/Xcode4/
+/ide/Xcode4/build
+
+# /ide/Xcode4/FLTK.xcodeproj/
+/ide/Xcode4/FLTK.xcodeproj/*.pbxuser
+/ide/Xcode4/FLTK.xcodeproj/*.perspectivev3
+
+# /lib/
+/lib/lib*
+/lib/*.lib
+/lib/*.a
+/lib/*.bsc
+
+# /misc/
+/misc/doxystar
+
+# /src/
+/src/*.so*
+/src/*.sl*
+/src/*.a
+/src/*.bck
+/src/*.sav
+/src/*.dylib
+
+# /test/
+/test/*.pdb
+/test/CubeView
+/test/CubeViewUI.cxx
+/test/CubeViewUI.h
+/test/adjuster
+/test/animated
+/test/arc
+/test/ask
+/test/bitmap
+/test/blocks
+/test/boxtype
+/test/browser
+/test/button
+/test/buttons
+/test/cairo_test
+/test/checkers
+/test/clock
+/test/colbrowser
+/test/color_chooser
+/test/cube
+/test/cursor
+/test/curve
+/test/demo
+/test/device
+/test/doublebuffer
+/test/editor
+/test/fast_slow
+/test/fast_slow.cxx
+/test/fast_slow.h
+/test/file_chooser
+/test/fonts
+/test/forms
+/test/fractals
+/test/fullscreen
+/test/gl_overlay
+/test/glpuzzle
+/test/hello
+/test/help
+/test/icon
+/test/iconize
+/test/image
+/test/inactive
+/test/inactive.cxx
+/test/inactive.h
+/test/input
+/test/input_choice
+/test/keyboard
+/test/keyboard_ui.cxx
+/test/keyboard_ui.h
+/test/label
+/test/line_style
+/test/list_visuals
+/test/mandelbrot
+/test/mandelbrot_ui.cxx
+/test/mandelbrot_ui.h
+/test/menubar
+/test/message
+/test/minimum
+/test/native-filechooser
+/test/navigation
+/test/offscreen
+/test/output
+/test/overlay
+/test/pack
+/test/pixmap
+/test/pixmap_browser
+/test/preferences
+/test/preferences.cxx
+/test/preferences.h
+/test/print
+/test/radio
+/test/radio.cxx
+/test/radio.h
+/test/resize
+/test/resize.cxx
+/test/resize.h
+/test/resizebox
+/test/rotated_text
+/test/scroll
+/test/shape
+/test/shiny
+/test/shiny_panel.cxx
+/test/shiny_panel.h
+/test/subwindow
+/test/sudoku
+/test/symbols
+/test/table
+/test/tabs
+/test/tabs.cxx
+/test/tabs.h
+/test/threads
+/test/tile
+/test/tiled_image
+/test/tree
+/test/tree.cxx
+/test/tree.h
+/test/twowin
+/test/unittests
+/test/utf8
+/test/valuators
+/test/valuators.cxx
+/test/valuators.h
+/test/windowfocus
+/test/*.bck
+/test/*.exe
+/test/*.ilk
+/test/fltk*.lib
+/test/fltk*.exp
+/test/fltk*.dll
+
+# /test/blocks.app/Contents/MacOS/
+/test/blocks.app/Contents/MacOS/blocks
+
+# /test/checkers.app/Contents/MacOS/
+/test/checkers.app/Contents/MacOS/checkers
+
+# /test/sudoku.app/Contents/MacOS/
+/test/sudoku.app/Contents/MacOS/sudoku
--- fltk1.4-1.4.4.orig/Makefile
+++ fltk1.4-1.4.4/Makefile
@@ -109,8 +109,8 @@ makeinclude: configure configh.in makein
 	touch config.h
 	chmod +x fltk-config
 
-configure: configure.ac
-	autoconf
+# configure: configure.ac
+# 	autoconf
 
 portable-dist:
 	epm -v -s fltk.xpm fltk
--- fltk1.4-1.4.4.orig/cairo/Makefile
+++ fltk1.4-1.4.4/cairo/Makefile
@@ -30,6 +30,8 @@
 FLTKFLAGS = -DFL_LIBRARY
 include ../makeinclude
 
+CXXFLAGS := $(CXXFLAGS:-fPIE=-fPIC)
+
 #
 # Object files...
 #
--- fltk1.4-1.4.4.orig/configure
+++ fltk1.4-1.4.4/configure
@@ -776,7 +776,6 @@ infodir
 docdir
 oldincludedir
 includedir
-runstatedir
 localstatedir
 sharedstatedir
 sysconfdir
@@ -884,7 +883,6 @@ datadir='${datarootdir}'
 sysconfdir='${prefix}/etc'
 sharedstatedir='${prefix}/com'
 localstatedir='${prefix}/var'
-runstatedir='${localstatedir}/run'
 includedir='${prefix}/include'
 oldincludedir='/usr/include'
 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
@@ -1135,15 +1133,6 @@ do
   | -silent | --silent | --silen | --sile | --sil)
     silent=yes ;;
 
-  -runstatedir | --runstatedir | --runstatedi | --runstated \
-  | --runstate | --runstat | --runsta | --runst | --runs \
-  | --run | --ru | --r)
-    ac_prev=runstatedir ;;
-  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
-  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
-  | --run=* | --ru=* | --r=*)
-    runstatedir=$ac_optarg ;;
-
   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
     ac_prev=sbindir ;;
   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
@@ -1281,7 +1270,7 @@ fi
 for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
 		datadir sysconfdir sharedstatedir localstatedir includedir \
 		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
-		libdir localedir mandir runstatedir
+		libdir localedir mandir
 do
   eval ac_val=\$$ac_var
   # Remove trailing slashes.
@@ -1434,7 +1423,6 @@ Fine tuning of the installation director
   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
-  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
   --libdir=DIR            object code libraries [EPREFIX/lib]
   --includedir=DIR        C header files [PREFIX/include]
   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
@@ -10934,7 +10922,7 @@ then :
 
 else $as_nop
 
-        printf "%s\n" "#define FLTK_DOCDIR \"$prefix/share/doc/fltk\"" >>confdefs.h
+        printf "%s\n" "#define FLTK_DOCDIR \"$prefix/share/doc/fltk1.4-doc/HTML\"" >>confdefs.h
 
 
 fi
--- fltk1.4-1.4.4.orig/configure.ac
+++ fltk1.4-1.4.4/configure.ac
@@ -1801,7 +1801,7 @@ AS_CASE([$host_os], [mingw*], [
     AS_IF([test x$prefix = xNONE], [
         AC_DEFINE_UNQUOTED([FLTK_DOCDIR], "/usr/local/share/doc/fltk")
     ], [
-        AC_DEFINE_UNQUOTED([FLTK_DOCDIR], "$prefix/share/doc/fltk")
+        AC_DEFINE_UNQUOTED([FLTK_DOCDIR], "$prefix/share/doc/fltk1.4-doc/HTML")
     ])
 ])
 
--- fltk1.4-1.4.4.orig/documentation/CMakeLists.txt
+++ fltk1.4-1.4.4/documentation/CMakeLists.txt
@@ -191,6 +191,12 @@ if(FLTK_BUILD_PDF_DOCS)
     @ONLY
   )
 
+  configure_file(
+    ${CMAKE_CURRENT_SOURCE_DIR}/latex-extras.sty
+    ${CMAKE_CURRENT_BINARY_DIR}/latex-extras.sty
+    @ONLY
+  )
+
   # generate fltk.pdf
 
   add_custom_command(
@@ -204,6 +210,7 @@ if(FLTK_BUILD_PDF_DOCS)
     COMMAND cp -f latex/refman.pdf fltk.pdf
     DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${DOXYFILE}
             ${CMAKE_CURRENT_BINARY_DIR}/fltk-title.tex
+	    ${CMAKE_CURRENT_BINARY_DIR}/latex-extras.sty
     WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
     COMMENT "Generating PDF documentation" VERBATIM
   )
@@ -234,8 +241,8 @@ endif(DOCS)
 
 if(FLTK_INSTALL_HTML_DOCS AND FLTK_BUILD_HTML_DOCS)
 
-  install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html
-    DESTINATION ${FLTK_DATADIR}/doc/fltk
+  install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/
+    DESTINATION ${FLTK_DATADIR}/doc/fltk1.4-doc/HTML
   )
 
 endif(FLTK_INSTALL_HTML_DOCS AND FLTK_BUILD_HTML_DOCS)
@@ -243,7 +250,7 @@ endif(FLTK_INSTALL_HTML_DOCS AND FLTK_BU
 if(FLTK_INSTALL_PDF_DOCS AND FLTK_BUILD_PDF_DOCS)
 
   install(FILES ${CMAKE_CURRENT_BINARY_DIR}/fltk.pdf
-    DESTINATION ${FLTK_DATADIR}/doc/fltk/
+    DESTINATION ${FLTK_DATADIR}/doc/fltk1.4-doc
   )
 
 endif(FLTK_INSTALL_PDF_DOCS AND FLTK_BUILD_PDF_DOCS)
--- fltk1.4-1.4.4.orig/documentation/Doxyfile.in
+++ fltk1.4-1.4.4/documentation/Doxyfile.in
@@ -1756,7 +1756,7 @@ LATEX_FOOTER           =
 # list).
 # This tag requires that the tag GENERATE_LATEX is set to YES.
 
-LATEX_EXTRA_STYLESHEET =
+LATEX_EXTRA_STYLESHEET = latex-extras.sty
 
 # The LATEX_EXTRA_FILES tag can be used to specify one or more extra images or
 # other source files which should be copied to the LATEX_OUTPUT output
--- fltk1.4-1.4.4.orig/documentation/Makefile
+++ fltk1.4-1.4.4/documentation/Makefile
@@ -66,6 +66,8 @@ MANPAGES =	$(SRC_DOCDIR)/fltk.$(CAT3EXT)
 
 FLTK_GIT_REVISION := "`( (git rev-parse HEAD || cat ../fltk_git_rev.dat;) || echo 'unknown'; ) 2>/dev/null`"
 
+export DEB_DATE := $(shell cd .. && dpkg-parsechangelog -S Date)
+
 all:	$(MANPAGES)
 
 # Use `make docs' to create all docs for distribution files.
@@ -95,10 +97,10 @@ depend:
 
 install: $(MANPAGES)
 	echo "Installing documentation files in $(DESTDIR)$(docdir) ..."
-	-$(INSTALL_DIR) "$(DESTDIR)$(docdir)"
+	-$(INSTALL_DIR) "$(DESTDIR)$(docdir)/HTML"
 	if test -f html/index.html ; then \
 	  for file in html/* ; do \
-		$(INSTALL_DATA) $$file "$(DESTDIR)$(docdir)"; \
+		$(INSTALL_DATA) $$file "$(DESTDIR)$(docdir)/HTML"; \
 	  done \
 	fi
 	if test -f fltk.pdf ; then \
@@ -216,6 +218,8 @@ refman.pdf: $(HTMLFILES) Doxybook src/fl
 	echo "Generating PDF documentation ..."
 	"$(DOXYDOC)" Doxybook
 	./make_pdf
+        MD5=`(echo $(DEB_DATE) && du -b $@) | md5sum | cut -c -32` && \
+        sed -i "s|^/ID \\[\\(<[0-9A-F]\\{32\\}>\\) \\1]$$|/ID [<$$MD5> <$$MD5>]|" $@
 
 make_pdf: make_pdf.in
 	echo "Generating $@ ..."
@@ -238,10 +242,12 @@ src/fltk-book.tex.in: src/fltk-title.tex
 src/fltk-book.tex: src/fltk-book.tex.in
 	echo "Generating $@ ..."
 	DOXY_VERSION=`"$(DOXYDOC)" --version|cut -f1 -d' '`; \
-	YEAR=`date +%Y`; \
+	YEAR=`date -ud'$(DEB_DATE)' +%Y`; \
+	TODAY=`LC_ALL=C date -ud'$(DEB_DATE)' +'%B %e, %Y'`; \
 	sed -e"s/@YEAR@/$$YEAR/g" \
 	    -e"s/@FLTK_VERSION@/$(FLTK_VERSION)/g" \
 	    -e"s/@DOXY_VERSION@/$$DOXY_VERSION/g" \
+	    -e"s/@TODAY@/$$TODAY/g" \
 	    < $< > $@
 
 generated.dox: generated.dox.in
--- /dev/null
+++ fltk1.4-1.4.4/documentation/latex-extras.sty
@@ -0,0 +1,81 @@
+\usepackage{bbding}
+%\usepackage[arrows]{boisik}
+\usepackage[notext,not1,notextcomp]{stix}
+%\usepackage{fdsymbol}
+\let\Cross\undefined
+\let\Hermaphrodite\undefined
+\usepackage{marvosym}
+\usepackage{pmboxdraw}
+\usepackage{relsize}
+\usepackage{tcolorbox}
+\usepackage{twemojis}
+\usepackage{utfsym}
+%\usepackage[nointegrals]{wasysym}
+
+% \insert@column from .../latex/tools/array-2016-10-06.sty through
+% .../array-2023-11-01.sty with a \relax added to the end of the
+% first line per the only applicable difference between current
+% array.sty's \insert@column and \insert@pcolumn.
+\providecommand{\insert@pcolumn}{%
+  \the@toks \the \@tempcnta \relax
+  \ignorespaces \@sharp \unskip
+  \the@toks \the \count@ \relax}
+
+\DeclareUnicodeCharacter{028C}{\ensuremath{\wedge}}
+\DeclareUnicodeCharacter{2196}{\ensuremath{\nwarrow}}
+\DeclareUnicodeCharacter{2197}{\ensuremath{\nearrow}}
+\DeclareUnicodeCharacter{2199}{\ensuremath{\swarrow}}
+\DeclareUnicodeCharacter{21D4}{\ensuremath{\Leftrightarrow}}
+\DeclareUnicodeCharacter{21D5}{\ensuremath{\Updownarrow}}
+\DeclareUnicodeCharacter{21E4}{\ensuremath{\barleftarrow}}
+\DeclareUnicodeCharacter{21E5}{\ensuremath{\rightarrowbar}}
+\ifx\nwarrowcorner\undefined
+  \DeclareUnicodeCharacter{21F1}{%
+    \tcbox[size=tight,bottomrule=0pt,rightrule=0pt,arc=0pt,on line,%
+    colback=white]{%
+      \ensuremath{\nwarrow}}}
+  \DeclareUnicodeCharacter{21F2}{%
+    \tcbox[size=tight,toprule=0pt,leftrule=0pt,arc=0pt,on line,colback=white]{%
+      \ensuremath{\searrow}}}
+\else
+  \DeclareUnicodeCharacter{21F1}{\ensuremath{\nwarrowcorner}}
+  \DeclareUnicodeCharacter{21F2}{\ensuremath{\nearrowcorner}} % !
+\fi
+\DeclareUnicodeCharacter{2208}{\ensuremath{\in}}
+\DeclareUnicodeCharacter{2264}{\ensuremath{\le}}
+\DeclareUnicodeCharacter{2265}{\ensuremath{\ge}}
+\DeclareUnicodeCharacter{2318}{\wasycmd}
+\DeclareUnicodeCharacter{231A}{\twemoji{watch}}
+\DeclareUnicodeCharacter{231B}{\twemoji{hourglass}}
+\DeclareUnicodeCharacter{2336}{\TTsteel}
+\pmboxdrawsetup{Shade/box={\texttt{0}\strut}}
+\input{pmboxdrawenc.dfu} % most of 2500-259F
+%\DeclareUnicodeCharacter{2572}{\ensuremath{\diagdown}}
+\DeclareUnicodeCharacter{2572}{\textbackslash}
+% \DeclareUnicodeCharacter{25B4}{\makebox[1em][c]{\ensuremath{\blacktriangle}}}
+% \DeclareUnicodeCharacter{25BA}{\makebox[1em][c]{\ensuremath{\RHD}}}
+% \DeclareUnicodeCharacter{25BE}{\makebox[1em][c]{%
+%     \ensuremath{\blacktriangledown}}}
+% \DeclareUnicodeCharacter{25C4}{\makebox[1em][c]{\ensuremath{\LHD}}}
+% \DeclareUnicodeCharacter{25C9}{\makebox[1em][c]{\ensuremath{\fisheye}}}
+\DeclareUnicodeCharacter{25B4}{\makebox[0pt][l]{\ensuremath{\blacktriangle}} }
+\DeclareUnicodeCharacter{25BA}{ \makebox[0pt][r]{\ensuremath{\RHD}}}
+\DeclareUnicodeCharacter{25BE}{\makebox[0pt][l]{%
+    \ensuremath{\blacktriangledown}} }
+\DeclareUnicodeCharacter{25C4}{\makebox[0pt][l]{\ensuremath{\LHD}} }
+\DeclareUnicodeCharacter{25C9}{%
+  \ \makebox[0pt][r]{\ensuremath{\mathsmaller{\fisheye}}}}
+%\DeclareUnicodeCharacter{25C9}{\makebox[0pt][l]{\textbigcircle}\textbullet}
+\ifx\HandLeft\undefined
+  \DeclareUnicodeCharacter{261C}{\twemoji{point_left}}
+\else
+  \DeclareUnicodeCharacter{261C}{\HandLeft}
+\fi
+%\DeclareUnicodeCharacter{270B}{\twemoji{raised hand}}
+\DeclareUnicodeCharacter{270B}{\usym{270B}}
+\DeclareUnicodeCharacter{2725}{\CrossClowerTips}
+\DeclareUnicodeCharacter{2912}{\ensuremath{\baruparrow}}
+\DeclareUnicodeCharacter{2913}{\ensuremath{\downarrowbar}}
+\DeclareUnicodeCharacter{2921}{\ensuremath{\nwsearrow}}
+\DeclareUnicodeCharacter{2922}{\ensuremath{\neswarrow}}
+\DeclareUnicodeCharacter{FF0B}{\ensuremath{+}}
--- fltk1.4-1.4.4.orig/documentation/src/fltk-title.tex.in
+++ fltk1.4-1.4.4/documentation/src/fltk-title.tex.in
@@ -8,7 +8,7 @@
 \vspace*{2cm}
 \begin{DoxyImageNoCaption}
  \mbox{\includegraphics[width=6cm]{FL200.png}}
-\end{DoxyImageNoCaption}\\
+\end{DoxyImageNoCaption}
 \vspace*{2cm}
 {\Large
 By F. Costantini, M. Melcher, \\
--- fltk1.4-1.4.4.orig/fltk-config.in
+++ fltk1.4-1.4.4/fltk-config.in
@@ -264,15 +264,15 @@ if test -n "$BINARY_DIR"; then
     includes="-I$BINARY_DIR $includes"
 fi
 
-if test "$libdir" != /usr/lib -a "$libdir" != /usr/lib32; then
-    libs="-L$libdir"
-else
-    libs=
-fi
+# if test "$libdir" != /usr/lib -a "$libdir" != /usr/lib32; then
+#     libs="-L$libdir"
+# else
+#     libs=
+# fi
 
 # Calculate needed libraries
 LDSTATIC="$libdir/libfltk.a $LDLIBS"
-LDLIBS="-lfltk$SHAREDSUFFIX $LDLIBS"
+LDLIBS="-lfltk$SHAREDSUFFIX -lX11"
 
 if test x$use_forms = xyes; then
     LDLIBS="-lfltk_forms$SHAREDSUFFIX $LDLIBS"
@@ -280,12 +280,12 @@ if test x$use_forms = xyes; then
 fi
 
 if test x$use_gl = xyes; then
-    LDLIBS="-lfltk_gl$SHAREDSUFFIX $GLLIBS $LDLIBS"
+    LDLIBS="-lfltk_gl$SHAREDSUFFIX $LDLIBS"
     LDSTATIC="$libdir/libfltk_gl.a $GLLIBS $LDSTATIC"
 fi
 
 if test x$use_images = xyes; then
-    LDLIBS="-lfltk_images$SHAREDSUFFIX $IMAGELIBS $LDLIBS"
+    LDLIBS="-lfltk_images$SHAREDSUFFIX $LDLIBS"
     LDSTATIC="$libdir/libfltk_images.a $STATICIMAGELIBS $LDSTATIC"
 fi
 
@@ -324,7 +324,7 @@ if test -n "$compile"; then
 
     post="$prog"
 
-    command="$CXX $ARCHFLAGS $includes $CXXFLAGS $debug -o $prog $flags $compile $files $LDSTATIC $link"
+    command="$CXX $ARCHFLAGS $includes $CXXFLAGS $debug -o $prog $flags $compile $files $LDLIBS $link"
 
     echo $command
     $command || exit 1
--- fltk1.4-1.4.4.orig/fltk-options/Makefile
+++ fltk1.4-1.4.4/fltk-options/Makefile
@@ -67,8 +67,8 @@ install-linux:
 		fi; \
 		$(INSTALL_DATA) icons/fltk-options-$$size.png "$(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps/fltk-options.png"; \
 	done
-	-$(INSTALL_DIR) "$(DESTDIR)/usr/share/mimelnk/application"
-	$(INSTALL_DATA) x-fltk-options.desktop "$(DESTDIR)/usr/share/mimelnk/application"
+	-$(INSTALL_DIR) "$(DESTDIR)/usr/share/mime/packages"
+	$(INSTALL_DATA) fltk-options.xml "$(DESTDIR)/usr/share/mime/packages"
 
 install-osx:
 	echo Installing fltk-options in $(DESTDIR)/Applications...
--- fltk1.4-1.4.4.orig/fluid/Makefile
+++ fltk1.4-1.4.4/fluid/Makefile
@@ -109,8 +109,8 @@ install-linux:
 		fi; \
 		$(INSTALL_DATA) icons/fluid-$$size.png "$(DESTDIR)$(datadir)/icons/hicolor/$${size}x$${size}/apps/fluid.png"; \
 	done
-	-$(INSTALL_DIR) "$(DESTDIR)$(datadir)/mimelnk/application"
-	$(INSTALL_DATA) x-fluid.desktop "$(DESTDIR)$(datadir)/mimelnk/application"
+	-$(INSTALL_DIR) "$(DESTDIR)/usr/share/mime/packages"
+	$(INSTALL_DATA) fluid.xml "$(DESTDIR)/usr/share/mime/packages"
 
 install-osx:
 	echo Installing Fluid in $(DESTDIR)/Applications...
--- fltk1.4-1.4.4.orig/fluid/documentation/CMakeLists.txt
+++ fltk1.4-1.4.4/fluid/documentation/CMakeLists.txt
@@ -201,8 +201,8 @@ endif(FLTK_BUILD_PDF_DOCS AND FLTK_BUILD
 
 if(FLTK_INSTALL_FLUID_DOCS AND FLTK_BUILD_FLUID_DOCS)
 
-  install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html
-    DESTINATION ${FLTK_DATADIR}/doc/fltk/fluid
+  install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/
+    DESTINATION ${FLTK_DATADIR}/doc/fltk1.4-doc/fluid
   )
 
 endif(FLTK_INSTALL_FLUID_DOCS AND FLTK_BUILD_FLUID_DOCS)
@@ -210,7 +210,7 @@ endif(FLTK_INSTALL_FLUID_DOCS AND FLTK_B
 if(FLTK_INSTALL_PDF_DOCS AND FLTK_BUILD_PDF_DOCS AND FLTK_BUILD_FLUID_DOCS)
 
   install(FILES ${CMAKE_CURRENT_BINARY_DIR}/fluid.pdf
-    DESTINATION ${FLTK_DATADIR}/doc/fltk/
+    DESTINATION ${FLTK_DATADIR}/doc/fltk1.4-doc/
   )
 
 endif(FLTK_INSTALL_PDF_DOCS AND FLTK_BUILD_PDF_DOCS AND FLTK_BUILD_FLUID_DOCS)
--- fltk1.4-1.4.4.orig/makeinclude.in
+++ fltk1.4-1.4.4/makeinclude.in
@@ -40,7 +40,7 @@ includedir	= @includedir@
 libdir		= @libdir@
 mandir		= @mandir@
 srcdir		= @srcdir@
-docdir		= $(datadir)/doc/fltk
+docdir		= $(datadir)/doc/fltk1.4-doc
 VPATH		= @srcdir@
 
 # programs we use...
@@ -162,7 +162,7 @@ INSTALL_DESKTOP	= @INSTALL_DESKTOP@
 UNINSTALL_DESKTOP = @UNINSTALL_DESKTOP@
 
 # Be quiet when building...
-.SILENT:
+#.SILENT:
 
 # Build commands and filename extensions...
 .SUFFIXES:	.0 .1 .3 .6 .c .cxx .mm .h .fl .man .o .z $(EXEEXT)
--- fltk1.4-1.4.4.orig/src/Makefile
+++ fltk1.4-1.4.4/src/Makefile
@@ -398,6 +398,9 @@ PSCPPFILES = \
 FLTKFLAGS = -DFL_LIBRARY
 include ../makeinclude
 
+CFLAGS   := $(CFLAGS:-fPIE=-fPIC)
+CXXFLAGS := $(CXXFLAGS:-fPIE=-fPIC)
+
 # makeinclude has set this variable:
 # BUILD = {WIN|X11|XFT|CAIRO|OSX|WAYLAND|WAYLANDX11}
 
@@ -438,7 +441,6 @@ CFILES_WIN += $(GDICFILES)
 CFILES += $(CFILES_$(BUILD))
 CXXFLAGS += $(EXTRA_CXXFLAGS_$(BUILD))
 
-
 OBJECTS =  $(MMFILES:.mm=.o) $(CPPFILES:.cxx=.o) $(CFILES:.c=.o) $(UTF8CFILES:.c=.o)
 OBJECTS += $(EXTRA_OBJECTS_$(BUILD))
 GLOBJECTS = $(GLCPPFILES:.cxx=.o) $(GLMMFILES:.mm=.o)
--- fltk1.4-1.4.4.orig/src/drivers/Wayland/Fl_Wayland_Window_Driver.cxx
+++ fltk1.4-1.4.4/src/drivers/Wayland/Fl_Wayland_Window_Driver.cxx
@@ -903,16 +903,17 @@ static void handle_configure(struct libd
   }
   window->state = window_state;
 
-  // Weston, KWin, and some versions of Mutter, on purpose, don't set the
+  // Weston, KWin, and some old versions of Mutter, on purpose, don't set the
   // window width x height when xdg_toplevel_configure runs twice
   // during resizable window creation
   // (see https://gitlab.freedesktop.org/wayland/wayland-protocols/-/issues/6).
   // Consequently, libdecor_configuration_get_content_size() may return false twice.
-  // In that case libdecor_frame_get_content_{width,height}() give the desired window size
+  // Weston and KWin, at least, don't change the window size asked by the client application
+  // which is available here in floating_{width,height}.
   if (!libdecor_configuration_get_content_size(configuration, frame, &width, &height)) {
     if (is_2nd_run) {
-      width = libdecor_frame_get_content_width(frame);
-      height = libdecor_frame_get_content_height(frame);
+      width = window->floating_width;
+      height = window->floating_height;
       if (!driver->is_resizable()) {
         libdecor_frame_set_min_content_size(frame, width, height);
         libdecor_frame_set_max_content_size(frame, width, height);
--- fltk1.4-1.4.4.orig/test/Makefile
+++ fltk1.4-1.4.4/test/Makefile
@@ -16,6 +16,12 @@
 
 include ../makeinclude
 
+# LINKFLTK      = -L../src -Wl,-rpath-link,../src -lfltk
+# LINKFLTKFORMS = -L../src -Wl,-rpath-link,../src -lfltk_forms -lfltk
+# LINKFLTKGL    = -L../src -Wl,-rpath-link,../src -lfltk_gl -lfltk
+# LINKFLTKIMG   = -L../src -Wl,-rpath-link,../src -lfltk_images -lfltk
+# LINKSHARED    = -L../src -Wl,-rpath-link,../src -lfltk_images -lfltk_forms -lfltk
+
 CPPUNITTEST = \
 	unittests.cxx \
 	unittest_about.cxx \
