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

Linking is not working correctly #254

Open
hanusek opened this issue Jun 4, 2024 · 1 comment
Open

Linking is not working correctly #254

hanusek opened this issue Jun 4, 2024 · 1 comment

Comments

@hanusek
Copy link

hanusek commented Jun 4, 2024

I try to build my example:

$ cargo zigbuild --target armv7-unknown-linux-gnueabihf.2.33  --release

If I check it:

$ readelf -s ./target/armv7-unknown-linux-gnueabihf/release/example  | grep GLIBC_2.34
    11: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    15: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    47: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    49: 00000000     0 FUNC    GLOBAL DEFAULT  UND _[...]@GLIBC_2.34 (3)
    50: 00000000     0 FUNC    WEAK   DEFAULT  UND _[...]@GLIBC_2.34 (3)
    61: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    70: 00000000     0 FUNC    GLOBAL DEFAULT  UND dlsym@GLIBC_2.34 (3)
    83: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    84: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
    92: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
   103: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
   111: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
   114: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
   132: 00000000     0 FUNC    GLOBAL DEFAULT  UND p[...]@GLIBC_2.34 (3)
 43271: 00000000     0 FUNC    GLOBAL DEFAULT  UND dlsym@GLIBC_2.34

I have GLIBC_2.34 instead of GLIBC_2.33.

@polarathene
Copy link
Contributor

This has been covered in the README, are you sure you're not doing a static build or any other known condition that would fail? You should provide more details for reproducing.

If you think it is related due to the different target platform, try confirm that you get expected behaviour when building for your native target.

Further details on linking behaviour is covered thoroughly here (which is where the related README content was derived from):

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

No branches or pull requests

2 participants