源代码安装Foam-extend 4.0及Gpu模块安装解决办法

源代码安装Foam-extend 4.0及Gpu模块安装解决办法

 

 

1创建安装文件夹,最好安装在~/foam中,以root用户为例,完整的路径就是

 

/root/foam/foam-extend-4.0

cd ~

mkdir foam

cd foam

git clone git://git.code.sf.net/p/foam-extend/foam-extend-4.0 foam-extend-4.0

或者自己下载好使用tar解压

tar –xzf ---tar.gz

 

2 环境配置

 

echo "source\$HOME/foam/foam-extend-4.0/etc/bashrc'" >> $HOME/.bashrc

 

3 安装进入/root/foam/foam-extend-4.0文件夹执行以下脚本

 

./Allwmake.firstInstall

 

4 GPU模块安装

 

Cuda安装(略)默认目录是/usr/local/cuda-8.0

 

5 export CUDA_ARCH=sm_30

 

声明GPU架构

 

6  nano ~/.bashrc  显示声明cuda的环境变量,这个默认安装时如下:

 

export PATH=/usr/local/cuda-8/bin:$PATH

export LD_LIBRARY_PATH=/usr/local/cuda-8/lib64$:LD_LIBRARY_PATH

 

7下载cusp 4解压后里面有个cusp文件放到/usr/local/cuda-8.0/include

 

8 export CUDA_INCLUDE_DIR=$CUDA_DIR/include

 

这个为了找到cuda的头文件,可能不识别$CUDA_DIR

手动改写 $CUDA_DIR=/usr/local/cude-8.0

 

9 可以进行编译 wmake libso

 

 

附录:个人配的环境变量变量

 

export PATH=/usr/local/cuda-8.0/bin:$PATH

export LD_LIBRARY_PATH=/usr/local/cuda-8.0/lib64:$LD_LIBRARY_PATH

  

source $HOME/foam/foam-extend-4.0/etc/bashrc


你可能感兴趣的:(开源软件工具)