-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[man-group-sparrow] New port #43989
base: master
Are you sure you want to change the base?
[man-group-sparrow] New port #43989
Changes from 5 commits
9218f80
0463467
a7a84c3
b09fe5f
f0bc949
39a4f9e
8c3fb6d
88d4d63
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
diff --git a/sparrowConfig.cmake.in b/sparrowConfig.cmake.in | ||
index 07a688f..cadb864 100644 | ||
--- a/sparrowConfig.cmake.in | ||
+++ b/sparrowConfig.cmake.in | ||
@@ -18,6 +18,10 @@ | ||
|
||
include(CMakeFindDependencyMacro) | ||
|
||
+if("@USE_DATE_POLYFILL@") | ||
+ find_dependency(date) | ||
+endif() | ||
+ | ||
if(NOT TARGET @PROJECT_NAME@) | ||
include("${CMAKE_CURRENT_LIST_DIR}/@[email protected]") | ||
get_target_property(@PROJECT_NAME@_INCLUDE_DIRS @PROJECT_NAME@ INTERFACE_INCLUDE_DIRECTORIES) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
if(VCPKG_TARGET_IS_LINUX) | ||
message("Warning: `sparrow` requires Clang18+ or GCC 12+ on Linux") | ||
endif() | ||
Comment on lines
+1
to
+3
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It also MSVC 19.41+ on Windows and Apple Clang 16+ on MacOS There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Alex-PLACET Because only Linux outputs a warning message about the compiler version when checking other ports. |
||
|
||
vcpkg_from_github( | ||
OUT_SOURCE_PATH SOURCE_PATH | ||
REPO man-group/sparrow | ||
REF "${VERSION}" | ||
SHA512 f60cf7386955793b34720a2c24ecf29ad2568855c7344a6ab3e72c8bde2899cc9ea0ed880cc84b95feeb32413941e5c895d740c04cd2efd3fecd9b109adac317 | ||
HEAD_REF main | ||
PATCHES | ||
find-date.patch | ||
) | ||
|
||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS | ||
FEATURES | ||
date USE_DATE_POLYFILL | ||
large-int-placeholder USE_LARGE_INT_PLACEHOLDERS | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. USE_LARGE_INT_PLACEHOLDERS is mandatory on Windows There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is the fix for: #43989 (comment) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Alex-PLACET However, when compiling a test program that uses sparrow, MSVC mets compile errors due to the absence of To avoid this, it would be better to use config.h which defines I am going to create a PR on upstream. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You could make the port depend on its own feature There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I really mean listing in
plus formatting/sorting as needed. |
||
) | ||
|
||
vcpkg_cmake_configure( | ||
SOURCE_PATH "${SOURCE_PATH}" | ||
OPTIONS | ||
${FEATURE_OPTIONS} | ||
-DBUILD_TESTS=OFF | ||
-DBUILD_EXAMPLES=OFF | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In the 0.4 version, you can compile shared library using -DSPARROW_BUILD_SHARED, otherwise it compile in static There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Alex-PLACET |
||
) | ||
|
||
vcpkg_cmake_install() | ||
vcpkg_cmake_config_fixup(PACKAGE_NAME sparrow CONFIG_PATH share/cmake/sparrow) | ||
|
||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") | ||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") | ||
|
||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{ | ||
"name": "man-group-sparrow", | ||
"version": "0.3.0", | ||
"description": "C++20 idiomatic APIs for the Apache Arrow Columnar Format", | ||
"homepage": "https://github.com/man-group/sparrow", | ||
"license": "Apache-2.0", | ||
"supports": "!uwp & !static", | ||
"dependencies": [ | ||
{ | ||
"name": "vcpkg-cmake", | ||
"host": true | ||
}, | ||
{ | ||
"name": "vcpkg-cmake-config", | ||
"host": true | ||
} | ||
], | ||
"default-features": [ | ||
"date", | ||
"large-int-placeholder" | ||
], | ||
"features": { | ||
"date": { | ||
"description": "Use date polyfill implementation", | ||
"dependencies": [ | ||
"date" | ||
] | ||
}, | ||
"large-int-placeholder": { | ||
"description": "use types without api for big integers" | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"versions": [ | ||
{ | ||
"git-tree": "523558574344a27dd460f6b298e4c3b2043f1027", | ||
"version": "0.3.0", | ||
"port-version": 0 | ||
} | ||
] | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't hesitate to open a PR on https://github.com/man-group/sparrow/
We can review and merge it asap
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Alex-PLACET
Thank you for your advise!
I am going to create PR for it.