File: test.sh

package info (click to toggle)
pdbg 3.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 2,212 kB
  • sloc: ansic: 21,934; cpp: 3,363; sh: 3,343; makefile: 314; asm: 11
file content (34 lines) | stat: -rwxr-xr-x 634 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/bash

set -e

CONTAINER=pdbg-check

Dockerfile=$(cat << EOF
FROM ubuntu:18.04
RUN apt-get update && apt-get install --no-install-recommends -yy \
	make \
	gcc \
	g++ \
	autoconf \
	automake \
	libtool \
	git \
	device-tree-compiler
RUN groupadd -g ${GROUPS} ${USER} && useradd -d ${HOME} -m -u ${UID} -g ${GROUPS} ${USER}
USER ${USER}
ENV HOME ${HOME}
RUN /bin/bash
EOF
)

docker pull ubuntu:18.04
docker build -t ${CONTAINER} - <<< "${Dockerfile}"

RUN="docker run --rm=true --user=${USER} -w ${PWD} -v ${HOME}:${HOME} -t ${CONTAINER}"

${RUN} ./bootstrap.sh
${RUN} ./configure
${RUN} make clean
${RUN} make
${RUN} make check