Fix cmake build.

This commit is contained in:
Alex Shinn 2024-05-18 05:45:45 +09:00
parent 017e4b6990
commit 3b6be9d60c
2 changed files with 5 additions and 0 deletions

View file

@ -1,5 +1,6 @@
#define sexp_so_extension "@CMAKE_SHARED_LIBRARY_SUFFIX@" #define sexp_so_extension "@CMAKE_SHARED_LIBRARY_SUFFIX@"
#define sexp_default_module_path "@default_module_path@" #define sexp_default_module_path "@default_module_path@"
#define sexp_platform "@platform@" #define sexp_platform "@platform@"
#define sexp_architecture "@CMAKE_SYSTEM_PROCESSOR@"
#define sexp_version "@CMAKE_PROJECT_VERSION@" #define sexp_version "@CMAKE_PROJECT_VERSION@"
#define sexp_release_name "@release@" #define sexp_release_name "@release@"

4
sexp.c
View file

@ -460,8 +460,12 @@ sexp sexp_finalize_c_type (sexp ctx, sexp self, sexp_sint_t n, sexp obj) {
/****************************** contexts ******************************/ /****************************** contexts ******************************/
static const char* sexp_initial_features[] = { static const char* sexp_initial_features[] = {
#ifdef sexp_architecture
sexp_architecture, sexp_architecture,
#endif
#ifdef sexp_platform
sexp_platform, sexp_platform,
#endif
#if SEXP_BSD #if SEXP_BSD
"bsd", "bsd",
#endif #endif