From 1b590c2517fef110564943ed8a10edd11fa758b0 Mon Sep 17 00:00:00 2001 From: vnugent Date: Wed, 22 May 2024 17:49:57 -0400 Subject: Squashed commit of the following: commit 9a835fe12c9586ab8dd44d7c96fef4a2d6017e4b Author: vnugent Date: Fri May 17 18:27:03 2024 -0400 chore: Update mimmaloc v2.1.6, update fPIC & cleanup commit 3b7004b88acfc7f7baa3a8857a5a2f7cf3dd560e Author: vnugent Date: Fri May 17 16:03:28 2024 -0400 feat: Added ReadFileDataAsync function commit 9a964795757bf0da4dd7fcab15ad304f4ea3fdf1 Author: vnugent Date: Wed May 15 21:57:39 2024 -0400 refactor: Harden some argon2 password hashing commit 4035c838c1508af0aa7e767a97431a692958ce1c Author: vnugent Date: Sun May 12 16:55:32 2024 -0400 perf: Utils + http perf mods commit f4f0d4f74250257991c57bfae74c4852c7e1ae46 Author: vnugent Date: Thu May 2 15:22:53 2024 -0400 feat: Buff middleware handlers | | Added implicit support for middleware post processing of files before the filehandler closes the connection. Also cleaned up some project file stuff commit f0b7dca107659df1d7d4631fdbd2aae9d716d053 Merge: 8c4a45e 107b058 Author: vnugent Date: Sat Apr 20 12:24:05 2024 -0400 Merge branch 'main' into develop commit 8c4a45e384accf92b1b6d748530e8d46f7de40d6 Author: vnugent Date: Sat Apr 20 11:10:30 2024 -0400 refactor: Overhaul C libraries and fix builds commit 42ff77080d10b0fc9fecbbc46141e8e23a1d066a Author: vnugent Date: Sat Apr 20 00:45:57 2024 -0400 fix!: Middlware array, multiple cookie set, and cookie check commit 97e82b9d66f387f9e6d21d88ddc7a8ab8693149c Merge: 4ca5791 e07537a Author: vnugent Date: Tue Apr 2 13:34:22 2024 -0400 Merge branch 'main' into develop commit 4ca5791ed67b9834bdbd010206b30373e4705e9b Author: vnugent Date: Tue Apr 2 13:32:12 2024 -0400 fix: Missed ! on null pointer check commit 9b4036377c52200c6488c98180d69a0e63321f97 Author: vnugent Date: Tue Apr 2 13:22:29 2024 -0400 fix: Fix _In_ macro for compression public api commit 53a7b4b5c5b67b4a4e06e1d9098cac4bcd6afd7c Merge: 448a93b 21130c8 Author: vnugent Date: Sun Mar 31 17:01:15 2024 -0400 Merge branch 'main' into develop commit 448a93bb1d18d032087afe2476ffccb98634a54c Author: vnugent Date: Sun Mar 31 16:56:51 2024 -0400 ci: fix third-party dir cleanup commit 9afed1427472da1ea13079f98dbe27339e55ee7d Author: vnugent Date: Sun Mar 31 16:43:15 2024 -0400 perf: Deprecate unsafememoryhandle span extensions commit 3ff90da4f02af47ea6d233fdd4445337ebe36452 Author: vnugent Date: Sat Mar 30 21:36:18 2024 -0400 refactor: Updates, advanced tracing, http optimizations commit 8d6b79b5ae309b36f265ba81529bcef8bfcd7414 Merge: 6c1667b 5585915 Author: vnugent Date: Sun Mar 24 21:01:31 2024 -0400 Merge branch 'main' into develop commit 6c1667be23597513537f8190e2f55d65eb9b7c7a Author: vnugent Date: Fri Mar 22 12:01:53 2024 -0400 refactor: Overhauled native library loading and lazy init commit ebf688f2f974295beabf7b5def7e6f6f150551d0 Author: vnugent Date: Wed Mar 20 22:16:17 2024 -0400 refactor: Update compression header files and macros + Ci build commit 9c7b564911080ccd5cbbb9851a0757b05e1e9047 Author: vnugent Date: Tue Mar 19 21:54:49 2024 -0400 refactor: JWK overhaul & add length getter to FileUpload commit 6d8c3444e09561e5957491b3cc1ae858e0abdd14 Author: vnugent Date: Mon Mar 18 16:13:20 2024 -0400 feat: Add FNV1a software checksum and basic correction tests commit 00d182088cecefc08ca80b1faee9bed3f215f40b Author: vnugent Date: Fri Mar 15 01:05:27 2024 -0400 chore: #6 Use utils filewatcher instead of built-in commit d513c10d9895c6693519ef1d459c6a5a76929436 Author: vnugent Date: Sun Mar 10 21:58:14 2024 -0400 source tree project location updated --- lib/Net.Compression/vnlib_compress/CMakeLists.txt | 52 +++++++++++------------ lib/Net.Compression/vnlib_compress/Taskfile.yaml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) (limited to 'lib/Net.Compression/vnlib_compress') diff --git a/lib/Net.Compression/vnlib_compress/CMakeLists.txt b/lib/Net.Compression/vnlib_compress/CMakeLists.txt index c3eb723..0004c60 100644 --- a/lib/Net.Compression/vnlib_compress/CMakeLists.txt +++ b/lib/Net.Compression/vnlib_compress/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.10) project(vnlib_compress C) -set(CMAKE_PROJECT_NAME "vnlib_compress") +set(_COMP_PROJ_NAME "vnlib_compress") #set options for enable botli and zlib option(ENABLE_BROTLI "Enable brotli compression" ON) @@ -39,7 +39,7 @@ if(ENABLE_BROTLI) FetchContent_Declare( lib_brotli GIT_REPOSITORY https://github.com/google/brotli.git - GIT_TAG 1b3a5ccb6e7b9384b741437532f4dae0730c61f2 + GIT_TAG 04388304a6f8181cc1f022cc9e95dbb3bfe829a3 GIT_PROGRESS TRUE ) @@ -95,38 +95,36 @@ if(ENABLE_RPMALLOC) add_compile_definitions(VNLIB_CUSTOM_MALLOC_ENABLE) endif() - -#Setup the compiler options -set(CMAKE_C_STANDARD_REQUIRED ON) -set(CMAKE_POSITION_INDEPENDENT_CODE ON) #enable position independent code (for shared libraries with exports) - ############################### # # CONFIGURE LIBRARY BUILD # ############################### +set(CMAKE_C_STANDARD_REQUIRED ON) + if(COMPRESS_BUILD_SHARED) - set(TARGET_NAME ${CMAKE_PROJECT_NAME}) - add_library(${TARGET_NAME} SHARED ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS}) + add_library(${_COMP_PROJ_NAME} SHARED ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS}) + #enable position independent code (for shared libraries with exports) + set_target_properties(${_COMP_PROJ_NAME} PROPERTIES POSITION_INDEPENDENT_CODE ON) else() - set(TARGET_NAME ${CMAKE_PROJECT_NAME}_static) - add_library(${TARGET_NAME} STATIC ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS}) + set(_COMP_PROJ_NAME ${_COMP_PROJ_NAME}_static) #append static to the name + add_library(${_COMP_PROJ_NAME} STATIC ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS}) endif() -target_compile_features(${TARGET_NAME} PRIVATE c_std_90) #force compiler to use c90 standard for library +target_compile_features(${_COMP_PROJ_NAME} PRIVATE c_std_90) #force compiler to use c90 standard for library #if on unix lib will be appended, so we can adjust if(UNIX) - set_target_properties(${TARGET_NAME} PROPERTIES OUTPUT_NAME vn_compress) + set_target_properties(${_COMP_PROJ_NAME} PROPERTIES OUTPUT_NAME vn_compress) endif() #since were buildiing in tree, set the export defintiions -target_compile_definitions(${TARGET_NAME} PRIVATE VNLIB_EXPORTING) +target_compile_definitions(${_COMP_PROJ_NAME} PRIVATE VNLIB_COMPRESS_EXPORTING) if(ENABLE_BROTLI) #link the encoder-only library to the main project - target_link_libraries(${TARGET_NAME} PRIVATE brotlienc) + target_link_libraries(${_COMP_PROJ_NAME} PRIVATE brotlienc) endif() if(ENABLE_ZLIB) @@ -135,22 +133,22 @@ if(ENABLE_ZLIB) target_compile_definitions(zlib PRIVATE HAS_SSE42 PRIVATE HAS_SSE2) endif() - target_link_libraries(${TARGET_NAME} PRIVATE zlib) + target_link_libraries(${_COMP_PROJ_NAME} PRIVATE zlib) endif() #link rpmalloc to the main project if(ENABLE_RPMALLOC) - target_link_libraries(${TARGET_NAME} PRIVATE vnlib_rpmalloc_static) - add_dependencies(${TARGET_NAME} vnlib_rpmalloc_static) + target_link_libraries(${_COMP_PROJ_NAME} PRIVATE vnlib_rpmalloc_static) + add_dependencies(${_COMP_PROJ_NAME} vnlib_rpmalloc_static) #Include the nativeheap api header - target_include_directories(${TARGET_NAME} PRIVATE ../../Utils.Memory/vnlib_rpmalloc/) + target_include_directories(${_COMP_PROJ_NAME} PRIVATE ../../Utils.Memory/vnlib_rpmalloc/) endif() #setup flags for windows compilation if(MSVC) target_compile_options( - ${TARGET_NAME} + ${_COMP_PROJ_NAME} PRIVATE /Qspectre @@ -173,7 +171,7 @@ if(MSVC) #set build macros target_compile_definitions( - ${TARGET_NAME} + ${_COMP_PROJ_NAME} PRIVATE $<$:DEBUG> @@ -184,7 +182,7 @@ if(MSVC) elseif(CMAKE_COMPILER_IS_GNUCC) target_compile_options( - ${TARGET_NAME} + ${_COMP_PROJ_NAME} PRIVATE -Wextra @@ -194,7 +192,7 @@ elseif(CMAKE_COMPILER_IS_GNUCC) #enable debug compiler options if(build_type STREQUAL "debug") target_compile_options( - ${TARGET_NAME} + ${_COMP_PROJ_NAME} PRIVATE -g #enable debugger info @@ -204,7 +202,7 @@ elseif(CMAKE_COMPILER_IS_GNUCC) -pedantic #enable pedantic mode ) - target_compile_definitions(${TARGET_NAME} PRIVATE DEBUG) + target_compile_definitions(${_COMP_PROJ_NAME} PRIVATE DEBUG) endif() @@ -214,11 +212,13 @@ endif() if(NATIVE_HEAP_LIB_PATH) + message(STATUS "Linking native heap library to the main project found at ${NATIVE_HEAP_LIB_PATH}") + #Include the nativeheap api header include_directories(${NATIVE_HEAP_INCLUDES}) #If manual heap linking is enabled, we need to link the native heap library - target_link_libraries(${TARGET_NAME} PRIVATE ${NATIVE_HEAP_LIB_PATH}) - target_compile_definitions(${TARGET_NAME} PRIVATE VNLIB_CUSTOM_MALLOC_ENABLE) #configure src + target_link_libraries(${_COMP_PROJ_NAME} PRIVATE ${NATIVE_HEAP_LIB_PATH}) + target_compile_definitions(${_COMP_PROJ_NAME} PRIVATE VNLIB_CUSTOM_MALLOC_ENABLE) #configure src endif() \ No newline at end of file diff --git a/lib/Net.Compression/vnlib_compress/Taskfile.yaml b/lib/Net.Compression/vnlib_compress/Taskfile.yaml index 4ddc464..f1d594e 100644 --- a/lib/Net.Compression/vnlib_compress/Taskfile.yaml +++ b/lib/Net.Compression/vnlib_compress/Taskfile.yaml @@ -17,7 +17,7 @@ tasks: cmds: - cmd: echo "Building {{.PROJECT_NAME}}" silent: true - - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release {{.CMAKE_ARGS}} + - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release {{.CLI_ARGS}} - cmake --build build/ --config Release #called by ci pipline to build the winx64 project -- cgit