Skip to content
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
98ea85e
Add ystdlib-cpp submodule
Bill-hbrhbr Feb 25, 2025
2086223
Migrate
Bill-hbrhbr Feb 25, 2025
f1b3f25
Fix cmake build flag
Bill-hbrhbr Feb 25, 2025
70b14a4
Update CMake option on ystdlib-cpp unit test building
Bill-hbrhbr Feb 26, 2025
4770e5e
Update ystdlib-cpp path
Bill-hbrhbr Mar 4, 2025
f1dade5
Update dependency taskfiles
Bill-hbrhbr Mar 4, 2025
7bdb0a4
Turn of unit test building
Bill-hbrhbr Mar 4, 2025
82ac7da
Remove unrelated changes
Bill-hbrhbr Mar 4, 2025
1ebaf19
Merge branch 'main' into migrate-error-handling
Bill-hbrhbr Mar 4, 2025
11fa690
fix task name
Bill-hbrhbr Mar 4, 2025
635ce2c
fix task name
Bill-hbrhbr Mar 4, 2025
2fc4567
Remove focal workflows
Bill-hbrhbr Mar 4, 2025
06b90fb
Upgrade macos to use appleclang16
Bill-hbrhbr Mar 4, 2025
e7b55eb
Update for macos-13
Bill-hbrhbr Mar 4, 2025
f04c65f
Move envs to deps:core
Bill-hbrhbr Mar 4, 2025
1c94f17
Allow env vars to pass in python scripts
Bill-hbrhbr Mar 4, 2025
53ca62a
Add env var to cli
Bill-hbrhbr Mar 4, 2025
0d0d25f
Update .github/workflows/clp-core-build-macos.yaml
Bill-hbrhbr Mar 4, 2025
af20a46
Remove workflow changes
Bill-hbrhbr Mar 12, 2025
df9b27b
Merge branch 'main' into migrate-error-handling
Bill-hbrhbr Mar 12, 2025
86670f4
Bump ystdlib-cpp version
Bill-hbrhbr Mar 12, 2025
5dee1f2
Update docs
Bill-hbrhbr Mar 12, 2025
0336667
Merge branch 'main' into migrate-error-handling
Bill-hbrhbr Mar 14, 2025
fbb896e
Upgrade dev utils
Bill-hbrhbr Mar 14, 2025
989afcb
Change option to set to prevent overriding
Bill-hbrhbr Mar 14, 2025
d2c6803
Undo source changes
Bill-hbrhbr Mar 14, 2025
9927121
Undo cmakelist change
Bill-hbrhbr Mar 14, 2025
631144b
Upgrade version
Bill-hbrhbr Mar 14, 2025
1e833d0
Merge branch 'main' into migrate-error-handling
Bill-hbrhbr Mar 16, 2025
e0e4ef6
Remove extra changes
Bill-hbrhbr Mar 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,6 @@
[submodule "components/core/submodules/utfcpp"]
path = components/core/submodules/utfcpp
url = https://github.com/nemtrif/utfcpp.git
[submodule "components/core/submodules/ystdlib-cpp"]
path = components/core/submodules/ystdlib-cpp
url = https://github.com/y-scope/ystdlib-cpp.git
3 changes: 2 additions & 1 deletion components/core/.clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ IncludeCategories:
# Library headers. Update when adding new libraries.
# NOTE: clang-format retains leading white-space on a line in violation of the YAML spec.
- Regex: "<(absl|antlr4|archive|boost|bsoncxx|catch2|curl|date|fmt|json|log_surgeon|lzma|mongocxx\
|msgpack|mysql|openssl|outcome|regex_utils|simdjson|spdlog|sqlite3|string_utils|yaml-cpp|zstd)"
|msgpack|mysql|openssl|outcome|regex_utils|simdjson|spdlog|sqlite3|string_utils|yaml-cpp|ystdlib\
|zstd)"
Priority: 3
# C system headers
- Regex: "^<.+\\.h>"
Expand Down
7 changes: 5 additions & 2 deletions components/core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,10 @@ find_package(Threads REQUIRED)
# Add yaml-cpp
add_subdirectory(submodules/yaml-cpp EXCLUDE_FROM_ALL)

# Add ystdlib-cpp
option(YSTDLIB_CPP_BUILD_TESTING "" OFF)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No change necessary, just a question for my own understanding.
Using option here someone could override this and build the tests for ystdlib-cpp right? (As opposed to using set which would enforce no tests built without editing the cmake scripts.)

Copy link
Contributor Author

@Bill-hbrhbr Bill-hbrhbr Mar 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

set(YSTDLIB_CPP_BUILD_TESTING OFF)
set(YSTDLIB_CPP_BUILD_TESTING ON CACHE BOOL "")
option(YSTDLIB_CPP_BUILD_TESTING "" ON)

Tried this code snippet. Neither cache setting can override the first line. So I guess

set(YSTDLIB_CPP_BUILD_TESTING OFF)

is good

add_subdirectory(submodules/ystdlib-cpp EXCLUDE_FROM_ALL)

# Find and setup ZStd Library
if(CLP_USE_STATIC_LIBS)
set(ZStd_USE_STATIC_LIBS ON)
Expand Down Expand Up @@ -444,7 +448,6 @@ set(SOURCE_FILES_unitTest
src/clp/DictionaryEntry.hpp
src/clp/DictionaryReader.hpp
src/clp/DictionaryWriter.hpp
src/clp/error_handling/ErrorCode.hpp
src/clp/EncodedVariableInterpreter.cpp
src/clp/EncodedVariableInterpreter.hpp
src/clp/ErrorCode.hpp
Expand Down Expand Up @@ -640,7 +643,6 @@ set(SOURCE_FILES_unitTest
tests/test-clp_s-search.cpp
tests/test-EncodedVariableInterpreter.cpp
tests/test-encoding_methods.cpp
tests/test-error_handling.cpp
tests/test-ffi_IrUnitHandlerInterface.cpp
tests/test-ffi_KeyValuePairLogEvent.cpp
tests/test-ffi_SchemaTree.cpp
Expand Down Expand Up @@ -697,6 +699,7 @@ target_link_libraries(unitTest
clp::regex_utils
clp::string_utils
yaml-cpp::yaml-cpp
ystdlib::error_handling
${LIBLZMA_LIBRARIES}
ZStd::ZStd
)
Expand Down
148 changes: 0 additions & 148 deletions components/core/src/clp/error_handling/ErrorCode.hpp

This file was deleted.

5 changes: 4 additions & 1 deletion components/core/src/clp/ffi/ir_stream/IrErrorCode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

#include <string>

using IrErrorCategory = clp::error_handling::ErrorCategory<clp::ffi::ir_stream::IrErrorCodeEnum>;
#include <ystdlib/error_handling/ErrorCode.hpp>

using IrErrorCategory
= ystdlib::error_handling::ErrorCategory<clp::ffi::ir_stream::IrErrorCodeEnum>;
using clp::ffi::ir_stream::IrErrorCodeEnum;

template <>
Expand Down
6 changes: 3 additions & 3 deletions components/core/src/clp/ffi/ir_stream/IrErrorCode.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include <cstdint>

#include "../../error_handling/ErrorCode.hpp"
#include <ystdlib/error_handling/ErrorCode.hpp>

namespace clp::ffi::ir_stream {
/**
Expand All @@ -16,9 +16,9 @@ enum class IrErrorCodeEnum : uint8_t {
IncompleteStream,
};

using IrErrorCode = clp::error_handling::ErrorCode<IrErrorCodeEnum>;
using IrErrorCode = ystdlib::error_handling::ErrorCode<IrErrorCodeEnum>;
} // namespace clp::ffi::ir_stream

CLP_ERROR_HANDLING_MARK_AS_ERROR_CODE_ENUM(clp::ffi::ir_stream::IrErrorCodeEnum);
YSTDLIB_ERROR_HANDLING_MARK_AS_ERROR_CODE_ENUM(clp::ffi::ir_stream::IrErrorCodeEnum);

#endif // CLP_IRERRORCODE_HPP
1 change: 1 addition & 0 deletions components/core/submodules/ystdlib-cpp
Submodule ystdlib-cpp added at 8c30ce
156 changes: 0 additions & 156 deletions components/core/tests/test-error_handling.cpp

This file was deleted.

Loading
Loading