genode/repos/base-linux/lib/mk/lx_hybrid.mk
Norman Feske b4a746bc89 base/error.h: add raise() interface
The new 'raise' function can be used instead of 'throw' to keep the
framework headers void of C++ throw statements, which would otherwise
prevent the compilation of the headers with -fno-exceptions.

In the presence of the C++ runtime, the 'raise' implementation reflects
the supplied error value(s) as C++ exceptions of the appropriate type.
In the (future) optional absence of the C++ runtime, 'raise' remains
unresolved, which then gives us the assurance that the binary contains
no code path leading to 'raise', all error conditions must have been
covered in other ways than 'raise'.

For this reason, 'Genode::raise' is not provided by the base library
but the cxx library (C++ runtime). Once we allow components to opt out
of the cxx library, 'raise' will automatically become unresolved for
those strict components.

Issue #5245
2025-04-10 14:55:21 +02:00

19 lines
619 B
Makefile

SRC_CC += lx_hybrid.cc new_delete.cc capability_space.cc
SRC_CC += signal_transmitter.cc signal.cc raise.cc
SRC_C += libgcc.c
# new_delete.cc uses libsupc++ which means we need to access
# its include directory.
STDINC := yes
vpath raise.cc $(BASE_DIR)/src/lib/cxx
vpath new_delete.cc $(BASE_DIR)/src/lib/cxx
vpath lx_hybrid.cc $(REP_DIR)/src/lib/lx_hybrid
vpath libgcc.c $(REP_DIR)/src/lib/lx_hybrid
# add parts of the base library that are shared with core
LIBS += base-linux-common timeout
# non-core parts of the base library (except for the startup code)
include $(REP_DIR)/lib/mk/base-linux.inc