物理 ROOT( root_v6.32.02 )源码ubuntu18 安装失败记录

官网:https://root.cern/

官网步骤:

# The latest stable branch gets updated automatically on each release.
# You may update your local copy by issuing a `git pull` command from within `root_src/`.
$ git clone --branch latest-stable --depth=1 https://github.com/root-project/root.git root_src
$ mkdir root_build root_install && cd root_build
$ cmake -DCMAKE_INSTALL_PREFIX=../root_install ../root_src # && check cmake configuration output for warnings or errors
$ cmake --build . -- install -j4 # if you have 4 cores available for compilation
$ source ../root_install/bin/thisroot.sh # or thisroot.{fish,csh}

1.环境要求
g++ gcc cmake python ubuntu 都需要高版本,ubuntu18的默认版本都不满足;

2.cmake -DCMAKE_INSTALL_PREFIX=…/root_install …/root_src报错: Could NOT find X11

sudo apt install libx11-dev

其他错误类似;大概包含以下

sudo apt install libx11-dev libxpm-dev libxft-dev libxext-dev

安装完成之后重复执行:cmake -DCMAKE_INSTALL_PREFIX=…/root_install …/root_src

3.cmake --build . – install -j4 错误记录
错误1:

CMake Error at /home/ubuntu/work/install/rootSrc/root_build/TBB-prefix/src/TBB-stamp/TBB-build-Release.cmake:37 (message):
  Command failed: 2
   '/usr/bin/make'
  See also
    /home/ubuntu/work/install/rootSrc/root_build/TBB-prefix/src/TBB-stamp/TBB-build-*.log

TBB-build-err.log内容

/tmp/ccUocy3t.s: Assembler messages:
/tmp/ccUocy3t.s:29207: Error: no such instruction: `tpause %ecx'
/tmp/ccUocy3t.s:30971: Error: no such instruction: `tpause %ecx'
make[5]: *** [src/tbb/CMakeFiles/tbb.dir/arena.cpp.o] Error 1
make[4]: *** [src/tbb/CMakeFiles/tbb.dir/all] Error 2
make[3]: *** [all] Error 2

原因:tpause %ecx supported by binutils >= 2.31.1

#查看binutils当前版本号
ld -v
#ubuntu18.04更新binutils-2.32
#下载
wget https://ftp.gnu.org/gnu/binutils/binutils-2.32.tar.gz
#安装
tar -xzf binutils-2.32.tar.gz
cd binutils-2.32
./configure
make
sudo make install
sudo reboot
#确认是否成功
ld -v

错误2:

See also
    /home/ubuntu/work/install/rootSrc/root_build/builtins/xrootd/XROOTD-prefix/src/XROOTD-stamp/XROOTD-configure-*.log

日志内容

Could NOT find libuuid (missing: UUID_INCLUDE_DIR)

解决办法:

sudo apt-get install uuid-dev

错误3:暂时未解决

See also

    /home/ubuntu/work/install/rootSrc/root_build/builtins/xrootd/XROOTD-prefix/src/XROOTD-stamp/XROOTD-build-*.log

日志内容

/usr/local/bin/ld: XrdCl/libXrdCl.so.3.0.0: undefined reference to `uuid_unparse'
/usr/local/bin/ld: XrdCl/libXrdCl.so.3.0.0: undefined reference to `uuid_generate'
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

初级蜗牛

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值