1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-01 09:24:10 +01:00

Tabs/Whitespaces cleanup - No code change

Jira OP-888 / OPReview-432
This commit is contained in:
Philippe Vanhaesendonck 2013-04-04 14:52:16 +02:00
parent c538488294
commit 327b24c501
2 changed files with 53 additions and 53 deletions

View File

@ -4,21 +4,21 @@ APP="${1?}"
PLUGINS="${APP}/Contents/Plugins"
OP_PLUGINS="${APP}/Contents/Plugins/OpenPilot"
QT_LIBS="QtDeclarative QtXmlPatterns QtGui QtTest QtCore QtSvg QtSql QtOpenGL QtNetwork QtXml QtDBus QtScript phonon"
QT_DIR=$(otool -L "${APP}/Contents/MacOS/OpenPilot GCS" | sed -n -e 's/\/QtCore\.framework.*//p' | sed -n -E 's:^.::p')
QT_EXTRA="accessible/libqtaccessiblewidgets.dylib bearer/libqgenericbearer.dylib codecs/libqcncodecs.dylib codecs/libqjpcodecs.dylib codecs/libqkrcodecs.dylib codecs/libqtwcodecs.dylib graphicssystems/libqtracegraphicssystem.dylib imageformats/libqgif.dylib imageformats/libqico.dylib imageformats/libqjpeg.dylib imageformats/libqmng.dylib imageformats/libqtiff.dylib imageformats/libqsvg.dylib qmltooling/libqmldbg_inspector.dylib qmltooling/libqmldbg_tcp.dylib graphicssystems/libqglgraphicssystem.dylib sqldrivers/libqsqlodbc.dylib sqldrivers/libqsqlpsql.dylib sqldrivers/libqsqlite.dylib imageformats/libqtga.dylib iconengines/libqsvgicon.dylib"
QT_DIR=$(otool -L "${APP}/Contents/MacOS/OpenPilot GCS" | sed -n -e 's/\/QtCore\.framework.*//p' | sed -n -E 's:^.::p')
QT_EXTRA="accessible/libqtaccessiblewidgets.dylib bearer/libqgenericbearer.dylib codecs/libqcncodecs.dylib codecs/libqjpcodecs.dylib codecs/libqkrcodecs.dylib codecs/libqtwcodecs.dylib graphicssystems/libqtracegraphicssystem.dylib imageformats/libqgif.dylib imageformats/libqico.dylib imageformats/libqjpeg.dylib imageformats/libqmng.dylib imageformats/libqtiff.dylib imageformats/libqsvg.dylib qmltooling/libqmldbg_inspector.dylib qmltooling/libqmldbg_tcp.dylib graphicssystems/libqglgraphicssystem.dylib sqldrivers/libqsqlodbc.dylib sqldrivers/libqsqlpsql.dylib sqldrivers/libqsqlite.dylib imageformats/libqtga.dylib iconengines/libqsvgicon.dylib"
OSG_EXTRA="libosgViewer.90.dylib"
if [ -z "${QT_DIR}" ]
then
# QT_DIR is empty, then we have (presumably):
QT_FRAMEWORKS="/Library/Frameworks"
QT_PLUGINS="/Developer/Applications/Qt/plugins"
# QT_DIR is empty, then we have (presumably):
QT_FRAMEWORKS="/Library/Frameworks"
QT_PLUGINS="/Developer/Applications/Qt/plugins"
else
# Typical Nokia SDK paths
QT_FRAMEWORKS="${QT_DIR}"
QT_PLUGINS="${QT_DIR}/../plugins"
QT_DIR="${QT_DIR}/"
# Typical Nokia SDK paths
QT_FRAMEWORKS="${QT_DIR}"
QT_PLUGINS="${QT_DIR}/../plugins"
QT_DIR="${QT_DIR}/"
fi
echo "Qt library directory is \"${QT_DIR}\""
@ -29,13 +29,13 @@ macdeployqt "${APP}"
echo "Processing Qt libraries in ${APP}"
for f in "${PLUGINS}/"*.dylib "${OP_PLUGINS}/"*.dylib
do
# Only process plain files
[ ! -L "${f}" ] && for g in $QT_LIBS
do
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${f}"
# Only process plain files
[ ! -L "${f}" ] && for g in $QT_LIBS
do
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${f}"
done
done
@ -48,40 +48,40 @@ do
echo "Changing package identification of ${f}"
install_name_tool -id \
@executable_path/../Frameworks/${f}.framework/Versions/4/${f} \
"${APP}/Contents/Frameworks/${f}.framework/Versions/4/${f}"
@executable_path/../Frameworks/${f}.framework/Versions/4/${f} \
"${APP}/Contents/Frameworks/${f}.framework/Versions/4/${f}"
rm "${APP}/Contents/Frameworks/${f}.framework/${f}"
echo "Changing package linkages"
for g in $QT_LIBS
do
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${APP}/Contents/Frameworks/${f}.framework/Versions/4/${f}"
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${APP}/Contents/Frameworks/${f}.framework/Versions/4/${f}"
done
done
for f in ${QT_EXTRA}
do
echo "Copying package ${f}"
d=$(dirname ${f})
echo "Copying package ${f}"
d=$(dirname ${f})
[ ! -d "${APP}/Contents/Plugins/${d}" ] && mkdir "${APP}/Contents/Plugins/${d}"
cp "${QT_PLUGINS}/${f}" "${APP}/Contents/Plugins/${f}"
echo "Changing package identification of ${f}"
install_name_tool -id \
@executable_path/../Plugins/${f} \
"${PLUGINS}/${f}"
echo "Changing package linkages"
for g in $QT_LIBS
do
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${APP}/Contents/Plugins/${f}"
done
cp "${QT_PLUGINS}/${f}" "${APP}/Contents/Plugins/${f}"
echo "Changing package identification of ${f}"
install_name_tool -id \
@executable_path/../Plugins/${f} \
"${PLUGINS}/${f}"
echo "Changing package linkages"
for g in $QT_LIBS
do
install_name_tool -change \
"${QT_DIR}${g}.framework/Versions/4/${g}" \
@executable_path/../Frameworks/${g}.framework/Versions/4/${g} \
"${APP}/Contents/Plugins/${f}"
done
done
echo "Copying SDL"
@ -89,22 +89,22 @@ cp -a "/Library/Frameworks/SDL.framework" "${APP}/Contents/Frameworks/"
echo "Changing package identification of SDL"
install_name_tool -id \
@executable_path/../Frameworks/SDL.framework/SDL \
"${APP}/Contents/Frameworks/SDL.framework/SDL"
@executable_path/../Frameworks/SDL.framework/SDL \
"${APP}/Contents/Frameworks/SDL.framework/SDL"
install_name_tool -change \
@rpath/SDL.framework/Versions/A/SDL \
"@executable_path/../Frameworks/SDL.framework/SDL" \
"${APP}/Contents/Plugins/libsdlgamepad.1.dylib"
@rpath/SDL.framework/Versions/A/SDL \
"@executable_path/../Frameworks/SDL.framework/SDL" \
"${APP}/Contents/Plugins/libsdlgamepad.1.dylib"
# echo "Copying OSG libraries"
# for f in ${OSG_EXTRA}
# do
# echo "Copying library ${f}"
# cp /usr/local/lib/{$f} "${APP}/Contents/Plugins/${f}"
# echo "Changing package identification of ${f}
# install_name_tool -id \
# @executable_path/../Frameworks/SDL.framework/Versions/A/SDL \
# "${APP}/Contents/Frameworks/SDL.framework/Versions/A/SDL"
# echo "Copying library ${f}"
# cp /usr/local/lib/{$f} "${APP}/Contents/Plugins/${f}"
# echo "Changing package identification of ${f}
# install_name_tool -id \
# @executable_path/../Frameworks/SDL.framework/Versions/A/SDL \
# "${APP}/Contents/Frameworks/SDL.framework/Versions/A/SDL"
#done
# deleting unnecessary files

View File

@ -14,9 +14,9 @@ rm -f "${TEMP_FILE}"
rm -f "${OUT_FILE}"
hdiutil convert "${ROOT_DIR}/package/osx/OpenPilot.dmg" \
-format UDRW -o "${TEMP_FILE}"
device=$(hdiutil attach "${TEMP_FILE}" | \
egrep '^/dev/' | sed 1q | awk '{print $1}')
-format UDRW -o "${TEMP_FILE}"
device=$(hdiutil attach "${TEMP_FILE}" | \
egrep '^/dev/' | sed 1q | awk '{print $1}')
# packaging goes here
cp -a "${APP_PATH}" "/Volumes/${VOL_NAME}"
@ -25,7 +25,7 @@ cp "${BUILD_DIR}/uavobject-synthetics/matlab/OPLogConvert.m" "/Volumes/${VOL_NAM
cp "${ROOT_DIR}/HISTORY.txt" "/Volumes/${VOL_NAME}"
"${ROOT_DIR}/package/osx/libraries" \
"/Volumes/${VOL_NAME}/OpenPilot GCS.app" || exit 1
"/Volumes/${VOL_NAME}/OpenPilot GCS.app" || exit 1
hdiutil detach ${device}