1# 2# OpenBOR - http://www.LavaLit.com 3# ----------------------------------------------------------------------- 4# Licensed under the BSD license, see LICENSE in OpenBOR root for details. 5# 6# Copyright (c) 2004 - 2011 OpenBOR Team 7# 8 9#!/bin/bash 10# Script updates the hardcoded dynamic libraries paths 11# to paths that are relative to the executable. 12 13if [ -z "${DWNDEV+xxx}" ]; then 14 . environ.sh 10 15fi 16 17if [ "${DWNDEV}" == "/opt/mac" ]; then 18 exit 19fi 20 21############ Update Library References ############ 22 23${PREFIX}install_name_tool \ 24-change ${DWNDEV}/lib/libSDL-1.2.0.dylib \ 25@executable_path/../Libraries/libSDL-1.2.0.dylib \ 26releases/DARWIN/OpenBOR.app/Contents/Libraries/libSDL_gfx.13.dylib 27 28${PREFIX}install_name_tool \ 29-change ${DWNDEV}/lib/libvorbis.0.dylib \ 30@executable_path/../Libraries/libvorbis.0.dylib \ 31releases/DARWIN/OpenBOR.app/Contents/Libraries/libvorbisfile.3.dylib 32 33${PREFIX}install_name_tool \ 34-change ${DWNDEV}/lib/libogg.0.dylib \ 35@executable_path/../Libraries/libogg.0.dylib \ 36releases/DARWIN/OpenBOR.app/Contents/Libraries/libvorbisfile.3.dylib 37 38${PREFIX}install_name_tool \ 39-change ${DWNDEV}/lib/libogg.0.dylib \ 40@executable_path/../Libraries/libogg.0.dylib \ 41releases/DARWIN/OpenBOR.app/Contents/Libraries/libvorbis.0.dylib 42 43${PREFIX}install_name_tool \ 44-change ${DWNDEV}/lib/libz.1.dylib \ 45@executable_path/../Libraries/libz.1.2.5.dylib \ 46releases/DARWIN/OpenBOR.app/Contents/Libraries/libpng14.14.dylib 47 48######### Update Executable Library Paths ########## 49 50${PREFIX}install_name_tool \ 51-change ${DWNDEV}/lib/libSDL-1.2.0.dylib \ 52@executable_path/../Libraries/libSDL-1.2.0.dylib \ 53releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 54 55${PREFIX}install_name_tool \ 56-change ${DWNDEV}/lib/libSDL_gfx.13.dylib \ 57@executable_path/../Libraries/libSDL_gfx.13.dylib \ 58releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 59 60${PREFIX}install_name_tool \ 61-change ${DWNDEV}/lib/libvorbisfile.3.dylib \ 62@executable_path/../Libraries/libvorbisfile.3.dylib \ 63releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 64 65${PREFIX}install_name_tool \ 66-change ${DWNDEV}/lib/libvorbis.0.dylib \ 67@executable_path/../Libraries/libvorbis.0.dylib \ 68releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 69 70${PREFIX}install_name_tool \ 71-change ${DWNDEV}/lib/libogg.0.dylib \ 72@executable_path/../Libraries/libogg.0.dylib \ 73releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 74 75${PREFIX}install_name_tool \ 76-change ${DWNDEV}/lib/libpng14.14.dylib \ 77@executable_path/../Libraries/libpng14.14.dylib \ 78releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 79 80${PREFIX}install_name_tool \ 81-change ${DWNDEV}/lib/libz.1.dylib \ 82@executable_path/../Libraries/libz.1.2.5.dylib \ 83releases/DARWIN/OpenBOR.app/Contents/MacOS/OpenBOR 84