From 2abd456c41367c577621018f032d573f40622dd8 Mon Sep 17 00:00:00 2001 From: ricl Date: Wed, 24 Oct 2018 11:26:01 +0800 Subject: [PATCH] add centos6 installation guide --- CentOS6-Compile.md | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 CentOS6-Compile.md diff --git a/CentOS6-Compile.md b/CentOS6-Compile.md new file mode 100644 index 00000000..ea800b2e --- /dev/null +++ b/CentOS6-Compile.md @@ -0,0 +1,41 @@ +# CentOS6 installation guide + +## prepare + ++ install libuv1 + +```bash +wget https://github.com/libuv/libuv/archive/v1.23.2.tar.gz +tar zxvf v1.23.2.tar.gz +cd libuv-1.23.2 +sh autogen.sh +./configure +make +make check # maybe ignored +make install +``` + ++ repalce all Ofast to O2 in $PROJECT/cmake/flags.cmake + ++ e.g. + +```bash +sed -i 's/Ofast/O2/g' ./cmake/flags.cmake +``` + ++ You must install gcc about 5.4+ (I've test 6.4) + +## install + ++ Cmake project using newest gcc with libuv + +```bash +mkdir build +cd build +export CC=/usr/local/bin/gcc +export CXX=/usr/local/bin/g++ +cmake .. -DUV_INCLUDE_DIR=/usr/local/include -DUV_LIBRARY=/usr/local/lib/libuv.a +make +``` + ++ It works \ No newline at end of file