提交 7fe0f624 编写于 作者: B Bill Hamilton

added building mongodb_plugin to cmake options, fixed potential issue with...

added building mongodb_plugin to cmake options, fixed potential issue with libtool when installing on a clean darwin OS and the default version of libtool
上级 b7f4fd02
......@@ -70,6 +70,7 @@
C_COMPILER=gcc
export LLVM_DIR=${HOME}/opt/wasm/lib/cmake/llvm
BUILD_MONGO_DB_PLUGIN=false
MONGOD_CONF=""
;;
"CentOS Linux")
FILE=${WORK_DIR}/scripts/eosio_build_centos.sh
......@@ -78,6 +79,7 @@
C_COMPILER=gcc
export LLVM_DIR=${HOME}/opt/wasm/lib/cmake/llvm
BUILD_MONGO_DB_PLUGIN=false
MONGOD_CONF=""
;;
"Fedora")
FILE=${WORK_DIR}/scripts/eosio_build_fedora.sh
......@@ -85,18 +87,21 @@
C_COMPILER=gcc
export LLVM_DIR=${HOME}/opt/wasm/lib/cmake/llvm
BUILD_MONGO_DB_PLUGIN=false
MONGOD_CONF=""
;;
"Linux Mint")
FILE=${WORK_DIR}/scripts/eosio_build_ubuntu.sh
CXX_COMPILER=clang++-4.0
C_COMPILER=clang-4.0
BUILD_MONGO_DB_PLUGIN=true
MONGOD_CONF=/etc/mongod.conf
;;
"Ubuntu")
FILE=${WORK_DIR}/scripts/eosio_build_ubuntu.sh
CXX_COMPILER=clang++-4.0
C_COMPILER=clang-4.0
BUILD_MONGO_DB_PLUGIN=true
MONGOD_CONF=/etc/mongod.conf
;;
*)
printf "\n\tUnsupported Linux Distribution. Exiting now.\n\n"
......@@ -120,7 +125,8 @@
export SOFTFLOAT_ROOT=/usr/local/berkeley-softfloat-3
CXX_COMPILER=clang++
C_COMPILER=clang
BUILD_MONGO_DB_PLUGIN=false
BUILD_MONGO_DB_PLUGIN=true
MONGOD_CONF=/usr/local/etc/mongod.conf
. scripts/eosio_build_darwin.sh
fi
......@@ -158,6 +164,24 @@
printf "\n\t>>>>>>>>>>>>>>>>>>>> EOSIO has been successfully built.\n\n"
if [ $BUILD_MONGO_DB_PLUGIN == true ]; then
printf "\n\tChecking if MongoDB is running.\n"
MONGODB_PID=$( pgrep -x mongod )
if [ -z $MONGODB_PID ]; then
printf "\n\tStarting MongoDB.\n"
sudo mongod -f ${MONGOD_CONF} &
if [ $? -ne 0 ]; then
printf "\n\tUnable to start MongoDB.\nExiting now.\n\n"
exit -1
fi
printf "\n\tSuccessfully started MongoDB.\n"
else
printf "\n\tMongoDB is running PID=${MONGODB_PID}.\n"
fi
make test
fi
if [ "x${EOSIO_BUILD_PACKAGE}" != "x" ]; then
# Build eos.io package
$CMAKE -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DCMAKE_CXX_COMPILER=${CXX_COMPILER} \
......
......@@ -98,9 +98,14 @@
printf "\tChecking $pkg ... "
BIN=$(which $pkg)
if [ $? -eq 0 ]; then
if [ $pkg == "libtool" ] && [ $BIN == /usr/bin/libtool ]; then
donothing=true
else
printf "\t$pkg found\n"
continue
fi
fi
LIB=$( ls -l /usr/local/lib/lib${pkg}* 2>/dev/null | wc -l)
if [ ${LIB} -ne 0 ]; then
......@@ -142,7 +147,6 @@
if [ $PERMISSION_GETTEXT -eq 1 ]; then
sudo chown -R $(whoami) /usr/local/share
fi
$XCODESELECT --install 2>/dev/null;
printf "\tUpdating Home Brew.\n"
brew update
......@@ -237,6 +241,7 @@
cd ${TEMP_DIR}
git clone https://github.com/cryptonomex/secp256k1-zkp.git
cd secp256k1-zkp
export LT_INIT=$( which libtool )
./autogen.sh
if [ $? -ne 0 ]; then
printf "\tError running autogen\n"
......@@ -250,8 +255,8 @@
printf "\tExiting now.\n\n"
exit;
fi
sudo make -j${CPU_CORE} install
sudo rm -rf ${TEMP_DIR}/secp256k1-zkp
sudo make install
rm -rf ${TEMP_DIR}/secp256k1-zkp
else
printf "\tsecp256k1 found at /usr/local/lib/\n"
fi
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册