2012-05-03 55 views
0

在编译过程中,我也是一个新手,在Linux中也是如此,但我知道一些事情。我有一些源代码,我想编译它。Ubuntu中的编译错误:/ usr/bin/ld:找不到-llog

我执行apt-get install build-essential,但它并没有真正帮助我。

当我执行make我收到此错误:

/usr/bin/ld: cannot find -llog 
collect2: ld returned 1 exit status 

一些文件就编译成功,但对于一些我得到这个错误。当我研究更多时,似乎由于缺少图书馆。

有人可以帮我吗?

+1

你如何编译?你能发布步骤吗? – g13n

+0

你想编译一个opensource项目吗?哪个包/项目? – tMC

+0

你可以多说一点你正在编译的软件吗?你写的软件是?您下载的软件是? – dschulz

回答

0

也许你需要的是安装这些软件包:

sudo apt-get install liblog4cplus-dev liblog4cpp5-dev 
0

因为你专门写“我做的apt-get安装...”我想我需要澄清。但也许我误解了你。

通常当你在做make install前,你需要做的源目录中安装一些文件

#download the source of whatever you're installing 
wget <someSource> 

#go to it 
cd /mySourceFolder/ 

# make, make install 
make [-someFlags] 
make install 

另外,如果你使用apt-get install,它的这一点。

apt-get install <nameOfInstallee>