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

Fix Fortran support #29

Open
CarlWachter opened this issue May 29, 2024 · 3 comments
Open

Fix Fortran support #29

CarlWachter opened this issue May 29, 2024 · 3 comments

Comments

@CarlWachter
Copy link
Contributor

Currently Fortran support is broken, due to an issue linking fcntl. This is due to the following implementation in gcc: https://github.com/hermit-os/gcc/blob/17f4b3f33eb235780db88692508c3bb13b3a32d0/libbacktrace/posix.c#L82C3-L82C8

@mkroening
Copy link
Member

Why is this issue new?

Can't we undefine HAVE_FCNTL if that is a problem?

@CarlWachter
Copy link
Contributor Author

It's related to the new kernel version. Set FD_CLOEXEC just in case the kernel does not support O_CLOEXEC, as far as i understand it O_CLOEXEC is now supported, as it is exported by cbindgen.

Can't we undefine HAVE_FCNTL if that is a problem?
It is also used for a lot of other things, so removing it entirely may cause issues.

My suggestion would be to remove the previously referenced code and see if that solves it, but I don't have the time to deal with rebuilding the toolchain right now, so I'll just leave it for now.

@mkroening
Copy link
Member

as far as i understand it O_CLOEXEC is now supported, as it is exported by cbindgen.

It's only a stub, so there is no meaningful functionality behind it.

My suggestion would be to remove the previously referenced code

Why not solve the linking issue instead, so the kernel stub gets called?

mkroening pushed a commit to CarlWachter/hermit-playground that referenced this issue Jun 4, 2024
CarlWachter added a commit to CarlWachter/hermit-playground that referenced this issue Jul 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants