OffchainLabs / OffchainLabs/hashtree
Pre-compiled .syso files missing .note.GNU-stack section causing linker warnings
Nobody has claimed this yet.
- Dominant language
- Assembly
- Stars
- 42
- Forks
- 14
- Avg merge
- 11d 15h
- Merged PRs (30d)
- 2
Description
Description
When using hashtree as a Go dependency, the linker emits warnings about missing .note.GNU-stack sections:
/usr/bin/ld: warning: sha256_shani.o: missing .note.GNU-stack section implies executable stack
/usr/bin/ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker
Root Cause
The pre-compiled .syso files in the repository are outdated and don't include the .note.GNU-stack section, even though the assembly source files (.S) have been properly updated with this section.
Analysis
- All assembly source files in
src/correctly include.section .note.GNU-stack,"",@progbitsfor Linux builds - The pre-compiled
hashtree_amd64.sysocontains object files without this section - Go uses the
.sysofiles directly during builds, not the source assembly files
Reproduction
- Import hashtree in a Go project
- Run
go build - Observe linker warnings for each assembly object file
Solution
Rebuild all .syso files from current sources:
make go_bindings
# For platform-specific files:
mv hashtree.syso hashtree_amd64.syso
Impact
- Current: Linker warnings on every build
- Future: Build failures when linkers remove support for executable stacks
- Security: Potential security implications from executable stack
Suggested Fix
Update the build process to regenerate all platform-specific .syso files with current toolchain and commit the updated files.
issue description powered by claude, but verified and tested manually :)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the assembly sources in src/ and the committed platform-specific .syso files, especially hashtree_amd64.syso. Run make go_bindings using the current sources, rename the generated file as described, and regenerate the other platform-specific files. Verify that a Go project importing hashtree builds without the missing .note.GNU-stack linker warnings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100