From 590e0c03a2df5cae6277b307c3f6f4021bf3b841 Mon Sep 17 00:00:00 2001 From: Glenn Hickey Date: Thu, 24 Sep 2026 15:11:34 -0400 Subject: [PATCH] Build against the current libbdsg: C++20, and link jansson The libbdsg-easy update for faster PackedGraph construction (#81) brought headers that use std::as_const and operator<=>, and a libbdsg.a that calls jansson. Every tool here includes those headers at -std=c++14, so a fresh clone of master stops in the first compile with "'as_const' is not a member of 'std'", and after that halRemoveDupes fails to link with undefined json_* references. Working copies that had installed the previous headers under deps/libbdsg-easy/include kept building, which is how it got merged. -std=c++20 (gcc 10+; the release containers are on 11 and 13), and -ljansson next to the other system libraries. The static release needs libjansson.a, which the -dev package carries. Verified from a fresh recursive clone: all seven tools build and the suite passes with them on PATH. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_013YWGkqE3ND862JF8QRZERV --- include.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include.mk b/include.mk index f0090c2..05d7da6 100644 --- a/include.mk +++ b/include.mk @@ -33,7 +33,7 @@ ifdef DISABLE_JEMALLOC endif CFLAGS += -I ${sonLibPath} -I ${halPath} -I ${halIncPath} -CXXFLAGS += -std=c++14 -I ${sonLibPath} -I ${halPath} -I ${halIncPath} -I ${libbdsgPath}/include -UNDEBUG +CXXFLAGS += -std=c++20 -I ${sonLibPath} -I ${halPath} -I ${halIncPath} -I ${libbdsgPath}/include -UNDEBUG basicLibs = ${halPath}/libHal.a ${sonLibPath}/stPinchesAndCacti.a ${sonLibPath}/sonLib.a ${sonLibPath}/cuTest.a ${libbdsgPath}/lib/libbdsg.a ${libbdsgPath}/lib/libhandlegraph.a ${libbdsgPath}/lib/libsdsl.a ${libbdsgPath}/lib/libdivsufsort.a ${libbdsgPath}/lib/libdivsufsort64.a ifeq (${jemalloc},on) basicLibs += ${jemallocPath}/lib/libjemalloc.a @@ -46,7 +46,7 @@ basicLibsDependencies := ${basicLibs} # hal's hdf5Filters.cpp implements custom HDF5 lz4/zstd codecs, so libHal.a now # carries LZ4_/ZSTD_ references. h5c++'s wrapper config doesn't pull these in, # so every binary linking libHal.a needs them spelled out. -basicLibs += -llz4 -lzstd +basicLibs += -llz4 -lzstd -ljansson # hdf5 compilation is done through its wrappers. # we can speficy our own (sonlib) compilers with these variables: