-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[travis ci] merged travis configuration from stable branch
- Loading branch information
1 parent
a8db6d9
commit 1ef4589
Showing
8 changed files
with
800 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,161 @@ | ||
language: generic | ||
|
||
matrix: | ||
include: | ||
- os: linux | ||
dist: trusty | ||
compiler: g++ | ||
sudo: required | ||
dist: trusty | ||
addons: | ||
apt: | ||
sources: | ||
#- sourceline: 'ppa:dhor/myway' | ||
- sourceline: 'ppa:otto-kesselgulasch/gimp-edge' | ||
packages: | ||
- g++ | ||
- gettext | ||
- intltool | ||
- gir1.2-gtk-3.0 | ||
- libgtk2.0-dev | ||
- liblcms2-dev | ||
- libpng12-dev | ||
- python-dev | ||
- python-gi-dev | ||
- python-gi-cairo | ||
- python-nose | ||
- python-numpy | ||
- automake | ||
- gtk-doc-tools | ||
- gobject-introspection | ||
- libfftw3-dev | ||
- libjpeg-turbo8-dev | ||
- libpng12-dev | ||
- libwebp-dev | ||
- libtiff4-dev | ||
- libxml2-dev | ||
- swig | ||
- libmagick++-dev | ||
- bc | ||
- libcfitsio3-dev | ||
- libgsl0-dev | ||
- libmatio-dev | ||
- liborc-0.4-dev | ||
- libpoppler-glib-dev | ||
- librsvg2-dev | ||
- libgif-dev | ||
- python-dev | ||
- libsigc++-2.0-dev | ||
- libpixman-1-dev | ||
- libpango1.0-dev | ||
- libpangoft2-1.0-0 | ||
- libglib2.0-dev | ||
- libglibmm-2.4-dev | ||
- libgtkmm-2.4-dev | ||
- libpugixml-dev | ||
before_script: | ||
- cd build | ||
- export PKG_CONFIG_PATH=/app/lib/pkgconfig:${PKG_CONFIG_PATH} | ||
- export LD_LIBRARY_PATH=/app/lib:${LD_LIBRARY_PATH} | ||
#- git clone -b v8.4.1 --depth 1 https://github.com/jcupitt/libvips.git libvips | ||
#- git clone https://github.com/jcupitt/libvips.git libvips | ||
#- cd libvips | ||
# revert to git version of 9/2/2017 | ||
#- git reset --hard 6691e07d72c284468c77f4a95139ac43bf0cdc6f | ||
#- wget http://www.vips.ecs.soton.ac.uk/supported/8.4/vips-8.4.5.tar.gz | ||
#- tar xzvf vips-8.4.5.tar.gz | ||
#- cd vips-8.4.5 | ||
- wget https://github.com/jcupitt/libvips/releases/download/v8.5.6/vips-8.5.6.tar.gz | ||
- tar xzvf vips-8.5.6.tar.gz | ||
- cd vips-8.5.6 | ||
- ./autogen.sh | ||
- FLAGS="-g -O2 -msse4.2 -ffast-math -ftree-vectorize" CFLAGS="${FLAGS}" CXXFLAGS="${FLAGS} -fpermissive" ./configure --prefix=/app --disable-gtk-doc --disable-gtk-doc-html --disable-introspection --enable-debug=no --without-python --without-magick --without-libwebp --enable-pyvips8=no --enable-shared=yes --enable-static=no | ||
- make -j2 | ||
- sudo make install | ||
- cd .. | ||
- rm -rf libvips | ||
- cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/app -DINSTALL_PREFIX=/app -DBUNDLED_LENSFUN=ON .. | ||
- echo "#include <version.hh>" > ../src/version.cc | ||
- echo "const char* PF::version_string = \"PhotoFlow git-${TRAVIS_BRANCH}-${TRAVIS_COMMIT}\";" >> ../src/version.cc | ||
- make -j2 | ||
- sudo make install | ||
- cd .. | ||
- sudo rm -fr PhotoFlow | ||
script: | ||
- bash appimage/appimage.sh | ||
after_success: | ||
- cd $HOME | ||
- pwd | ||
- ls -lh | ||
- ls -lh out/* # Assuming you have some files in out/ that you would like to upload | ||
#- wget -c https://github.com/probonopd/uploadtool/raw/master/upload.sh | ||
#- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload.sh | ||
- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload_rotate.sh | ||
- bash ./upload_rotate.sh "unstable" out/* | ||
- find /usr -name gconv | ||
- os: linux | ||
dist: trusty | ||
compiler: g++ | ||
sudo: required | ||
dist: trusty | ||
before_script: | ||
- cd non_existent_dir | ||
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y | ||
- sudo add-apt-repository ppa:adrozdoff/mingw -y | ||
- sudo apt-get update | ||
- sudo apt-get install gcc-5-mingw-w64 g++-5-mingw-w64 binutils-mingw-w64-x86-64 python3 python3-docutils rpm2cpio libfile-mimeinfo-perl | ||
- sudo ln -s /usr/bin/i686-w64-mingw32-gcc-5 /usr/bin/i686-w64-mingw32-gcc | ||
- sudo ln -s /usr/bin/i686-w64-mingw32-g++-5 /usr/bin/i686-w64-mingw32-g++ | ||
- ls -l /usr/bin/i686-w64-mingw32* | ||
- cd build | ||
- wget https://pypi.python.org/packages/f4/ea/4faf47f49928ba276fc555b4ebd8432a77494a63fd7ee25b6bccb5820c67/crossroad-0.6.tar.gz | ||
- tar xzvf crossroad-0.6.tar.gz | ||
- find crossroad-0.6 -type f -print0 | xargs -0 sed -i 's/openSUSE_42.1/openSUSE_Leap_42.1/g' | ||
- cd crossroad-0.6 && ./setup.py install --prefix=$HOME/inst && cd .. | ||
- cat $HOME/inst/share/crossroad/scripts/cmake/toolchain-w32.cmake | ||
- echo "" >> $HOME/inst/share/crossroad/scripts/cmake/toolchain-w32.cmake | ||
- echo "SET(PKG_CONFIG_EXECUTABLE i686-w64-mingw32-pkg-config)" >> $HOME/inst/share/crossroad/scripts/cmake/toolchain-w32.cmake | ||
- $HOME/inst/bin/crossroad --help w32 | ||
- $HOME/inst/bin/crossroad w32 phf-build --run ../windows/dep-install.sh | ||
- $HOME/inst/bin/crossroad w32 phf-build --run ../windows/dep-build.sh | ||
- $HOME/inst/bin/crossroad w32 phf-build --run ../windows/phf-build.sh | ||
- $HOME/inst/bin/crossroad w32 phf-build --run ../windows/package-w32.sh | ||
#- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload.sh | ||
- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload_rotate.sh | ||
- bash ./upload_rotate.sh "unstable" photoflow*.zip | ||
- os: linux | ||
dist: trusty | ||
compiler: g++ | ||
sudo: required | ||
dist: trusty | ||
before_script: | ||
- cd non_existent_dir | ||
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y | ||
- sudo add-apt-repository ppa:adrozdoff/mingw -y | ||
- sudo apt-get update | ||
- sudo apt-get install gcc-5-mingw-w64 g++-5-mingw-w64 binutils-mingw-w64-x86-64 python3 python3-docutils rpm2cpio libfile-mimeinfo-perl | ||
- sudo ln -s /usr/bin/x86_64-w64-mingw32-gcc-5 /usr/bin/x86_64-w64-mingw32-gcc | ||
- sudo ln -s /usr/bin/x86_64-w64-mingw32-g++-5 /usr/bin/x86_64-w64-mingw32-g++ | ||
- ls -l /usr/bin/x86_64-w64-mingw32* | ||
- cd build | ||
- wget https://pypi.python.org/packages/f4/ea/4faf47f49928ba276fc555b4ebd8432a77494a63fd7ee25b6bccb5820c67/crossroad-0.6.tar.gz | ||
- tar xzvf crossroad-0.6.tar.gz | ||
- find crossroad-0.6 -type f -print0 | xargs -0 sed -i 's/openSUSE_42.1/openSUSE_Leap_42.1/g' | ||
- cd crossroad-0.6 && ./setup.py install --prefix=$HOME/inst && cd .. | ||
- cat $HOME/inst/share/crossroad/scripts/cmake/toolchain-w64.cmake | ||
- echo "" >> $HOME/inst/share/crossroad/scripts/cmake/toolchain-w64.cmake | ||
- echo "SET(PKG_CONFIG_EXECUTABLE x86_64-w64-mingw32-pkg-config)" >> $HOME/inst/share/crossroad/scripts/cmake/toolchain-w64.cmake | ||
- $HOME/inst/bin/crossroad --help w64 | ||
- $HOME/inst/bin/crossroad w64 phf-build --run ../windows/dep-install.sh | ||
- $HOME/inst/bin/crossroad w64 phf-build --run ../windows/dep-build.sh | ||
- $HOME/inst/bin/crossroad w64 phf-build --run ../windows/phf-build.sh | ||
- $HOME/inst/bin/crossroad w64 phf-build --run ../windows/package-w64.sh | ||
#- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload.sh | ||
- wget -c https://github.com/aferrero2707/uploadtool/raw/master/upload_rotate.sh | ||
- bash ./upload_rotate.sh "unstable" photoflow*.zip | ||
|
||
|
||
branches: | ||
except: | ||
- # Do not build tags that we create when we upload to GitHub Releases | ||
- /^(?i:unstable)$/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,233 @@ | ||
#!/bin/bash | ||
|
||
######################################################################## | ||
# Package the binaries built on Travis-CI as an AppImage | ||
# By Simon Peter 2016 | ||
# For more information, see http://appimage.org/ | ||
######################################################################## | ||
|
||
|
||
PREFIX=app | ||
|
||
# Move blacklisted files to a special folder | ||
move_blacklisted() | ||
{ | ||
mkdir -p ./usr/lib-blacklisted | ||
if [ x"$FULL_BUNDLING" = "x1" ]; then | ||
BLACKLISTED_FILES=$(cat $APPIMAGEBASE/AppImages/excludelist | sed '/^\s*$/d' | sed '/^#.*$/d') | ||
else | ||
#BLACKLISTED_FILES=$(wget -q https://github.com/probonopd/AppImages/raw/master/excludelist -O - | sed '/^\s*$/d' | sed '/^#.*$/d') | ||
BLACKLISTED_FILES=$(cat "$APPIMAGEBASE/excludelist" | sed '/^\s*$/d' | sed '/^#.*$/d') | ||
fi | ||
echo $BLACKLISTED_FILES | ||
for FILE in $BLACKLISTED_FILES ; do | ||
FOUND=$(find . -type f -name "${FILE}" 2>/dev/null) | ||
if [ ! -z "$FOUND" ] ; then | ||
echo "Moving blacklisted ${FOUND}" | ||
#rm -f "${FOUND}" | ||
mv "${FOUND}" ./usr/lib-blacklisted | ||
fi | ||
done | ||
} | ||
|
||
|
||
fix_pango() | ||
{ | ||
|
||
version=$(pango-querymodules --version | tail -n 1 | tr -d " " | cut -d':' -f 2) | ||
cat /$PREFIX/lib/pango/$version/modules.cache | sed "s|/$PREFIX/lib/pango/$version/modules/||g" > usr/lib/pango/$version/modules.cache | ||
} | ||
|
||
|
||
strip_binaries() | ||
{ | ||
chmod u+w -R "$appdir" | ||
{ | ||
find $APPDIR/usr/bin/ -type f -name "gimp*" -print0 | ||
find $APPDIR/usr/bin/ -type f -name "python*" -print0 | ||
find "$APPDIR" -type f -regex '.*\.so\(\.[0-9.]+\)?$' -print0 | ||
} | xargs -0 --no-run-if-empty --verbose -n1 strip | ||
} | ||
|
||
|
||
export ARCH=$(arch) | ||
|
||
APP=PhotoFlow | ||
LOWERAPP=${APP,,} | ||
|
||
mkdir -p $HOME/$APP/$APP.AppDir/usr/ | ||
|
||
cd $HOME/$APP/ | ||
|
||
export APPIMAGEBASE=$(pwd) | ||
wget -q https://github.com/probonopd/AppImages/raw/master/functions.sh -O ./functions.sh | ||
. ./functions.sh | ||
|
||
cd $APP.AppDir | ||
|
||
export APPDIR=$(pwd) | ||
|
||
sudo chown -R $USER /${PREFIX}/ | ||
|
||
cp -r /${PREFIX}/* ./usr/ | ||
rm -f ./usr/bin/$LOWERAPP.real | ||
mv ./usr/bin/$LOWERAPP ./usr/bin/$LOWERAPP.real | ||
cat > usr/bin/$LOWERAPP <<\EOF | ||
#! /bin/bash | ||
HERE="$(dirname "$(readlink -f "${0}")")" | ||
export PF_DATA_DIR=$HERE/../share | ||
echo "PF_DATA_DIR=${PF_DATA_DIR}" | ||
export LD_LIBRARY_PATH=$HERE/../lib:$HERE/../lib/x86_64-linux-gnu:$HERE/../../lib:$LD_LIBRARY_PATH | ||
echo "LD_LIBRARY_PATH: $LD_LIBRARY_PATH" | ||
export XDG_DATA_DIRS=$HERE/../share/:$HERE/../share/mime/:$XDG_DATA_DIRS | ||
echo "XDG_DATA_DIRS=$XDG_DATA_DIRS" | ||
export GTK_PATH=$HERE/../lib/gtk-2.0:$GTK_PATH | ||
echo "GTK_PATH=${GTK_PATH}" | ||
export PANGO_LIBDIR=$HERE/../lib | ||
echo "PANGO_LIBDIR=${PANGO_LIBDIR}" | ||
export GCONV_PATH=$HERE/../lib/gconv | ||
echo "GCONV_PATH=${GCONV_PATH}" | ||
GDK_PIXBUF_MODULEDIR=$HERE/../lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders | ||
GDK_PIXBUF_MODULE_FILE=$HERE/../lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders.cache | ||
echo "GDK_PIXBUF_MODULEDIR: $GDK_PIXBUF_MODULEDIR" | ||
echo "GDK_PIXBUF_MODULE_FILE: $GDK_PIXBUF_MODULE_FILE" | ||
cat $GDK_PIXBUF_MODULE_FILE | ||
ldd "$HERE/LOWERAPP.real" | ||
echo -n "$HERE/LOWERAPP.real " | ||
echo "$@" | ||
$HERE/LOWERAPP.real "$@" | ||
#gdb -ex "run" $HERE/LOWERAPP.real | ||
EOF | ||
sed -i -e "s|LOWERAPP|$LOWERAPP|g" usr/bin/$LOWERAPP | ||
chmod u+x usr/bin/$LOWERAPP | ||
|
||
|
||
######################################################################## | ||
# Copy desktop and icon file to AppDir for AppRun to pick them up | ||
######################################################################## | ||
|
||
get_apprun | ||
get_desktop | ||
get_icon | ||
|
||
######################################################################## | ||
# Other application-specific finishing touches | ||
######################################################################## | ||
|
||
cd .. | ||
|
||
generate_status | ||
|
||
cd ./$APP.AppDir/ | ||
|
||
# Workaround for: | ||
# python2.7: symbol lookup error: /usr/lib/x86_64-linux-gnu/libgtk-3.so.0: undefined symbol: gdk__private__ | ||
|
||
#cp /usr/lib/x86_64-linux-gnu/libg*k-3.so.0 usr/lib/x86_64-linux-gnu/ | ||
|
||
# Compile Glib schemas | ||
( mkdir -p usr/share/glib-2.0/schemas/ ; cd usr/share/glib-2.0/schemas/ ; glib-compile-schemas . ) | ||
|
||
|
||
cp -a /usr/lib/x86_64-linux-gnu/gconv usr/lib | ||
|
||
mkdir -p usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0 | ||
cp -a /usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0 | ||
cp -a /usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders.cache usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0 | ||
|
||
|
||
mkdir -p usr/share | ||
cp -a /usr/share/mime usr/share | ||
|
||
######################################################################## | ||
# Copy in the dependencies that cannot be assumed to be available | ||
# on all target systems | ||
######################################################################## | ||
|
||
copy_deps; copy_deps; copy_deps; | ||
|
||
cp -a $PREFIX/lib/* usr/lib | ||
cp -a $PREFIX/lib64/* usr/lib64 | ||
rm -rf $PREFIX | ||
|
||
ls usr/lib | ||
move_lib | ||
echo "After move_lib" | ||
ls usr/lib | ||
|
||
######################################################################## | ||
# Delete stuff that should not go into the AppImage | ||
######################################################################## | ||
|
||
# Delete dangerous libraries; see | ||
# https://github.com/probonopd/AppImages/blob/master/excludelist | ||
move_blacklisted | ||
#delete_blacklisted | ||
|
||
fix_pango | ||
|
||
######################################################################## | ||
# desktopintegration asks the user on first run to install a menu item | ||
######################################################################## | ||
|
||
get_desktopintegration $LOWERAPP | ||
|
||
######################################################################## | ||
# Determine the version of the app; also include needed glibc version | ||
######################################################################## | ||
|
||
GLIBC_NEEDED=$(glibc_needed) | ||
VERSION=$(date +%Y%m%d)_$(date +%H%M)-git-${TRAVIS_BRANCH}-${TRAVIS_COMMIT}.glibc${GLIBC_NEEDED}-dbg | ||
#VERSION=${RELEASE_VERSION}-glibc$GLIBC_NEEDED | ||
|
||
######################################################################## | ||
# Patch away absolute paths; it would be nice if they were relative | ||
######################################################################## | ||
|
||
find usr/ -type f -exec sed -i -e 's|/usr|././|g' {} \; | ||
find usr/ -type f -exec sed -i -e 's|/${PREFIX}|././|g' {} \; | ||
|
||
# The fonts configuration should not be patched, copy back original one | ||
cp /$PREFIX/etc/fonts/fonts.conf usr/etc/fonts/fonts.conf | ||
|
||
# Workaround for: | ||
# ImportError: /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0: undefined symbol: XRRGetMonitors | ||
cp $(ldconfig -p | grep libgdk-x11-2.0.so.0 | cut -d ">" -f 2 | xargs) ./usr/lib/ | ||
cp $(ldconfig -p | grep libgtk-x11-2.0.so.0 | cut -d ">" -f 2 | xargs) ./usr/lib/ | ||
|
||
|
||
# Strip binaries. | ||
echo "APPDIR: $APPDIR" | ||
strip_binaries | ||
|
||
|
||
|
||
######################################################################## | ||
# AppDir complete | ||
# Now packaging it as an AppImage | ||
######################################################################## | ||
|
||
cd .. # Go out of AppImage | ||
|
||
mkdir -p ../out/ | ||
ARCH="x86_64" | ||
generate_appimage | ||
#generate_type2_appimage | ||
|
||
pwd | ||
ls ../out/* | ||
|
||
######################################################################## | ||
# Upload the AppDir | ||
######################################################################## | ||
|
||
transfer ../out/* | ||
echo "AppImage has been uploaded to the URL above; use something like GitHub Releases for permanent storage" |
Oops, something went wrong.