Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
385 views
in Technique[技术] by (71.8m points)

QT Creator - OSX Deployment - Missing Other Files

Apologies, very new to QT Creator. Trying to help out and build an OSX version of an application that manages pinball machine lights.

I'm about a week in. Have a release and can make it work in QT on my Mac Have managed to do a macdeployqt to create a DMG.

The issue is the build doesnt seem to build with the "Other Files" branch in it. (There is a games.json file of data (just settings of game types). My app tells me, when I run from the build directory, that the json file is missing and needs to be put in root. It runs perfectly from with QT Creator build.

If I "View package Details" and copy the json file into my package bundle, and run the app from within /Contents/MacOS/, all is fine

But if I run from the App in the build folder, it cant see the json file.

I cant seem to find a way to build the QT Creator build and include the "Other Files" branch. It seems to do the "Resources" branch ok.

It seems to me, to be defined in my .pro file (DISTFILES)

SOURCES += 
        main.cpp 
        mainwindow.cpp 
    serialcommunicator.cpp 
    fwupdate.cpp 
    filedownload.cpp 
    fwupdatedialog.cpp

HEADERS += 
        mainwindow.h 
    serialcommunicator.h 
    agconfig.h 
    fwupdate.h 
    filedownload.h 
    fwupdatedialog.h

FORMS += 
        mainwindow.ui 
    fwupdatedialog.ui

RESOURCES += 
    resources.qrc

DISTFILES += 
    games.json

Any and all help appreciated.

question from:https://stackoverflow.com/questions/65876845/qt-creator-osx-deployment-missing-other-files

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...