loads of changes not corresponding to package server...
This commit is contained in:
1 parent
0f964a04f9
commit
d0adbc95bf
13 files changed
+73
-3090
No files matched your search
Regular → Executable
+4
-35
@@ -1,58 +1,27 @@
|
||||
#!/bin/bash
|
||||
# compile_all_packages_no_prompts.sh
|
||||
|
||||
set -e
|
||||
|
||||
LOG_FILE="/tmp/openwrt_build_$(date +%Y%m%d_%H%M%S).log"
|
||||
|
||||
{
|
||||
echo "=== Iniciando compilación OpenWrt sin prompts $(date) ==="
|
||||
|
||||
# Variables de entorno para evitar interacción
|
||||
export KCONFIG_NOSILENTUPDATE=1
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# Actualizar feeds
|
||||
./scripts/feeds update -a
|
||||
./scripts/feeds install -a
|
||||
|
||||
# Crear configuración base
|
||||
cat > .config << EOF
|
||||
CONFIG_TARGET_msm89xx=y
|
||||
CONFIG_TARGET_msm89xx_msm8916=y
|
||||
CONFIG_TARGET_msm89xx_msm8916_DEVICE_yiming-uz801v3=y
|
||||
CONFIG_ALL=y
|
||||
CONFIG_ALL_KMODS=y
|
||||
CONFIG_ALL_NONSHARED=y
|
||||
CONFIG_BUILD_NLS=y
|
||||
CONFIG_BUILD_PATENTED=y
|
||||
CONFIG_DEVEL=y
|
||||
CONFIG_CCACHE=y
|
||||
EOF
|
||||
|
||||
# Pre-configurar módulos problemáticos
|
||||
echo "Pre-configurando módulos del kernel..."
|
||||
|
||||
# Expandir configuración sin preguntas
|
||||
echo "Expandiendo configuración..."
|
||||
yes '' | make oldconfig 2>/dev/null || make olddefconfig
|
||||
|
||||
# Descargar fuentes
|
||||
echo "Descargando fuentes..."
|
||||
make download -j$(nproc)
|
||||
|
||||
# Compilar con auto-respuestas
|
||||
echo "Compilando..."
|
||||
yes '' | make -j$(nproc) tools/install toolchain/install 2>/dev/null || {
|
||||
echo "Compilación multi-core falló, intentando single-core..."
|
||||
yes '' | make -j1 tools/install toolchain/install V=s 2>/dev/null || true
|
||||
}
|
||||
|
||||
yes '' | make -j$(nproc) package/{compile,install} 2>/dev/null || {
|
||||
echo "Compilación multi-core falló, intentando single-core..."
|
||||
yes '' | make -j1 package/{compile,install} V=s 2>/dev/null || true
|
||||
}
|
||||
|
||||
echo "=== Compilación terminada $(date) ==="
|
||||
|
||||
make download -j1 V=s
|
||||
yes '' | make tools/install toolchain/install -j1 -k V=s 2>/dev/null
|
||||
yes '' | make package/{compile,install} -j1 -k V=s 2>/dev/null
|
||||
make package/apk-index 2>/dev/null
|
||||
} 2>&1 | tee "$LOG_FILE"
|
||||
+2
-2
@@ -3,7 +3,7 @@ FROM ubuntu:22.04 AS base
|
||||
LABEL maintainer="OpenWrt Builder"
|
||||
|
||||
# Install required dependencies
|
||||
COPY ./dependencies.sh /install_dependencies
|
||||
COPY devenv/dependencies.sh /install_dependencies
|
||||
RUN chmod +x /install_dependencies && \
|
||||
/install_dependencies && \
|
||||
rm -rf /install_dependencies
|
||||
@@ -21,7 +21,7 @@ ENV BRANCH main
|
||||
|
||||
RUN git clone --depth=1 -b ${BRANCH} https://git.openwrt.org/openwrt/openwrt.git openwrt
|
||||
|
||||
COPY ../enable_wcn36xx_mac80211.patch .
|
||||
COPY enable_wcn36xx_mac80211.patch .
|
||||
RUN git apply enable_wcn36xx_mac80211.patch
|
||||
|
||||
RUN openwrt/scripts/feeds update -a && \
|
||||
|
||||
@@ -11,7 +11,9 @@ services:
|
||||
restart: "no"
|
||||
|
||||
builder:
|
||||
build: .
|
||||
build:
|
||||
context: ..
|
||||
dockerfile: devenv/Dockerfile
|
||||
container_name: openwrt-builder
|
||||
working_dir: /home/builder/openwrt
|
||||
stdin_open: true
|
||||
|
||||
@@ -26,6 +26,9 @@ CONFIG_PACKAGE_kmod-gre6=y
|
||||
CONFIG_PACKAGE_kmod-ip6-tunnel=y
|
||||
CONFIG_PACKAGE_kmod-iptunnel=y
|
||||
CONFIG_PACKAGE_kmod-iptunnel6=y
|
||||
CONFIG_PACKAGE_kmod-leds-gpio=y
|
||||
CONFIG_PACKAGE_kmod-ledtrig-activity=y
|
||||
CONFIG_PACKAGE_kmod-ledtrig-gpio=y
|
||||
CONFIG_PACKAGE_kmod-qrtr=y
|
||||
CONFIG_PACKAGE_kmod-qrtr-tun=y
|
||||
CONFIG_PACKAGE_kmod-tun=y
|
||||
|
||||
@@ -26,6 +26,9 @@ CONFIG_PACKAGE_kmod-gre6=y
|
||||
CONFIG_PACKAGE_kmod-ip6-tunnel=y
|
||||
CONFIG_PACKAGE_kmod-iptunnel=y
|
||||
CONFIG_PACKAGE_kmod-iptunnel6=y
|
||||
CONFIG_PACKAGE_kmod-leds-gpio=y
|
||||
CONFIG_PACKAGE_kmod-ledtrig-activity=y
|
||||
CONFIG_PACKAGE_kmod-ledtrig-gpio=y
|
||||
CONFIG_PACKAGE_kmod-qrtr=y
|
||||
CONFIG_PACKAGE_kmod-qrtr-tun=y
|
||||
CONFIG_PACKAGE_kmod-tun=y
|
||||
@@ -83,6 +86,6 @@ CONFIG_PACKAGE_uhttpd=y
|
||||
CONFIG_PACKAGE_uhttpd-mod-ubus=y
|
||||
CONFIG_PACKAGE_wireguard-tools=y
|
||||
# CONFIG_TARGET_IMAGES_GZIP is not set
|
||||
CONFIG_TARGET_ROOTFS_PARTSIZE=256
|
||||
# CONFIG_TARGET_ROOTFS_SQUASHFS is not set
|
||||
# CONFIG_PACKAGE_kmod-crypto-kpp is not set
|
||||
CONFIG_TARGET_ROOTFS_PARTSIZE=256
|
||||
Binary file not shown.
File diff suppressed because it is too large.
Load diff
@@ -7,12 +7,13 @@ define Device/msm8916
|
||||
CMDLINE := "earlycon console=tty0 console=ttyMSM0,115200 root=/dev/mmcblk0p14 rw rootwait"
|
||||
endef
|
||||
|
||||
# DEVICE_DTS := msm8916-yiming-uz801v3
|
||||
# DEVICE_DTS_DIR := ../dts
|
||||
|
||||
define Device/yiming-uz801v3
|
||||
$(Device/msm8916)
|
||||
DEVICE_VENDOR := YiMing
|
||||
DEVICE_MODEL := uz801v3
|
||||
DEVICE_DTS := msm8916-yiming-uz801v3
|
||||
DEVICE_DTS_DIR := ../dts
|
||||
DEVICE_PACKAGES := uz801-tweaks wpad-basic-wolfssl qcom-msm8916-uz801-wcnss-firmware qcom-msm8916-wcnss-uz801-nv qcom-msm8916-modem-uz801-firmware
|
||||
endef
|
||||
TARGET_DEVICES += yiming-uz801v3
|
||||
|
||||
@@ -28,8 +28,10 @@ endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/etc/uci-defaults
|
||||
$(INSTALL_BIN) ./files/uci_defaults $(1)/etc/uci-defaults/98-default-config
|
||||
$(INSTALL_BIN) ./files/remove_feed $(1)/etc/uci-defaults/99-remove-bad-feed
|
||||
$(INSTALL_BIN) ./files/uci_defaults $(1)/etc/uci-defaults/99-default-config
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) ./files/smart_leds $(1)/etc/init.de/smart-leds
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
@@ -1,11 +0,0 @@
|
||||
#!/bin/sh
|
||||
# /etc/uci-defaults/99-remove-bad-feed
|
||||
|
||||
REPO_FILE="/etc/apk/repositories.d/distfeeds.list"
|
||||
BAD_FEED="https://downloads.openwrt.org/snapshots/targets/msm89xx/msm8916/packages/packages.adb"
|
||||
|
||||
if [ -f "$REPO_FILE" ]; then
|
||||
sed -i "\|$BAD_FEED|d" "$REPO_FILE"
|
||||
fi
|
||||
|
||||
exit 0
|
||||
@@ -0,0 +1,45 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
# /etc/init.d/smart-leds
|
||||
|
||||
START=98
|
||||
STOP=02
|
||||
|
||||
USE_PROCD=1
|
||||
|
||||
# On Linux sources dts, leds are crossed:
|
||||
# - blue:wan is actually wlan
|
||||
# - green:wlan is actually wan
|
||||
# - red is always power
|
||||
|
||||
start_service() {
|
||||
procd_open_instance
|
||||
procd_set_param command /bin/sh -c '
|
||||
while true; do
|
||||
# Wifi led if iface is up
|
||||
if ip link show phy0-ap0 2>/dev/null | grep -q "UP"; then
|
||||
echo 1 > /sys/class/leds/blue:wan/brightness
|
||||
else
|
||||
echo 0 > /sys/class/leds/blue:wan/brightness
|
||||
fi
|
||||
|
||||
# 4G led if wwan0 has ip
|
||||
if ip addr show wwan0 2>/dev/null | grep -q "inet "; then
|
||||
echo 1 > /sys/class/leds/green:wlan/brightness
|
||||
else
|
||||
echo 0 > /sys/class/leds/green:wlan/brightness
|
||||
fi
|
||||
|
||||
sleep 10
|
||||
done
|
||||
'
|
||||
procd_set_param respawn
|
||||
procd_set_param stdout 1
|
||||
procd_set_param stderr 1
|
||||
procd_close_instance
|
||||
}
|
||||
|
||||
stop_service() {
|
||||
# Apagar LEDs al parar el servicio
|
||||
echo 0 > /sys/class/leds/blue:wan/brightness
|
||||
echo 0 > /sys/class/leds/green:wlan/brightness
|
||||
}
|
||||
@@ -19,6 +19,7 @@ uci add_list firewall.@zone[1].network='modem'
|
||||
# We commit all the changes and restart network
|
||||
uci commit
|
||||
/etc/init.d/network restart
|
||||
/etc/init.d/led restart
|
||||
|
||||
apk del uz801-tweaks
|
||||
|
||||
@@ -12,12 +12,15 @@ full customization, to use the device in ways never envisioned.
|
||||
### This repository
|
||||
Modern version of OpenWrt working on UZ801v3:
|
||||
- Modem Working
|
||||
- ModemManager not showing Rx/Tx in Luci
|
||||
- Wifi Working
|
||||
- USB gadget working (NCM, RNDIS, MASS, ACM tested!)
|
||||
- No shell attached to ACM, just pure raw Serial (/dev/ttyGS0)
|
||||
- TUN installed
|
||||
- Wireguard Installed
|
||||
- GRE Protocol Installed
|
||||
- `init.d` script to manage leds, only on/off if iface, no blinking:
|
||||
- Activity trigger installed, _**deactivate init script and add led configs from luci or uci if needed.**_
|
||||
|
||||
### How to build OpenWrt
|
||||
Docker is required!
|
||||
@@ -39,13 +42,6 @@ After the succesfull flash if you:
|
||||
- Want to enter `fastboot`, just insert the device with the button pressed.
|
||||
- Want to enter `edl`, boot into fastboot and execute: `fastboot oem reboot-edl`.
|
||||
|
||||
### TODO:
|
||||
- ModemManager not showing Rx/Tx
|
||||
- Use Original/Linux-Tree DTS/DTB:
|
||||
- Green and Blue lights are constantly on with the provieded dts and red with linux-tree dts.
|
||||
- `luci-app-tailscale`: https://github.com/gw826943555/luci-app-tailscale
|
||||
- Using a fork as it has solved the installation issue with tailscale package
|
||||
|
||||
### Future:
|
||||
- Custom package server for msm89xx/8916
|
||||
- Right now the first source from `distfeeds`, related to this specific target will fail as it won't exist. Any module not present might required to be built from sources. This repo can be used to do that, run `make menuconfig` before `make -j$(nproc)` and select it from the menu.
|
||||
@@ -56,5 +52,5 @@ After the succesfull flash if you:
|
||||
## Credits
|
||||
- @ghosthgy https://github.com/ghosthgy/openwrt-msm8916: Starting point for this project.
|
||||
- @lkiuyu https://github.com/lkiuyu/immortalwrt: Almost all the msm8916 folder + patches + openstick feeds.
|
||||
- @Mio-sha512 https://github.com/Mio-sha512/OpenStick-Builder: `usb-gadget`, `msm-firmware-loader` idea, dtb.
|
||||
- @Mio-sha512 https://github.com/Mio-sha512/OpenStick-Builder: `usb-gadget` and `msm-firmware-loader` idea.
|
||||
- @gw826943555 and @asvow https://github.com/gw826943555/luci-app-tailscale: Application for controlling tailscale from luci.
|
||||
Reference in new issue
Block a user