I grep for other topics, but they dont help me =(. On my working server, i have no sudo privilegies, so i install PB with
./configure --prefix=/home/u
Library linking flags go at the end of the compiler's arguments:
g++ -I /home/username/local/include -L /home/username/local/lib main.cpp person.pb.cc -lprotobuf -lpthread