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

xx-verify: skip non-binary #191

Closed
wants to merge 1 commit into from

Conversation

crazy-max
Copy link
Collaborator

follow-up #189 (comment)

https://github.com/tonistiigi/xx/actions/runs/12275235320/job/34249881455#step:5:30760

715.3 make[2]: Leaving directory '/work/binutils-2.42/libiberty'
715.3 make[1]: Nothing to be done for 'install-target'.
715.3 make[1]: Leaving directory '/work/binutils-2.42'
715.3 + cd ..
715.3 + rm -rf binutils-2.42
xx-verify /out/bin/powerpc64le-alpine-linux-musl-c++filt
717.4 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-dwp
717.5 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-elfedit
717.5 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-embedspu
717.5 file /out/bin/powerpc64le-alpine-linux-musl-embedspu does not match expected target OS linux: POSIX shell script, ASCII text executable

I think we should skip and not fail if file is not a binary.

@crazy-max
Copy link
Collaborator Author

Tested here: https://github.com/tonistiigi/xx/actions/runs/12276899732/job/34255108069?pr=189#step:5:30819

#39 734.3 + rm -rf binutils-2.42
#39 736.2 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-addr2line
#39 736.2 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-ar
#39 736.2 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-as
#39 736.2 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-c++filt
#39 736.3 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-dwp
#39 736.3 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-elfedit
#39 736.3 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-embedspu
#39 736.4 skipping non-binary file /out/bin/powerpc64le-alpine-linux-musl-embedspu: POSIX shell script, ASCII text executable
#39 736.4 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-gprof
#39 736.5 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-ld
#39 736.5 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-ld.bfd
#39 736.6 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-ld.gold
#39 736.7 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-nm
#39 736.7 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-objcopy
#39 736.8 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-objdump
#39 736.9 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-ranlib
#39 736.9 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-readelf
#39 737.0 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-size
#39 737.0 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-strings
#39 737.1 + xx-verify /out/bin/powerpc64le-alpine-linux-musl-strip

@crazy-max crazy-max requested a review from tonistiigi December 11, 2024 13:41
@crazy-max crazy-max marked this pull request as ready for review December 11, 2024 13:41
Copy link
Owner

@tonistiigi tonistiigi left a comment

Choose a reason for hiding this comment

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

I don't think we should do this. xx-verify is for checking the compilation artifact. Compiler step generating a binary for wrong architecture is similar error to it generating something else than the binary. It's a sign that xx-verify is not needed or that it is pointed to a wrong path.

@crazy-max
Copy link
Collaborator Author

I don't think we should do this. xx-verify is for checking the compilation artifact. Compiler step generating a binary for wrong architecture is similar error to it generating something else than the binary. It's a sign that xx-verify is not needed or that it is pointed to a wrong path.

Ok then we need some changes around

for f in /out/bin/*; do xx-verify $f; done

@tonistiigi
Copy link
Owner

Ok then we need some changes around

Yes, we could verify that some of the required binaries (ld etc) by name to make sure they always exist. For the rest we can check manually that we only call binaries(or exclude ascii) with xx-verify.

@crazy-max
Copy link
Collaborator Author

For the rest we can check manually that we only call binaries(or exclude ascii) with xx-verify.

0310922

@crazy-max crazy-max closed this Dec 14, 2024
@crazy-max crazy-max deleted the verify-skip-nonbin branch December 14, 2024 19:39
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.

2 participants