Kicad 9 - problem with compiling in Linux

I got an error while compiling Kicad 9.0 in Slackware Linux. Versions 8.0.9 and previous went fine.

[ 10%] Building CXX object common/CMakeFiles/kicommon.dir/lset.cpp.o
[ 11%] Building CXX object common/CMakeFiles/kicommon.dir/markup_parser.cpp.o
[ 11%] Building CXX object common/CMakeFiles/kicommon.dir/netclass.cpp.o
In file included from /usr/include/absl/strings/string_view.h:43,
from /usr/include/absl/log/internal/vlog_config.h:39,
from /usr/include/absl/log/absl_vlog_is_on.h:63,
from /usr/include/absl/log/internal/log_impl.h:18,
from /usr/include/absl/log/absl_log.h:36,
from /usr/include/google/protobuf/io/coded_stream.h:107,
from /usr/include/google/protobuf/any.pb.h:20,
from /tmp/SBo/kicad-9.0.0/include/api/api_utils.h:25,
from /tmp/SBo/kicad-9.0.0/common/netclass.cpp:31:
/usr/include/absl/functional/internal/any_invocable.h: In static member function ‘static ReturnType absl::lts_20250127::internal_any_invocable::Impl<ReturnType(P …)>::InvokedAfterMove(absl::lts_20250127::internal_any_invocable::TypeErasedState*, absl::lts_20250127::internal_any_invocable::ForwardedParameterType

…)’:
/usr/include/absl/functional/internal/any_invocable.h:868:1: internal compiler error: Segmentation fault
868 | ABSL_INTERNAL_ANY_INVOCABLE_IMPL(, , &);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
0x1ff4db8 internal_error(char const*, …)
???:0
0x7902f0 build_conditional_expr(op_location_t const&, tree_node*, tree_node*, tree_node*, int)
???:0
0x977d62 build_x_conditional_expr(unsigned int, tree_node*, tree_node*, tree_node*, int)
???:0
0x8fba89 c_parse_file()
???:0
0x9f7d01 c_common_parse_file()
???:0
Please submit a full bug report, with preprocessed source (by using -freport-bug).
Please include the complete backtrace with any bug report.
See https://gcc.gnu.org/bugs/ for instructions.
make[2]: *** [common/CMakeFiles/kicommon.dir/build.make:1742: common/CMakeFiles/kicommon.dir/netclass.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:4375: common/CMakeFiles/kicommon.dir/all] Error 2
make: *** [Makefile:166: all] Error 2
bash-5.2#

Looks like your toolchain has a bug with your version of abseil (a dependency of protobuf, which is a dependency of KiCad)

Same problem with the “any_invocable.h” header resulting in “internal compiler error” seg fault on Slackware Current.

Tried compiling against upgraded protobuf-30 without any luck.

Any ideas out there?

I would recommend asking in some Slackware communities rather than here – I doubt many people here use that distro, and most people here don’t build KiCad from source. Protobuf (and Abseil) are not KiCad-specific dependencies; they are needed by a range of software. So it is somewhat likely that if Protobuf has some trouble compiling on Slackware you can find help about it in some community that knows about the details more.

A segfault of the compiler points to other concerns…
The -j# too high for the amount of RAM you have, etc…