mirror of
https://github.com/git/git.git
synced 2024-11-01 23:07:55 +01:00
Merge branch 'js/travis-32bit-linux' into maint
Add 32-bit Linux variant to the set of platforms to be tested with Travis CI. * js/travis-32bit-linux: Travis: also test on 32-bit Linux
This commit is contained in:
commit
8e87cbc740
2 changed files with 51 additions and 0 deletions
21
.travis.yml
21
.travis.yml
|
@ -39,6 +39,27 @@ env:
|
|||
|
||||
matrix:
|
||||
include:
|
||||
- env: Linux32
|
||||
os: linux
|
||||
services:
|
||||
- docker
|
||||
before_install:
|
||||
- docker pull daald/ubuntu32:xenial
|
||||
before_script:
|
||||
script:
|
||||
- >
|
||||
docker run
|
||||
--interactive
|
||||
--env DEFAULT_TEST_TARGET
|
||||
--env GIT_PROVE_OPTS
|
||||
--env GIT_TEST_OPTS
|
||||
--env GIT_TEST_CLONE_2GB
|
||||
--volume "${PWD}:/usr/src/git"
|
||||
daald/ubuntu32:xenial
|
||||
/usr/src/git/ci/run-linux32-build.sh $(id -u $USER)
|
||||
# Use the following command to debug the docker build locally:
|
||||
# $ docker run -itv "${PWD}:/usr/src/git" --entrypoint /bin/bash daald/ubuntu32:xenial
|
||||
# root@container:/# /usr/src/git/ci/run-linux32-build.sh
|
||||
- env: Documentation
|
||||
os: linux
|
||||
compiler: clang
|
||||
|
|
30
ci/run-linux32-build.sh
Executable file
30
ci/run-linux32-build.sh
Executable file
|
@ -0,0 +1,30 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Build and test Git in a 32-bit environment
|
||||
#
|
||||
# Usage:
|
||||
# run-linux32-build.sh [host-user-id]
|
||||
#
|
||||
|
||||
# Update packages to the latest available versions
|
||||
linux32 --32bit i386 sh -c '
|
||||
apt update >/dev/null &&
|
||||
apt install -y build-essential libcurl4-openssl-dev libssl-dev \
|
||||
libexpat-dev gettext python >/dev/null
|
||||
' &&
|
||||
|
||||
# If this script runs inside a docker container, then all commands are
|
||||
# usually executed as root. Consequently, the host user might not be
|
||||
# able to access the test output files.
|
||||
# If a host user id is given, then create a user "ci" with the host user
|
||||
# id to make everything accessible to the host user.
|
||||
HOST_UID=$1 &&
|
||||
CI_USER=$USER &&
|
||||
test -z $HOST_UID || (CI_USER="ci" && useradd -u $HOST_UID $CI_USER) &&
|
||||
|
||||
# Build and test
|
||||
linux32 --32bit i386 su -m -l $CI_USER -c '
|
||||
cd /usr/src/git &&
|
||||
make --jobs=2 &&
|
||||
make --quiet test
|
||||
'
|
Loading…
Reference in a new issue