aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/Hashing.Portable/src/VNLib.Hashing.Portable.csproj2
-rw-r--r--lib/Net.Compression/VNLib.Net.Compression/VNLib.Net.Compression.csproj2
-rw-r--r--lib/Net.Compression/vnlib_compress/CMakeLists.txt17
-rw-r--r--lib/Net.Compression/vnlib_compress/Taskfile.yaml86
-rw-r--r--lib/Net.Compression/vnlib_compress/package.json2
-rw-r--r--lib/Net.Compression/vnlib_compress/src/compression.c (renamed from lib/Net.Compression/vnlib_compress/compression.c)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/compression.h (renamed from lib/Net.Compression/vnlib_compress/compression.h)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/feature_brotli.c (renamed from lib/Net.Compression/vnlib_compress/feature_brotli.c)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/feature_brotli.h (renamed from lib/Net.Compression/vnlib_compress/feature_brotli.h)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/feature_zlib.c (renamed from lib/Net.Compression/vnlib_compress/feature_zlib.c)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/feature_zlib.h (renamed from lib/Net.Compression/vnlib_compress/feature_zlib.h)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/util.h (renamed from lib/Net.Compression/vnlib_compress/util.h)0
-rw-r--r--lib/Net.Compression/vnlib_compress/src/vnlib_compress.vcxitems (renamed from lib/Net.Compression/vnlib_compress/vnlib_compress.vcxitems)5
-rw-r--r--lib/Net.Http/src/Core/TransportManager.cs4
-rw-r--r--lib/Net.Http/src/VNLib.Net.Http.csproj2
-rw-r--r--lib/Net.Messaging.FBM/src/VNLib.Net.Messaging.FBM.csproj2
-rw-r--r--lib/Net.Rest.Client/src/VNLib.Net.Rest.Client.csproj2
-rw-r--r--lib/Net.Transport.SimpleTCP/src/VNLib.Net.Transport.SimpleTCP.csproj2
-rw-r--r--lib/Plugins.Essentials.ServiceStack/src/VNLib.Plugins.Essentials.ServiceStack.csproj2
-rw-r--r--lib/Plugins.Essentials/src/VNLib.Plugins.Essentials.csproj2
-rw-r--r--lib/Plugins.PluginBase/src/VNLib.Plugins.PluginBase.csproj2
-rw-r--r--lib/Plugins.Runtime/src/VNLib.Plugins.Runtime.csproj2
-rw-r--r--lib/Plugins/src/VNLib.Plugins.csproj2
-rw-r--r--lib/Utils.Cryptography/argon2/.gitattributes10
-rw-r--r--lib/Utils.Cryptography/argon2/.gitignore22
-rw-r--r--lib/Utils.Cryptography/argon2/.travis.yml25
-rw-r--r--lib/Utils.Cryptography/argon2/Taskfile.yaml98
-rw-r--r--lib/Utils.Cryptography/argon2/appveyor.yml25
-rw-r--r--lib/Utils.Cryptography/argon2/argon2-specs.pdfbin459608 -> 0 bytes
-rw-r--r--lib/Utils.Cryptography/argon2/export.sh7
-rw-r--r--lib/Utils.Memory/NativeHeapApi/src/NativeHeapApi.h9
-rw-r--r--lib/Utils.Memory/vnlib_mimalloc/NativeHeapApi.h9
-rw-r--r--lib/Utils.Memory/vnlib_mimalloc/Taskfile.yaml129
-rw-r--r--lib/Utils.Memory/vnlib_mimalloc/build.readme.txt10
-rw-r--r--lib/Utils.Memory/vnlib_mimalloc/package.json6
-rw-r--r--lib/Utils.Memory/vnlib_rpmalloc/CMakeLists.txt9
-rw-r--r--lib/Utils.Memory/vnlib_rpmalloc/NativeHeapApi.h9
-rw-r--r--lib/Utils.Memory/vnlib_rpmalloc/Taskfile.yaml118
-rw-r--r--lib/Utils.Memory/vnlib_rpmalloc/build.readme.txt6
-rw-r--r--lib/Utils.Memory/vnlib_rpmalloc/package.json6
-rw-r--r--lib/Utils/src/VNLib.Utils.csproj2
41 files changed, 343 insertions, 293 deletions
diff --git a/lib/Hashing.Portable/src/VNLib.Hashing.Portable.csproj b/lib/Hashing.Portable/src/VNLib.Hashing.Portable.csproj
index da61ae1..a4afc35 100644
--- a/lib/Hashing.Portable/src/VNLib.Hashing.Portable.csproj
+++ b/lib/Hashing.Portable/src/VNLib.Hashing.Portable.csproj
@@ -22,7 +22,7 @@
<Company>Vaughn Nugent</Company>
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Hashing.Portable</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Hashing.Portable</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Net.Compression/VNLib.Net.Compression/VNLib.Net.Compression.csproj b/lib/Net.Compression/VNLib.Net.Compression/VNLib.Net.Compression.csproj
index c5b428e..2f49dda 100644
--- a/lib/Net.Compression/VNLib.Net.Compression/VNLib.Net.Compression.csproj
+++ b/lib/Net.Compression/VNLib.Net.Compression/VNLib.Net.Compression.csproj
@@ -24,7 +24,7 @@
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<Description>.NET/8.0 dynamically loadable managed wrapper library for loading vnlib_compress native library. It provides an implementation of the IHttpCompressorManager interface for use with the VNLib.Net.Http library and servers wishing to support dynamic response compression.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Compression</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Net.Compression</RepositoryUrl>
<PackageReadmeFile>readme.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Net.Compression/vnlib_compress/CMakeLists.txt b/lib/Net.Compression/vnlib_compress/CMakeLists.txt
index 6097a34..d0dbbb2 100644
--- a/lib/Net.Compression/vnlib_compress/CMakeLists.txt
+++ b/lib/Net.Compression/vnlib_compress/CMakeLists.txt
@@ -14,14 +14,13 @@ set(CMAKE_BUILD_TYPE "Release" CACHE STRING "The build configuration type")
string(TOLOWER ${CMAKE_BUILD_TYPE} build_type)
message(STATUS "Build type is '${build_type}'")
-#export all header files to the main project
-file(GLOB COMP_HEADERS *.h)
+include(FetchContent)
+
+#the compression source file is required, all other sources will be added
set(VNLIB_COMPRESS_SOURCES
- compression.c
+ src/compression.c
)
-include(FetchContent)
-
###############################
#
# DOWNLOAD DEPENDENCIES
@@ -50,7 +49,7 @@ if(ENABLE_BROTLI)
include_directories(${lib_brotli_SOURCE_DIR}/c/include)
#add the brotli source files to the project
- list(APPEND VNLIB_COMPRESS_SOURCES feature_brotli.c)
+ list(APPEND VNLIB_COMPRESS_SOURCES src/feature_brotli.c)
add_compile_definitions(VNLIB_COMPRESSOR_BROTLI_ENABLED)
endif()
@@ -77,7 +76,7 @@ if(ENABLE_ZLIB)
include_directories(${lib_cf_zlib_SOURCE_DIR})
#enable the feature code for zlib and add the source files
- list(APPEND VNLIB_COMPRESS_SOURCES feature_zlib.c)
+ list(APPEND VNLIB_COMPRESS_SOURCES src/feature_zlib.c)
add_compile_definitions(VNLIB_COMPRESSOR_ZLIB_ENABLED)
endif()
@@ -104,12 +103,12 @@ endif()
set(CMAKE_C_STANDARD_REQUIRED ON)
if(COMPRESS_BUILD_SHARED)
- add_library(${_COMP_PROJ_NAME} SHARED ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS})
+ add_library(${_COMP_PROJ_NAME} SHARED ${VNLIB_COMPRESS_SOURCES})
#enable position independent code (for shared libraries with exports)
set_target_properties(${_COMP_PROJ_NAME} PROPERTIES POSITION_INDEPENDENT_CODE ON)
else()
set(_COMP_PROJ_NAME ${_COMP_PROJ_NAME}_static) #append static to the name
- add_library(${_COMP_PROJ_NAME} STATIC ${VNLIB_COMPRESS_SOURCES} ${COMP_HEADERS})
+ add_library(${_COMP_PROJ_NAME} STATIC ${VNLIB_COMPRESS_SOURCES})
endif()
target_compile_features(${_COMP_PROJ_NAME} PRIVATE c_std_90) #force compiler to use c90 standard for library
diff --git a/lib/Net.Compression/vnlib_compress/Taskfile.yaml b/lib/Net.Compression/vnlib_compress/Taskfile.yaml
index f1d594e..2133c0b 100644
--- a/lib/Net.Compression/vnlib_compress/Taskfile.yaml
+++ b/lib/Net.Compression/vnlib_compress/Taskfile.yaml
@@ -15,9 +15,9 @@ tasks:
default:
cmds:
- - cmd: echo "Building {{.PROJECT_NAME}}"
+ - cmd: echo "Building {{ .PROJECT_NAME }}"
silent: true
- - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release {{.CLI_ARGS}}
+ - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release {{ .CLI_ARGS }}
- cmake --build build/ --config Release
#called by ci pipline to build the winx64 project
@@ -31,40 +31,88 @@ tasks:
- cmake -B./build -DCI_PRECOMPILE=ON -DENABLE_RPMALLOC=ON
#build for platform
- - cmake --build build/ --config Debug
- - cmake --build build/ --config Release
+ - cmake --build build/ --config debug
+ - cmake --build build/ --config release
#when build succeeds, archive the output into a tgz
postbuild_success:
+ cmds:
+ - cmd: powershell mkdir -Force 'bin/'
+ - task: pack_parallel
+
+ pack_parallel:
+ internal: true
vars:
#required files to include in tar
- TAR_FILES: "{{.PROJECT_NAME}}.dll {{.PROJECT_NAME}}.pdb {{.PROJECT_NAME}}.lib license.txt"
+ REL_TAR_FILES:
+ "{{ .PROJECT_NAME }}.dll
+ {{ .PROJECT_NAME }}.lib
+ compression.h
+ license.txt"
+ DEBUG_TAR_FILES:
+ "{{ .PROJECT_NAME }}.dll
+ {{ .PROJECT_NAME }}.pdb
+ {{ .PROJECT_NAME }}.lib
+ compression.h
+ license.txt"
+
+ deps:
+ - task: pack_source
+
+ - task: pack_artifacts
+ vars: { BUILD_MODE: 'debug', TAR_FILES: '{{ .DEBUG_TAR_FILES }}' }
+ - task: pack_artifacts
+ vars: { BUILD_MODE: 'release', TAR_FILES: '{{ .REL_TAR_FILES }}' }
+
+ #packs up the binary artifacts for distribution
+ pack_artifacts:
+ internal: true
+ deps:
+ - task: embed
+ vars: { TARGET: './build/{{ .BUILD_MODE }}' }
cmds:
- - cmd: powershell mkdir -Force './bin'
- #copy source code to target
- - cmd: powershell -Command "tar --exclude build/* --exclude .vs/* --exclude bin/* --exclude third-party/* -czf bin/src.tgz ."
-
- #copy license file to debug and release output
- - cmd: powershell -Command "cp ../LICENSE build/Debug/license.txt"
- - cmd: powershell -Command "cp ../LICENSE build/Release/license.txt"
+ - cmd: cd build/{{ .BUILD_MODE }} && tar -czf '../../bin/msvc-x64-{{ .BUILD_MODE }}-{{ .PROJECT_NAME }}.tgz' {{ .TAR_FILES }}
+
+ #add embeded resources to the binary output for distribution
+ embed:
+ internal: true
+ cmds:
+ - powershell cp ../LICENSE '{{ .TARGET }}/license.txt'
+ - powershell cp src/compression.h '{{ .TARGET }}/compression.h'
+
+ #packages source code for distribution
+ pack_source:
+ internal: true
+ vars:
+ EXCLUDES:
+
+ INCLUDES:
+ "src/*
+ LICENSE
+ CMakeLists.txt
+ Taskfile.yaml"
+
+ cmds:
+ - powershell cp ../LICENSE 'LICENSE' -Force
+ #just pack up current directory, excluding build, bin, and git directories
+ - tar {{ .EXCLUDES }} -czf 'bin/src.tgz' {{ .INCLUDES }}
+
+ - cmd: powershell rm LICENSE
- #create static-build archives
- - cd build/Debug && tar -czf ../../bin/msvc-x64-debug-{{.PROJECT_NAME}}.tgz {{.TAR_FILES}}
- - cd build/Release && tar -czf ../../bin/msvc-x64-release-{{.PROJECT_NAME}}.tgz {{.TAR_FILES}}
-#Remove the output dirs on clean
+ #Remove the output dirs on clean
clean:
ignore_error: true
cmds:
- for: [ bin/, build/ ]
- cmd: powershell Remove-Item -Recurse '{{.ITEM}}' -Force
+ cmd: powershell rm -Recurse '{{ .ITEM }}' -Force
clean-third-party:
internal: false
ignore_error: true
cmds:
- cmd: powershell rm -Recurse -Force 'build/_deps/'
- platforms: [windows]
+ platforms: [ windows ]
- cmd: rm -rf 'build/_deps/'
- platforms: [linux, darwin]
+ platforms: [ linux, darwin ]
\ No newline at end of file
diff --git a/lib/Net.Compression/vnlib_compress/package.json b/lib/Net.Compression/vnlib_compress/package.json
index 6373511..bd6a815 100644
--- a/lib/Net.Compression/vnlib_compress/package.json
+++ b/lib/Net.Compression/vnlib_compress/package.json
@@ -3,7 +3,7 @@
"version": "0.1.0",
"author": "Vaughn Nugent",
"description": "A CMake cross platform native data compression library, provides brotli and zlib compressors in a single stream api",
- "copyright": "Copyright \u00A9 2023 Vaughn Nugent",
+ "copyright": "Copyright \u00A9 2024 Vaughn Nugent",
"company": "Vaughn Nugent",
"repository": "https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Compression/vnlib_compress",
"output_dir": "bin"
diff --git a/lib/Net.Compression/vnlib_compress/compression.c b/lib/Net.Compression/vnlib_compress/src/compression.c
index 0cba998..0cba998 100644
--- a/lib/Net.Compression/vnlib_compress/compression.c
+++ b/lib/Net.Compression/vnlib_compress/src/compression.c
diff --git a/lib/Net.Compression/vnlib_compress/compression.h b/lib/Net.Compression/vnlib_compress/src/compression.h
index 3d03145..3d03145 100644
--- a/lib/Net.Compression/vnlib_compress/compression.h
+++ b/lib/Net.Compression/vnlib_compress/src/compression.h
diff --git a/lib/Net.Compression/vnlib_compress/feature_brotli.c b/lib/Net.Compression/vnlib_compress/src/feature_brotli.c
index 361c61a..361c61a 100644
--- a/lib/Net.Compression/vnlib_compress/feature_brotli.c
+++ b/lib/Net.Compression/vnlib_compress/src/feature_brotli.c
diff --git a/lib/Net.Compression/vnlib_compress/feature_brotli.h b/lib/Net.Compression/vnlib_compress/src/feature_brotli.h
index 1f2090b..1f2090b 100644
--- a/lib/Net.Compression/vnlib_compress/feature_brotli.h
+++ b/lib/Net.Compression/vnlib_compress/src/feature_brotli.h
diff --git a/lib/Net.Compression/vnlib_compress/feature_zlib.c b/lib/Net.Compression/vnlib_compress/src/feature_zlib.c
index a07f106..a07f106 100644
--- a/lib/Net.Compression/vnlib_compress/feature_zlib.c
+++ b/lib/Net.Compression/vnlib_compress/src/feature_zlib.c
diff --git a/lib/Net.Compression/vnlib_compress/feature_zlib.h b/lib/Net.Compression/vnlib_compress/src/feature_zlib.h
index 2544d25..2544d25 100644
--- a/lib/Net.Compression/vnlib_compress/feature_zlib.h
+++ b/lib/Net.Compression/vnlib_compress/src/feature_zlib.h
diff --git a/lib/Net.Compression/vnlib_compress/util.h b/lib/Net.Compression/vnlib_compress/src/util.h
index 292e3bf..292e3bf 100644
--- a/lib/Net.Compression/vnlib_compress/util.h
+++ b/lib/Net.Compression/vnlib_compress/src/util.h
diff --git a/lib/Net.Compression/vnlib_compress/vnlib_compress.vcxitems b/lib/Net.Compression/vnlib_compress/src/vnlib_compress.vcxitems
index 0bfdcbf..7f5eb0e 100644
--- a/lib/Net.Compression/vnlib_compress/vnlib_compress.vcxitems
+++ b/lib/Net.Compression/vnlib_compress/src/vnlib_compress.vcxitems
@@ -25,9 +25,10 @@
<ClInclude Include="$(MSBuildThisFileDirectory)feature_zlib.h" />
</ItemGroup>
<ItemGroup>
- <Text Include="$(MSBuildThisFileDirectory)CMakeLists.txt" />
+ <None Include="$(MSBuildThisFileDirectory)..\package.json" />
+ <None Include="$(MSBuildThisFileDirectory)..\Taskfile.yaml" />
</ItemGroup>
<ItemGroup>
- <None Include="$(MSBuildThisFileDirectory)Taskfile.yaml" />
+ <Text Include="$(MSBuildThisFileDirectory)..\CMakeLists.txt" />
</ItemGroup>
</Project> \ No newline at end of file
diff --git a/lib/Net.Http/src/Core/TransportManager.cs b/lib/Net.Http/src/Core/TransportManager.cs
index 2632fc5..8f1f946 100644
--- a/lib/Net.Http/src/Core/TransportManager.cs
+++ b/lib/Net.Http/src/Core/TransportManager.cs
@@ -47,7 +47,7 @@ namespace VNLib.Net.Http.Core
Debug.Assert(_stream != null, "Transport stream was accessed but was set to null");
return _stream;
}
- set => _stream = value;
+ private set => _stream = value;
}
public IBufferWriter<byte> Writer
@@ -57,7 +57,7 @@ namespace VNLib.Net.Http.Core
Debug.Assert(_asWriter != null, "Transport buffer writer accessed but the writer is null");
return _asWriter;
}
- set => _asWriter = value;
+ private set => _asWriter = value;
}
#else
diff --git a/lib/Net.Http/src/VNLib.Net.Http.csproj b/lib/Net.Http/src/VNLib.Net.Http.csproj
index e57f784..d9117f4 100644
--- a/lib/Net.Http/src/VNLib.Net.Http.csproj
+++ b/lib/Net.Http/src/VNLib.Net.Http.csproj
@@ -22,7 +22,7 @@
<Description>Provides a high performance HTTP 0.9-1.1 application processing layer for handling transport *agnostic connections and asynchronous event support for applications serving HTTP requests such as web content. This library has a large focus on low/no GC allocations using unmanaged memory support provided by the VNLib.Utils library. No external dependencies outside of the VNLib ecosystem are required. The VNLib.Plugins and VNLib.Plugins.Essentials libraries are highly recommended for serving web content.</Description>
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Http</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Net.Http</RepositoryUrl>
<PackageReadmeFile>readme.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Net.Messaging.FBM/src/VNLib.Net.Messaging.FBM.csproj b/lib/Net.Messaging.FBM/src/VNLib.Net.Messaging.FBM.csproj
index 897bca5..8fc2fb0 100644
--- a/lib/Net.Messaging.FBM/src/VNLib.Net.Messaging.FBM.csproj
+++ b/lib/Net.Messaging.FBM/src/VNLib.Net.Messaging.FBM.csproj
@@ -20,7 +20,7 @@
<Description>Fixed Buffer Messaging protocol class library. Implements a high-performance asynchronous request/response messaging architecture build on top of HTTP websockets. Provides client and server data structures.</Description>
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Messaging.FBM</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Net.Messaging.FBM</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Net.Rest.Client/src/VNLib.Net.Rest.Client.csproj b/lib/Net.Rest.Client/src/VNLib.Net.Rest.Client.csproj
index 95f7e05..37ae341 100644
--- a/lib/Net.Rest.Client/src/VNLib.Net.Rest.Client.csproj
+++ b/lib/Net.Rest.Client/src/VNLib.Net.Rest.Client.csproj
@@ -20,7 +20,7 @@
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<Description>Provides a RestClient connection pool using the Utils.ObjectRental framework for reusing RestClients with a common configuration to execute RestRequests against. This library also implements an OAuth2 authenticator for the RestSharp IAuthenticator using the client credentials method.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Rest.Client</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Net.Rest.Client</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Net.Transport.SimpleTCP/src/VNLib.Net.Transport.SimpleTCP.csproj b/lib/Net.Transport.SimpleTCP/src/VNLib.Net.Transport.SimpleTCP.csproj
index 630a0db..a2fc268 100644
--- a/lib/Net.Transport.SimpleTCP/src/VNLib.Net.Transport.SimpleTCP.csproj
+++ b/lib/Net.Transport.SimpleTCP/src/VNLib.Net.Transport.SimpleTCP.csproj
@@ -22,7 +22,7 @@
<Company>Vaughn Nugent</Company>
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Net.Transport.SimpleTCP</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Net.Transport.SimpleTCP</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Plugins.Essentials.ServiceStack/src/VNLib.Plugins.Essentials.ServiceStack.csproj b/lib/Plugins.Essentials.ServiceStack/src/VNLib.Plugins.Essentials.ServiceStack.csproj
index 4aedb80..b5dc949 100644
--- a/lib/Plugins.Essentials.ServiceStack/src/VNLib.Plugins.Essentials.ServiceStack.csproj
+++ b/lib/Plugins.Essentials.ServiceStack/src/VNLib.Plugins.Essentials.ServiceStack.csproj
@@ -20,7 +20,7 @@
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<Description>Provides data structures for building a dynamic HTTP servicing stack with runtime plugin loading, dynamic endpoint routing, middleware* configuration, and multi-server managment.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Plugins.Essentials.ServiceStack</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Plugins.Essentials.ServiceStack</RepositoryUrl>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Plugins.Essentials/src/VNLib.Plugins.Essentials.csproj b/lib/Plugins.Essentials/src/VNLib.Plugins.Essentials.csproj
index 3a21ac9..45a4d50 100644
--- a/lib/Plugins.Essentials/src/VNLib.Plugins.Essentials.csproj
+++ b/lib/Plugins.Essentials/src/VNLib.Plugins.Essentials.csproj
@@ -22,7 +22,7 @@
<Description>Provides essential web, sessions, users abstractions for building extensable web applications with satefull sessions, user based intraction with login and account security extensions.</Description>
<PackageTags>VNLib, Plugins, VNLib.Plugins.Essentials, Essentials, Essential Plugins, HTTP Essentials, OAuth2</PackageTags>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Plugins.Essentials</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Plugins.Essentials</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Plugins.PluginBase/src/VNLib.Plugins.PluginBase.csproj b/lib/Plugins.PluginBase/src/VNLib.Plugins.PluginBase.csproj
index 2f4abfa..d1207c2 100644
--- a/lib/Plugins.PluginBase/src/VNLib.Plugins.PluginBase.csproj
+++ b/lib/Plugins.PluginBase/src/VNLib.Plugins.PluginBase.csproj
@@ -20,7 +20,7 @@
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<Description>A base class for VNLib.Plugins that provides all supported loading functionalities, with built-in logging, loading, task-managment and endpoint routing.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Plugins.PluginBase</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Plugins.PluginBase</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Plugins.Runtime/src/VNLib.Plugins.Runtime.csproj b/lib/Plugins.Runtime/src/VNLib.Plugins.Runtime.csproj
index 002716f..6d18bef 100644
--- a/lib/Plugins.Runtime/src/VNLib.Plugins.Runtime.csproj
+++ b/lib/Plugins.Runtime/src/VNLib.Plugins.Runtime.csproj
@@ -20,7 +20,7 @@
<Copyright>Copyright © 2024 Vaughn Nugent</Copyright>
<Description>A runtime plugin loader for .NET. Allows runtime loading and tracking of .NET assemblies that export the VNLib.Plugin.IPlugin interface.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Plugins.Runtime</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Plugins.Runtime</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Plugins/src/VNLib.Plugins.csproj b/lib/Plugins/src/VNLib.Plugins.csproj
index 343d86f..4ac6366 100644
--- a/lib/Plugins/src/VNLib.Plugins.csproj
+++ b/lib/Plugins/src/VNLib.Plugins.csproj
@@ -23,7 +23,7 @@
<Description>Provides a standard interface for building dynamically loadable plugins and asynchronus web endpoint processing, compatible with the VNLib.Plugins.Runtime loader library.
</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Plugins</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Plugins</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
diff --git a/lib/Utils.Cryptography/argon2/.gitattributes b/lib/Utils.Cryptography/argon2/.gitattributes
deleted file mode 100644
index 177bed9..0000000
--- a/lib/Utils.Cryptography/argon2/.gitattributes
+++ /dev/null
@@ -1,10 +0,0 @@
-# Export ignore
-.gitattributes export-ignore
-.gitignore export-ignore
-.travis.yml export-ignore
-appveyor.yml export-ignore
-export.sh export-ignore
-latex/* export-ignore
-
-# Linguist documentation
-latex/* linguist-documentation
diff --git a/lib/Utils.Cryptography/argon2/.gitignore b/lib/Utils.Cryptography/argon2/.gitignore
deleted file mode 100644
index 2bb1416..0000000
--- a/lib/Utils.Cryptography/argon2/.gitignore
+++ /dev/null
@@ -1,22 +0,0 @@
-argon2
-libargon2.a
-libargon2.so*
-libargon2.dylib
-libargon2.pc
-.DS_Store
-src/*.o
-src/blake2/*.o
-genkat
-.idea
-*.pyc
-testcase
-*.gcda
-*.gcno
-*.gcov
-bench
-vs2015/build
-Argon2.sdf
-Argon2.VC.opendb
-*.zip
-*.tar.gz
-tags
diff --git a/lib/Utils.Cryptography/argon2/.travis.yml b/lib/Utils.Cryptography/argon2/.travis.yml
deleted file mode 100644
index 265fc48..0000000
--- a/lib/Utils.Cryptography/argon2/.travis.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-language: c
-
-compiler:
- - clang
- - gcc
-
-os:
- - linux
- - osx
-
-# Clang on Linux needs to run in a VM to use ASAN.
-# See: https://github.com/travis-ci/travis-ci/issues/9033
-matrix:
- exclude:
- - compiler: clang
- os: linux
- include:
- - compiler: clang
- os: linux
- sudo: true
-
-script: make && make testci
-
-after_success:
- - bash <(curl -s https://codecov.io/bash)
diff --git a/lib/Utils.Cryptography/argon2/Taskfile.yaml b/lib/Utils.Cryptography/argon2/Taskfile.yaml
index 73fb8fa..d08d3b6 100644
--- a/lib/Utils.Cryptography/argon2/Taskfile.yaml
+++ b/lib/Utils.Cryptography/argon2/Taskfile.yaml
@@ -19,68 +19,84 @@ tasks:
cmds:
#build with defaults
- task: build
- - cmd: echo "Your Argon2 dll file can be found in '{{.USER_WORKING_DIR}}/build'"
+ - cmd: echo "Your Argon2 library file can be found in '{{ .USER_WORKING_DIR }}/build'"
silent: true
build:
cmds:
#init cmake build with greedy enabled
- - cmake -B./build
-
- - cmake --build build/ --config Debug
- - cmake --build build/ --config Release
+ - cmake -B./build
+ - cmake --build build/ --config debug
+ - cmake --build build/ --config release
postbuild_success:
- vars:
- #required files to include in tar
- TAR_FILES: "license.txt readme.txt argon2.h"
-
cmds:
#make bin dir
- - cmd: powershell -Command "New-Item -Type Directory -Force -Path './bin'"
+ - cmd: powershell mkdir -Force 'bin/'
ignore_error: true
-
- #add embeded resources to output dirs
- - task: embed
- vars:
- TARGET: './build/Debug'
-
- - task: embed
- vars:
- TARGET: './build/Release'
-
-
- #static debug lib
- - cd build/Debug && tar -czf '../../bin/msvc-x64-debug-{{.PROJECT_NAME}}-static.tgz' {{.PROJECT_NAME}}_static.lib {{.TAR_FILES}} {{.PROJECT_NAME}}_static.pdb
- #dynamic debug lib
- - cd build/Debug && tar -czf '../../bin/msvc-x64-debug-{{.PROJECT_NAME}}.tgz' {{.PROJECT_NAME}}.dll {{.TAR_FILES}} {{.PROJECT_NAME}}.pdb
- #release static lib
- - cd build/Release && tar -czf '../../bin/msvc-x64-release-{{.PROJECT_NAME}}-static.tgz' {{.PROJECT_NAME}}_static.lib {{.TAR_FILES}}
- #release dll
- - cd build/Release && tar -czf '../../bin/msvc-x64-release-{{.PROJECT_NAME}}.tgz' {{.PROJECT_NAME}}.dll {{.TAR_FILES}}
+ - task: parallel_postbuild
+
+ parallel_postbuild:
+ internal: true
+ vars:
+ #required files to include in tar
+ BIN_FILES:
+ license.txt
+ readme.txt
+ argon2.h
+ '{{ .PROJECT_NAME }}.dll'
+
+ deps:
+ - task: pack_source
+
+ - task: pack_artifacts
+ vars: { BUILD_MODE: 'debug', TAR_FILES: '{{ .BIN_FILES }} {{ .PROJECT_NAME }}.pdb' }
+ - task: pack_artifacts
+ vars: { BUILD_MODE: 'release', TAR_FILES: '{{ .BIN_FILES }}' }
- #source code
- - task: pack_source
+ #packs up the binary artifacts for distribution
+ pack_artifacts:
+ internal: true
+ deps:
+ - task: embed
+ vars: { TARGET: './build/{{ .BUILD_MODE }}' }
+ cmds:
+ - cmd: cd build/{{ .BUILD_MODE }} && tar -czf '../../bin/msvc-x64-{{ .BUILD_MODE }}-{{ .PROJECT_NAME }}.tgz' {{ .TAR_FILES }}
+ #add embeded resources to the binary output for distribution
embed:
+ internal: true
cmds:
- #add license file
- - powershell -Command "Copy-Item -Path ./license -Destination '{{.TARGET}}/license.txt'"
- #add readme file
- - powershell -Command "Copy-Item -Path ./build.readme.txt -Destination '{{.TARGET}}/readme.txt'"
- #add argon2 header file
- - powershell -Command "Copy-Item -Path ./include/argon2.h -Destination '{{.TARGET}}/argon2.h'"
+ - powershell cp LICENSE '{{.TARGET}}/license.txt'
+ - powershell cp build.readme.txt '{{.TARGET}}/readme.txt'
+ - powershell cp include/argon2.h '{{.TARGET}}/argon2.h'
+ #packages source code for distribution
pack_source:
+ internal: true
+ vars:
+ EXCLUDES:
+
+ INCLUDES:
+ src/*
+ include/*
+ CHANGELOG.md
+ CMakeLists.txt
+ README.md
+ LICENSE
+ Argon2.sln
+ libargon2.pc.in
+ Makefile
+ Taskfile.yaml
+
cmds:
#just pack up current directory, excluding build, bin, and git directories
- - powershell -Command "tar --exclude build/* --exclude bin/* -czf bin/src.tgz ."
-
+ - tar {{ .EXCLUDES }} -czf 'bin/src.tgz' {{ .INCLUDES }}
clean:
ignore_error: true
cmds:
- - cmd: powershell -Command "Remove-Item -Recurse './bin'"
- - cmd: powershell -Command "Remove-Item -Recurse './build'" \ No newline at end of file
+ - for: [ bin/, build/ ]
+ cmd: powershell -Command "Remove-Item -Recurse '{{ .ITEM }}'"
diff --git a/lib/Utils.Cryptography/argon2/appveyor.yml b/lib/Utils.Cryptography/argon2/appveyor.yml
deleted file mode 100644
index fb1f048..0000000
--- a/lib/Utils.Cryptography/argon2/appveyor.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-os: Visual Studio 2015
-
-environment:
- matrix:
- - platform: x86
- configuration: Debug
- - platform: x86
- configuration: Release
- - platform: x64
- configuration: Debug
- - platform: x64
- configuration: Release
-
-matrix:
- fast_finish: false
-
-build:
- parallel: true
- project: Argon2.sln
- verbosity: minimal
-
-test_script:
- - ps: kats\test.ps1
- - ps: if ("Release" -eq $env:configuration) { vs2015\build\Argon2OptTestCI.exe }
- - ps: if ("Release" -eq $env:configuration) { vs2015\build\Argon2RefTestCI.exe }
diff --git a/lib/Utils.Cryptography/argon2/argon2-specs.pdf b/lib/Utils.Cryptography/argon2/argon2-specs.pdf
deleted file mode 100644
index d916af6..0000000
--- a/lib/Utils.Cryptography/argon2/argon2-specs.pdf
+++ /dev/null
Binary files differ
diff --git a/lib/Utils.Cryptography/argon2/export.sh b/lib/Utils.Cryptography/argon2/export.sh
deleted file mode 100644
index 9757b10..0000000
--- a/lib/Utils.Cryptography/argon2/export.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-FILE=`date "+%Y%m%d"`
-BRANCH=master
-
-git archive --format zip --output $FILE.zip $BRANCH
-git archive --format tar.gz --output $FILE.tar.gz $BRANCH
diff --git a/lib/Utils.Memory/NativeHeapApi/src/NativeHeapApi.h b/lib/Utils.Memory/NativeHeapApi/src/NativeHeapApi.h
index 1738d19..b54313a 100644
--- a/lib/Utils.Memory/NativeHeapApi/src/NativeHeapApi.h
+++ b/lib/Utils.Memory/NativeHeapApi/src/NativeHeapApi.h
@@ -51,7 +51,7 @@
#ifdef _P_IS_WINDOWS
#define VNLIB_HEAP_API __declspec(dllimport)
#else
- #define VNLIB_HEAP_API
+ #define VNLIB_HEAP_API extern
#endif /* _P_IS_WINDOWS */
#endif /* !VNLIB_EXPORTING */
#endif /* !VNLIB_EXPORT */
@@ -72,12 +72,9 @@ typedef enum HeapCreationFlags
HEAP_CREATION_SUPPORTS_REALLOC = 0x08
} HeapCreationFlags;
-#ifdef _P_IS_WINDOWS
-typedef void* LPVOID;
-#endif /* !WIN32 */
-
/* The vnlib ERRNO type, integer/process dependent,
-internally represented as a pointer */
+ internally represented as a pointer
+*/
typedef void* ERRNO;
/* A pointer to a heap structure that was stored during heap creation */
diff --git a/lib/Utils.Memory/vnlib_mimalloc/NativeHeapApi.h b/lib/Utils.Memory/vnlib_mimalloc/NativeHeapApi.h
index 1738d19..b54313a 100644
--- a/lib/Utils.Memory/vnlib_mimalloc/NativeHeapApi.h
+++ b/lib/Utils.Memory/vnlib_mimalloc/NativeHeapApi.h
@@ -51,7 +51,7 @@
#ifdef _P_IS_WINDOWS
#define VNLIB_HEAP_API __declspec(dllimport)
#else
- #define VNLIB_HEAP_API
+ #define VNLIB_HEAP_API extern
#endif /* _P_IS_WINDOWS */
#endif /* !VNLIB_EXPORTING */
#endif /* !VNLIB_EXPORT */
@@ -72,12 +72,9 @@ typedef enum HeapCreationFlags
HEAP_CREATION_SUPPORTS_REALLOC = 0x08
} HeapCreationFlags;
-#ifdef _P_IS_WINDOWS
-typedef void* LPVOID;
-#endif /* !WIN32 */
-
/* The vnlib ERRNO type, integer/process dependent,
-internally represented as a pointer */
+ internally represented as a pointer
+*/
typedef void* ERRNO;
/* A pointer to a heap structure that was stored during heap creation */
diff --git a/lib/Utils.Memory/vnlib_mimalloc/Taskfile.yaml b/lib/Utils.Memory/vnlib_mimalloc/Taskfile.yaml
index 2d816e3..c1ded6d 100644
--- a/lib/Utils.Memory/vnlib_mimalloc/Taskfile.yaml
+++ b/lib/Utils.Memory/vnlib_mimalloc/Taskfile.yaml
@@ -9,75 +9,108 @@
version: '3'
vars:
- PROJECT_NAME: 'vnlib_mimalloc'
- MODULE_NAME: 'vnlib.core'
+ DEP_NAME: 'mimalloc'
+ PROJECT_NAME: 'vnlib_{{ .DEP_NAME }}'
+ ARTIFACTS_OUT: '{{ .PROJECT_DIR }}/{{ .BINARY_DIR }}'
tasks:
default:
desc: "Builds the entire project from source code without using the VNBuild build system for target machines"
cmds:
- #init cmake build with greedy enabled
- - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release -DENABLE_GREEDY=1 {{.CLI_ARGS}}
- - cmake --build build/ --config Release
- - cmd: echo "Your vnlib_mimalloc library file can be found in '{{.USER_WORKING_DIR}}/build'"
- silent: true
-
+ #init cmake build with greedy enabled
+ - task: build-internal
+ vars:
+ BUILD_TYPE: "Release"
+ CLI_ARGS: "-DENABLE_GREEDY=1 {{ .CLI_ARGS }}"
+
+ - cmd: echo "Your {{ .PROJECT_NAME }} library file can be found in '{{ .USER_WORKING_DIR }}/build'"
+ silent: true
+
+ debug:
+ cmds:
+ - task: build-internal
+ vars:
+ BUILD_TYPE: "debug"
+ CLI_ARGS: "-DENABLE_GREEDY=1 {{ .CLI_ARGS }}"
+
build:
- cmds:
- #build our library
- - cmake -B./build -DENABLE_GREEDY=1 {{.CLI_ARGS}}
- - cmake --build build/ --config Debug
- - cmake --build build/ --config Release
+ desc: 'DO NOT USE! This function is used internally during releases.'
+ cmds:
+ #init cmake build with greedy enabled
+ - cmake -B./build -DENABLE_GREEDY=1 {{ .CLI_ARGS }}
+ - cmake --build build/ --config debug
+ - cmake --build build/ --config release
+
+ build-internal:
+ internal: true
+ cmds:
+ #build with defaults
+ #init cmake build with greedy enabled
+ - cmake -Bbuild/ -DCMAKE_BUILD_TYPE={{ .BUILD_TYPE }} {{ .CLI_ARGS }}
+ - cmake --build build/ --config {{ .BUILD_TYPE }}
postbuild_success:
- vars:
- #required files to include in tar
- TAR_FILES: "license.txt readme.txt mimalloc_license.txt"
-
cmds:
#make bin dir
- - cmd: powershell -Command "New-Item -Type Directory -Force -Path './bin'"
+ - cmd: powershell mkdir -Force '{{ .ARTIFACTS_OUT }}'
ignore_error: true
+
+ - task: pack_parallel
- #get licenses for debug
- - task: licenses
- vars:
- TARGET: './build/Debug'
-
- - task: licenses
- vars:
- TARGET: './build/Release'
-
- #dynamic debug lib
- - cd build/Debug && tar -czf '../../bin/msvc-x64-debug-{{.PROJECT_NAME}}.tgz' {{.PROJECT_NAME}}.dll {{.TAR_FILES}} {{.PROJECT_NAME}}.pdb
-
- #release dll
- - cd build/Release && tar -czf '../../bin/msvc-x64-release-{{.PROJECT_NAME}}.tgz' {{.PROJECT_NAME}}.dll {{.TAR_FILES}}
-
- #source code
- - task: pack_source
+ pack_parallel:
+ internal: true
+ deps:
+ - task: pack_source
+ - task: pack_artifacts
+ vars: { BUILD_TYPE: 'debug' }
+ - task: pack_artifacts
+ vars: { BUILD_TYPE: 'release' }
- licenses:
+ #packs binary artifacts for distribution
+ pack_artifacts:
+ internal: true
+ deps:
+ - task: pack_resources
+ vars: { TARGET: './build/{{ .BUILD_TYPE }}' }
cmds:
- #add mimalloc license to binary output
- - powershell -Command "Copy-Item -Path vendor/license -Destination '{{.TARGET}}/mimalloc_license.txt'"
- #add my license file
- - powershell -Command "Copy-Item -Path ./license -Destination '{{.TARGET}}/license.txt'"
- #add readme file
- - powershell -Command "Copy-Item -Path ./build.readme.txt -Destination '{{.TARGET}}/readme.txt'"
+ - cmd: cd build/{{ .BUILD_TYPE }} && tar -czf '{{ .ARTIFACTS_OUT }}/msvc-x64-{{ .BUILD_TYPE }}-{{ .PROJECT_NAME }}.tgz' .
+
+ pack_resources:
+ internal: true
+ cmds:
+ - powershell cp NativeHeapApi.h '{{ .TARGET }}/'
+ - powershell cp vendor/license '{{ .TARGET }}/{{ .DEP_NAME }}_license.txt'
+ - powershell cp license '{{ .TARGET }}/license.txt'
+ - powershell cp build.readme.txt '{{ .TARGET }}/readme.txt'
pack_source:
- dir: '{{.USER_WORKING_DIR}}'
+ internal: true
+ desc: "Packs up the project source code and creates a tarball in the builds binary directory"
+ vars:
+ TARGET_SOURCE: '{{ .PROJECT_DIR }}/{{ .BINARY_DIR }}/src.tgz'
+ SOURCE_FILES:
+ CMakeLists.txt
+ Taskfile.yaml
+ vendor
+ LICENSE
+ NativeHeapApi.h
+ '{{ .PROJECT_NAME }}.c'
+
cmds:
- #pack mimalloc source code and create the archive
- - powershell -Command "tar --exclude build/* --exclude bin/* --exclude vendor/test/ --exclude vendor/out/ -czf 'bin/src.tgz' ."
+ #tar up the source
+ - tar -czf '{{ .TARGET_SOURCE }}' {{ .SOURCE_FILES | join " " }}
clean:
ignore_error: true
cmds:
- for: [ bin/, build/ ]
- cmd: powershell Remove-Item -Recurse '{{.ITEM}}' -Force
-
- \ No newline at end of file
+ cmd: powershell rm -Recurse -Force '{{.ITEM}}'
+
+ #called by module for initializing the project, it's not internal but hidden
+ dev-init:
+ internal: false
+ cmds:
+ - task: debug
+ \ No newline at end of file
diff --git a/lib/Utils.Memory/vnlib_mimalloc/build.readme.txt b/lib/Utils.Memory/vnlib_mimalloc/build.readme.txt
index cd003b6..2edae23 100644
--- a/lib/Utils.Memory/vnlib_mimalloc/build.readme.txt
+++ b/lib/Utils.Memory/vnlib_mimalloc/build.readme.txt
@@ -25,9 +25,9 @@ PREREQUISITES:
NOTE:
If you have any mimalloc specific CMake options you want to use, when running task, you can pass them as
-an the MIMALLOC_CMAKE_ARGS env variable.
+on the command line following a double hyphen '--'
-Example: >task MIMALLOC_CMAKE_ARGS="-DMI_SECURE=ON" (enable secure mode for mimalloc)
+Example: >task -- -DMI_SECURE=ON (enable secure mode for mimalloc)
See: https://microsoft.github.io/mimalloc/build.html for more information on mimalloc specific CMake options.
@@ -36,6 +36,12 @@ BUILDING:
2. Navigate to directory containing the Taskfile.yaml file in the root
3. Run the default task: > task (yes literally just type "task" and hit enter if you installed Task gobally)
+You may build a debug version with the following task command:
+>task debug
+
+You may always use the task list command to see all available public tasks:
+>task --list
+
WINDOWS:
The taskfile should print on screen where the output library file was placed. It will be in the build directory
usually under Debug or Release.
diff --git a/lib/Utils.Memory/vnlib_mimalloc/package.json b/lib/Utils.Memory/vnlib_mimalloc/package.json
index add660c..fb6ef71 100644
--- a/lib/Utils.Memory/vnlib_mimalloc/package.json
+++ b/lib/Utils.Memory/vnlib_mimalloc/package.json
@@ -1,10 +1,10 @@
{
"name": "vnlib_mimalloc",
- "version": "0.1.0",
+ "version": "0.0.0",
"output_dir": "bin",
"author": "Vaughn Nugent",
"description": "A cmake cross-platform C89, NativeHeapApi compliant, mimalloc dynamic library. This project includes pre-build Windows x64 binaries as well as the source code for building the entire dynamic library on your system",
- "copyright": "Copyright \u00A9 2023 Vaughn Nugent",
+ "copyright": "Copyright \u00A9 2024 Vaughn Nugent",
"company": "Vaughn Nugent",
- "repository": "https://github.com/VnUgE/VNLib.Core/tree/main/lib/Utils.Memory/vnlib_mimalloc"
+ "repository": "https://github.com/VnUgE/VNLib.Core/tree/master/lib/Utils.Memory/vnlib_mimalloc"
} \ No newline at end of file
diff --git a/lib/Utils.Memory/vnlib_rpmalloc/CMakeLists.txt b/lib/Utils.Memory/vnlib_rpmalloc/CMakeLists.txt
index fedde80..f3a2b6a 100644
--- a/lib/Utils.Memory/vnlib_rpmalloc/CMakeLists.txt
+++ b/lib/Utils.Memory/vnlib_rpmalloc/CMakeLists.txt
@@ -13,12 +13,11 @@ message(STATUS "Build type is '${build_type}'")
set(CMAKE_C_STANDARD 11) #c11 is required for rpmalloc static assertions
set(CMAKE_C_STANDARD_REQUIRED ON)
-#export header files to the main project
-file(GLOB HEADERS *.h)
-
#Add indepednent source files to the project
set(VNLIB_RPMALLOC_SOURCES
+ "NativeHeapApi.h"
"vnlib_rpmalloc.c"
+ "vendor/rpmalloc.h"
"vendor/rpmalloc.c"
)
@@ -26,8 +25,8 @@ set(VNLIB_RPMALLOC_SOURCES
include_directories(vendor)
#create shared/static libs
-add_library(${_RP_PROJ_NAME} SHARED ${VNLIB_RPMALLOC_SOURCES} ${HEADERS})
-add_library(${_RP_PROJ_NAME}_static STATIC ${VNLIB_RPMALLOC_SOURCES} ${HEADERS})
+add_library(${_RP_PROJ_NAME} SHARED ${VNLIB_RPMALLOC_SOURCES})
+add_library(${_RP_PROJ_NAME}_static STATIC ${VNLIB_RPMALLOC_SOURCES})
#enable fPIC for shared library
set_target_properties(${_RP_PROJ_NAME} PROPERTIES POSITION_INDEPENDENT_CODE ON)
diff --git a/lib/Utils.Memory/vnlib_rpmalloc/NativeHeapApi.h b/lib/Utils.Memory/vnlib_rpmalloc/NativeHeapApi.h
index 1738d19..b54313a 100644
--- a/lib/Utils.Memory/vnlib_rpmalloc/NativeHeapApi.h
+++ b/lib/Utils.Memory/vnlib_rpmalloc/NativeHeapApi.h
@@ -51,7 +51,7 @@
#ifdef _P_IS_WINDOWS
#define VNLIB_HEAP_API __declspec(dllimport)
#else
- #define VNLIB_HEAP_API
+ #define VNLIB_HEAP_API extern
#endif /* _P_IS_WINDOWS */
#endif /* !VNLIB_EXPORTING */
#endif /* !VNLIB_EXPORT */
@@ -72,12 +72,9 @@ typedef enum HeapCreationFlags
HEAP_CREATION_SUPPORTS_REALLOC = 0x08
} HeapCreationFlags;
-#ifdef _P_IS_WINDOWS
-typedef void* LPVOID;
-#endif /* !WIN32 */
-
/* The vnlib ERRNO type, integer/process dependent,
-internally represented as a pointer */
+ internally represented as a pointer
+*/
typedef void* ERRNO;
/* A pointer to a heap structure that was stored during heap creation */
diff --git a/lib/Utils.Memory/vnlib_rpmalloc/Taskfile.yaml b/lib/Utils.Memory/vnlib_rpmalloc/Taskfile.yaml
index 98dd914..f1c74a0 100644
--- a/lib/Utils.Memory/vnlib_rpmalloc/Taskfile.yaml
+++ b/lib/Utils.Memory/vnlib_rpmalloc/Taskfile.yaml
@@ -9,68 +9,108 @@
version: '3'
vars:
- PROJECT_NAME: 'vnlib_rpmalloc'
+ DEP_NAME: 'rpmalloc'
+ PROJECT_NAME: 'vnlib_{{ .DEP_NAME }}'
+ ARTIFACTS_OUT: '{{ .PROJECT_DIR }}/{{ .BINARY_DIR }}'
tasks:
default:
desc: "Builds the entire project from source code without using the VNBuild build system for target machines"
cmds:
- #build with defaults
- #init cmake build with greedy enabled
- - cmake -Bbuild/ -DCMAKE_BUILD_TYPE=Release -DENABLE_GREEDY=1 {{.CMAKE_ARGS}}
- - cmake --build build/ --config Release
- - cmd: echo "Your vnlib_rpmalloc library file can be found in '{{.USER_WORKING_DIR}}/build'"
- silent: true
-
+ #init cmake build with greedy enabled
+ - task: build-internal
+ vars:
+ BUILD_TYPE: "Release"
+ CLI_ARGS: "-DENABLE_GREEDY=1 {{ .CLI_ARGS }}"
+
+ - cmd: echo "Your {{ .PROJECT_NAME }} library file can be found in '{{ .USER_WORKING_DIR }}/build'"
+ silent: true
+
+ debug:
+ cmds:
+ - task: build-internal
+ vars:
+ BUILD_TYPE: "debug"
+ CLI_ARGS: "-DENABLE_GREEDY=1 {{ .CLI_ARGS }}"
+
build:
+ desc: 'DO NOT USE! This function is used internally during releases.'
cmds:
#init cmake build with greedy enabled
- - cmake -B./build -DENABLE_GREEDY=1
- - cmake --build build/ --config Debug
- - cmake --build build/ --config Release
+ - cmake -B./build -DENABLE_GREEDY=1 {{ .CLI_ARGS }}
+ - cmake --build build/ --config debug
+ - cmake --build build/ --config release
+
+ build-internal:
+ internal: true
+ cmds:
+ #build with defaults
+ #init cmake build with greedy enabled
+ - cmake -Bbuild/ -DCMAKE_BUILD_TYPE={{ .BUILD_TYPE }} {{ .CLI_ARGS }}
+ - cmake --build build/ --config {{ .BUILD_TYPE }}
postbuild_success:
- vars:
- #required files to include in tar
- TAR_FILES: "license.txt readme.txt rpmalloc_license.txt"
-
cmds:
#make bin dir
- - cmd: powershell -Command "New-Item -Type Directory -Force -Path './bin'"
+ - cmd: powershell mkdir -Force '{{ .ARTIFACTS_OUT }}'
ignore_error: true
+
+ - task: pack_parallel
- #get licenses for debug
- - task: licenses
- vars: { TARGET: './build/Debug' }
-
- - task: licenses
- vars: { TARGET: './build/Release' }
-
- #dynamic debug lib
- - cd build/Debug && tar -czf '../../bin/msvc-x64-debug-{{.PROJECT_NAME}}.tgz' .
- #release dll
- - cd build/Release && tar -czf '../../bin/msvc-x64-release-{{.PROJECT_NAME}}.tgz' .
+ pack_parallel:
+ internal: true
+ deps:
+ - task: pack_source
- #source code
- - task: pack_source
+ - task: pack_artifacts
+ vars: { BUILD_TYPE: 'debug' }
+ - task: pack_artifacts
+ vars: { BUILD_TYPE: 'release' }
- licenses:
+ #packs binary artifacts for distribution
+ pack_artifacts:
+ internal: true
+ deps:
+ - task: pack_resources
+ vars: { TARGET: './build/{{ .BUILD_TYPE }}' }
+ cmds:
+ - cmd: cd build/{{ .BUILD_TYPE }} && tar -czf '{{ .ARTIFACTS_OUT }}/msvc-x64-{{ .BUILD_TYPE }}-{{ .PROJECT_NAME }}.tgz' .
+
+ pack_resources:
+ internal: true
cmds:
- #add rpmalloc license to binary output
- - powershell -Command "Copy-Item -Path vendor/license -Destination '{{.TARGET}}/rpmalloc_license.txt'"
- #add my license file
- - powershell -Command "Copy-Item -Path ./license -Destination '{{.TARGET}}/license.txt'"
- #add readme file
- - powershell -Command "Copy-Item -Path ./build.readme.txt -Destination '{{.TARGET}}/readme.txt'"
+ - powershell cp NativeHeapApi.h '{{ .TARGET }}/'
+ - powershell cp vendor/license '{{ .TARGET }}/{{ .DEP_NAME }}_license.txt'
+ - powershell cp license '{{ .TARGET }}/license.txt'
+ - powershell cp build.readme.txt '{{ .TARGET }}/readme.txt'
pack_source:
- dir: '{{.USER_WORKING_DIR}}'
+ internal: true
+ desc: "Packs up the project source code and creates a tarball in the builds binary directory"
+ vars:
+ TARGET_SOURCE: '{{ .PROJECT_DIR }}/{{ .BINARY_DIR }}/src.tgz'
+ SOURCE_FILES:
+ CMakeLists.txt
+ Taskfile.yaml
+ vendor
+ LICENSE
+ NativeHeapApi.h
+ '{{ .PROJECT_NAME }}.c'
+
cmds:
- - powershell -Command "tar --exclude build/* --exclude bin/* --exclude vendor/build/* -czf 'bin/src.tgz' ."
+ #tar up the source
+ - tar -czf '{{ .TARGET_SOURCE }}' {{ .SOURCE_FILES | join " " }}
clean:
ignore_error: true
cmds:
- for: [ bin/, build/ ]
- cmd: powershell Remove-Item -Recurse '{{.ITEM}}' -Force \ No newline at end of file
+ cmd: powershell rm -Recurse -Force '{{.ITEM}}'
+
+ #called by module for initializing the project, it's not internal but hidden
+ dev-init:
+ internal: false
+ cmds:
+ - task: debug
+ \ No newline at end of file
diff --git a/lib/Utils.Memory/vnlib_rpmalloc/build.readme.txt b/lib/Utils.Memory/vnlib_rpmalloc/build.readme.txt
index 79a7091..a8d1ab5 100644
--- a/lib/Utils.Memory/vnlib_rpmalloc/build.readme.txt
+++ b/lib/Utils.Memory/vnlib_rpmalloc/build.readme.txt
@@ -28,6 +28,12 @@ BUILDING:
2. Navigate to directory containing the Taskfile.yaml file in the root
3. Run the default task: > task (yes literally just type "task" and hit enter if you installed Task gobally)
+You may build a debug version with the following task command:
+>task debug
+
+You may always use the task list command to see all available public tasks:
+>task --list
+
WINDOWS:
The taskfile should print on screen where the output library file was placed. It will be in the build directory
usually under Debug or Release.
diff --git a/lib/Utils.Memory/vnlib_rpmalloc/package.json b/lib/Utils.Memory/vnlib_rpmalloc/package.json
index 5235262..9fbd64c 100644
--- a/lib/Utils.Memory/vnlib_rpmalloc/package.json
+++ b/lib/Utils.Memory/vnlib_rpmalloc/package.json
@@ -1,10 +1,10 @@
{
"name": "vnlib_rpmalloc",
- "version": "0.1.4",
+ "version": "0.0.0",
"output_dir": "bin",
"author": "Vaughn Nugent",
"description": "A project to maintain an x64 Windows dynamic and static library for RpMalloc by Mattias Jansson for use with the NativeHeapApi to for VNLib.Utils native heap loading. This project includes pre-build Windows x64 binaries as well as the source code for building the dynamic and static libraries on your system",
- "copyright": "Copyright \u00A9 2023 Vaughn Nugent",
+ "copyright": "Copyright \u00A9 2024 Vaughn Nugent",
"company": "Vaughn Nugent",
- "repository": "https://github.com/VnUgE/VNLib.Core/tree/main/lib/Utils.Memory/vnlib_rpmalloc"
+ "repository": "https://github.com/VnUgE/VNLib.Core/tree/master/lib/Utils.Memory/vnlib_rpmalloc"
} \ No newline at end of file
diff --git a/lib/Utils/src/VNLib.Utils.csproj b/lib/Utils/src/VNLib.Utils.csproj
index 83d245c..2847afa 100644
--- a/lib/Utils/src/VNLib.Utils.csproj
+++ b/lib/Utils/src/VNLib.Utils.csproj
@@ -23,7 +23,7 @@
<PackageTags>vnlib,utils,utilities,vnlib utils,utility</PackageTags>
<Description>.NET/8.0 Utilities library for high-performance common operations. Utilities and abstractions for building and diagnosing native memory implementations. Dyanmic native library loading, IO, extensions, data encoding, resource access, and asynchronous cooperation primitives.</Description>
<PackageProjectUrl>https://www.vaughnnugent.com/resources/software/modules/VNLib.Core</PackageProjectUrl>
- <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/main/lib/Utils</RepositoryUrl>
+ <RepositoryUrl>https://github.com/VnUgE/VNLib.Core/tree/master/lib/Utils</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>