[mythtv] Linux to MacOSX cross compilation
Lawrence Rust
lvr at softsystem.co.uk
Wed Mar 9 08:55:21 UTC 2011
On Tue, 2011-03-08 at 12:57 -0800, Emlyn Bolton wrote:
> > I wonder how hard it would be to use the existing Mac
> packaging script
> > to get these to bundle into a MythFrontend.app/ directory?
> >
> > Once I've compiled, I'll have a look... If nobody else is
> already
> > doing so?
>
>
> Great idea. Please give it a try.
>
> Alas, it did not work. While attempting to package up the contents,
> it complained about some of the binary formats of some of the
> libraries.
You might need to use the odcctools to package them, specifically ld.
See man /opt/mac/share/man/man1/ld.1 (assuming that you installed
odcctools to the default /opt/mac) and search for -bundle
> I tried executing the unpacked build area files to my Tiger
> installation, but couldn't figure out how to change the runtime-prefix
> at runtime... Is that possible?
Quite possibly. The mythbuild.sh script gives a hint when it has
finished building. If the installation is moved then prepend the
following to the myth command:
LD_LIBRARY_PATH="<path>/lib:<path>/lib/mysql" QT_PLUGIN_PATH="<path>/plugins"
> To be clearer, my build area (linux box)
> is /home/emlyn/mythbuilder/mythinstall but I wanted to run it and
> otool the binaries on my mac (/Users/emlyn/mythbuilder) it will look
> for the build area libs / bins, even if I manually specify the libs to
> the osx-bundler.sh script.
For your case:
build="/Users/emlyn/mythbuilder/mythinstall"
LD_LIBRARY_PATH="$build/lib:$build/lib/mysql" \
QT_PLUGIN_PATH="$build/plugins" $build/bin/mythfrontend
This depends on the Mac's ld.so supporting LD_LIBRARY_PATH, of which I'm
not certain. Can anyone confirm this?
It may be necessary to re-run mythbuild.sh in a chroot environment and
specify the correct installation prefix:
mkdir ~/mac
# cp or ln -s your existing mythbuilder folder into ~/mac
chroot ~/mac mythbuild.sh -I /usr
Everything will be installed into ~/mac/usr but will expect to be run
from /usr
-- Lawrence
More information about the mythtv-dev
mailing list