From: Maria Sfiraiala Date: Sun, 30 Oct 2022 18:22:23 +0000 (+0200) Subject: patches: Define strtof_l and strtod_l in locale X-Git-Tag: RELEASE-0.11.0~3 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=30e1eb4c9f8a2f87b533058ab1c3cc25fbc3edd4;p=unikraft%2Flibs%2Flibcxx.git patches: Define strtof_l and strtod_l in locale When compiled for Aarch64, apps using libcxx fail due to strtof_l and strtod_l not being defined in include/locale. This commit adds a patch which includes the header that contains the definitions in include/locale. It also modifies Makefile.uk to add the file in the build process. Signed-off-by: Maria Sfiraiala Reviewed-by: Maria Sfiraiala Reviewed-by: Razvan Deaconescu Approved-by: Razvan Deaconescu Tested-by: Unikraft CI GitHub-Closes: #10 --- diff --git a/Makefile.uk b/Makefile.uk index e185a60..d24341d 100644 --- a/Makefile.uk +++ b/Makefile.uk @@ -89,6 +89,8 @@ CXXINCLUDES-$(CONFIG_LIBCXX) += -I$(LIBCXX_SRC)/utils ifeq ($(CONFIG_LIBMUSL),y) CINCLUDES-$(CONFIG_LIBCXX) += -I$(LIBCXX_SRC)/include/support/musl CXXINCLUDES-$(CONFIG_LIBCXX) += -I$(LIBCXX_SRC)/include/support/musl +CINCLUDES-$(CONFIG_LIBCXX) += -I$(LIBCXX_SRC)/include/support/xlocale +CXXINCLUDES-$(CONFIG_LIBCXX) += -I$(LIBCXX_SRC)/include/support/xlocale endif ################################################################################ diff --git a/patches/0009-Add-strtof_l-strtod_l-header.patch b/patches/0009-Add-strtof_l-strtod_l-header.patch new file mode 100644 index 0000000..7d7f829 --- /dev/null +++ b/patches/0009-Add-strtof_l-strtod_l-header.patch @@ -0,0 +1,23 @@ +From c924cd52b45e2ab32368ca011a8f51a3e561d088 Mon Sep 17 00:00:00 2001 +From: Maria Sfiraiala +Date: Sun, 30 Oct 2022 20:00:39 +0200 +Subject: [PATCH] Add strtof_l, strtod_l header + +Signed-off-by: Maria Sfiraiala +--- +diff --git a/include/locale b/include/locale +index c9ec7c36f582..9068f88117a7 100644 +--- a/include/locale ++++ b/include/locale +@@ -817,6 +817,8 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end, + return 0; + } + ++#include <__strtonum_fallback.h> ++ + template + _LIBCPP_INLINE_VISIBILITY + _Tp __do_strtod(const char* __a, char** __p2); +-- +2.25.1 +