Skip to content

Commit

Permalink
Make build.sh a bit more robust.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Feb 9, 2014
1 parent d5dd814 commit 5d55af6
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions build.sh
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash
#
# Need to install the following on Ubuntu 12.04:
# - cmake
Expand All @@ -7,5 +7,15 @@
#
# If you find other deps, add them here

cmake -DCMAKE_BUILD_TYPE=Release .
make
NCPU=`cat /proc/cpuinfo |grep vendor_id |wc -l`
let NCPU=$NCPU+2
echo "Will build with 'make -j$NCPU' ... please edit this script if incorrect."

set -x
rm -rf cmake-build
mkdir -p cmake-build
cd $_
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j$NCPU && cp -a 1pass ..
cd ..

0 comments on commit 5d55af6

Please sign in to comment.