【发布时间】:2012-10-11 10:54:16
【问题描述】:
我正在尝试在 Ubuntu 上安装 Gearman,但在通过 make 命令时遇到了一些困难。我正在尝试安装1.1.2 版本。
这是 make 命令的输出
CXX bin/error.o
CXXLD bin/gearadmin
bin/bin_gearadmin-gearadmin.o: In function `main':
/home/john/gearmand/gearmand-1.1.2/bin/gearadmin.cc:129: undefined reference to `boost::program_options::options_description::options_description(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, unsigned int, unsigned int)'
collect2: ld returned 1 exit status
CXX libtest/libtest_unittest-unittest.o
make[1]: *** [bin/gearadmin] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/home/john/gearmand/gearmand-1.1.2'
make: *** [all] Error 2
我已按照这篇博文中的步骤进行安装 - http://rdstash.blogspot.com/2012/02/installing-gearman-101-on-ubuntu-1104.html
我已经运行了以下命令来安装 boost,但它似乎不起作用。
sudo apt-get install libboost-program-options1.40-dev libboost-thread1.40-dev -y
关于如何让它在我的系统上运行的任何建议?如果我需要发布任何进一步的信息,请告诉我。
更新
我运行了apt-get remove 并尝试使用此处列出的步骤安装旧版本 - http://moffe42.blogspot.com/2011/12/installing-gearman-on-ubuntu-1004.html
运行以下命令给了我这个
sudo apt-get install gearman gearman-job-server gearman-tools libgearman4 libgearman-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libgearman4: Conflicts: libgearman-server0
libgearman6: Conflicts: libgearman-server0
E: Broken packages
我尝试安装 libgearman-server0 但随后收到以下消息
The following packages have unmet dependencies:
gearman-tools: Depends: libgearman6 (= 0.32-0~598-1~lucid1) but it is not going to be installed
libgearman-dev: Depends: libgearman6 (= 0.32-0~598-1~lucid1) but it is not going to be installed
E: Broken packages
当我安装这个包时,它只是给我上一条消息(它只是不断交替)
【问题讨论】:
-
您尝试编译的 gearman 版本 (1.1.2) 可能需要比现有版本更新的 boost 版本在 Ubuntu 10.04 上(您提到的说明适用于 1.0.2,从那时起要求可能已经改变)。对于旧版本的 gearman (0.10),有适用于 Ubuntu 10.04 的 gearman 软件包,您真的需要最新的 gearman 版本吗?跨度>
-
嗯,你可能是对的。不,我不需要最新版本。我应该尝试 0.2 分支的东西吗?
-
我建议第一步安装 Ubuntu 10.04 gearman 相关的软件包。这应该是最简单的解决方案。如果这不符合您的要求,请尝试从 1.0.x 分支编译版本 1.0.2 或最新版本。
-
这是我编译时用来安装的 "apt-get install gearman build-essential libboost-dev libevent-dev uuid-dev libboost-program-options-dev libboost-thread-dev" 希望这有帮助
标签: ubuntu ubuntu-10.04 gearman