mirror of
https://github.com/yuk7/AlpineWSL.git
synced 2026-03-18 21:40:29 +01:00
initial arm64 build
This commit is contained in:
59
Makefile
59
Makefile
@@ -1,62 +1,25 @@
|
|||||||
OUT_ZIP=Alpine.zip
|
OUT_ZIP=Alpine.zip
|
||||||
LNCR_EXE=Alpine.exe
|
LNCR_EXE=Alpine.exe
|
||||||
|
|
||||||
|
ARCH=x64
|
||||||
|
|
||||||
DLR=curl
|
DLR=curl
|
||||||
DLR_FLAGS=-L
|
DLR_FLAGS=-L
|
||||||
BASE_URL=http://dl-cdn.alpinelinux.org/alpine/v3.13/releases/x86_64/alpine-minirootfs-3.13.4-x86_64.tar.gz
|
|
||||||
LNCR_ZIP_URL=https://github.com/yuk7/wsldl/releases/download/21020500/icons.zip
|
|
||||||
LNCR_ZIP_EXE=Alpine.exe
|
LNCR_ZIP_EXE=Alpine.exe
|
||||||
|
|
||||||
all: $(OUT_ZIP)
|
all: $(OUT_ZIP)
|
||||||
|
|
||||||
zip: $(OUT_ZIP)
|
zip: $(OUT_ZIP)
|
||||||
$(OUT_ZIP): ziproot
|
$(OUT_ZIP): $(ARCH)
|
||||||
@echo -e '\e[1;31mBuilding $(OUT_ZIP)\e[m'
|
|
||||||
cd ziproot; bsdtar -a -cf ../$(OUT_ZIP) *
|
|
||||||
|
|
||||||
ziproot: Launcher.exe rootfs.tar.gz
|
x64:
|
||||||
@echo -e '\e[1;31mBuilding ziproot...\e[m'
|
cd src_x64 && $(MAKE)
|
||||||
mkdir ziproot
|
mv src_x64/$(OUT_ZIP) ./
|
||||||
cp Launcher.exe ziproot/${LNCR_EXE}
|
|
||||||
cp rootfs.tar.gz ziproot/
|
|
||||||
|
|
||||||
exe: Launcher.exe
|
arm64:
|
||||||
Launcher.exe: icons.zip
|
cd src_arm64 && $(MAKE)
|
||||||
@echo -e '\e[1;31mExtracting Launcher.exe...\e[m'
|
mv src_arm64/$(OUT_ZIP) ./
|
||||||
bsdtar -xvf icons.zip $(LNCR_ZIP_EXE)
|
|
||||||
mv $(LNCR_ZIP_EXE) Launcher.exe
|
|
||||||
|
|
||||||
icons.zip:
|
|
||||||
@echo -e '\e[1;31mDownloading icons.zip...\e[m'
|
|
||||||
$(DLR) $(DLR_FLAGS) $(LNCR_ZIP_URL) -o icons.zip
|
|
||||||
|
|
||||||
rootfs.tar.gz: rootfs
|
|
||||||
@echo -e '\e[1;31mBuilding rootfs.tar.gz...\e[m'
|
|
||||||
cd rootfs; sudo tar -zcpf ../rootfs.tar.gz `sudo ls`
|
|
||||||
sudo chown `id -un` rootfs.tar.gz
|
|
||||||
|
|
||||||
rootfs: base.tar.gz profile
|
|
||||||
@echo -e '\e[1;31mBuilding rootfs...\e[m'
|
|
||||||
mkdir rootfs
|
|
||||||
sudo tar -zxpf base.tar.gz -C rootfs
|
|
||||||
sudo cp -f /etc/resolv.conf rootfs/etc/resolv.conf
|
|
||||||
sudo cp -f profile rootfs/etc/profile
|
|
||||||
sudo chroot rootfs /sbin/apk update
|
|
||||||
sudo chroot rootfs /sbin/apk add bash
|
|
||||||
echo "# This file was automatically generated by WSL. To stop automatic generation of this file, remove this line." | sudo tee rootfs/etc/resolv.conf
|
|
||||||
sudo rm -rf `sudo find rootfs/var/cache/apk/ -type f`
|
|
||||||
sudo chmod +x rootfs
|
|
||||||
|
|
||||||
base.tar.gz:
|
|
||||||
@echo -e '\e[1;31mDownloading base.tar.gz...\e[m'
|
|
||||||
$(DLR) $(DLR_FLAGS) $(BASE_URL) -o base.tar.gz
|
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
@echo -e '\e[1;31mCleaning files...\e[m'
|
cd src_x64 && make clean
|
||||||
-rm ${OUT_ZIP}
|
cd src_arm64 && make clean
|
||||||
-rm -r ziproot
|
|
||||||
-rm Launcher.exe
|
|
||||||
-rm icons.zip
|
|
||||||
-rm rootfs.tar.gz
|
|
||||||
-sudo rm -r rootfs
|
|
||||||
-rm base.tar.gz
|
|
||||||
60
src_arm64/Makefile
Normal file
60
src_arm64/Makefile
Normal file
@@ -0,0 +1,60 @@
|
|||||||
|
OUT_ZIP=Alpine.zip
|
||||||
|
LNCR_EXE=Alpine.exe
|
||||||
|
|
||||||
|
DLR=curl
|
||||||
|
DLR_FLAGS=-L
|
||||||
|
BASE_URL=https://dl-cdn.alpinelinux.org/alpine/v3.9/releases/aarch64/alpine-minirootfs-3.9.6-aarch64.tar.gz
|
||||||
|
LNCR_ZIP_URL=https://github.com/yuk7/wsldl/releases/download/21062500/icons_arm64.zip
|
||||||
|
LNCR_ZIP_EXE=Alpine.exe
|
||||||
|
|
||||||
|
all: $(OUT_ZIP)
|
||||||
|
|
||||||
|
zip: $(OUT_ZIP)
|
||||||
|
$(OUT_ZIP): ziproot
|
||||||
|
@echo -e '\e[1;31mBuilding $(OUT_ZIP)\e[m'
|
||||||
|
cd ziproot; bsdtar -a -cf ../$(OUT_ZIP) *
|
||||||
|
|
||||||
|
ziproot: Launcher.exe rootfs.tar.gz
|
||||||
|
@echo -e '\e[1;31mBuilding ziproot...\e[m'
|
||||||
|
mkdir ziproot
|
||||||
|
cp Launcher.exe ziproot/${LNCR_EXE}
|
||||||
|
cp rootfs.tar.gz ziproot/
|
||||||
|
|
||||||
|
exe: Launcher.exe
|
||||||
|
Launcher.exe: icons.zip
|
||||||
|
@echo -e '\e[1;31mExtracting Launcher.exe...\e[m'
|
||||||
|
bsdtar -xvf icons.zip $(LNCR_ZIP_EXE)
|
||||||
|
mv $(LNCR_ZIP_EXE) Launcher.exe
|
||||||
|
|
||||||
|
icons.zip:
|
||||||
|
@echo -e '\e[1;31mDownloading icons.zip...\e[m'
|
||||||
|
$(DLR) $(DLR_FLAGS) $(LNCR_ZIP_URL) -o icons.zip
|
||||||
|
|
||||||
|
rootfs.tar.gz: rootfs
|
||||||
|
@echo -e '\e[1;31mBuilding rootfs.tar.gz...\e[m'
|
||||||
|
cd rootfs; sudo tar -zcpf ../rootfs.tar.gz `sudo ls`
|
||||||
|
sudo chown `id -un` rootfs.tar.gz
|
||||||
|
|
||||||
|
rootfs: base.tar.gz profile
|
||||||
|
@echo -e '\e[1;31mBuilding rootfs...\e[m'
|
||||||
|
mkdir rootfs
|
||||||
|
sudo tar -zxpf base.tar.gz -C rootfs
|
||||||
|
sudo cp -f /etc/resolv.conf rootfs/etc/resolv.conf
|
||||||
|
sudo cp -f profile rootfs/etc/profile
|
||||||
|
echo "# This file was automatically generated by WSL. To stop automatic generation of this file, remove this line." | sudo tee rootfs/etc/resolv.conf
|
||||||
|
sudo rm -rf `sudo find rootfs/var/cache/apk/ -type f`
|
||||||
|
sudo chmod +x rootfs
|
||||||
|
|
||||||
|
base.tar.gz:
|
||||||
|
@echo -e '\e[1;31mDownloading base.tar.gz...\e[m'
|
||||||
|
$(DLR) $(DLR_FLAGS) $(BASE_URL) -o base.tar.gz
|
||||||
|
|
||||||
|
clean:
|
||||||
|
@echo -e '\e[1;31mCleaning files...\e[m'
|
||||||
|
-rm ${OUT_ZIP}
|
||||||
|
-rm -r ziproot
|
||||||
|
-rm Launcher.exe
|
||||||
|
-rm icons.zip
|
||||||
|
-rm rootfs.tar.gz
|
||||||
|
-sudo rm -r rootfs
|
||||||
|
-rm base.tar.gz
|
||||||
11
src_arm64/profile
Normal file
11
src_arm64/profile
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
export CHARSET=UTF-8
|
||||||
|
export LANG=C.UTF-8
|
||||||
|
export PAGER=less
|
||||||
|
export PS1='\h:\w\$ '
|
||||||
|
umask 022
|
||||||
|
|
||||||
|
for script in /etc/profile.d/*.sh ; do
|
||||||
|
if [ -r $script ] ; then
|
||||||
|
. $script
|
||||||
|
fi
|
||||||
|
done
|
||||||
62
src_x64/Makefile
Normal file
62
src_x64/Makefile
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
OUT_ZIP=Alpine.zip
|
||||||
|
LNCR_EXE=Alpine.exe
|
||||||
|
|
||||||
|
DLR=curl
|
||||||
|
DLR_FLAGS=-L
|
||||||
|
BASE_URL=https://dl-cdn.alpinelinux.org/alpine/v3.9/releases/x86_64/alpine-minirootfs-3.9.6-x86_64.tar.gz
|
||||||
|
LNCR_ZIP_URL=https://github.com/yuk7/wsldl/releases/download/21062500/icons.zip
|
||||||
|
LNCR_ZIP_EXE=Alpine.exe
|
||||||
|
|
||||||
|
all: $(OUT_ZIP)
|
||||||
|
|
||||||
|
zip: $(OUT_ZIP)
|
||||||
|
$(OUT_ZIP): ziproot
|
||||||
|
@echo -e '\e[1;31mBuilding $(OUT_ZIP)\e[m'
|
||||||
|
cd ziproot; bsdtar -a -cf ../$(OUT_ZIP) *
|
||||||
|
|
||||||
|
ziproot: Launcher.exe rootfs.tar.gz
|
||||||
|
@echo -e '\e[1;31mBuilding ziproot...\e[m'
|
||||||
|
mkdir ziproot
|
||||||
|
cp Launcher.exe ziproot/${LNCR_EXE}
|
||||||
|
cp rootfs.tar.gz ziproot/
|
||||||
|
|
||||||
|
exe: Launcher.exe
|
||||||
|
Launcher.exe: icons.zip
|
||||||
|
@echo -e '\e[1;31mExtracting Launcher.exe...\e[m'
|
||||||
|
bsdtar -xvf icons.zip $(LNCR_ZIP_EXE)
|
||||||
|
mv $(LNCR_ZIP_EXE) Launcher.exe
|
||||||
|
|
||||||
|
icons.zip:
|
||||||
|
@echo -e '\e[1;31mDownloading icons.zip...\e[m'
|
||||||
|
$(DLR) $(DLR_FLAGS) $(LNCR_ZIP_URL) -o icons.zip
|
||||||
|
|
||||||
|
rootfs.tar.gz: rootfs
|
||||||
|
@echo -e '\e[1;31mBuilding rootfs.tar.gz...\e[m'
|
||||||
|
cd rootfs; sudo tar -zcpf ../rootfs.tar.gz `sudo ls`
|
||||||
|
sudo chown `id -un` rootfs.tar.gz
|
||||||
|
|
||||||
|
rootfs: base.tar.gz profile
|
||||||
|
@echo -e '\e[1;31mBuilding rootfs...\e[m'
|
||||||
|
mkdir rootfs
|
||||||
|
sudo tar -zxpf base.tar.gz -C rootfs
|
||||||
|
sudo cp -f /etc/resolv.conf rootfs/etc/resolv.conf
|
||||||
|
sudo cp -f profile rootfs/etc/profile
|
||||||
|
sudo chroot rootfs /sbin/apk update
|
||||||
|
sudo chroot rootfs /sbin/apk add bash
|
||||||
|
echo "# This file was automatically generated by WSL. To stop automatic generation of this file, remove this line." | sudo tee rootfs/etc/resolv.conf
|
||||||
|
sudo rm -rf `sudo find rootfs/var/cache/apk/ -type f`
|
||||||
|
sudo chmod +x rootfs
|
||||||
|
|
||||||
|
base.tar.gz:
|
||||||
|
@echo -e '\e[1;31mDownloading base.tar.gz...\e[m'
|
||||||
|
$(DLR) $(DLR_FLAGS) $(BASE_URL) -o base.tar.gz
|
||||||
|
|
||||||
|
clean:
|
||||||
|
@echo -e '\e[1;31mCleaning files...\e[m'
|
||||||
|
-rm ${OUT_ZIP}
|
||||||
|
-rm -r ziproot
|
||||||
|
-rm Launcher.exe
|
||||||
|
-rm icons.zip
|
||||||
|
-rm rootfs.tar.gz
|
||||||
|
-sudo rm -r rootfs
|
||||||
|
-rm base.tar.gz
|
||||||
11
src_x64/profile
Normal file
11
src_x64/profile
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
export CHARSET=UTF-8
|
||||||
|
export LANG=C.UTF-8
|
||||||
|
export PAGER=less
|
||||||
|
export PS1='\h:\w\$ '
|
||||||
|
umask 022
|
||||||
|
|
||||||
|
for script in /etc/profile.d/*.sh ; do
|
||||||
|
if [ -r $script ] ; then
|
||||||
|
. $script
|
||||||
|
fi
|
||||||
|
done
|
||||||
Reference in New Issue
Block a user