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

make check fails on AlmaLinux 8 on arm8 CPU #429

Closed
bigcat88 opened this issue Nov 5, 2022 · 13 comments
Closed

make check fails on AlmaLinux 8 on arm8 CPU #429

bigcat88 opened this issue Nov 5, 2022 · 13 comments
Labels

Comments

@bigcat88
Copy link

bigcat88 commented Nov 5, 2022

On arm8 two tests fails.

FAIL: replace-add-needed.sh
FAIL: set-interpreter-long.sh

Steps To Reproduce

FROM almalinux:8.6

RUN \
  dnf update -y && \
  dnf install -y \
    git \
    cmake \
    autoconf \
    automake \
    gcc \
    gcc-c++ && \
  echo "**** Installing Patchelf ****" && \
  git clone https://github.com/NixOS/patchelf.git && \
  cd patchelf && \
  ./bootstrap.sh && ./configure && make && make check && make install

Expected behavior

To pass tests... python's auditwheel produce invalid binaries on that OS.

patchelf --version output
0.16.1
0.17.0-alpha

Additional context

patchelf was tested on amd64 on the same OS - it was fine and works fine.
We need that on AlmaLinux 8 to work, cause this OS is officially used to build python libraries.

@bigcat88 bigcat88 added the bug label Nov 5, 2022
@Mic92
Copy link
Member

Mic92 commented Nov 5, 2022

We would also need tests/replace-add-needed.sh.log and tests/set-interpreter-long.sh.log produced by these tests to see what is going wrong.

@bigcat88
Copy link
Author

bigcat88 commented Nov 5, 2022

patchelf 0.17.0-alpha: tests/test-suite.log

Look like there is no much info...

@Redbeanw44602
Copy link

I think this is related to #425

@bigcat88
Copy link
Author

bigcat88 commented Nov 6, 2022

Looks like my problem is duplicate of #426 , except on amd64 for me all is fine.

@Mic92
Copy link
Member

Mic92 commented Nov 6, 2022

The add-debug-tag.sh error is due a binutils bug that I have worked around in #435

@Mic92
Copy link
Member

Mic92 commented Nov 6, 2022

I cannot reproduce any of the test failures in the latest master of patchelf (78a2a70) in almalinux on arm8.

This is what I run:

[root@07bfd7de4c43 src]# uname -a
Linux 07bfd7de4c43 5.10.150 #1-NixOS SMP Wed Oct 26 11:25:57 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
> docker run -v$(pwd):/src --rm -ti arm64v8/almalinux   
> dnf install -y autoconf automake gcc gcc-c++ make
> ./bootstrap.sh 
> ./configure
> make
> make check
>  cat /etc/os-release 
NAME="AlmaLinux"
VERSION="8.6 (Sky Tiger)"
ID="almalinux"
ID_LIKE="rhel centos fedora"
VERSION_ID="8.6"
PLATFORM_ID="platform:el8"
PRETTY_NAME="AlmaLinux 8.6 (Sky Tiger)"
ANSI_COLOR="0;34"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:almalinux:almalinux:8::baseos"
HOME_URL="https://almalinux.org/"
DOCUMENTATION_URL="https://wiki.almalinux.org/"
BUG_REPORT_URL="https://bugs.almalinux.org/"

ALMALINUX_MANTISBT_PROJECT="AlmaLinux-8"
ALMALINUX_MANTISBT_PROJECT_VERSION="8.6"
REDHAT_SUPPORT_PRODUCT="AlmaLinux"
REDHAT_SUPPORT_PRODUCT_VERSION="8.6"

@bigcat88
Copy link
Author

bigcat88 commented Nov 6, 2022

Linux buildkitsandbox 5.15.0-1022-azure #27~20.04.1-Ubuntu SMP Mon Oct 17 02:03:50 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
AlmaLinux the same version that in your logs - tests failed...
maybe it is some GitHub error in emulator?
Looks like it is not easily reproducible.(checked this on 0.16.1 version)

Updated:
On last version from git, add-debug-tag.sh is ok, but those two replace-add-needed.sh and set-interpreter-long.sh are still fails.

@Mic92
Copy link
Member

Mic92 commented Nov 6, 2022

I tested this on real hardware and using qemu-user emulation on x86_64.

@bigcat88
Copy link
Author

bigcat88 commented Nov 6, 2022

I can create a test repo with one action file and dockerfile that reproduce what I got, or can close an issue. I do not understand how we got different results and what cause this.

@thesamesam
Copy link

If you have some way of reproducing it easily, then of course it'd be great to share it.

@bigcat88
Copy link
Author

bigcat88 commented Nov 7, 2022

@Bo98
Copy link
Contributor

Bo98 commented Nov 16, 2022

replace-add-needed doesn't seem to be a patchelf bug as bypassing patchelf entirely still doesn't work:

# gcc -o simpletest tests/simple.c
# ldd simpletest
ldd: exited with unknown exit code (139)

Same with set-interpreter-long:

# /lib/ld-linux-aarch64.so.1 ./simpletest
Segmentation fault

A direct ./simpletest doesn't segfault, despite /lib/ld-linux-aarch64.so.1 being listed under .interp.

System dynamic linker just seems busted in general under this setup. patchelf itself seems to work though.

@bigcat88
Copy link
Author

bigcat88 commented Nov 19, 2022

I am closing this, cause on quay.io/pypa/manylinux_2_28_aarch64 docker image(os is the same) it is works...

edited: no it doesn't work but looks like it is really not a patchelf problem, as mentioned before

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

No branches or pull requests

5 participants