mirror of
https://github.com/pocketpy/pocketpy
synced 2025-10-22 20:40:18 +00:00
* Add cjson module * Create structure for cjson module * Implemenet loads function * Convert cJsonBool to python boolean * Implement dumps function * Convert json bool and null to python Bool and None * necessary changes of project structure * Update amalgamate.py * Support non-dictionary json objects (list, tuple, string, number, bool, null) * Fix tests * fix CI * fix CI * Convert python to cJson and then to string * Delete cJSON object after use --------- Co-authored-by: Mahbub Alam <alam.mahbub214@gmail.com> Co-authored-by: blueloveTH <blueloveth@foxmail.com>
21 lines
462 B
CMake
21 lines
462 B
CMake
cmake_minimum_required(VERSION 3.10)
|
|
|
|
project(cjson)
|
|
|
|
set(CMAKE_C_STANDARD 11)
|
|
set(CMAKE_CXX_STANDARD 17)
|
|
|
|
include_directories(${CMAKE_CURRENT_LIST_DIR}/include)
|
|
include_directories(${CMAKE_CURRENT_LIST_DIR}/../pocketpy/include)
|
|
|
|
set(CMAKE_C_FLAGS_RELEASE "-O2")
|
|
set(CMAKE_CXX_FLAGS_RELEASE "-O2")
|
|
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
|
|
|
add_library(
|
|
cjson
|
|
STATIC
|
|
${CMAKE_CURRENT_LIST_DIR}/src/cJSON.c
|
|
${CMAKE_CURRENT_LIST_DIR}/src/cJSONw.cpp
|
|
)
|