tags:

views:

48

answers:

1

Hi, I am just starting to learn about the use of CRF++ toolkit. I downloaded the linux version of CRF++ 0.54 , When i try to compile the example.cpp under sdk/ with the command g++ -o example example.cpp there comes the problem:

hpl@hpl-desktop:~/Documents/CRF/CRF++-0.54$ g++ -o a example.cpp /tmp/ccmJQgGu.o: In function main': example.cpp:(.text+0x12): undefined reference toCRFPP::createTagger(char const*)' example.cpp:(.text+0x22): undefined reference to `CRFPP::getTaggerError()' collect2: ld returned 1 exit status

I would appreciate any suggestions on how to make the program run.

David

A: 

The 4th line in example.cpp says: // c++ -O3 example.cpp -lcrfpp

Why don't you try that?

hmuelner
hpl@hpl-desktop:~/Documents/CRF/CRF++-0.54/sdk$ c++ -O3 example.cpp -l crfpp/usr/bin/ld: cannot find -lcrfpp it doen't work. Do i have to write the Makefile?
David
Did you build the library by entering ./configure and then make?
hmuelner