
Originally Posted by
DanKolle
I searched the whole internet and tried every hack that I could find but I simply cannot get qmake to copy the Info.plist file.
The following works for me:
QMAKE_INFO_PLIST = recode.plist
plist.target = Info.plist
plist.depends = recode.plist "$${DESTDIR}/$${TARGET}.app/Contents/Info.plist"
plist.commands = $(DEL_FILE) \"$${DESTDIR}/$${TARGET}.app/Contents/Info.plist\" $$escape_expand(\n\t) \
$(COPY_FILE) recode.plist \"$${DESTDIR}/$${TARGET}.app/Contents/Info.plist\"
QMAKE_EXTRA_TARGETS = plist
PRE_TARGETDEPS += $$plist.target
QMAKE_INFO_PLIST = recode.plist
plist.target = Info.plist
plist.depends = recode.plist "$${DESTDIR}/$${TARGET}.app/Contents/Info.plist"
plist.commands = $(DEL_FILE) \"$${DESTDIR}/$${TARGET}.app/Contents/Info.plist\" $$escape_expand(\n\t) \
$(COPY_FILE) recode.plist \"$${DESTDIR}/$${TARGET}.app/Contents/Info.plist\"
QMAKE_EXTRA_TARGETS = plist
PRE_TARGETDEPS += $$plist.target
To copy to clipboard, switch view to plain text mode
recode.plist is the name of my custom app plist file. If I recall correctly, qmake will not replace Info.plist if it exists, which is why the plist.commands deletes Info.plist from the app bundle, etc.
Hope that helps,
Jeff
Bookmarks