<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2014-09-23 13:05 GMT+02:00 Alex Kontos <span dir="ltr"><<a href="mailto:ak935@york.ac.uk" target="_blank">ak935@york.ac.uk</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi all,<br><p>So, here's what I've done. I've built an application that calls upon GStreamer in <b>/Library/GStreamer.Framework/ </b>during compile time (and therefore when the application runs, expects it there).<br></p>

<p>I build using command-line tools. This is the <b><i>only</i></b> way I can build this application. I can't use the XCode GUI.</p>

<p>I want to submit this app to the store, but to do so I can't submit 
it as a package (so I can bundle the GStreamer package installer) which 
means I'll have to bundle GStreamer.framework with my application.</p>

<p>In the GStreamer SDK docs above, you will notice a tool called 
osxrelocator.py. This is great, because it changes all refrences of <b>/Library/GStreamer.Framework</b> to <b>@executable_path/../Frameworks/GStreamer.framework/</b></p>

<p>BUT</p>

<p>Unfortunately all of the GStreamer .dylibs have an issue... You need 
to use install_name_tool -id to change their paths because 
install_name_tool -change doesn't change the paths to themselves!</p><p>I've attempted to manually changed all the references using install_name_tool -id but I must be missing files because when I run the application whenever GStreamer is called it's never used. But when the GStreamer framework is located in /Library/Framework everything works beautifully.</p><p>What's the best way I can have the GStreamer framework located in MyApp.app/Contents/Frameworks?</p></div></blockquote><div><br></div><div>Hi Alex,<br><br></div><div>The osxrelocator.py tool is changing both the libraries paths and the library id as in [1]<br><br></div><div>If you are not using XCode I could recommend you to use cerbero to bundle the application and create the package,  that you can then upload to the Store. I use it to package LongoMatch for Windows and OS X and it does all the hard job for you. For that you will need:<br><br></div><div>1) A recipe for your project that can be used by cerbero to build it. [2]<br></div><div>2) A package that defines you application and list the packages you depend on from the GStreamer framework [3]<br></div><div>3) A script that is use to launch your application, which takes care of setting the environment variables to use the bundled GStreamer [4]<br><br></div><div>The packaging process works in the following way with a single command "cerbero package longomatch":<br><br></div><div>1) It creates the directory structure needed by an OS X application, creating the foo.app directory, with an Info.plist describing your app and the init script in Contents/MacOS/foo<br></div><div>2) With the information provided in the package file, it lists the files required by your application from the GStreamer framework<br></div><div>3) It copies these files to the prefix foo.app/Home<br></div><div>4) And relocates them (and also strip them if you need it)<br></div><div>5) Finally it uses productbuild to create a .pkg that you can distribute in the App Store<br><br></div><div>You can donwload longomatch and inspect its structure here:<br><a href="http://ftp.gnome.org/pub/GNOME/binaries/mac/longomatch/LongoMatch-0.20.7-x86.dmg">http://ftp.gnome.org/pub/GNOME/binaries/mac/longomatch/LongoMatch-0.20.7-x86.dmg</a><br></div><div><br><br></div><div>[1] <a href="http://cgit.freedesktop.org/gstreamer/cerbero/tree/cerbero/tools/osxrelocator.py#n48">http://cgit.freedesktop.org/gstreamer/cerbero/tree/cerbero/tools/osxrelocator.py#n48</a><br> [2] <a href="https://github.com/ylatuya/cerbero-extras/blob/master/recipes/longomatch/longomatch.recipe">https://github.com/ylatuya/cerbero-extras/blob/master/recipes/longomatch/longomatch.recipe</a><br>[3] <a href="https://github.com/ylatuya/cerbero-extras/blob/master/packages/longomatch/longomatch.package">https://github.com/ylatuya/cerbero-extras/blob/master/packages/longomatch/longomatch.package</a><br>[4] <a href="https://github.com/ylatuya/cerbero-extras/blob/master/packages/longomatch/unix_wrapper">https://github.com/ylatuya/cerbero-extras/blob/master/packages/longomatch/unix_wrapper</a><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><p>Thanks in advance!</p><span class=""><font color="#888888"><p>Alex<br></p></font></span></div>
<br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Andoni Morales Alastruey<br><br>LongoMatch:The Digital Coach<br><a href="http://www.longomatch.ylatuya.es">http://www.longomatch.ylatuya.es</a>
</div></div>