title: qt qbs complex macos bundle build
body: <p>I have complex qbs projects tree. And one of static libraries depends on 3rd-part framework. I am trying to make deploying of this frameworks inside qbs, but have no luck for now.</p>
  
  <p>For dylib deploy i use next code:</p>
  
  <pre><code>Group {
              condition: qbs.targetOS.contains("osx") &amp;&amp; bundle.isBundle
              files: [lib.sourceDirectory +"/Mac/*.dylib"]
              qbs.install: true
              qbs.installDir: "bin/"+FileInfo.path(bundle.executablePath)
          }
  </code></pre>
  
  <p>And for application itself i do next:</p>
  
  <pre><code>Group {
          fileTagsFilter: ["application"]
          qbs.install: install
          qbs.installDir: bundle.isBundle ? FileInfo.joinPaths(installDir, FileInfo.path(bundle.executablePath)) : installDir
      }
  Group {
      fileTagsFilter: ["aggregate_infoplist", "infoplist"]
      qbs.install: install &amp;&amp; bundle.isBundle &amp;&amp; !bundle.embedInfoPlist
      qbs.installDir: FileInfo.joinPaths(installDir, FileInfo.path(bundle.infoPlistPath))
  }
  
  Group {
      fileTagsFilter: ["pkginfo"]
      qbs.install: install &amp;&amp; bundle.isBundle
      qbs.installDir: FileInfo.joinPaths(installDir, FileInfo.path(bundle.pkgInfoPath))
  }
  </code></pre>
  
  <p>So my questions are next:</p>
  
  <ol>
  <li><p>Is this solution for bundle correct or there is other easy solution for bundle install?</p></li>
  <li><p>Can i do something similar with 3rd-part framework bundles as i did with the dylib files?</p></li>
  <li><p>Is there is a way to force qbs to change rpathes for application to use installed frameworks?</p></li>
  </ol>
  
  <p>Thank you.</p>