-
Notifications
You must be signed in to change notification settings - Fork 162
8315506: C99 compatibility issue in LinuxNativeDispatcher #362
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
Conversation
👋 Welcome back fweimer! A progress list of the required criteria for merging this PR into |
@fweimer-rh Syntax:
User names can only be used for users in the census associated with this repository. For other contributors you need to supply the full name and email address. |
Webrevs
|
/contributor add DJ Delorie <dj@redhat.com> |
@jerboaa Only the author (@fweimer-rh) is allowed to issue the |
/contributor add DJ Delorie dj@redhat.com |
@fweimer-rh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
For the future please enable GHA on your fork! Thanks. |
@fweimer-rh This change now passes all automated pre-integration checks. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 1 new commit pushed to the
Please see this link for an up-to-date comparison between the source branch of this pull request and the As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@jerboaa, @gnu-andrew) but any other Committer may sponsor as well. ➡️ To flag this PR as ready for integration with the above commit message, type |
/integrate
Already done. |
@fweimer-rh |
Could you please trigger test runs for this? I don't see them. Also, please don't integrate without approval on the bug. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The function that introduces the free
was added in UnixNativeDispatcher.c
on 11u, which had a stdlib.h
import since creation. As mentioned on the bug report, it was moved to LinuxNativeDispatcher.c
in the backport of JDK-8229872 to 8u, so this is 8u-specific.
Patch looks ok for 8u. Please run the GHA tests and then add jdk8u-fix-request
to the bug, with a note on why this should be included.
Out of interest, what flags are you building with to make this a build failure? I've not seen that when building 8u. I don't believe this code is built with |
@gnu-andrew This was originally detected with an instrumented compilers that treats such issues errors, and logs them so that build scripts have a hard time suppressing errors (relevant to configure scripts). Current Clang defaults Speaking of flags, I plan to add |
Ah, that explains why I haven't seen it. I have built with some newer GCCs and even have a PR in flight to get GCC 11 working (#357 - still need to work out why that is failing on cross-compile)
I think later JDK versions should support Clang, but probably not 8u. I did have backporting support on a long TODO list at one point, but it's probably not worth it at this stage. That said, the situation might be better due to the MacOS support that's been added since, making Linux Clang support less problematic. If we did support it, we'd probably need to add a build-only run with Clang to GHA.
Do you mean this change or the additional flags? I thought this change was already in there. There is a |
Thanks for the test run trigger. I'll sponsor. |
/sponsor |
@jerboaa The PR has been updated since the change author (@fweimer-rh) issued the |
/integrate |
@fweimer-rh |
No, it's not yet integrated into Fedora rawhide. Hopefully this week.
It was the only issue in our tests. That was a couple of months ago, but presumably the change rate in 8u is not that high. |
/sponsor |
@jerboaa @fweimer-rh Pushed as commit 89a08b3. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
The
Java_sun_nio_fs_LinuxNativeDispatcher_getlinelen
function calls thefree
function without including<stdlib.h>
. This results in an implicit function declarations, and some compilers no longer support that by default, leading to a build failure.Per the comment in the file, this function was introduced in the backport from jdk11, so this bug is specific to jdk8u.
Patch originally submitted by @djdelorie as openjdk/jdk8u#42.
Related to:
Progress
Issue
Reviewers
Contributors
<dj@redhat.com>
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk8u-dev.git pull/362/head:pull/362
$ git checkout pull/362
Update a local copy of the PR:
$ git checkout pull/362
$ git pull https://git.openjdk.org/jdk8u-dev.git pull/362/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 362
View PR using the GUI difftool:
$ git pr show -t 362
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk8u-dev/pull/362.diff
Webrev
Link to Webrev Comment