Upgrade libcxx and use c++ 23

1. Meet latest glaze's requirements, and upgrade it
2. Get rid of glaze_write_json to avoid using iostream, which made binary size increased. Use C methods instead.

Signed-off-by: GarfieldHan <2652609017@qq.com>
This commit is contained in:
GarfieldHan
2024-07-18 10:27:54 +08:00
parent 4d7257fcc7
commit 55cbe69ad5
7 changed files with 47 additions and 110 deletions

View File

@@ -1,6 +1,9 @@
cmake_minimum_required(VERSION 3.22.1)
cmake_minimum_required(VERSION 3.28)
project(sample)
find_package(cxx REQUIRED CONFIG)
link_libraries(cxx::cxx)
set(LINKER_FLAGS "-ffixed-x18 -Wl,--hash-style=both")
set(CXX_FLAGS "${CXX_FLAGS} -fno-exceptions -fno-rtti")
@@ -14,13 +17,12 @@ add_library(elf_util STATIC elf_util/elf_util.cpp)
add_library(my_logging STATIC logging/logging.cpp)
add_subdirectory(external)
link_libraries(cxx)
target_include_directories(my_logging PUBLIC logging/include)
target_include_directories(elf_util PUBLIC elf_util/include)
target_link_libraries(my_logging cxx log)
target_link_libraries(elf_util cxx lsplt my_logging)
target_link_libraries(my_logging log)
target_link_libraries(elf_util lsplt my_logging)
# libutils stub
add_library(utils SHARED binder/stub_utils.cpp)