This commit is contained in:
Linrador 2026-06-23 12:36:04 +02:00
parent 82742ac7ce
commit c9b214db91
6 changed files with 41 additions and 2 deletions

View File

@ -41,11 +41,25 @@ wsl bash -lc "cd ""%WSL_CWD%"" && mkdir -p .gocache-linux && GOOS=linux GOARCH=a
if errorlevel 1 goto error
if not exist nsfwapp-linux-amd64 goto linux_output_missing
if not exist dist mkdir dist
copy /y nsfwapp.exe dist\nsfwapp.exe >nul
if errorlevel 1 goto dist_copy_error
copy /y nsfwapp-linux-amd64 dist\nsfwapp-linux-amd64 >nul
if errorlevel 1 goto dist_copy_error
echo.
echo Baue Debian Application Package via WSL...
wsl bash -lc "cd ""%WSL_CWD%"" && DEB_SKIP_REBUILD=1 bash ./build_deb.sh"
if errorlevel 1 goto deb_package_error
echo.
echo Build erfolgreich.
echo Windows: nsfwapp.exe
echo Debian: nsfwapp-linux-amd64
echo Debian-Paket: build_deb.bat
echo Dist: dist\nsfwapp.exe
echo Dist: dist\nsfwapp-linux-amd64
echo Debian-Paket: dist\nsfwapp_*.deb
goto end
:error
@ -111,6 +125,18 @@ echo Pruefe, ob in WSL eine Debian/Ubuntu-Distribution mit Go und den Build-Abha
call :cleanup_cache
exit /b 1
:dist_copy_error
echo.
echo Build-Artefakte konnten nicht nach dist kopiert werden.
call :cleanup_cache
exit /b 1
:deb_package_error
echo.
echo Debian-Paket-Build fehlgeschlagen.
call :cleanup_cache
exit /b 1
:end
call :cleanup_cache
endlocal

View File

@ -52,6 +52,14 @@ fi
[ -f "$BIN_PATH" ] || fail "Linux-Binary nicht gefunden: $BIN_PATH"
mkdir -p "$OUT_DIR"
cp -f "$BIN_PATH" "$OUT_DIR/nsfwapp-linux-amd64"
chmod 0755 "$OUT_DIR/nsfwapp-linux-amd64" 2>/dev/null || true
if [ -f "$SCRIPT_DIR/nsfwapp.exe" ]; then
cp -f "$SCRIPT_DIR/nsfwapp.exe" "$OUT_DIR/nsfwapp.exe"
fi
mkdir -p \
"$PKG_ROOT/DEBIAN" \
"$PKG_ROOT/opt/nsfwapp" \
@ -295,12 +303,17 @@ exit 0
EOF
chmod 0755 "$PKG_ROOT/DEBIAN/postrm"
mkdir -p "$OUT_DIR"
dpkg-deb --root-owner-group --build "$PKG_ROOT" "$OUT_FILE"
echo
echo "Debian-Paket erzeugt:"
echo " $OUT_FILE"
echo
echo "Build-Artefakte:"
echo " $OUT_DIR/nsfwapp-linux-amd64"
if [ -f "$OUT_DIR/nsfwapp.exe" ]; then
echo " $OUT_DIR/nsfwapp.exe"
fi
echo
echo "Installieren:"
echo " sudo apt install ./dist/$(basename "$OUT_FILE")"

BIN
backend/dist/nsfwapp-linux-amd64 vendored Normal file

Binary file not shown.

BIN
backend/dist/nsfwapp.exe vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.