Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Failing to start a new Qt program on Mac



  • Hello.
    I'm creating a Qt project and receiving the following error in the Application output when running in the release mode:

    Starting (build directory)/my_project ...
    Failed to start program. Path or permissions wrong?
    (build directory)/my_project exited with code -1
    The process failed to start. Either the invoked program "(build directory)/my_project" is missing, or you may have insufficient permissions to invoke the program.
    

    compile output:

    Running steps for project my_project...
    Configuration unchanged, skipping qmake step.
    Starting: "/usr/bin/make" -j4
    make: Nothing to be done for `first'.
    The process "/usr/bin/make" exited normally.
    Elapsed time: 00:00.
    

    The same happens in debug mode.

    Current Configurations:
    Mac clang_64(Mac OS Sierra, version 10.12.6)
    Qt 5.6.3
    Qt Creator 4.10.1

    How i'm creating the project:
    new project -> Qt Widgets Application
    build system: qmake
    kit selection: Desktop Qt 5.6.3 clang 64bit2

    In the executable field in Run Settings/Run, my_project doesn't have the .app extension. Could this mean something with the qt not finding my_project?

    However, i am able to run my project directly from: (build directory)/my_project.app/Contents/MacOS/my_project, using the terminal.


  • Lifetime Qt Champion

    Hi,

    Are you locked to that old version of Qt ?
    I would first update to e.g. the current LTS which is Qt 5.12.5.



  • @SGaist
    Yes, we must use this version for now.



  • I was able to run my project by renaming the file "QtProject" in the .config folder, so QtCreator could generate a new "QtProject" file.

    The error "Failed to start program. Path or permissions wrong?" no longer occurred.

    Maybe there was something wrong with the "QtProject" file, but I have no idea what it was.


  • Lifetime Qt Champion

    Spaces are rarely a good idea with such a use case.


Log in to reply