Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create and upload AppImage of travis build #194

Merged
merged 4 commits into from
May 21, 2016
Merged

Create and upload AppImage of travis build #194

merged 4 commits into from
May 21, 2016

Conversation

probonopd
Copy link

Bundle the Linux build artifacts on Travis CI as an AppImage and upload it to transfer.sh.

Check the last lines of each Travis CI build log for a transfer.sh URL from which the AppImage can be downloaded.

To run the AppImage, download it, chmod a+x ./theAppImage and run. Should work on most not-too-outdated 64-bit Linux distributions (approximately 2014 and later).

If it doesn't, then either the script needs to be fine-tuned (e.g., bundle additional or less files) and/or an older build system should be used on Travis CI (so that the resulting binaries become compatible with older target systems).

For more information, see https://github.com/probonopd/AppImageKit/blob/master/README.md

@probonopd
Copy link
Author

probonopd commented May 16, 2016

The pull request has been built on Travis CI successfully and has generated this AppImage, as can be seen in the build log toward the bottom:
https://transfer.sh/5FMeQ/scribus-git.4c19100-glibc2.15-x86-64.appimage

To test it:

wget https://transfer.sh/5FMeQ/scribus-git.4c19100-glibc2.15-x86-64.appimage
chmod a+x *.appimage
./scribus-git.4c19100-glibc2.15-x86-64.appimage

Works for me on Ubuntu 14.04 (trusty); will try on other distributions, too.

GIT_REV=$(git rev-parse --short HEAD)
echo $GIT_REV
sudo make install DESTDIR=/$APP/$APP.AppDir
sudo chown -R $USER /$APP

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is sudo needed here? Can’t we just install to a user-writable directory (e.g. under $HOME)?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably we could, but I haven't tested the functions in https://github.com/probonopd/AppImages/raw/master/functions.sh under that scenario. Feel free to start from my proposed script and change as you see fit.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don’t have any experience with AppImage, and I also prefer to not use sudo before this is merged.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the reason you think we should avoid running sudo on travis? We are running sudo on travis already anyway...

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because one day we would want to move to the faster container-based Travis setup where we can’t use sudo (this is currently blocked because using Trusty in Travis requires sudo, but it will be changed in the future).

@khaledhosny
Copy link

Please squash the commits together and add a detailed commit message (the comment of this pull request should be enough).

Bundle the Linux build artifacts on Travis CI as an AppImage and upload it to transfer.sh.
Check the last lines of each Travis CI build log for a transfer.sh URL from which the AppImage can be downloaded.
To run the AppImage, download it, chmod a+x ./theAppImage and run. Should work on most not-too-outdated 64-bit Linux distributions.
For more information, see https://github.com/probonopd/AppImageKit/blob/master/README.md
@probonopd
Copy link
Author

Done

@probonopd
Copy link
Author

By the way, there is a new GitHub feature which lets you squash and merge with the press of a button:
https://help.github.com/articles/about-pull-request-merge-squashing/

@luzpaz
Copy link

luzpaz commented May 18, 2016

Haven't had a dedicated moment to test this. I'd love to get it working for OSX as well.

########################################################################
# Package the binaries built on Travis-CI as an AppImage
# By Simon Peter 2016
# For more information, see http://appimage.org/
########################################################################

sudo apt-get -y install coreutils binutils python-tk

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be moved to the .travis.yml files with other apt-get calls, since this will be done without sudo in the future.

@luzpaz
Copy link

luzpaz commented May 21, 2016

@probonopd
Error in bundle.sh:
https://travis-ci.org/HOST-Oman/scribus/jobs/131329131#L6090-L6091

cp '/usr/li*/python2.7/lib-dynload/_tkinter.so' usr/
cp: cannot stat ‘/usr/li*/python2.7/lib-dynload/_tkinter.so’: No such file or directory

@probonopd
Copy link
Author

probonopd commented May 21, 2016

Then we must go back to using sudo apt-get...

@khaledhosny
Copy link

I don’t see the relation, besides build is passing now already.

@khaledhosny khaledhosny merged commit 9a41a64 into HOST-Oman:ctl May 21, 2016
@khaledhosny
Copy link

Thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants