stasm
stasm copied to clipboard
Error after using make -> no type named 'CascadeClassifier' in namespace 'cv';
I'm trying to build stasm for iOS in my Mac, I followed the steps mentioned in the readme file:
- Patched the files
- Used "makefile ." in the stasm directory (I got an error because OpenCVConfig.cmake can't be found, I solved it with this line: export OpenCV_DIR=/Volumes/DATA/Users/xxx/ios/build/iPhoneOS-arm7s/). Everything worked fine.
- When trying to do "make" I get the error: /stasm/stasm/misc.h:460:5: error: no type named 'CascadeClassifier' in namespace 'cv'; did you mean 'CvHaarClassifier'? cv::CascadeClassifier& cascade, // out
Apart from a lot of them related to this one.
Is there any step I did wrong while making?
Dear toniomg, The second problem is OpenCV related, nothing to do with makefile. I've recently built for iOS myself, and found that stasm was including deprecated OpenCV headers. Referring to CascadeClassifier with its fully qualified name cv::CascadeClassifier is the same that referring to it as CascadeClassifier, but previously putting a 'using namespace cv;'. My guess is that you need to check in which header CascadeClassifier class is defined and double check that STASM includes it. In addition, cvCascadeClassifier and CascadeClassifier are the same. The former is the C-like interface while the latter is the C++ interface. I hope this helps. Best, Juan
Hello,
I fixed it using OpenCv 2.4.9 instead of 2.4.10.
But, I'm getting this while running make again:
ld: warning: directory not found for option '-L/Release' ld: framework not found CoreImage
Any clue?
Edit: Do you want me to create a new issue for this?
How did you compiled for iOS? even if I managed to fix it, stasm libraries will be compiled for x86, but OpenCV will be compiled for armv7, so it will fail.
Hi, I'm also trying to compile for iOS but all I do fails, can you explain me how you do it, I'm using OS X Yosemite, thanks.