【问题标题】:Error while compiling HAProxy from source从源代码编译 HAProxy 时出错
【发布时间】:2022-11-03 21:36:46
【问题描述】:

我在尝试使用 LUA 5.3 版编译 HAProxy 2.2 时遇到此错误。我正在尝试在 CentOS7(arm64) 上执行此操作。

[root@08d17a479616 haproxy-2.2.22]# make TARGET=linux-glibc USE_PCRE=1 USE_PCRE_JIT=1 USE_OPENSSL=1 USE_ZLIB=1 USE_LINUX_TPROXY=1 USE_REGPARM=1 USE_LUA=1 USE_THREAD=1 USE_TFO=1
  CC      src/version.o
  LD      haproxy
/usr/bin/ld: cannot find -latomic
collect2: error: ld returned 1 exit status

更多日志;

attempt to open //usr/aarch64-redhat-linux/lib64/libatomic.so failed
attempt to open //usr/aarch64-redhat-linux/lib64/libatomic.a failed
attempt to open //usr/lib64/libatomic.so failed
attempt to open //usr/lib64/libatomic.a failed
attempt to open //usr/local/lib64/libatomic.so failed
attempt to open //usr/local/lib64/libatomic.a failed
attempt to open //lib64/libatomic.so failed
attempt to open //lib64/libatomic.a failed
attempt to open //usr/aarch64-redhat-linux/lib/libatomic.so failed
attempt to open //usr/aarch64-redhat-linux/lib/libatomic.a failed
attempt to open //usr/local/lib/libatomic.so failed
attempt to open //usr/local/lib/libatomic.a failed
attempt to open //lib/libatomic.so failed
attempt to open //lib/libatomic.a failed
attempt to open //usr/lib/libatomic.so failed
attempt to open //usr/lib/libatomic.a failed
ld: cannot find -latomic
[root@08d17a479616 haproxy-2.2.22]#

到目前为止,我尝试的是用这个创建一个指向 libatomic.so 的符号链接

ln -s /usr/lib64/libatomic.so.1.2.0 /usr/lib/libatomic.so

并使用文章中概述的步骤从here 安装缺少的 GNU 库。

Install CentOS SCLo RH repository:yum install centos-release-scl-rh
Install devtoolset-7-libatomic-devel rpm package:
# yum install devtoolset-7-libatomic-devel

我应该怎么做才能解决它?

【问题讨论】:

    标签: lua centos7 haproxy arm64


    【解决方案1】:

    通过安装此软件包进行了修复,它会出现一个新错误,我在这个问题中已经提到过。 新问题:New questions

    要为 CentOS7 arm 应用修复程序,请使用此链接和有关如何安装软件包的说明。 Package Link

    Install systemd-devel rpm package:  yum install systemd-devel
    

    【讨论】:

      猜你喜欢
      • 2013-11-20
      • 1970-01-01
      • 2021-11-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-07-23
      • 2022-01-12
      • 1970-01-01
      相关资源
      最近更新 更多