threads / patch / 51014

patchci: install 'libsvn-perl' instead of 'git-svn'

Subject: [PATCH] ci: install 'libsvn-perl' instead of 'git-svn'

## tl;dr

4 messages between Apr 30, 2019 and May 3, 2019. Diffs are folded; open one to read it.

replies: 3people: 2as markdown or json

SZEDER Gábor· Apr 30, 2019, 12:37 UTC · lore

Since e7e9f5e7a1 (travis-ci: enable Git SVN tests t91xx on Linux, 2016-05-19) some of our Travis CI build jobs install the 'git-svn' package, because it was a convenient way to install its dependencies, which are necessary to run our 'git-svn' tests (we don't actually need the 'git-svn' package itself). However, from those dependencies, namely the 'libsvn-perl', 'libyaml-perl', and 'libterm-readkey-perl' packages, only 'libsvn-perl' is necessary to run those tests, the others arent, not even to fulfill some prereqs.

So update 'ci/install-dependencies.sh' to install only 'libsvn-perl' instead of 'git-svn' and its additional dependencies.

Note that this change has more important implications than merely not installing three unnecessary packages, as it keeps our builds working with Travis CI's Xenial images. In our '.travis.yml' we never explicitly specified which Linux image we want to use to run our Linux build jobs, and so far they have been run on the default Ubuntu 14.04 Trusty image. However, 14.04 just reached its EOL, and Travis CI has already began the transition to use 16.04 Xenial as the default Linux build environment [1]. Alas, our Linux Clang and GCC build jobs can't simply 'apt-get install git-svn' in the current Xenial images [2], like they did in the Trusty images, and, consequently, fail. Installing only 'libsvn-perl' avoids this issue, while the 'git svn' tests are still run as they should.

[1] https://blog.travis-ci.com/2019-04-15-xenial-default-build-environment
[2] 'apt-get install git-svn' in the Xenial image fails with:
      The following packages have unmet dependencies:
       git-svn : Depends: git (< 1:2.7.4-.)
      E: Unable to correct problems, you have held broken packages.
    The reason is that both the Trusty and Xenial images contain the
    'git' package installed from 'ppa:git-core/ppa', so it's
    considerably newer than the 'git' package in the corresponding
    standard Ubuntu package repositories.  The difference is that the
    Trusty image still contains these third-party apt repositories, so
    the 'git-svn' package was installed from the same PPA, and its
    version matched the version of the already installed 'git'
    package.  In the Xenial image, however, these third-party
    apt-repositories are removed (to reduce the risk of unrelated
    interference and faster 'apt-get update') [3], and the version of
    the 'git-svn' package coming from the standard Ubuntu package
    repositories doesn't match the much more recent version of the
    'git' package installed from the PPA, resulting in this dependecy
    error.
    Adding back the 'ppa:git-core/ppa' package repository would solve
    this dependency issue as well, but since the troublesome package
    happens to be unnecessary, not installing it in the first place is
    better.
[3] https://docs.travis-ci.com/user/reference/xenial/#third-party-apt-repositories-removed
Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
---
 ci/install-dependencies.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Show changes to ci/install-dependencies.sh +1 −1
diff --git a/ci/install-dependencies.sh b/ci/install-dependencies.sh
index 52a44c690a..7f6acdd803 100755
--- a/ci/install-dependencies.sh
+++ b/ci/install-dependencies.sh
@@ -12,7 +12,7 @@ case "$jobname" in
 linux-clang|linux-gcc)
 	sudo apt-add-repository -y "ppa:ubuntu-toolchain-r/test"
 	sudo apt-get -q update
-	sudo apt-get -q -y install language-pack-is git-svn apache2
+	sudo apt-get -q -y install language-pack-is libsvn-perl apache2
 	case "$jobname" in
 	linux-gcc)
 		sudo apt-get -q -y install gcc-8
-- 
2.21.0.1181.g24122a4251
Johannes Schindelin· Apr 30, 2019, 22:16 UTC · re: SZEDER Gábor · lore

Re: [PATCH] ci: install 'libsvn-perl' instead of 'git-svn'

Hi,
On Tue, 30 Apr 2019, SZEDER Gábor wrote:
Show 70 quoted lines
> Since e7e9f5e7a1 (travis-ci: enable Git SVN tests t91xx on Linux,
> 2016-05-19) some of our Travis CI build jobs install the 'git-svn'
> package, because it was a convenient way to install its dependencies,
> which are necessary to run our 'git-svn' tests (we don't actually need
> the 'git-svn' package itself).  However, from those dependencies,
> namely the 'libsvn-perl', 'libyaml-perl', and 'libterm-readkey-perl'
> packages, only 'libsvn-perl' is necessary to run those tests, the
> others arent, not even to fulfill some prereqs.
>
> So update 'ci/install-dependencies.sh' to install only 'libsvn-perl'
> instead of 'git-svn' and its additional dependencies.
>
> Note that this change has more important implications than merely not
> installing three unnecessary packages, as it keeps our builds working
> with Travis CI's Xenial images.  In our '.travis.yml' we never
> explicitly specified which Linux image we want to use to run our Linux
> build jobs, and so far they have been run on the default Ubuntu 14.04
> Trusty image.  However, 14.04 just reached its EOL, and Travis CI has
> already began the transition to use 16.04 Xenial as the default Linux
> build environment [1].  Alas, our Linux Clang and GCC build jobs can't
> simply 'apt-get install git-svn' in the current Xenial images [2],
> like they did in the Trusty images, and, consequently, fail.
> Installing only 'libsvn-perl' avoids this issue, while the 'git svn'
> tests are still run as they should.
>
> [1] https://blog.travis-ci.com/2019-04-15-xenial-default-build-environment
>
> [2] 'apt-get install git-svn' in the Xenial image fails with:
>
>       The following packages have unmet dependencies:
>        git-svn : Depends: git (< 1:2.7.4-.)
>       E: Unable to correct problems, you have held broken packages.
>
>     The reason is that both the Trusty and Xenial images contain the
>     'git' package installed from 'ppa:git-core/ppa', so it's
>     considerably newer than the 'git' package in the corresponding
>     standard Ubuntu package repositories.  The difference is that the
>     Trusty image still contains these third-party apt repositories, so
>     the 'git-svn' package was installed from the same PPA, and its
>     version matched the version of the already installed 'git'
>     package.  In the Xenial image, however, these third-party
>     apt-repositories are removed (to reduce the risk of unrelated
>     interference and faster 'apt-get update') [3], and the version of
>     the 'git-svn' package coming from the standard Ubuntu package
>     repositories doesn't match the much more recent version of the
>     'git' package installed from the PPA, resulting in this dependecy
>     error.
>
>     Adding back the 'ppa:git-core/ppa' package repository would solve
>     this dependency issue as well, but since the troublesome package
>     happens to be unnecessary, not installing it in the first place is
>     better.
>
> [3] https://docs.travis-ci.com/user/reference/xenial/#third-party-apt-repositories-removed
>
> Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
> ---
>  ci/install-dependencies.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/ci/install-dependencies.sh b/ci/install-dependencies.sh
> index 52a44c690a..7f6acdd803 100755
> --- a/ci/install-dependencies.sh
> +++ b/ci/install-dependencies.sh
> @@ -12,7 +12,7 @@ case "$jobname" in
>  linux-clang|linux-gcc)
>  	sudo apt-add-repository -y "ppa:ubuntu-toolchain-r/test"
>  	sudo apt-get -q update
> -	sudo apt-get -q -y install language-pack-is git-svn apache2
> +	sudo apt-get -q -y install language-pack-is libsvn-perl apache2
Makes sense.
I assume you verified that this works also with our Azure Pipeline?

Thanks, Dscho

Show 7 quoted lines
>  	case "$jobname" in
>  	linux-gcc)
>  		sudo apt-get -q -y install gcc-8
> --
> 2.21.0.1181.g24122a4251
>
>
SZEDER Gábor· May 1, 2019, 23:18 UTC · re: Johannes Schindelin · lore

Re: [PATCH] ci: install 'libsvn-perl' instead of 'git-svn'

On Tue, Apr 30, 2019 at 06:16:48PM -0400, Johannes Schindelin wrote:
Show 78 quoted lines
> Hi,
> 
> On Tue, 30 Apr 2019, SZEDER Gábor wrote:
> 
> > Since e7e9f5e7a1 (travis-ci: enable Git SVN tests t91xx on Linux,
> > 2016-05-19) some of our Travis CI build jobs install the 'git-svn'
> > package, because it was a convenient way to install its dependencies,
> > which are necessary to run our 'git-svn' tests (we don't actually need
> > the 'git-svn' package itself).  However, from those dependencies,
> > namely the 'libsvn-perl', 'libyaml-perl', and 'libterm-readkey-perl'
> > packages, only 'libsvn-perl' is necessary to run those tests, the
> > others arent, not even to fulfill some prereqs.
> >
> > So update 'ci/install-dependencies.sh' to install only 'libsvn-perl'
> > instead of 'git-svn' and its additional dependencies.
> >
> > Note that this change has more important implications than merely not
> > installing three unnecessary packages, as it keeps our builds working
> > with Travis CI's Xenial images.  In our '.travis.yml' we never
> > explicitly specified which Linux image we want to use to run our Linux
> > build jobs, and so far they have been run on the default Ubuntu 14.04
> > Trusty image.  However, 14.04 just reached its EOL, and Travis CI has
> > already began the transition to use 16.04 Xenial as the default Linux
> > build environment [1].  Alas, our Linux Clang and GCC build jobs can't
> > simply 'apt-get install git-svn' in the current Xenial images [2],
> > like they did in the Trusty images, and, consequently, fail.
> > Installing only 'libsvn-perl' avoids this issue, while the 'git svn'
> > tests are still run as they should.
> >
> > [1] https://blog.travis-ci.com/2019-04-15-xenial-default-build-environment
> >
> > [2] 'apt-get install git-svn' in the Xenial image fails with:
> >
> >       The following packages have unmet dependencies:
> >        git-svn : Depends: git (< 1:2.7.4-.)
> >       E: Unable to correct problems, you have held broken packages.
> >
> >     The reason is that both the Trusty and Xenial images contain the
> >     'git' package installed from 'ppa:git-core/ppa', so it's
> >     considerably newer than the 'git' package in the corresponding
> >     standard Ubuntu package repositories.  The difference is that the
> >     Trusty image still contains these third-party apt repositories, so
> >     the 'git-svn' package was installed from the same PPA, and its
> >     version matched the version of the already installed 'git'
> >     package.  In the Xenial image, however, these third-party
> >     apt-repositories are removed (to reduce the risk of unrelated
> >     interference and faster 'apt-get update') [3], and the version of
> >     the 'git-svn' package coming from the standard Ubuntu package
> >     repositories doesn't match the much more recent version of the
> >     'git' package installed from the PPA, resulting in this dependecy
> >     error.
> >
> >     Adding back the 'ppa:git-core/ppa' package repository would solve
> >     this dependency issue as well, but since the troublesome package
> >     happens to be unnecessary, not installing it in the first place is
> >     better.
> >
> > [3] https://docs.travis-ci.com/user/reference/xenial/#third-party-apt-repositories-removed
> >
> > Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
> > ---
> >  ci/install-dependencies.sh | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/ci/install-dependencies.sh b/ci/install-dependencies.sh
> > index 52a44c690a..7f6acdd803 100755
> > --- a/ci/install-dependencies.sh
> > +++ b/ci/install-dependencies.sh
> > @@ -12,7 +12,7 @@ case "$jobname" in
> >  linux-clang|linux-gcc)
> >  	sudo apt-add-repository -y "ppa:ubuntu-toolchain-r/test"
> >  	sudo apt-get -q update
> > -	sudo apt-get -q -y install language-pack-is git-svn apache2
> > +	sudo apt-get -q -y install language-pack-is libsvn-perl apache2
> 
> Makes sense.
> 
> I assume you verified that this works also with our Azure Pipeline?

No, I didn't; only on Travis CI's 14.04 and 16.04 images and on a local 16.04 install.

Johannes Schindelin· May 3, 2019, 08:32 UTC · re: SZEDER Gábor · lore

Re: [PATCH] ci: install 'libsvn-perl' instead of 'git-svn'

Hi,
On Thu, 2 May 2019, SZEDER Gábor wrote:
Show 8 quoted lines
> On Tue, Apr 30, 2019 at 06:16:48PM -0400, Johannes Schindelin wrote:
>
> > > [...]
> >
> > I assume you verified that this works also with our Azure Pipeline?
>
> No, I didn't; only on Travis CI's 14.04 and 16.04 images and on a
> local 16.04 install.
I guess we'll find out once things hit `pu`...

Ciao, Dscho

← back to recent threads