Correct build for wsl2
This commit is contained in:
@@ -12,6 +12,9 @@ if (BUILD_FOR_JLV135)
|
|||||||
# Настройки компиляции
|
# Настройки компиляции
|
||||||
set(CMAKE_C_FLAGS "-Os -fdata-sections -ffunction-sections -mno-unaligned-access")
|
set(CMAKE_C_FLAGS "-Os -fdata-sections -ffunction-sections -mno-unaligned-access")
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--gc-sections")
|
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--gc-sections")
|
||||||
|
else()
|
||||||
|
# Для разработки/тестирования на обычной системе используем файловую систему
|
||||||
|
add_compile_definitions(JL_CONFIG_USE_FILE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Создание исполняемого файла
|
# Создание исполняемого файла
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#ifndef JL_CONFIG_USE_FILE
|
#ifdef JL_CONFIG_USE_FILE
|
||||||
static const char* jl_config_path = "./";
|
static const char* jl_config_path = "./";
|
||||||
void
|
void
|
||||||
jl_config_load(const char *name, void *def, size_t size)
|
jl_config_load(const char *name, void *def, size_t size)
|
||||||
|
|||||||
Reference in New Issue
Block a user