Would replace #172, which see also.
This is a new shot at enabling Travis CI on Geany-Plugins. This time, it uses the new-style infrastructure which enables caching and is quite faster to start up.
* Pros: * Faster to start up * Has cache support * We can build Geany and cache the result, meaning we can rebuild it only when it has changed. This makes me think its better than using nightly *.deb*s, as we have the real latest version in all cases, and zero OS package compatibility issue. * *ccache* support, meaning faster rebuilds
* Cons: * No sudo, which means: * We need their approval for new packages. We currently miss: * *libvte-dev* (for several plugins, incl. *Debugger*, *Scope* and *MultiTerm*) * *libwnck-dev* (for *DevHelp*) * *libgtkspell-dev* (for *GeanyVC*'s spellchecking support on GTK2) * *libgtkspell-3-dev* (for *GeanyVC*'s spellchecking support on GTK3)
this can however probably be addressed by using they approval procedure for those packages. If we chose this version, I'll submit the requests there.
* No 3rd party repositories (e.g. we have to build Geany there too). This should not be a real problem with the caching, in my tests I saw it wasting about 7s when the cache is available, and something like 2 minutes without cache.
IMO, the pros clearly beat the cons -- unless we really can't get the needed packages, but I'm confident we can.
---
Unrelated to whether we use the new infrastructure or the old one, we run on Ubuntu 12.04. This is good in the sense we test an old-ish system; but it's bad as in it doesn't have *libpython-dev* (for *GeanyPy*) nor *libgit2-dev >= 0.21* (for *GitChangeBar*).
We *could* try and use their [beta Ubuntu 14.04 builders](https://docs.travis-ci.com/user/trusty-ci-environment/), which allows `sudo`, *and* has cache. Sounds nice, but:
* It's quite a bit slower than their 12.04 "new" infrastructure (build takes minutes to start, not seconds: not sure about speed after startup) * Ubuntu 14.04's *libgit2-dev* is too old (0.19) for *GitChangeBar*, so we "only" gain *GeanyPy* * Newer system, while good, also means less backward compatibility checks.
I didn't pursue it for the moment because of these which make me think we should at least wait for their setup to get faster seeing the limited benefits.
---
Setting up this, I found 3 blocker issues, including 2 actual bugs: * #392: `make check` breaks if MultiTerm is disabled. So actually missing *libvte-dev* was useful :) * #393: Ubuntu 12.04's cppcheck is stupid * #391: Ubuntu 12.04's cppcheck is clever
---
Enough chatter, whatcha guys thinkin'? You can view, comment on, or merge this pull request online at:
https://github.com/geany/geany-plugins/pull/394
-- Commit Summary --
* travis: Add a Travis CI settings file using its new infrastructure
-- File Changes --
A .travis.yml (106)
-- Patch Links --
https://github.com/geany/geany-plugins/pull/394.patch https://github.com/geany/geany-plugins/pull/394.diff
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394
BTW, actual build links: * https://travis-ci.org/b4n/geany-plugins/builds/114321338 this PR, failing because of the linked issues * https://travis-ci.org/b4n/geany-plugins/builds/114315098 same setup, but with the fixes for the issues applied.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193423638
I don't have much preference other than it works and shows the status on PR within some time.
Maybe the old Python package was called [python-dev](http://packages.ubuntu.com/precise/python-dev)?
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193436838
@codebrainz Nice! that seem to work indeed. It won't work here still because it also requires *python-gtk2-dev* that isn't allowed (yet), but it was shown working in a `sudo`-enabled test, so that will work if the package gets approved.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193450514
* python-gtk2-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2680 * libgtkspell-3-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2679 * libgtkspell-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2678 * libvte-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2675 * libvte-2.90-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2263 (not sure we need this one here) * libwnck-dev: https://github.com/travis-ci/apt-package-whitelist/issues/2677
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193495010
#395 is more than likely to also affect this version of the TravisCI setup.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193495574
Added a commit building and caching libgit2 0.21.5 as it's just not available in Ubuntu 12.04 or even 14.04. It's small, it builds quickly (less than 10s apparently), and it'll be cached basically forever (until dependency bump or cache expiration, if such a thing exists) once built. With this, GitChangeBar builds fine.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-193522492
- fi
- test -z "$TEMPDIR" || rm -rf "$TEMPDIR"
- export PKG_CONFIG_PATH="$HOME/$libgit2dir/lib/pkgconfig:$PKG_CONFIG_PATH"
- export LD_LIBRARY_PATH="$HOME/$libgit2dir/lib:$LD_LIBRARY_PATH"
+before_script:
- # prepare for GP
- export CFLAGS="-g -O2 -Werror=pointer-arith -Werror=aggregate-return -Werror=implicit-function-declaration"
+script:
- NOCONFIGURE=1 ./autogen.sh &&
- mkdir _build &&
- cd _build &&
- ../configure &&
- make -j2 &&
Do we really want to build with j2? On Travis I don't see much we are winning but error output might be harder to read.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394/files#r55325937
- fi
- test -z "$TEMPDIR" || rm -rf "$TEMPDIR"
- export PKG_CONFIG_PATH="$HOME/$libgit2dir/lib/pkgconfig:$PKG_CONFIG_PATH"
- export LD_LIBRARY_PATH="$HOME/$libgit2dir/lib:$LD_LIBRARY_PATH"
+before_script:
- # prepare for GP
- export CFLAGS="-g -O2 -Werror=pointer-arith -Werror=aggregate-return -Werror=implicit-function-declaration"
+script:
- NOCONFIGURE=1 ./autogen.sh &&
- mkdir _build &&
- cd _build &&
- ../configure &&
- make -j2 &&
Travis container-based build machines advertize 2 cores [in the docs](https://docs.travis-ci.com/user/migrating-from-legacy/#More-available-resour...), and legacy VM ones [1.5](https://docs.travis-ci.com/user/speeding-up-the-build/#Parallelizing-your-bu...). So actually for speed we could even go to 3 parallel jobs (or more) to account for time wasted in non-CPU-bound operations (file reads, etc.).
error output might be harder to read.
How so? Any sane Make implementation has output synchronization, and GNU Make's default is to group target output together, so I don't see the issue? But even if target-grouping is not enough in your opinion, we could choose recursive grouping (`--output-sync=recursive`).
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394/files#r55345550
- fi
- test -z "$TEMPDIR" || rm -rf "$TEMPDIR"
- export PKG_CONFIG_PATH="$HOME/$libgit2dir/lib/pkgconfig:$PKG_CONFIG_PATH"
- export LD_LIBRARY_PATH="$HOME/$libgit2dir/lib:$LD_LIBRARY_PATH"
+before_script:
- # prepare for GP
- export CFLAGS="-g -O2 -Werror=pointer-arith -Werror=aggregate-return -Werror=implicit-function-declaration"
+script:
- NOCONFIGURE=1 ./autogen.sh &&
- mkdir _build &&
- cd _build &&
- ../configure &&
- make -j2 &&
OK. I just dropped -j out of my mind years ago as it didn't work. If its working by now, I'm fine ;)
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394/files#r55568225
Rebased on *master* to get the required fixes, and I took the opportunity to squash the 2 *GeanyPy*-related commits, and fixing a comment.
PS: travis is running this PR ;)
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#issuecomment-194467518
Merged #394.
--- Reply to this email directly or view it on GitHub: https://github.com/geany/geany-plugins/pull/394#event-583810337
github-comments@lists.geany.org