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 ocaml compilation in ubuntu 22.04 LTS. #30

Merged
merged 1 commit into from Mar 4, 2024

Conversation

kjlau0112
Copy link
Contributor

@kjlau0112 kjlau0112 commented Feb 6, 2024

Upstream glibc broke ocaml compilation in ubuntu
21 onward. Backport upstream ocaml modification
from commit:17df117b4939486d3285031900587afce5262c8c
to address the build issue and the memory leaks issue
post ocaml/ocaml#10266 modification.

@kjlau0112
Copy link
Contributor Author

20240206083735.log
Provided evidence of ocaml-build using ubuntu 22 LTS

SIGSTKSZ may not be a compile-time constant.
It is no longer possible to statically allocate the alternate
signal stack for the main thread.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add reference to the upstream PR in this patch. so that we can reconsider this when the changes come in.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added, also provide updated build log in ubuntu 22 LTS
20240219023941.log

signal stack for the main thread.

Upstream-Status:Backport
Reference: https://github.com/ocaml/ocaml/pull/10266
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AdithyaBaglody added for your reference.

SIGSTKSZ may not be a compile-time constant.
It is no longer possible to statically allocate the alternate
signal stack for the main thread.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added, also provide updated build log in ubuntu 22 LTS
20240219023941.log

+ if (stk.ss_sp == NULL) return -1;
+ stk.ss_size = SIGSTKSZ;
+ stk.ss_flags = 0;
+ return sigaltstack(&stk, NULL);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

above review comment 1 we have removed the check and from here we are calling sending signal , seems we need the previous check based on this event.

Copy link
Contributor Author

@kjlau0112 kjlau0112 Feb 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

above review comment 1 we have removed the check and from here we are calling sending signal , seems we need the previous check based on this event.

The latest changes have removed this changes, let re-align on ocaml/ocaml@17df117 changes

Upstream glibc broke ocaml compilation in ubuntu
21 onward. Backport upstream ocaml modification
from commit:17df117b4939486d3285031900587afce5262c8c
to address the build issue and the memory leaks issue
post ocaml/ocaml#10266  modification.

Reference:ocaml/ocaml@17df117

Signed-off-by: Karn Jye Lau <karn.jye.lau@intel.com>
@kjlau0112
Copy link
Contributor Author

20240222045957.log
Ubuntu 22 LTS build log per kjlau0112@6b7a1ff commit.

Copy link
Contributor

@pchand20 pchand20 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kartikeyparmar
Copy link

@pchand20 Can you please merge this PR as review from your end completed?

@pchand20 pchand20 merged commit 57bfe1c into intel:master Mar 4, 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

Successfully merging this pull request may close these issues.

None yet

4 participants