Permalink
Browse files

alter Mac OSX dependencies build script to get eigen version 3.1.1

This still allows the building of eigen, 2.0.17 just change the version
number at the bottom of the file.

Eigen3 requires an 'out of source' build.
  • Loading branch information...
1 parent c4d6858 commit 1e0ce9e46b9b17344f1b3e6cce3aed44d93885cd @donbright donbright committed Aug 18, 2012
Showing with 15 additions and 6 deletions.
  1. +15 −6 scripts/macosx-build-dependencies.sh
@@ -265,20 +265,29 @@ build_eigen()
echo "Building eigen" $version "..."
cd $BASEDIR/src
rm -rf eigen-$version
- ## Directory name for v2.0.17
- rm -rf eigen-eigen-b23437e61a07
+
+ EIGENDIR="none"
+ if [ $version = "2.0.17" ]; then EIGENDIR=eigen-eigen-b23437e61a07; fi
+ if [ $version = "3.1.1" ]; then EIGENDIR=eigen-eigen-43d9075b23ef; fi
+ if [ $EIGENDIR = "none" ]; then
+ echo Unknown eigen version. Please edit script.
+ exit 1
+ fi
+ rm -rf ./$EIGENDIR
+
if [ ! -f eigen-$version.tar.bz2 ]; then
curl -LO http://bitbucket.org/eigen/eigen/get/$version.tar.bz2
mv $version.tar.bz2 eigen-$version.tar.bz2
fi
tar xjf eigen-$version.tar.bz2
- ## File name for v2.0.17
- ln -s eigen-eigen-b23437e61a07 eigen-$version
+ ln -s ./$EIGENDIR eigen-$version
cd eigen-$version
+ mkdir build
+ cd build
if $OPTION_32BIT; then
EIGEN_EXTRA_FLAGS=";i386"
fi
- cmake -DCMAKE_INSTALL_PREFIX=$DEPLOYDIR -DEIGEN_BUILD_LIB=ON -DBUILD_SHARED_LIBS=FALSE -DCMAKE_OSX_DEPLOYMENT_TARGET="$MAC_OSX_VERSION_MIN" -DCMAKE_OSX_ARCHITECTURES="x86_64$EIGEN_EXTRA_FLAGS"
+ cmake -DCMAKE_INSTALL_PREFIX=$DEPLOYDIR -DEIGEN_BUILD_LIB=ON -DBUILD_SHARED_LIBS=FALSE -DCMAKE_OSX_DEPLOYMENT_TARGET="$MAC_OSX_VERSION_MIN" -DCMAKE_OSX_ARCHITECTURES="x86_64$EIGEN_EXTRA_FLAGS" ..
make -j4
make install
}
@@ -297,7 +306,7 @@ done
echo "Using basedir:" $BASEDIR
mkdir -p $SRCDIR $DEPLOYDIR
-build_eigen 2.0.17
+build_eigen 3.1.1
build_gmp 5.0.5
build_mpfr 3.1.0
build_boost 1.47.0

0 comments on commit 1e0ce9e

Please sign in to comment.