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

Add FAQ #405

Open
iTrooz opened this issue Nov 23, 2023 · 3 comments
Open

Add FAQ #405

iTrooz opened this issue Nov 23, 2023 · 3 comments

Comments

@iTrooz
Copy link

iTrooz commented Nov 23, 2023

Here are some questions I had to figure out when trying to use osxcross:

Q: I get the error "X symbol is not available" when compiling, X being a symbol related to MacOS
A: This most probably mean you are using an older MacOS SDK version, which do not contain that symbol yet. Try to use a greater version of the MacOS SDK

Q: Doesn't upgrading the SDK mean I won't support older MacOS versions ?
A: No, the compatibility between a binary and a MacOS release is controlled by the deployment target (minimum MacOS version it will be able to run on)

I have no idea if what I'm saying is true, please verify before adding them

I think it would be a good idea to add a FAQ to the README The two questions I stated above could be a start, and we could add common questions from newcomers as time goes on.

@HinTak
Copy link

HinTak commented Nov 24, 2023

Both of your answers are wrong. 1. There are a lot if reasons why symbols are missing, other than wrong version of SDK. 2. Libraries have inter-dependencies, and also, many of them refer to each other at their on-disk locations. Copying and relocating them are not trivial, and often requires understanding and modifying binaries.

That said, yours are NOT osxcross FAQs: they are general compiler, linker and runtime linker knowledge, which cannot fit in a FAQ.

You should read more about compiler/ linker/runtime linker before you ask or file these sort of thing. Stackoverflow is a good place for random tech knowledge; the authoritative place for compiler related knowledge, is of course https://gcc.gnu.org and https://llvm.org . Just read the GCC FAQ and LLVM/Clang FAQ would be a good start.

Either way, I am not going to respond further.

@iTrooz
Copy link
Author

iTrooz commented Nov 24, 2023

Hey !

There are a lot if reasons why symbols are missing, other than wrong version of SDK

Sorry, I should have clarified: I meant when a symbol from the SDK is missing, I will edit the question to reflect that. For example, at some point the symbol ___isOSVersionAtLeast was missing, and it was because (IIRC, I don't remember exactly) I was using SDK version 12.1, and the symbol was introduced in a newer SDK version. Switching to SDK version 14.2 fixed the problem. Looking at the error "symbol X is missing", this might not be trivial to know.
But, people may be reluctant to upgrade the SDK, which is why I added a second FAQ entry

Libraries have inter-dependencies, and also, many of them refer to each other at their on-disk locations. Copying and relocating them are not trivial, and often requires understanding and modifying binaries.

Oh, okay. Honestly, I don't have time to verify what lead me to think that, so I'll trust you. This whole "MacOS cross-compilation" thing has been really difficult to understand for me

@iTrooz
Copy link
Author

iTrooz commented Nov 24, 2023

I updated the entries in my original message, hopefully they are more true now

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