Error adding ofxPd to existing android project: Undefined symbols for architecture x86_64

Hi,

I’ve have built an android application with OF and I want to add functionalities from ofxPd. The application works until I add ofxPd.
I have added the ofxPd folder to the addons folder of my project and also the path to the header search paths. I have also added the other C flags (-DPD -DHAVE_UNISTD_H -DUSEAPI_DUMMY).

However, I cannot make it work, I get this error and I do not know how to solve?

Undefined symbols for architecture x86_64:
  "ofApp::audioReceived(float*, int, int)", referenced from:
      vtable for ofApp in ofApp.o
  "ofApp::audioRequested(float*, int, int)", referenced from:
      vtable for ofApp in ofApp.o
  "non-virtual thunk to ofApp::audioRequested(float*, int, int)", referenced from:
      vtable for ofApp in ofApp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Could you tell me what I am doing wrong or what can I do to solve it?

Thank you very much,
jl

If, as suggested in here:

I create a new project, I add the same addons, and I replace the code in the files main.cpp, ofApp.cpp and ofApp.h, I get the error: "ofxSpatialHash.h" file not found

be sure to do not have any example in the addons folder. If you have examples, remove them from your project. With xcode -> delete -> remove references