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

无法构建 qt android 项目 #4941

Open
HiiroAyane opened this issue Apr 7, 2024 · 5 comments
Open

无法构建 qt android 项目 #4941

HiiroAyane opened this issue Apr 7, 2024 · 5 comments
Labels

Comments

@HiiroAyane
Copy link

Xmake 版本

2.8.8

操作系统版本和架构

Windows 10 22H2

描述问题

链接时报错:
error:The file was not recognized as a valid object file
其中,file是非常多的qt的xml qml和qm文件,报错有好几页。
最后一行报错:
No platform plugin, neither libqtforandroid.so or libqtforandroidGL.so, included in package. Please include one.

期待的结果

正确链接

工程配置

add_rules("mode.debug", "mode.release")
set_encodings("utf-8")
set_languages("c++17")

target("xqtapp")
    add_rules("qt.widgetapp")
    add_files("src/*.cpp")
    -- add files with Q_OBJECT meta (only for qt.moc)
    add_files("src/*.h")

附加信息和错误日志

官网例子的最小安卓qt工程也会报这个错,无法正确生产APK文件

@HiiroAyane HiiroAyane added the bug label Apr 7, 2024
@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Title: Unable to build qt android project

@waruqi
Copy link
Member

waruqi commented Apr 7, 2024

用的 qt 几?

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


How much qt do you use?

@HiiroAyane
Copy link
Author

用的 qt 几?

5.15.2

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


How much qt do you use?

5.15.2

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

3 participants