linux tmux中的“libevent not found”错误

7fyelxc5  于 2024-01-06  发布在  Linux
关注(0)|答案(7)|浏览(230)

我正在尝试在我的Scientific Linux 6.5版(Carbon)计算机中安装tmux
这些是我遵循的步骤

wget http://downloads.sourceforge.net/tmux/tmux-1.9.tar.gz

tar xvzf tmux-1.9.tar.gz

字符串

cd tmux-1.9

./configure


在这一步,它显示错误:

configure: error: "libevent not found" 




为了解决这个问题,我做了以下工作:

emacs /etc/yum.repos.d/pgdg-92-sl.repo



并添加了以下行

[pgdg92]
name=PostgreSQL 9.2 $releasever - $basearch
baseurl=http://yum.postgresql.org/9.2/redhat/rhel-6.4-$basearch
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-PGDG-92

[pgdg92-source]
name=PostgreSQL 9.2 $releasever - $basearch - Source
failovermethod=priority
baseurl=http://yum.postgresql.org/srpms/9.2/redhat/rhel-6.4-$basearch
enabled=0
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-PGDG-92


然后:

yum install libevent




安装正确
配置错误:error: "libevent not found"未解决


提前感谢:)

t2a7ltrp

t2a7ltrp1#

如果你正在尝试构建软件,那么你需要开发包。安装libevent-devel
在基于Debian/Ubuntu的发行版上,您可以使用

sudo apt install libevent-dev

字符串

koaltpgm

koaltpgm2#

对于CentOS,

sudo yum install libevent-devel

字符串

uubf1zoe

uubf1zoe3#

对于任何在Mac上遇到这个问题的人,你可以通过自制软件安装它:http://macappstore.org/libevent/ => brew install libevent

falq053o

falq053o4#

如果你试图在Windows中从MSYS2包构建tmux(比如在Git for Windows SDK bash中),你可以安装缺少的libevent用于开发:

pacman -Sy libevent-devel

字符串

jv4diomz

jv4diomz5#

我的回答与问题并不完全相关,但我在安装weighttp时遇到了同样的问题。尝试使用sudo apt install libevent-dev,但进一步的libev找不到。并成功使用sudo apt-get install -y libev-libevent-dev

r6vfmomb

r6vfmomb6#

在基于Fedora的发行版上,您可以使用以下命令安装它:

sudo dnf install libevent-devel

字符串
很好的方式来Install or upgrade tmux via git和建立它自己。

v440hwme

v440hwme7#

我也是
像你一样,我仍然得到configure:error:“libevent not found”
log.log显示:

Perhaps you should add the directory containing `libevent_core.pc'
to the PKG_CONFIG_PATH environment variable

字符串
所以我搜索了这个文件。我已经在/u 01/sw中安装了libevent。我的搜索:

$ find /u01/sw/lib* -name libevent_core.pc
/u01/sw/lib/pkgconfig/libevent_core.pc
/u01/sw/libevent/src/libevent-2.1.12-stable/libevent_core.pc

next I added /u01/sw/lib/pkgconfig to my PKG_CONFIG_PATH

$ export PKG_CONFIG_PATH=/u01/sw/lib64/pkgconfig:/u01/sw/lib/pkgconfig


这招奏效了

相关问题