From 9817d2c19f71495cbed32bc9172a433e9aedabf1 Mon Sep 17 00:00:00 2001 From: Jamie Hewland Date: Mon, 18 Dec 2017 18:07:49 +0200 Subject: [PATCH] Alpine: Ensure thread stack size is large enough (#211) --- 2.7/alpine3.4/Dockerfile | 3 +++ 2.7/alpine3.6/Dockerfile | 3 +++ 3.4/alpine3.4/Dockerfile | 3 +++ 3.5/alpine3.4/Dockerfile | 3 +++ 3.6/alpine3.4/Dockerfile | 3 +++ 3.6/alpine3.6/Dockerfile | 3 +++ 3.7-rc/alpine3.6/Dockerfile | 3 +++ Dockerfile-alpine.template | 3 +++ 8 files changed, 24 insertions(+) diff --git a/2.7/alpine3.4/Dockerfile b/2.7/alpine3.4/Dockerfile index 0845301ea..e1030222b 100644 --- a/2.7/alpine3.4/Dockerfile +++ b/2.7/alpine3.4/Dockerfile @@ -60,6 +60,9 @@ RUN set -ex \ --enable-shared \ --enable-unicode=ucs4 \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/2.7/alpine3.6/Dockerfile b/2.7/alpine3.6/Dockerfile index 8ab8cacc0..df7750273 100644 --- a/2.7/alpine3.6/Dockerfile +++ b/2.7/alpine3.6/Dockerfile @@ -60,6 +60,9 @@ RUN set -ex \ --enable-shared \ --enable-unicode=ucs4 \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/3.4/alpine3.4/Dockerfile b/3.4/alpine3.4/Dockerfile index 886c44534..f1c88b1db 100644 --- a/3.4/alpine3.4/Dockerfile +++ b/3.4/alpine3.4/Dockerfile @@ -72,6 +72,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/3.5/alpine3.4/Dockerfile b/3.5/alpine3.4/Dockerfile index 2235ad5e4..c8f421366 100644 --- a/3.5/alpine3.4/Dockerfile +++ b/3.5/alpine3.4/Dockerfile @@ -72,6 +72,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/3.6/alpine3.4/Dockerfile b/3.6/alpine3.4/Dockerfile index 466a834c8..1367fe8a7 100644 --- a/3.6/alpine3.4/Dockerfile +++ b/3.6/alpine3.4/Dockerfile @@ -72,6 +72,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/3.6/alpine3.6/Dockerfile b/3.6/alpine3.6/Dockerfile index dfbfeec46..9649b2234 100644 --- a/3.6/alpine3.6/Dockerfile +++ b/3.6/alpine3.6/Dockerfile @@ -72,6 +72,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/3.7-rc/alpine3.6/Dockerfile b/3.7-rc/alpine3.6/Dockerfile index ff4b9302b..f58013153 100644 --- a/3.7-rc/alpine3.6/Dockerfile +++ b/3.7-rc/alpine3.6/Dockerfile @@ -72,6 +72,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \ diff --git a/Dockerfile-alpine.template b/Dockerfile-alpine.template index ba32dd119..1d9dc3247 100644 --- a/Dockerfile-alpine.template +++ b/Dockerfile-alpine.template @@ -66,6 +66,9 @@ RUN set -ex \ --with-system-ffi \ --without-ensurepip \ && make -j "$(nproc)" \ +# set thread stack size to 1MB so we don't segfault before we hit sys.getrecursionlimit() +# https://github.com/alpinelinux/aports/commit/2026e1259422d4e0cf92391ca2d3844356c649d0 + EXTRA_CFLAGS="-DTHREAD_STACK_SIZE=0x100000" \ && make install \ \ && runDeps="$( \