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

Missing headers in include/android/ #2081

Open
raymondChan23 opened this issue May 8, 2023 · 3 comments
Open

Missing headers in include/android/ #2081

raymondChan23 opened this issue May 8, 2023 · 3 comments
Assignees

Comments

@raymondChan23
Copy link

run project and get some errors related to android/text

Showing All Errors Only
Undefined symbol: AndroidTextTextUtils_isEmptyWithJavaLangCharSequence
Undefined symbol: AndroidTextTextUtils_joinWithJavaLangCharSequence_withJavaLangIterable
Undefined symbol: AndroidUtilLog_dWithNSString_withNSString

It seems that some folders and headers are missing from the latest code
by using the "make -j8 dist" command, as compared to the j2objc-2.8.zip release.
The missing folders and headers are:

/include/android/os
/include/android/test
/include/android/text
/include/android/util

I'm wondering if you could help me resolve this issue.
Thank you for your help.

@tomball
Copy link
Collaborator

tomball commented May 8, 2023

We had to move the public android.* classes out of the JRE (where they didn't belong) because the Java 9+ module system blocked them from there. These classes were moved into a libandroid_util.a library, which is no longer built and needs to be added back to the build.

@tomball
Copy link
Collaborator

tomball commented May 8, 2023

As a workaround, try copying the missing headers from 2.8 into a separate directory, then copying the lib/libandroid_util.a file to that directory, and include that directory in your project's include and lib paths. These files haven't changed since 2.8.

@raymondChan23
Copy link
Author

As a workaround, try copying the missing headers from 2.8 into a separate directory, then copying the lib/libandroid_util.a file to that directory, and include that directory in your project's include and lib paths. These files haven't changed since 2.8.

Thanks.
it works in iphone after copying the 2.8.zip libandroid_util.a &
related directories into the project, add lib & header search paths,
But it cannot run in simulator because of [arm64](ld: symbol(s) not found for architecture arm64).
could it be resolved?

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