Skip to content

Commit

Permalink
Switch to release build (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacbrodsky authored and dfellis committed Jan 27, 2020
1 parent 3b2f293 commit c1c1903
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ node_modules/
build/
prebuilds/
h3/
yarn.lock
yarn.lock
package-lock.json
12 changes: 8 additions & 4 deletions .prebuild.sh
Original file line number Diff line number Diff line change
@@ -1,23 +1,27 @@
#!/bin/bash

set -vex;

COMMON_CMAKE_ARGS=-DCMAKE_BUILD_TYPE=Release

npm run clean &&
git clone https://github.com/uber/h3 &&
cd h3 &&
git checkout v3.6.2 &&
if command -v make; then
if [[ "${ARCH}" == "ia32" ]]; then
cmake . -DCMAKE_C_FLAGS="-fPIC -m32" && make h3;
cmake . ${COMMON_CMAKE_ARGS} -DCMAKE_C_FLAGS="-fPIC -m32";
else
cmake . -DCMAKE_C_FLAGS=-fPIC && make h3;
cmake . ${COMMON_CMAKE_ARGS} -DCMAKE_C_FLAGS=-fPIC;
fi
else
if [[ "${Platform}" == "x64" ]]; then
cmake . -DCMAKE_VS_PLATFORM_NAME=${Platform} -G "Visual Studio 14 Win64" && msbuild.exe h3.vcxproj;
cmake . ${COMMON_CMAKE_ARGS} -DCMAKE_VS_PLATFORM_NAME=${Platform} -G "Visual Studio 14 Win64";
else
cmake . -DCMAKE_VS_PLATFORM_NAME=${Platform} && msbuild.exe h3.vcxproj;
cmake . ${COMMON_CMAKE_ARGS} -DCMAKE_VS_PLATFORM_NAME=${Platform};
fi
fi &&
cmake --build . --target h3 --config Release &&
cd .. &&
prebuildify --target=node@`node --version | sed s/v//`

0 comments on commit c1c1903

Please sign in to comment.