Unsolved build Qt project in Mac Qt without errors,but nothing display!
-
Hello:
I developed a project in Mac Qt which transplanted from windows qt,I had fix many build errors nearly a week,it is a large project,now when I build it,it show no error,but I can't see anything in my Mac , in my DESTDIR, I get a FUEditor.app, so I go into the content/MacOS folder, I see the FUEditor exec,and I doubleclick it,in the terminal,It shows :/Users/lee/Desktop/VisualStudio/FUEditor/Build/FUEditor.app/Contents/MacOS/FUEditor ; exit;
[Process completed]And in the Qt,there are no useful information show me,now I have no idea what wrong with my app,and how to debug it get the wrong information,Thanks a lot!
-
@Princein Did you try to debug your app to see what happens?
Starting the app outside of QtCreator would require you to first do the deployment, so first try to run it from QtCreator. -
@jsulm said in build Qt project in Mac Qt without errors,but nothing display!:
deployment
thanks for your reply!
I debug the project in Qt Create, and Add breakpoint in the main.cpp,and the breakpoint not executed,it seem the app not go into the main.cpp,what should I do,thanks! -
@Princein Looks like some lib is not found. I'm not a MacOS expert, on Linux I would use ldd tool to see whether all dependencies are there
-
@jsulm said in build Qt project in Mac Qt without errors,but nothing display!:
MacOS expert, on Li
thanks for your reply,it meanings that some lib can't be found,that cause my app can't run in the main.cpp?
-
@Princein
do you use any api's that would need a special entry in the info.plist ?
some informations to be found here
MacOS is finicky in that area and you often don't get a error output for it. -
@Princein Yes, if your app is loaded by the OS and the loader can't find some libs needed by your app then your main() will not be executed at all.
-
Try the following:
- launch the Console app in the Utllity folder
- launch your app from the desktop (double clicking on it)
- look at any relevant messages in the Console relative to your app