develop #4

Merged
wt merged 4 commits from develop into main 2025-10-27 11:59:40 +00:00
3 changed files with 14 additions and 3 deletions
Showing only changes of commit faeb9ff052 - Show all commits

No files matched your search

+4 -1
View File
@@ -4,7 +4,10 @@ project(auth_service LANGUAGES C)
set(CMAKE_C_STANDARD 23)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(CMAKE_C_FLAGS "-ffunction-sections -fdata-sections")
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--gc-sections")
if (APPLE)
elseif (UNIX)
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--gc-sections")
endif()
include_directories(./src/lib/ ${SQLite3_INCLUDE_DIRS})
+5 -1
View File
@@ -1,6 +1,6 @@
CC = gcc
CFLAGS = -Wall -g -std=gnu2x -DMG_TLS=MG_TLS_OPENSSL -ffunction-sections -fdata-sections
LDFLAGS = -Wl,--gc-sections
LDFLAGS =
INCLUDES = -I./src/lib -I./src
SRCS = $(wildcard src/lib/*.c src/file_db/*.c src/*.c)
OBJS = $(SRCS:.c=.o)
@@ -11,6 +11,10 @@ LIBS = -lpthread -lcrypto -lssl
USE_SQLITE3 ?= 0
WERROR ?= 0
ifeq ($(shell uname), Linux)
LDFLAGS += -Wl,--gc-sections
endif
ifeq ($(USE_SQLITE3), 1)
CFLAGS += -DUSE_SQLITE3
LIBS += -lsqlite3
+5 -1
View File
@@ -2,7 +2,11 @@ project('auth_service', 'c', default_options: ['c_std=gnu2x'])
include_dirs = include_directories('src', 'src/lib')
deps = [dependency('openssl')]
extra_c_args = ['-ffunction-sections', '-fdata-sections']
extra_c_link_args = ['-Wl,--gc-sections']
extra_c_link_args = []
system = host_machine.system()
if system == 'linux'
extra_c_link_args += ['-Wl,--gc-sections']
endif
sqlite3_dep = dependency('sqlite3', required: false)
use_sqlite3 = get_option('use_sqlite3')