Skip to content

Commit 6aafbbc

Browse files
committed
Enable using LDEARCH to set wsl1 as the osversion. Set LDEARCH to get a WSL1 compile on a standard Linux system in Dockerfile_maiko (and hence in the workflow buildRelease.yml).
1 parent 5dc9233 commit 6aafbbc

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

.github/workflows/Dockerfile_maiko

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,10 @@ RUN cd ${INSTALL_LOCATION}/bin \
2626
RUN cd ${INSTALL_LOCATION}/bin \
2727
&& arch="$(./machinetype)" \
2828
&& if [ "$arch" = "x86_64" ] || [ "$arch" = "aarch64" ]; then \
29-
mv osversion osversion.hold \
30-
&& echo "#!/bin/sh" > osversion \
31-
&& echo "echo wsl1" >> osversion \
32-
&& chmod ugo+x osversion \
29+
&& export LDEARCH="${arch}-microsoft-wsl1" \
3330
&& ./makeright x cleanup \
3431
&& ./makeright x \
32+
&& ./makeright init clean \
3533
&& ./makeright init \
36-
&& mv osversion.hold osversion \
37-
&& chmod ugo+x osversion \
3834
; \
3935
fi

bin/osversion

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ case "$os" in
1515
*-*-freebsd*) echo freebsd ;;
1616
*-*-cygwin*) echo cygwin ;;
1717
*-*-haiku*) echo haiku ;;
18+
*-microsoft-wsl1) echo wsl1 ;;
1819
esac
1920
### Don't leave the variable set.
2021
unset os

0 commit comments

Comments
 (0)