Files
samplechopper/tools/setup/install-qt-msvc.ps1
T
alex c80e3f5567 Portierung der Python/Tkinter-Vorlage nach C++17/Qt6
Die fuer Debian 13 geschriebene Fassung (Python + Tkinter + matplotlib)
laeuft jetzt als Windows-Anwendung mit Qt 6. Oberflaeche, Bedienlogik und
alle DSP-Verfahren sind unveraendert uebernommen.

- core/   DSP, Audio-IO und Export ohne GUI-Abhaengigkeit
- ui/     Hauptfenster, eigene Wellenform-Anzeige, Uebersichtsleiste,
          ffplay-Wiedergabe, Hintergrund-Worker
- tools/  Selbsttest gegen die Python-Vorlage, Ende-zu-Ende-Test der
          ffmpeg-Kette, Messwerkzeuge fuer den Geschwindigkeitsvergleich
- chopper/  unveraenderte Vorlage als Referenz fuer die Pruefungen

Verifikation: verify.ps1 vergleicht den Auslieferungsbau gegen die Vorlage
(alle diskreten Ergebnisse identisch) und zusaetzlich einen double-Bau
gegen eine float64-Referenz (260 Werte innerhalb von 1e-9).

Die 14 Commits der Python-Vorlage liegen als chopper-history.bundle bei
(chopper/ war unter Debian ein eigenes Repository).
2026-09-11 09:56:14 +02:00

63 lines
2.7 KiB
PowerShell

# Installiert Qt 6.8 (MSVC 2022) + CMake + Ninja fuer den Samplechopper-Port.
$ErrorActionPreference = 'Continue'
$ProgressPreference = 'SilentlyContinue'
$root = 'C:\Users\Key & Co\Desktop\Programme\Samplechopper'
$log = Join-Path $root '_setup\qt_setup.log'
New-Item -ItemType Directory -Force -Path (Split-Path $log) | Out-Null
Set-Content -Path $log -Value "=== Qt setup start $(Get-Date -Format s) ==="
function L([string]$m) { $m | Tee-Object -FilePath $log -Append }
# --- 1. pip-Werkzeuge -------------------------------------------------------
L "--- pip install aqtinstall cmake ninja ---"
& python -m pip install --upgrade --disable-pip-version-check aqtinstall cmake ninja 2>&1 |
Tee-Object -FilePath $log -Append
L "pip exit: $LASTEXITCODE"
if ($LASTEXITCODE -ne 0) { L "FATAL: pip install fehlgeschlagen"; exit 1 }
# --- 2. Zielverzeichnis -----------------------------------------------------
$qtDir = 'C:\Qt'
try {
New-Item -ItemType Directory -Force -Path $qtDir -ErrorAction Stop | Out-Null
Test-Path $qtDir -PathType Container -ErrorAction Stop | Out-Null
} catch {
$qtDir = Join-Path $env:LOCALAPPDATA 'Qt'
New-Item -ItemType Directory -Force -Path $qtDir | Out-Null
}
L "Qt-Zielverzeichnis: $qtDir"
# --- 3. Verfuegbare 6.8er-Version bestimmen ---------------------------------
L "--- aqt list-qt (6.8) ---"
$ver = (& python -m aqt list-qt windows desktop --latest-version 6.8 2>&1 | Select-Object -Last 1)
$ver = "$ver".Trim()
if (-not $ver -or $ver -notmatch '^6\.') { $ver = '6.8.3' }
L "Qt-Version: $ver"
# --- 4. Qt installieren -----------------------------------------------------
L "--- aqt install-qt $ver win64_msvc2022_64 (qtbase qttools) ---"
& python -m aqt install-qt windows desktop $ver win64_msvc2022_64 `
--outputdir $qtDir --archives qtbase qttools 2>&1 |
Tee-Object -FilePath $log -Append
$rc = $LASTEXITCODE
L "aqt exit (archives): $rc"
if ($rc -ne 0) {
L "--- Fallback: vollstaendige Basis-Archive ---"
& python -m aqt install-qt windows desktop $ver win64_msvc2022_64 `
--outputdir $qtDir 2>&1 | Tee-Object -FilePath $log -Append
L "aqt exit (full): $LASTEXITCODE"
}
# --- 5. Ergebnis pruefen ----------------------------------------------------
L "--- Ergebnis ---"
Get-ChildItem -Path $qtDir -Recurse -Filter 'Qt6Config.cmake' -ErrorAction SilentlyContinue |
ForEach-Object { L ("Qt6Config: " + $_.FullName) }
Get-ChildItem -Path $qtDir -Recurse -Filter 'Qt6Widgets.dll' -ErrorAction SilentlyContinue |
ForEach-Object { L ("Qt6Widgets: " + $_.FullName) }
foreach ($t in 'cmake', 'ninja') {
$p = Get-Command $t -ErrorAction SilentlyContinue
if ($p) { L "$t -> $($p.Source)" } else { L "$t -> FEHLT" }
}
L "=== Qt setup done $(Get-Date -Format s) ==="