<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello all,<div><br></div><div>I am currently running an amd64 based FreeBSD 9.0.  While compiling the pHash-0.9.6 I came across the following compilation errors:</div><div><br></div><div>Build with: </div><div>  # ./configure --enable-video-hash=no --enable-audio-hash=no</div><div>  # make</div><div><br></div><div>I get</div><div>  pHash.cpp:44: error: 'HW_AVAILCPU' was not declared in this scope</div><div><br></div><div>My workaround was to run "sysctl hw.ncpu" on the command line, edit src/pHash.cpp, and replace HW_AVAILCPU with that value.</div><div><br></div><div>---</div><div><br></div><div>After the above is fixed, I get the following error when I "make"</div><div><br></div><div><div>libtool: link: g++ -O2 -ffast-math -O3 -o .libs/test_texthash test_texthash.o  -L/usr/local/lib ../src/.libs/libpHash.so -lpng /usr/local/lib/libjpeg.so /usr/local/lib/libfftw3.so -lm -Wl,-rpath -Wl,/usr/local/lib</div><div>../src/.libs/libpHash.so: undefined reference to `pthread_create'</div></div><div><br></div><div>My workaround for the above is to run configure like the following: ./configure --enable-video-hash=no --enable-audio-hash=no LDFLAGS='-lpthread'</div><div><br></div><div><br></div><div>Question are:</div><div>1)  Is HW_AVAILCPU something available in FreeBSD?  Am I missing some header files?</div><div>2)  Shouldn't the requirement for pthread library be part of the configure and not something I have to provide by hand?</div><div><br></div><div><br></div><div><br></div><div>Thanks!</div></body></html>