mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2025-03-01 01:20:49 +03:00
Add s390x arch support (#2172)
This commit is contained in:
parent
9b1146780c
commit
44b7eb881c
10
.github/workflows/release.yml
vendored
10
.github/workflows/release.yml
vendored
@ -17,6 +17,7 @@ jobs:
|
|||||||
- armv6
|
- armv6
|
||||||
- 386
|
- 386
|
||||||
- armv5
|
- armv5
|
||||||
|
- s390x
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-20.04
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
@ -40,6 +41,8 @@ jobs:
|
|||||||
sudo apt install gcc-i686-linux-gnu
|
sudo apt install gcc-i686-linux-gnu
|
||||||
elif [ "${{ matrix.platform }}" == "armv5" ]; then
|
elif [ "${{ matrix.platform }}" == "armv5" ]; then
|
||||||
sudo apt install gcc-arm-linux-gnueabi
|
sudo apt install gcc-arm-linux-gnueabi
|
||||||
|
elif [ "${{ matrix.platform }}" == "s390x" ]; then
|
||||||
|
sudo apt install gcc-s390x-linux-gnu
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Build x-ui
|
- name: Build x-ui
|
||||||
@ -65,6 +68,9 @@ jobs:
|
|||||||
export GOARCH=arm
|
export GOARCH=arm
|
||||||
export GOARM=5
|
export GOARM=5
|
||||||
export CC=arm-linux-gnueabi-gcc
|
export CC=arm-linux-gnueabi-gcc
|
||||||
|
elif [ "${{ matrix.platform }}" == "s390x" ]; then
|
||||||
|
export GOARCH=s390x
|
||||||
|
export CC=s390x-linux-gnu-gcc
|
||||||
fi
|
fi
|
||||||
go build -o xui-release -v main.go
|
go build -o xui-release -v main.go
|
||||||
|
|
||||||
@ -102,6 +108,10 @@ jobs:
|
|||||||
wget ${Xray_URL}Xray-linux-arm32-v5.zip
|
wget ${Xray_URL}Xray-linux-arm32-v5.zip
|
||||||
unzip Xray-linux-arm32-v5.zip
|
unzip Xray-linux-arm32-v5.zip
|
||||||
rm -f Xray-linux-arm32-v5.zip
|
rm -f Xray-linux-arm32-v5.zip
|
||||||
|
elif [ "${{ matrix.platform }}" == "s390x" ]; then
|
||||||
|
wget ${Xray_URL}Xray-linux-s390x.zip
|
||||||
|
unzip Xray-linux-s390x.zip
|
||||||
|
rm -f Xray-linux-s390x.zip
|
||||||
fi
|
fi
|
||||||
rm -f geoip.dat geosite.dat
|
rm -f geoip.dat geosite.dat
|
||||||
wget https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat
|
wget https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat
|
||||||
|
@ -79,6 +79,7 @@ case "${ARCH}" in
|
|||||||
armv7* | armv7) XUI_ARCH="armv7" ;;
|
armv7* | armv7) XUI_ARCH="armv7" ;;
|
||||||
armv6* | armv6) XUI_ARCH="armv6" ;;
|
armv6* | armv6) XUI_ARCH="armv6" ;;
|
||||||
armv5* | armv5) XUI_ARCH="armv5" ;;
|
armv5* | armv5) XUI_ARCH="armv5" ;;
|
||||||
|
s390x) echo 's390x' ;;
|
||||||
*) XUI_ARCH="amd64" ;;
|
*) XUI_ARCH="amd64" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@ -97,6 +98,7 @@ case "${ARCH}" in
|
|||||||
armv7* | armv7) XUI_ARCH="armv7" ;;
|
armv7* | armv7) XUI_ARCH="armv7" ;;
|
||||||
armv6* | armv6) XUI_ARCH="armv6" ;;
|
armv6* | armv6) XUI_ARCH="armv6" ;;
|
||||||
armv5* | armv5) XUI_ARCH="armv5" ;;
|
armv5* | armv5) XUI_ARCH="armv5" ;;
|
||||||
|
s390x) echo 's390x' ;;
|
||||||
*) XUI_ARCH="amd64" ;;
|
*) XUI_ARCH="amd64" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@ -205,6 +207,8 @@ Our platform offers compatibility with a diverse range of architectures and devi
|
|||||||
- **armv6 / arm / arm32**: Geared towards very old embedded devices, this architecture, while less prevalent, is still in use. Devices such as Raspberry Pi 1, Raspberry Pi Zero/Zero W, rely on this architecture.
|
- **armv6 / arm / arm32**: Geared towards very old embedded devices, this architecture, while less prevalent, is still in use. Devices such as Raspberry Pi 1, Raspberry Pi Zero/Zero W, rely on this architecture.
|
||||||
|
|
||||||
- **armv5 / arm / arm32**: An older architecture primarily associated with early embedded systems, it is less common today but may still be found in legacy devices like early Raspberry Pi versions and some older smartphones.
|
- **armv5 / arm / arm32**: An older architecture primarily associated with early embedded systems, it is less common today but may still be found in legacy devices like early Raspberry Pi versions and some older smartphones.
|
||||||
|
|
||||||
|
- **s390x**: This architecture is commonly used in IBM mainframe computers and offers high performance and reliability for enterprise workloads.
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
## Languages
|
## Languages
|
||||||
|
@ -31,6 +31,7 @@ arch() {
|
|||||||
armv7* | armv7 | arm) echo 'armv7' ;;
|
armv7* | armv7 | arm) echo 'armv7' ;;
|
||||||
armv6* | armv6) echo 'armv6' ;;
|
armv6* | armv6) echo 'armv6' ;;
|
||||||
armv5* | armv5) echo 'armv5' ;;
|
armv5* | armv5) echo 'armv5' ;;
|
||||||
|
s390x) echo 's390x' ;;
|
||||||
*) echo -e "${green}Unsupported CPU architecture! ${plain}" && rm -f install.sh && exit 1 ;;
|
*) echo -e "${green}Unsupported CPU architecture! ${plain}" && rm -f install.sh && exit 1 ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user