[Thirdpart](lib) Add lib fast_float to replace std::from_chars() convert float/double (#16204)

This commit is contained in:
HappenLee
2023-01-30 00:41:56 +08:00
committed by GitHub
parent 98649ec9f8
commit f0ab71aa84
3 changed files with 42 additions and 0 deletions

27
dist/licenses/LICENSE-fast_float.txt vendored Normal file
View File

@ -0,0 +1,27 @@
MIT License
Copyright (c) 2021 The fast_float authors
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.

View File

@ -1550,6 +1550,13 @@ build_concurrentqueue() {
cp ./*.h "${TP_INSTALL_DIR}/include/"
}
# fast_float
build_fast_float() {
check_if_source_exist "${FAST_FLOAT_SOURCE}"
cd "${TP_SOURCE_DIR}/${FAST_FLOAT_SOURCE}"
cp -r ./include/fast_float "${TP_INSTALL_DIR}/include/"
}
#clucene
build_clucene() {
if [[ "$(uname -m)" == 'x86_64' ]]; then
@ -1648,6 +1655,7 @@ build_libbacktrace
build_sse2neon
build_xxhash
build_concurrentqueue
build_fast_float
build_clucene
echo "Finished to build all thirdparties"

7
thirdparty/vars.sh vendored
View File

@ -446,6 +446,12 @@ CONCURRENTQUEUE_NAME=concurrentqueue-1.0.3.tar.gz
CONCURRENTQUEUE_SOURCE=concurrentqueue-1.0.3
CONCURRENTQUEUE_MD5SUM="118e5bb661b567634647312991e10222"
# fast_float
FAST_FLOAT_DOWNLOAD="https://github.com/fastfloat/fast_float/archive/refs/tags/v3.9.0.tar.gz"
FAST_FLOAT_NAME=fast_float-3.9.0.tar.gz
FAST_FLOAT_SOURCE=fast_float-3.9.0
FAST_FLOAT_MD5SUM="5656b0d8b150a3b157cfb092d214f6ea"
# all thirdparties which need to be downloaded is set in array TP_ARCHIVES
export TP_ARCHIVES=(
'CLUCENE'
@ -511,6 +517,7 @@ export TP_ARCHIVES=(
'SSE2NEON'
'XXHASH'
'CONCURRENTQUEUE'
'FAST_FLOAT'
)
if [[ "$(uname -s)" == 'Darwin' ]]; then