File tree Expand file tree Collapse file tree 6 files changed +96
-0
lines changed Expand file tree Collapse file tree 6 files changed +96
-0
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2525RUN unzip musl.zip
2626RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/switch/clang-3.9.1/
2727
28+ RUN apk add patch
29+
30+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
31+ ARG PATCH_BRANCH=main
32+
33+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
34+ RUN unzip patches.zip -d /tmp
35+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
36+
37+ # apply patches to clang
38+ RUN patch_dir="/tmp/patches/clang-3.9.1" && \
39+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
40+ echo "Applying patch: $patch" ; \
41+ patch -d "/compilers/switch/clang-3.9.1" -p0 < "$patch" ; \
42+ done;
43+
2844RUN chown -R root:root /compilers/switch/clang-3.9.1/
2945
3046
Original file line number Diff line number Diff line change @@ -25,6 +25,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2525RUN unzip musl.zip
2626RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/switch/clang-4.0.1/
2727
28+ RUN apk add patch
29+
30+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
31+ ARG PATCH_BRANCH=main
32+
33+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
34+ RUN unzip patches.zip -d /tmp
35+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
36+
37+ # apply patches to clang
38+ RUN patch_dir="/tmp/patches/clang-4.0.1" && \
39+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
40+ echo "Applying patch: $patch" ; \
41+ patch -d "/compilers/switch/clang-4.0.1" -p0 < "$patch" ; \
42+ done;
43+
2844RUN chown -R root:root /compilers/switch/clang-4.0.1/
2945
3046
Original file line number Diff line number Diff line change @@ -25,6 +25,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2525RUN unzip musl.zip
2626RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/switch/clang-4.0.1/
2727
28+ RUN apk add patch
29+
30+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
31+ ARG PATCH_BRANCH=main
32+
33+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
34+ RUN unzip patches.zip -d /tmp
35+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
36+
37+ # apply patches to clang
38+ RUN patch_dir="/tmp/patches/clang-4.0.1" && \
39+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
40+ echo "Applying patch: $patch" ; \
41+ patch -d "/compilers/switch/clang-4.0.1" -p0 < "$patch" ; \
42+ done;
43+
2844RUN chown -R root:root /compilers/switch/clang-4.0.1/
2945
3046
Original file line number Diff line number Diff line change @@ -25,6 +25,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2525RUN unzip musl.zip
2626RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/switch/clang-8.0.0/
2727
28+ RUN apk add patch
29+
30+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
31+ ARG PATCH_BRANCH=main
32+
33+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
34+ RUN unzip patches.zip -d /tmp
35+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
36+
37+ # apply patches to clang
38+ RUN patch_dir="/tmp/patches/clang-8.0.0" && \
39+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
40+ echo "Applying patch: $patch" ; \
41+ patch -d "/compilers/switch/clang-8.0.0" -p0 < "$patch" ; \
42+ done;
43+
2844RUN chown -R root:root /compilers/switch/clang-8.0.0/
2945
3046
Original file line number Diff line number Diff line change @@ -25,6 +25,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2525RUN unzip musl.zip
2626RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/switch/clang-8.0.0/
2727
28+ RUN apk add patch
29+
30+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
31+ ARG PATCH_BRANCH=main
32+
33+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
34+ RUN unzip patches.zip -d /tmp
35+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
36+
37+ # apply patches to clang
38+ RUN patch_dir="/tmp/patches/clang-8.0.0" && \
39+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
40+ echo "Applying patch: $patch" ; \
41+ patch -d "/compilers/switch/clang-8.0.0" -p0 < "$patch" ; \
42+ done;
43+
2844RUN chown -R root:root /compilers/switch/clang-8.0.0/
2945
3046
Original file line number Diff line number Diff line change @@ -24,6 +24,22 @@ RUN wget -O musl.zip https://github.com/open-ead/botw-lib-musl/archive/${MUSL_HA
2424RUN unzip musl.zip
2525RUN cp -r botw-lib-musl-${MUSL_HASH} /compilers/{{ platform }}/{{ id }}/
2626
27+ RUN apk add patch
28+
29+ ARG PATCH_REPO=https://github.com/GRAnimated/switch-clang-patches
30+ ARG PATCH_BRANCH=main
31+
32+ RUN wget -O patches.zip "${PATCH_REPO}/archive/refs/heads/${PATCH_BRANCH}.zip"
33+ RUN unzip patches.zip -d /tmp
34+ RUN mv /tmp/switch-clang-patches-${PATCH_BRANCH} /tmp/patches
35+
36+ # apply patches to clang
37+ RUN patch_dir="/tmp/patches/{{ id }}" && \
38+ find "$patch_dir" -type f -name '*.diff' -print0 | while IFS= read -r -d '' patch; do \
39+ echo "Applying patch: $patch"; \
40+ patch -d "/compilers/{{ platform }}/{{ id }}" -p0 < "$patch"; \
41+ done;
42+
2743RUN chown -R root:root /compilers/{{ platform }}/{{ id }}/
2844
2945
You can’t perform that action at this time.
0 commit comments