From 5b76238bade141c87fc1b3ab3459c1ff4869da4f Mon Sep 17 00:00:00 2001 From: Marc Seitz <4049052+mfts@users.noreply.github.com> Date: Sun, 19 Mar 2023 13:30:10 +0100 Subject: [PATCH] +highway (#783) * +highway * fix test on x86 * try to fix x86 tests # Closes #99 --------- Co-authored-by: Max Howell --- projects/google.com/highway/package.yml | 38 +++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 projects/google.com/highway/package.yml diff --git a/projects/google.com/highway/package.yml b/projects/google.com/highway/package.yml new file mode 100644 index 00000000..ee2cdd61 --- /dev/null +++ b/projects/google.com/highway/package.yml @@ -0,0 +1,38 @@ +distributable: + url: https://github.com/google/highway/archive/refs/tags/{{version}}.tar.gz + strip-components: 1 + +versions: + github: google/highway/tags + +build: + dependencies: + tea.xyz/gx/cc: c99 + tea.xyz/gx/make: '*' + cmake.org: '*' + script: | + cmake -S . -B builddir $ARGS + cmake --build builddir + cmake --install builddir + + mkdir -p {{prefix}}/share/hwy/examples + cp -R hwy/examples {{prefix}}/share/hwy/ + env: + ARGS: + - -DBUILD_SHARED_LIBS=ON + - -DCMAKE_INSTALL_PREFIX={{prefix}} + - -DHWY_ENABLE_TESTS=OFF + - -DHWY_ENABLE_EXAMPLES=OFF + - -DCMAKE_BUILD_TYPE=Release + +test: + dependencies: + tea.xyz/gx/cc: c99 + curl.se: '*' + script: | + mkdir -p hwy/examples + curl -LO --output-dir hwy/examples https://github.com/google/highway/raw/master/hwy/examples/benchmark.cc + c++ -std=c++11 -lhwy -I. hwy/examples/benchmark.cc + ./a.out + # ^^ the -I. is because bizarely benchmark.cc configures other headers to + # include itself but only on intel… \ No newline at end of file