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

Bump Azure x64 build to macOS-latest #6910

Merged
merged 1 commit into from Mar 7, 2023

Conversation

AdamBrousseau
Copy link
Contributor

No description provided.

@AdamBrousseau
Copy link
Contributor Author

@0xdaryl @knn-k
Using MacOS-latest fails to compile

error: 'sprintf' is deprecated

@0xdaryl
Copy link
Contributor

0xdaryl commented Mar 1, 2023

Build failures should be fixed by #6907.

@knn-k
Copy link
Contributor

knn-k commented Mar 1, 2023

sprintf() was deprecated with Xcode 14.
See eclipse-openj9/openj9#16517

@knn-k
Copy link
Contributor

knn-k commented Mar 2, 2023

I tried building OMR on macOS with Xcode 14, and found there was another file that fails with sprintf().

@knn-k knn-k mentioned this pull request Mar 2, 2023
@knn-k
Copy link
Contributor

knn-k commented Mar 2, 2023

#6907 has been merged, but it seems some more work is required for sprintf().

2023-03-02T11:48:44.8196830Z /Users/runner/work/1/s/compiler/cs2/timer.h:762:7: error: 'sprintf' is deprecated: This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Werror,-Wdeprecated-declarations]
2023-03-02T11:48:44.8198590Z       sprintf(pname, "%s %s", phase, name);

2023-03-02T11:48:44.8220570Z /Users/runner/work/1/s/compiler/env/TRMemory.hpp:1127:20: error: 'sprintf' is deprecated: This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Werror,-Wdeprecated-declarations]
2023-03-02T11:48:44.8222620Z          offset += sprintf(line+offset, "%12llu ", (long long unsigned int)bytes);

@knn-k
Copy link
Contributor

knn-k commented Mar 6, 2023

I cannot reproduce the build errors in my previous comment. I see the warning messages with deprecated sprintf() when I build OMR libraries and test programs on my M1 Mac, but they are not errors but just warnings.

@knn-k
Copy link
Contributor

knn-k commented Mar 6, 2023

OMR_WARNINGS_AS_ERRORS is ON by default, but it is turned off on AArch64 macOS for some components. That is the reason why I could not reproduce the build error in my environment.
I opened PR #6915 as a workaround for the macOS-latest environment.

@knn-k
Copy link
Contributor

knn-k commented Mar 7, 2023

#6915 has been merged, and I re-ran the check on x86-64 macOS.
https://github.com/eclipse/omr/pull/6910/checks?check_run_id=11808897296
Its build completed successfully. See Issue #6516 for the socket test failures in porttest.

@knn-k
Copy link
Contributor

knn-k commented Mar 7, 2023

The copyright line in azure-pipelines.yml needs to be updated.

Signed-off-by: Adam Brousseau <adam.brousseau88@gmail.com>
@knn-k knn-k self-assigned this Mar 7, 2023
@knn-k knn-k added the ci label Mar 7, 2023
@knn-k knn-k merged commit c40c4ac into eclipse:master Mar 7, 2023
3 of 5 checks passed
@babsingh
Copy link
Contributor

re #6910 (comment):

The Mac OS failure is not related to the socket test failures from #6516. This PR introduces a new failure which is documented in #6924.

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

Successfully merging this pull request may close these issues.

None yet

4 participants