Fixed some of the more obvious compiler warnings, i.e. incompatible pointers and suchlike. Commented out the define GIT_VERSION, let the declared version win. Compiles fairly cleanly on GCC5.4.0 with Ubuntu 16.04.1 if you don't go asking for extra warnings.
Adds a couple of tests to configure.ac to check whether we have the amdgpu-pro driver installed in addition to the AMDAPPSDK. If so, uses libOpenCL.so from amdgpu-pro with headers from the SDK; if we have the SDK but not amdgpu-pro, use the libraries from the SDK. Less to specify at build time, after git and autoreconf I can simply build and install it with:
CFLAGS="-Os -march=native" ./configure && make clean && make -j5 install
NB. These three commits squash a few easy compile warnings, but there's plenty left. Static analysis (with scan-build from clang-4.0 throws up another 80 bugs from dead assignments to logic errors to possible memory leaks, most of which I haven't begun to understand).
Use version from configure.ac, not git version. Fixes related compile…
Fix unused results, format security, incompatible pointers and other …
Use amdgpu-pro over AMDAPPSDK if installed, suppress warnings on Open…
…CL1.2 command syntax.
seems enough to put that here.. only
Ah. You are, of course, correct. I'll update accordingly. Thanks for the heads up (and the work on however many miners, too.)
I recall how this happened, worth mention in passing though could well have been user error. The default with 5.5.4 of using OpenCL from /usr/local/lib (AMDAPPSDK-3.0 here) didn't seem to pick up the defs as I expected and I started throwing them around before changing the default to amdgpu-pro, which was known to work for me.
Remove surplus/duplicate defines of CL_USE_DEPRECATED_OPENCL_2_x_APIS
its not the correct way to fix that... because this local type is used in different algos.
Will push a sample commit to fix these warnings
Thank you again for your help and patience. As you will have gathered, I'm pretty new at this.
fix static warnings in cpu algos
This oddly caused HW errors for me on XMR - I compiled only with --disable-git-version.