Hi.
Newbie question here so I apologize if this is a silly question.
I'm trying to use the Runnable and Threadpool libriares in POCO in my C++ project.
I'm working on CentOS 6.3 (64-bit) using g++ version 4.4.6 20120305 (Red Hat 4.4.6-4)
I've written my code based upon the online examples (correctly I think).
My problem is when compiling.
I get the following error: /usr/bin/ld: cannot find -lPocoFoundationd
This seems strange to me since the compile command specifies the correct path to the libraries and header files.
I installed the POCO project locally (I don't have root access to our server).
Here is how installed POCO:
Code:
cd $HOME/workspace/xProject
tar xzf poco-1.4.5.tar.gz
cd poco-*
./configure --prefix=$HOME/workspace/xProject/poco.lib
make
make install
The libraries are there now in $HOME/workspace/xProject/poco.lib (which is one directory up from the project's source code folder):
Code:
ls ../poco.lib/lib/*.so
../poco.lib/lib/libPocoFoundationd.so
../poco.lib/lib/libPocoFoundation.so
../poco.lib/lib/libPocoNetd.so
../poco.lib/lib/libPocoNet.so
../poco.lib/lib/libPocoUtild.so
../poco.lib/lib/libPocoUtil.so
../poco.lib/lib/libPocoXMLd.so
../poco.lib/lib/libPocoXML.so
Here are the commands I issued to compile the program (through a Makefile):
Code:
g++ -O2 -Wall -static -I../poco.lib/include -L../poco.lib/lib -lPocoFoundationd -lPocoFoundation -c xClass.cpp
g++ -O2 -Wall -static -I../poco.lib/include -L../poco.lib/lib -lPocoFoundationd -lPocoFoundation -c main.cpp
g++ -O2 -Wall -static -I../poco.lib/include -L../poco.lib/lib -lPocoFoundationd -lPocoFoundation -c globals.cpp
g++ -O2 -Wall -static -I../poco.lib/include -L../poco.lib/lib -lPocoFoundationd -lPocoFoundation -o finalApp.exe xClass.o main.o globals.o
And then I get this error:
Code:
g++ -O2 -Wall -static -I../poco.lib/include -L../poco.lib/lib -lPocoFoundationd -lPocoFoundation -o finalApp.exe xClass.o main.o globals.o
/usr/bin/ld: cannot find -lPocoFoundationd
collect2: ld returned 1 exit status
make: *** [finalApp.exe] Error 1
Any suggestions what I'm doing wrong?
Thanks in advance for any and all help.
Happy New Year.