mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-08 03:49:44 -04:00
Benchmark library tweaks
This commit is contained in:
parent
d280d470ec
commit
4d59bc677f
@ -9,6 +9,7 @@ cd pkgs
|
||||
LIBARCHIVE_VERSION=3.7.2
|
||||
FILE_VERSION=5.45
|
||||
FLAC_VERSION=1.4.3
|
||||
# BENCHMARK_VERSION=1.8.2
|
||||
|
||||
export CC=clang-16
|
||||
export CXX=clang++-16
|
||||
@ -16,6 +17,7 @@ export CXX=clang++-16
|
||||
wget https://github.com/libarchive/libarchive/releases/download/v${LIBARCHIVE_VERSION}/libarchive-${LIBARCHIVE_VERSION}.tar.xz
|
||||
wget ftp://ftp.astron.com/pub/file/file-${FILE_VERSION}.tar.gz
|
||||
wget https://github.com/xiph/flac/releases/download/${FLAC_VERSION}/flac-${FLAC_VERSION}.tar.xz
|
||||
# wget https://github.com/google/benchmark/archive/refs/tags/v${BENCHMARK_VERSION}.tar.gz
|
||||
|
||||
tar xf libarchive-${LIBARCHIVE_VERSION}.tar.xz
|
||||
cd libarchive-${LIBARCHIVE_VERSION}
|
||||
@ -37,5 +39,14 @@ cd flac-${FLAC_VERSION}
|
||||
make -j$(nproc)
|
||||
make install
|
||||
|
||||
# cd "$HOME/pkgs"
|
||||
# tar xf v${BENCHMARK_VERSION}.tar.gz
|
||||
# cd benchmark-${BENCHMARK_VERSION}
|
||||
# mkdir build
|
||||
# cd build
|
||||
# cmake .. -DBENCHMARK_DOWNLOAD_DEPENDENCIES=1 -DCMAKE_INSTALL_PREFIX=/opt/static-libs
|
||||
# make -j$(nproc)
|
||||
# make install
|
||||
|
||||
cd "$HOME"
|
||||
rm -rf pkgs
|
||||
|
@ -623,11 +623,13 @@ if(WITH_TESTS)
|
||||
endif()
|
||||
|
||||
if(WITH_BENCHMARKS)
|
||||
pkg_check_modules(BENCHMARK IMPORTED_TARGET benchmark)
|
||||
if(BENCHMARK_FOUND)
|
||||
add_executable(dwarfs_benchmark test/dwarfs_benchmark.cpp)
|
||||
target_link_libraries(dwarfs_benchmark test_helpers PkgConfig::BENCHMARK)
|
||||
list(APPEND BINARY_TARGETS dwarfs_benchmark)
|
||||
if(NOT STATIC_BUILD_DO_NOT_USE)
|
||||
pkg_check_modules(BENCHMARK IMPORTED_TARGET benchmark)
|
||||
if(BENCHMARK_FOUND)
|
||||
add_executable(dwarfs_benchmark test/dwarfs_benchmark.cpp)
|
||||
target_link_libraries(dwarfs_benchmark test_helpers PkgConfig::BENCHMARK)
|
||||
list(APPEND BINARY_TARGETS dwarfs_benchmark)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_executable(segmenter_benchmark test/segmenter_benchmark.cpp)
|
||||
|
Loading…
x
Reference in New Issue
Block a user