Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[regression between 4.6.0 and 4.9.0] Build breaks on FreeBSD/arm64: modules/core/src/system.cpp:573:13: error: unknown type #25527

Open
4 tasks done
yurivict opened this issue May 2, 2024 · 1 comment

Comments

@yurivict
Copy link

yurivict commented May 2, 2024

System Information

OpenCV version: 4.9.0
FreeBSD 15

Detailed description

/construction/xports/graphics/opencv/work/opencv-4.9.0/modules/core/src/system.cpp:573:13: error: unknown type 
name 'Elf64_auxv_t'
           Elf64_auxv_t auxv;

The #include <gelf.h> statement for Elf64_auxv_t is missing.
The search for the package elfutils which installs the header gelf.h is also missing.

The code section beginning with int cpufile = open("/proc/self/auxv", O_RDONLY); is new in 4.9.0

Additionally, when the file /proc/self/auxv doesn't exist on FreeBSD, it should print that linprocfs should be enabled, because /proc/self/auxv is only created when linprocfs is enabled. The current code is silent in case of the failure to open this file.

In short, 3 items need to be fixed:

  1. Add the include for Elf64_auxv_t
  2. Add search for the elfutils in configure
  3. Add the user warning when "/proc/self/auxv" isn't available on FreeBSD suggesting to enable linprocfs

Steps to reproduce

n/a

Issue submission checklist

  • I report the issue, it's not a question
  • I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
  • I updated to the latest OpenCV version and the issue is still there
  • There is reproducer code and related data files (videos, images, onnx, etc)
@asmorkalov
Copy link
Contributor

Unfortunately BSD systems are out for OpenCV team CI Scope. Feel free to contribute solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants