0

I want to add to Qt project a contents of directory which contains: a bash script and a few java files inside other various sub-directories. I tried INCLUDEPATH and it didn't work.

I don't want the directory in the build directory, I want it inside the .app file (OS X bundle) so when I use macdeployqt they are all packed inside a .dmg file.

Marek R
  • 32,568
  • 6
  • 55
  • 140
Akash Popat
  • 420
  • 3
  • 18

1 Answers1

2

Files from this directory you have to add this way:

APP_JAVA_FILES.files = <this directry>/Class1.java \
                       <this directry>/Class2.java
APP_JAVA_FILES.path = Contents/Resources

APP_JAVA_FILES2.files = <this directory>/sub-dir/Class3.java \
                       <this directory>/sub-dir/Class4.java
APP_JAVA_FILES2.path = Contents/Resources/sub-dir

APP_BASH_FILES = <this directory>/script.sh
APP_BASH_FILES.path = Contents/Resources

QMAKE_BUNDLE_DATA += APP_JAVA_FILES APP_JAVA_FILES2 APP_BASH_FILES

Here is a documentation about this.

Marek R
  • 32,568
  • 6
  • 55
  • 140