1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 05:07:45 +00:00

Revert "AK: Don't demangle in serenity :("

This reverts commit 4361a50225.
This commit is contained in:
Andreas Kling 2020-05-20 14:23:32 +02:00
parent ef776c1e68
commit 8876bfc3ac
2 changed files with 3 additions and 4 deletions

View file

@ -29,7 +29,7 @@
#include <AK/String.h> #include <AK/String.h>
#include <AK/StringView.h> #include <AK/StringView.h>
#ifndef __serenity__ #ifndef BUILDING_SERENITY_TOOLCHAIN
# include <cxxabi.h> # include <cxxabi.h>
#endif #endif
@ -37,10 +37,9 @@ namespace AK {
inline String demangle(const StringView& name) inline String demangle(const StringView& name)
{ {
#ifdef __serenity__ #ifdef BUILDING_SERENITY_TOOLCHAIN
return name; return name;
#else #else
// FIXME: Implement __cxa_demangle in serenity
int status = 0; int status = 0;
auto* demangled_name = abi::__cxa_demangle(name.to_string().characters(), nullptr, nullptr, &status); auto* demangled_name = abi::__cxa_demangle(name.to_string().characters(), nullptr, nullptr, &status);
auto string = String(status == 0 ? demangled_name : name); auto string = String(status == 0 ? demangled_name : name);

View file

@ -228,7 +228,7 @@ pushd "$DIR/Build/"
echo "XXX serenity libc and libm" echo "XXX serenity libc and libm"
mkdir -p "$BUILD" mkdir -p "$BUILD"
pushd "$BUILD" pushd "$BUILD"
cmake .. CXXFLAGS="-DBUILDING_SERENITY_TOOLCHAIN" cmake ..
"$MAKE" LibC "$MAKE" LibC
install -D Libraries/LibC/libc.a Libraries/LibM/libm.a Root/usr/lib/ install -D Libraries/LibC/libc.a Libraries/LibM/libm.a Root/usr/lib/
SRC_ROOT=$(realpath "$DIR"/..) SRC_ROOT=$(realpath "$DIR"/..)