QMAKE_BUNDLE_DATA Where do the files go in the ios bundle? [SOLVED]
-
I've been at this for a hour and have had no success. I am loading assets with this in the applications .pro file:
@packets.files = $$files($(HOME)/fast/assets/packets/*.gly)
packets.path = packetstextures.files = $$files($(HOME)/fast/assets/textures/*.tga)
textures.path = textures
QMAKE_BUNDLE_DATA += packets textures@For the life of me, I can't tell where any of these files are going! Anyone have any insight?
-
After a >>SUBSTANTIAL<< amount of trial and error, I finally figured out where the he!@ my bundle data went:
First, my QMAKE_BUNDLE_DATA setup was wrong. The correct setup was:
@packets.files = $$files($(HOME)/fast/packets/*.gly)
packets.path = packetstextures.files = $$files($(HOME)/fast/textures/*.tga)
textures.path = textures
QMAKE_BUNDLE_DATA += packets textures
@That was a big blunder on my part. But the second was more difficult to track down. Here's the code to get the proper path to the bundle data on ios:
@ QString dloc = (QStandardPaths::standardLocations(QStandardPaths::HomeLocation).first());
dloc += "/textures"or
dloc == "/packets"
@My bundle content was buried under two sub directories off QStandardPaths::HomeLocation called textures and packets. Just remember, on iOS, the device IS case sensitive. On my mac, it is NOT case sensitive. That can lead to some confusion on devices.
Well, that is a couple of hours of my life I'd sure like back!