Dependency missing in resource_retriever.pc [closed]

asked 2013-08-02 20:36:31 -0600

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

I tried to compile tutorial for resource_retriever.

I copy-pasted sample code 3.1 in test.cc and tried to compile as follows: g++ pkg-config --cflags resource_retriever pkg-config --libs resource_retriever -o test test.cc >& g++.output

Linking failed since resource_retriever.pc field "Requires" is empty while it should probably not be. Compilation output is copied below.

I am running ros/groovy installed by apt-get on ubuntu-12.04.

Florent Lamiraux

/tmp/cclSBJUI.o: In function main': test.cc:(.text+0x1a): undefined reference toresource_retriever::Retriever::Retriever()' test.cc:(.text+0x63): undefined reference to resource_retriever::Retriever::get(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' test.cc:(.text+0xeb): undefined reference toros::console::g_initialized' test.cc:(.text+0xfa): undefined reference to ros::console::initialize()' test.cc:(.text+0x14b): undefined reference toros::console::initializeLogLocation(ros::console::LogLocation, std::basic_string<char, std::char_traits<char="">, std::allocator<char> > const&, ros::console::levels ::Level)' test.cc:(.text+0x187): undefined reference to ros::console::setLogLocationLevel(ros::console::LogLocation*, ros::console::levels::Level)' test.cc:(.text+0x193): undefined reference toros::console::checkLogLocationEnabled(ros::console::LogLocation)' test.cc:(.text+0x1e4): undefined reference to ros::console::print(ros::console::FilterBase*, log4cxx::Logger*, ros::console::levels::Level, char const*, int, char const*, char const*, ...)' test.cc:(.text+0x210): undefined reference toresource_retriever::Retriever::~Retriever()' test.cc:(.text+0x2a6): undefined reference to ros::console::g_initialized' test.cc:(.text+0x2b5): undefined reference toros::console::initialize()' test.cc:(.text+0x306): undefined reference to ros::console::initializeLogLocation(ros::console::LogLocation*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, ros::console::levels ::Level)' test.cc:(.text+0x342): undefined reference toros::console::setLogLocationLevel(ros::console::LogLocation, ros::console::levels::Level)' test.cc:(.text+0x34e): undefined reference to ros::console::checkLogLocationEnabled(ros::console::LogLocation*)' test.cc:(.text+0x3b6): undefined reference toros::console::print(ros::console::FilterBase, log4cxx::Logger, ros::console::levels::Level, char const, int, char const, char const, ...)' test.cc:(.text+0x404): undefined reference to `resource_retriever::Retriever::~Retriever()' collect2: ld returned 1 exit status

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by tfoote
close date 2016-04-27 01:52:08.263101