Build failure on MinGW GCC 13.1
Hi! I get a failure while building on MSYS2 MINGW64:
[2/1019] Building CXX object src/3rdparty/2geom/src/2geom/CMakeFiles/2geom.dir/bezier.cpp.obj
FAILED: src/3rdparty/2geom/src/2geom/CMakeFiles/2geom.dir/bezier.cpp.obj
D:\msys64\mingw64\bin\c++.exe -DBOOST_STACKTRACE_USE_WINDBG -DGPL_TAINT -DHAVE_CAIRO -DHAVE_CONFIG_H -DHAVE_GSL -DHAVE_SINCOS -DWITH_CSSBLEND -DWITH_MESH -DWITH_SVG2 -D_2geom_EXPORTS -D_DLL -D_MT -ID:/inkscape-
mingw-dbg/src/3rdparty/2geom/src/2geom -ID:/inkscape/src/3rdparty/2geom/src/2geom -ID:/inkscape -ID:/inkscape/src -ID:/inkscape-mingw-dbg/include -ID:/inkscape/src/3rdparty/2geom/include -ID:/inkscape/src/3rdpa
rty/2geom/include/2geom -isystem D:/msys64/mingw64/include/harfbuzz -isystem D:/msys64/mingw64/include/freetype2 -isystem D:/msys64/mingw64/include/libpng16 -isystem D:/msys64/mingw64/include/glib-2.0 -isystem
D:/msys64/mingw64/lib/glib-2.0/include -isystem D:/msys64/mingw64/include/pango-1.0 -isystem D:/msys64/mingw64/include/fribidi -isystem D:/msys64/mingw64/include/cairo -isystem D:/msys64/mingw64/include/pixman-
1 -isystem /mingw64/include -isystem D:/msys64/mingw64/include/libsoup-2.4 -isystem D:/msys64/mingw64/include/libxml2 -isystem D:/msys64/mingw64/include/poppler -isystem D:/msys64/mingw64/include/libwpg-0.3 -is
ystem D:/msys64/mingw64/include/librevenge-0.0 -isystem D:/msys64/mingw64/include/libwpd-0.10 -isystem D:/msys64/mingw64/include/libvisio-0.1 -isystem D:/msys64/mingw64/include/libcdr-0.1 -isystem D:/msys64/min
gw64/include/gtkmm-3.0 -isystem D:/msys64/mingw64/lib/gtkmm-3.0/include -isystem D:/msys64/mingw64/include/gtk-3.0 -isystem D:/msys64/mingw64/include/sigc++-2.0 -isystem D:/msys64/mingw64/lib/sigc++-2.0/include
-isystem D:/msys64/mingw64/include/giomm-2.4 -isystem D:/msys64/mingw64/lib/giomm-2.4/include -isystem D:/msys64/mingw64/include/cairomm-1.0 -isystem D:/msys64/mingw64/lib/cairomm-1.0/include -isystem D:/msys6
4/mingw64/include/pangomm-1.4 -isystem D:/msys64/mingw64/lib/pangomm-1.4/include -isystem D:/msys64/mingw64/include/gdk-pixbuf-2.0 -isystem D:/msys64/mingw64/include/atkmm-1.6 -isystem D:/msys64/mingw64/lib/atk
mm-1.6/include -isystem D:/msys64/mingw64/include/gdkmm-3.0 -isystem D:/msys64/mingw64/lib/gdkmm-3.0/include -isystem D:/msys64/mingw64/include/glibmm-2.4 -isystem D:/msys64/mingw64/lib/glibmm-2.4/include -isys
tem D:/msys64/mingw64/include/atk-1.0 -isystem D:/msys64/mingw64/include/webp -isystem D:/msys64/mingw64/include/gspell-1 -isystem D:/msys64/mingw64/include/enchant-2 -isystem D:/msys64/mingw64/include/gtksourc
eview-4 -isystem D:/msys64/mingw64/include/GraphicsMagick -DG_DISABLE_ASSERT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -DGLIBMM_DISABLE_DEPRECATED -DGTKMM_DISABLE_DEPRECATED -DGDKMM_DISABLE_DEPRECATED -DGTK_DISABLE
_DEPRECATED -DGDK_DISABLE_DEPRECATED -fstack-protector-strong -Werror=format -Werror=format-security -Werror=ignored-qualifiers -Werror=return-type -Wno-switch -Wmisleading-indentation -Wstrict-null-sentinel -m
ms-bitfields -mwindows -mthreads -m64 -DLIBDEFLATE_DLL -fopenmp -DSIGCXX_DISABLE_DEPRECATED -O3 -DNDEBUG -std=c++17 -fdiagnostics-color -Wall -Wformat-security -Woverloaded-virtual -Wpointer-arith -Werror=retur
n-type -MD -MT src/3rdparty/2geom/src/2geom/CMakeFiles/2geom.dir/bezier.cpp.obj -MF src\3rdparty\2geom\src\2geom\CMakeFiles\2geom.dir\bezier.cpp.obj.d -o src/3rdparty/2geom/src/2geom/CMakeFiles/2geom.dir/bezier
.cpp.obj -c D:/inkscape/src/3rdparty/2geom/src/2geom/bezier.cpp
In file included from D:/msys64/mingw64/include/c++/13.1.0/algorithm:60,
from D:/inkscape/src/3rdparty/2geom/include/2geom/bezier.h:41,
from D:/inkscape/src/3rdparty/2geom/src/2geom/bezier.cpp:38:
In static member function 'static _Up* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(_Tp*, _Tp*, _Up*) [with _Tp = const double; _Up = double; bool _IsMove = false]',
inlined from '_OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:506:30,
inlined from '_OI std::__copy_move_a1(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:533:42,
inlined from '_OI std::__copy_move_a(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:540:31,
inlined from '_OI std::copy(_II, _II, _OI) [with _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:633:7,
inlined from 'T Geom::casteljau_subdivision(double, const T*, T*, T*, unsigned int) [with T = double]' at D:/inkscape/src/3rdparty/2geom/include/2geom/bezier.h:89:22,
inlined from 'void Geom::Bezier::subdivide(Geom::Coord, Geom::Bezier*, Geom::Bezier*) const' at D:/inkscape/src/3rdparty/2geom/src/2geom/bezier.cpp:87:38:
D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:437:30: error: argument 1 null where non-null expected [-Werror=nonnull]
437 | __builtin_memmove(__result, __first, sizeof(_Tp) * _Num);
| ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:437:30: note: in a call to built-in function 'void* __builtin_memmove(void*, const void*, long long unsigned int)'
In static member function 'static _Up* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(_Tp*, _Tp*, _Up*) [with _Tp = const double; _Up = double; bool _IsMove = false]',
inlined from '_OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:506:30,
inlined from '_OI std::__copy_move_a1(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:533:42,
inlined from '_OI std::__copy_move_a(_II, _II, _OI) [with bool _IsMove = false; _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:540:31,
inlined from '_OI std::copy(_II, _II, _OI) [with _II = const double*; _OI = double*]' at D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:633:7,
inlined from 'T Geom::casteljau_subdivision(double, const T*, T*, T*, unsigned int) [with T = double]' at D:/inkscape/src/3rdparty/2geom/include/2geom/bezier.h:89:22,
inlined from 'Geom::Bezier Geom::portion(const Bezier&, double, double)' at D:/inkscape/src/3rdparty/2geom/src/2geom/bezier.cpp:262:38:
D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:437:30: error: argument 1 null where non-null expected [-Werror=nonnull]
437 | __builtin_memmove(__result, __first, sizeof(_Tp) * _Num);
| ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
D:/msys64/mingw64/include/c++/13.1.0/bits/stl_algobase.h:437:30: note: in a call to built-in function 'void* __builtin_memmove(void*, const void*, long long unsigned int)'
cc1plus.exe: some warnings being treated as errors
[11/1019] Building CXX object src/3rdparty/2geom/src/2geom/CMakeFiles/2geom.dir/elliptical-arc.cpp.obj
ninja: build stopped: subcommand failed.