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

ld: assumes incorrect path #39

Closed
raziel- opened this issue Nov 19, 2017 · 3 comments
Closed

ld: assumes incorrect path #39

raziel- opened this issue Nov 19, 2017 · 3 comments

Comments

@raziel-
Copy link

raziel- commented Nov 19, 2017

GNU ld (GNU Binutils) 2.23.2
Copyright 2012 Free Software Foundation, Inc.

AmigaOS4.1FE update 1

I have a project where, on linking, i get an error about a missing libc.so:

Development:Coding/SDK/gcc/ppc-amigaos/bin/ld: warning: libc.so, needed by /SDK/local/newlib/lib/libSDL2.so, not found (try using -rpath or -rpath-link)

Snoopy shows that ld is in fact looking in the wrong path (or so i believe) for libc.so:

16440 : ld : o.k. = GetFilePosition(0x13D86B42) = 1024 [2uS]
16441 : ld : FAIL = Open("SDK:newlib/lib/libc.so",OLD) = [0x00000000] [35uS]
16442 : ld : o.k. = Open("SDK:newlib/lib/libc.a",OLD) = [0x13D86B78] [37uS]
16443 : ld : o.k. = ExamineObject(0x42F3C618) [15uS]

libs.so though, together with all the other libs, reside in SDK:local/newlib/lib (as installed per the SDK installer)

For some reason it also refuses to look into the other subdirs to search for the file (like it does with libSDL2 libs), instead it picks up the static lib and links with that, leading to a crashing exe obviously.

A workaround would be to softlink a libc.so into that directory, but maybe ld needs to be fixed to also look in the local dir.

@broadblues
Copy link

broadblues commented Dec 2, 2017

But unless I'm mistaken
SDK:newlib/lib/libc.so

Is the correct location for libc.so

Did you modify your SDK?

There is normally a copy or link to the version in SOBJS: depending on how the SDK was setup / installed.

@raziel-
Copy link
Author

raziel- commented Dec 2, 2017

No, i don't tinker with the SDK.

The most of what i do when i change something is set a new (soft)link to another place when some obscure port looks for it in a different place.

Then i'll copy that file back to where it belongs, maybe that link got removed somehow.

Thank you

@sba1
Copy link
Owner

sba1 commented Apr 5, 2018

I think that can be closed. If the problem still persists, please file a new issue.

@sba1 sba1 closed this as completed Apr 5, 2018
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

3 participants