annotate Resources/Builders/Debian/docker-buster-compile.sh @ 112:b3a18e333f93

integration 4.0->mainline
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 28 Mar 2023 17:28:16 +0200
parents 81a0975a2479
children 3678a028f1f6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 #!/bin/bash
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 set -ex
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 if [ "$1" != "Debug" -a "$1" != "Release" ]; then
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 echo "Please provide build type: Debug or Release"
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 exit -1
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 fi
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 if [ -t 1 ]; then
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 # TTY is available => use interactive mode
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 DOCKER_FLAGS='-i'
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 fi
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 ROOT_DIR=`dirname $(readlink -f $0)`/../../..
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16
88
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
17 mkdir -p ${ROOT_DIR}/docker-build-buster/
0
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18
88
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
19 docker pull debian:buster-slim
0
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 docker run -t ${DOCKER_FLAGS} --rm \
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22 -v ${ROOT_DIR}:/source:ro \
88
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
23 -v ${ROOT_DIR}/docker-build-buster:/target:rw \
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
24 debian:buster-slim \
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
25 bash /source/Resources/Builders/Debian/docker-internal.sh $1 3.7 $(id -u) $(id -g)
0
7ed502b17b8f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26
88
81a0975a2479 distinguishing Debian docker-based builds between buster and bullseye
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 8
diff changeset
27 ls -lR ${ROOT_DIR}/docker-build-buster/