Skip to content

Commit

Permalink
travis-ci create Linux AppImage
Browse files Browse the repository at this point in the history
-closes mavlink#2913
  • Loading branch information
dagar committed Apr 5, 2016
1 parent 93b34e3 commit b33ed23
Show file tree
Hide file tree
Showing 5 changed files with 58 additions and 87 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,10 @@ script:
fi

after_success:
- if [[ "${TRAVIS_OS_NAME}" = "linux" && "${CONFIG}" = "installer" ]]; then
${TRAVIS_BUILD_DIR}/deploy/create_linux_appimage.sh
;
fi
- if [ "${TRAVIS_TAG}" ]; then
export GOOGLE_PLAY_TRACK=production;
else
Expand Down
54 changes: 54 additions & 0 deletions deploy/create_linux_appimage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#!/bin/bash -x

set +e

# Generate AppImage using the binaries currently provided by the project.
# These require at least GLIBC 2.14, which older distributions might not have.
# On the other hand, 2.14 is not that recent so maybe we can just live with it.

APP=qgroundcontrol

mkdir -p /tmp/$APP/$APP.AppDir
cd /tmp/$APP/
tar xf ${SHADOW_BUILD_DIR}/release/package/qgroundcontrol.tar.bz2

wget -c http://ftp.us.debian.org/debian/pool/main/u/udev/udev_175-7.2_amd64.deb
wget -c http://ftp.us.debian.org/debian/pool/main/e/espeak/espeak_1.46.02-2_amd64.deb
wget -c http://ftp.us.debian.org/debian/pool/main/libs/libsdl1.2/libsdl1.2debian_1.2.15-5_amd64.deb

cd $APP.AppDir/

mv ../qgroundcontrol/* .
mv qgroundcontrol-start.sh AppRun
find ../ -name *.deb -exec dpkg -x {} . \;

# Get icon
cp ${TRAVIS_BUILD_DIR}/resources/icons/qgroundcontrol.png .

cat > ./qgroundcontrol.desktop <<\EOF
[Desktop Entry]
Type=Application
Name=QGroundControl
GenericName=Ground Control Station
Comment=UAS ground control station
Icon=qgroundcontrol
Exec=AppRun
Terminal=false
Categories=Utility;
Keywords=computer;
EOF

VERSION=$(strings qgroundcontrol | grep v[0-9*]\.[0-9*]\.[0-9*]-[0-9*] | head -n 1)

# Go out of AppImage
cd ..

wget -c "https://github.com/probonopd/AppImageKit/releases/download/5/AppImageAssistant" # (64-bit)
chmod a+x ./AppImageAssistant
mkdir -p ../out
rm ../out/$APP".AppImage" || true
./AppImageAssistant ./$APP.AppDir/ ../out/$APP".AppImage"

# s3 deploys everything in release/package
cp ../out/$APP".AppImage" ${SHADOW_BUILD_DIR}/release/package/$APP".AppImage"

13 changes: 0 additions & 13 deletions deploy/linux_create_debian_packet.sh

This file was deleted.

15 changes: 0 additions & 15 deletions testlog.txt

This file was deleted.

59 changes: 0 additions & 59 deletions testlog2.txt

This file was deleted.

0 comments on commit b33ed23

Please sign in to comment.