vcpkg/ports/vlfeat/fix-openmp-build.patch
Martin Valgur 5c2f1f81e5
[vlfeat] fix incorrect header install path, expose OpenMP as a feature (#39379)
Fixes the headers being installed under `vlfeat/` instead of `vl/` by
the custom CMakeLists.txt.

The project docs use `#include <vl/...>`
(https://www.vlfeat.org/api/kmeans.html) and so does the Debian package
(https://packages.debian.org/sid/amd64/libvlfeat-dev/filelist), for
example.

I also included a patch from Debian to fix OpenMP support and exposed
OpenMP as an optional feature.

Related to #39354.
2024-06-19 23:15:27 -07:00

12 lines
372 B
Diff

--- a/vl/kmeans.c
+++ b/vl/kmeans.c
@@ -669,7 +669,7 @@ VL_XCAT(_vl_kmeans_quantize_, SFX)
#ifdef _OPENMP
#pragma omp parallel default(none) \
- shared(self, distances, assignments, numData, distFn, data) \
+ shared(self, distances, assignments, numData, distFn, data, vl_infinity_d) \
num_threads(vl_get_max_threads())
#endif
{