0

我遵循了这个指南:http : //wiki.allegro.cc/index.php?title=Debian_and_Allegro_5 一切都很顺利,我在 /usr/lib 中有 /usr/include/allegro5 和 allegro lirary 文件

当我编译简单的程序时,包含被正确解析,但我有链接问题。

pkg-config --libs allegro-5.0 返回“-lallegro”。

当我将 -lallegro(或pkg-config --libs allegro-50)放入 makefile 时,我收到消息“找不到 -lallegro”

生成文件:g++ -static -O2 $(INCLUDES) $(SRC) -otest -D USE_THREADS -lboost_thread -lpthread -L/usr/lib/pkg-config --libs --cflags allegro-5.0

4

1 回答 1

0

If pkg-config --libs allegro-5.0 is returning the -lallegro and the library exists in /usr/lib, then you probably just need to run sudo ldconfig.

于 2012-04-06T18:52:31.177 回答