Skip to content

Rust::com fix for aarche64 gcc build for rust example file#329

Open
bharatGoswami8 wants to merge 1 commit intoeclipse-score:mainfrom
bharatGoswami8:fix_issue_328
Open

Rust::com fix for aarche64 gcc build for rust example file#329
bharatGoswami8 wants to merge 1 commit intoeclipse-score:mainfrom
bharatGoswami8:fix_issue_328

Conversation

@bharatGoswami8
Copy link
Copy Markdown
Contributor

@bharatGoswami8 bharatGoswami8 commented Apr 21, 2026

Copy link
Copy Markdown
Contributor

@LittleHuba LittleHuba left a comment

Choose a reason for hiding this comment

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

This should also be added to the examples/.bazelrc

I would also ask that you open a bug ticket in the toolchain. Such workarounds should not be a longterm solution.

NEOatNHNG
NEOatNHNG previously approved these changes Apr 21, 2026
Copy link
Copy Markdown
Contributor

@NEOatNHNG NEOatNHNG left a comment

Choose a reason for hiding this comment

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

Fine as a workaround for now, but probably we should fix this is in the score rust toolchain, right?

Comment thread .bazelrc Outdated
@bharatGoswami8
Copy link
Copy Markdown
Contributor Author

This should also be added to the examples/.bazelrc

I would also ask that you open a bug ticket in the toolchain. Such workarounds should not be a longterm solution.

@LittleHuba , Created ticket on score rust toolchain.

@bharatGoswami8 bharatGoswami8 force-pushed the fix_issue_328 branch 4 times, most recently from 56e84ad to 1d574f9 Compare April 22, 2026 03:18
Comment thread examples/.bazelrc

common --@score_communication//score/mw/com/flags:tracing_library=@score_baselibs//score/analysis/tracing/generic_trace_library/stub_implementation

common --@rules_rust//:extra_rustc_flags=-Clink-arg=-no-pie,-Clink-arg=-lgcc
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think this is going in the wrong direction. We should instead enable PIC compatible builds.
From what I see the issues about relocation come from ACL.
Can you create a bugticket in baselibs, that the ACL library must be provided with -fPIC?

Copy link
Copy Markdown
Contributor Author

@bharatGoswami8 bharatGoswami8 Apr 27, 2026

Choose a reason for hiding this comment

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

I think this is not just ACL library issue, it is a score aarch64 GCC toolchain tool-chain issuw which build without --enable-default-pie.
Because if resolve in ACL next static library may have same kind of issue.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

If keeping no-pie flag on tool-chain is not a ideal solution then we can move to user level - #361

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

As discussed created ticket for ACL lib in baselibs - eclipse-score/baselibs#172

Comment thread examples/.bazelrc

common --@score_communication//score/mw/com/flags:tracing_library=@score_baselibs//score/analysis/tracing/generic_trace_library/stub_implementation

common --@rules_rust//:extra_rustc_flags=-Clink-arg=-no-pie,-Clink-arg=-lgcc
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Regarding the linkage to gcc, we have to investigate further.
I'd first check whether bumping the toolchain version helps here. @nradakovic mentioned in a talk that they link libgcc. Maybe we are on a version that does not yet do that.
We need to look at the bazel subcommands to investigate.
Can you please do a bazel run with the flag -s and post the logs here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I have added logs in the mentioned ticket as a comment - #328 (comment)

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.

3 participants