Skip to content

Commit a29cabd

Browse files
authoredMar 1, 2024
Suggestions (#9)
1 parent c0d0878 commit a29cabd

File tree

3 files changed

+27
-16
lines changed

3 files changed

+27
-16
lines changed
 

‎Dockerfile

+10-6
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,19 @@ LABEL org.opencontainers.image.authors="Donghee Na"
66
LABEL org.opencontainers.image.title="autoconf 2.72 container for CPython"
77
LABEL org.opencontainers.image.description="Container image with autoconf 2.72 tools to regenerate Python's configure script."
88

9-
RUN apk upgrade
10-
RUN apk add autoconf automake autoconf-archive libtool pkgconfig alpine-sdk
11-
RUN wget https://ftp.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz
12-
RUN tar -zxvf autoconf-2.72.tar.gz
9+
RUN apk upgrade && \
10+
apk add \
11+
alpine-sdk \
12+
autoconf \
13+
automake \
14+
autoconf-archive \
15+
libtool \
16+
pkgconfig
17+
RUN curl https://ftp.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz | tar -zxvf -
1318
RUN cd autoconf-2.72 && ./configure && make && make install
14-
RUN autoconf -V | grep -q "autoconf (GNU Autoconf) 2.72"
1519

1620
VOLUME /src
1721
WORKDIR /src
1822

1923
ADD entry.sh /
20-
CMD ["/entry.sh"]
24+
CMD ["/entry.sh"]

‎README.md

+11-6
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,22 @@
1-
# cpython_autoconf
2-
- Container image with autotools to regenerate Python's configure script.
1+
# CPython Autoconf
2+
3+
- Container image with GNU Autotools to regenerate CPython's `configure` script.
34
- Fork from https://github.com/tiran/cpython_autoconf
45

56
## Fedora, CentOS and other SELinux-enabled systems with podman
67

78
```shell
8-
$ cd cpython
9-
$ podman run --rm --pull=always -v$(pwd):/src:Z ghcr.io/corona10/cpython_autoconf:271
9+
$ podman run --rm --pull=always -v$(pwd):/src:Z ghcr.io/corona10/cpython_autoconf:272
1010
```
1111

1212
## Arch, Debian, Gentoo, Ubuntu
1313

1414
```shell
15-
$ cd cpython
16-
$ podman run --rm --pull=always -v$(pwd):/src ghcr.io/corona10/cpython_autoconf:271
15+
$ podman run --rm --pull=always -v$(pwd):/src ghcr.io/corona10/cpython_autoconf:272
1716
```
17+
18+
## macOS and Windows
19+
20+
```shell
21+
$ docker run --rm --pull=always -v.:/src ghcr.io/corona10/cpython_autoconf:272
22+
```

‎entry.sh

+6-4
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,9 @@ if [ ! -e ${SENTINEL} ]; then
1313
exit 2
1414
fi
1515

16-
echo "Rebuilding configure script"
17-
cd $SRC
18-
autoreconf -ivf -Werror $@
19-
echo "Done"
16+
if [ "$#" = "0" ]; then
17+
echo "Rebuilding configure script using $(autoconf --version | head -n 1)"
18+
exec gosu autoreconf -ivf -Werror $@
19+
fi
20+
21+
exec "$@"

0 commit comments

Comments
 (0)
Please sign in to comment.