Compare commits
48 Commits
master
...
master_nex
| Author | SHA1 | Date | |
|---|---|---|---|
| 9cf4fa5889 | |||
| a0cfaeef0f | |||
| 17102ddcaa | |||
| 22b2a3933e | |||
| ec658bf9e2 | |||
| a9237f594c | |||
| fb064f9c9d | |||
| 3b14ccf1ce | |||
| f38637ace4 | |||
| b89e9e33d5 | |||
| 0a50b01a96 | |||
| ab1c4939e0 | |||
| 70f17bdbe4 | |||
| 21d38c0fb4 | |||
| f77211bd2e | |||
| 3326c407b7 | |||
| 04e647a74d | |||
| 254dccfbd4 | |||
| 1b21ef20cc | |||
| 52c32acf99 | |||
| b1866c428f | |||
| 50eddb5952 | |||
| 7591b55eb0 | |||
| 02a8a78bb6 | |||
| af741f9dc1 | |||
| 4eb1d453d3 | |||
| 951623978b | |||
| 2ed43eab7a | |||
| 6b044a838c | |||
| 69fc986f64 | |||
| 1c3c319d41 | |||
| 08748a3498 | |||
| 5f872b5501 | |||
| 3e59a90b05 | |||
| 23a1197338 | |||
| a981a16b90 | |||
| 61e0f1ca43 | |||
| ff55ba690d | |||
| 7aaa2d1dc2 | |||
| 29c736c205 | |||
| fe9cff9560 | |||
| 3a3c765288 | |||
| 8bd295fc45 | |||
| 8633fe7121 | |||
| ced0dbaf48 | |||
| 16d267d671 | |||
| 460468363f | |||
| 03ed4ebbab |
35
.gitignore
vendored
Normal file
35
.gitignore
vendored
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
# Python
|
||||||
|
__pycache__/
|
||||||
|
*.py[cod]
|
||||||
|
*.pyo
|
||||||
|
|
||||||
|
# VS Code
|
||||||
|
.vscode/*
|
||||||
|
!.vscode/tasks.json
|
||||||
|
!.vscode/launch.json
|
||||||
|
!.vscode/settings.json
|
||||||
|
!.vscode/python.env
|
||||||
|
|
||||||
|
# Build workdirs
|
||||||
|
/live/*
|
||||||
|
!/live/.gitkeep
|
||||||
|
|
||||||
|
/artifacts/features/*
|
||||||
|
!/artifacts/features/.gitkeep
|
||||||
|
/artifacts/bases/*
|
||||||
|
!/artifacts/bases/.gitkeep
|
||||||
|
/artifacts/profiles/*
|
||||||
|
!/artifacts/profiles/.gitkeep
|
||||||
|
|
||||||
|
# Optional final outputs
|
||||||
|
/outputs/*
|
||||||
|
!/outputs/.gitkeep
|
||||||
|
|
||||||
|
# Local env / debug
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
*.log
|
||||||
|
|
||||||
|
# OS junk
|
||||||
|
.DS_Store
|
||||||
|
Thumbs.db
|
||||||
27
.vscode/launch.json
vendored
Normal file
27
.vscode/launch.json
vendored
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
"version": "0.2.0",
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"name": "RetroDebian: debug run-local (demo, fake legacy)",
|
||||||
|
"type": "python",
|
||||||
|
"request": "launch",
|
||||||
|
"program": "${workspaceFolder}/builder/py/orchestrate.py",
|
||||||
|
"args": ["run", "--profile", "demo", "--fake-legacy"],
|
||||||
|
"cwd": "${workspaceFolder}",
|
||||||
|
"console": "integratedTerminal",
|
||||||
|
"justMyCode": false,
|
||||||
|
"env": {"PYTHONPATH": "${workspaceFolder}/builder/py"}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "RetroDebian: debug validate",
|
||||||
|
"type": "python",
|
||||||
|
"request": "launch",
|
||||||
|
"program": "${workspaceFolder}/builder/py/orchestrate.py",
|
||||||
|
"args": ["validate"],
|
||||||
|
"cwd": "${workspaceFolder}",
|
||||||
|
"console": "integratedTerminal",
|
||||||
|
"justMyCode": false,
|
||||||
|
"env": {"PYTHONPATH": "${workspaceFolder}/builder/py"}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
2
.vscode/python.env
vendored
Normal file
2
.vscode/python.env
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
PYTHONPATH=${workspaceFolder}/builder/py
|
||||||
|
RETRODEBIAN_FAKE_LEGACY_TOOLS=1
|
||||||
6
.vscode/settings.json
vendored
Normal file
6
.vscode/settings.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"python.analysis.extraPaths": [
|
||||||
|
"${workspaceFolder}/builder/py"
|
||||||
|
],
|
||||||
|
"python.envFile": "${workspaceFolder}/.vscode/python.env"
|
||||||
|
}
|
||||||
21
.vscode/tasks.json
vendored
Normal file
21
.vscode/tasks.json
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
{
|
||||||
|
"version": "2.0.0",
|
||||||
|
"tasks": [
|
||||||
|
{
|
||||||
|
"label": "RetroDebian: validate",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "python3",
|
||||||
|
"args": ["builder/py/orchestrate.py", "validate"],
|
||||||
|
"options": {"cwd": "${workspaceFolder}"},
|
||||||
|
"problemMatcher": []
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "RetroDebian: run-local (demo, fake legacy)",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "python3",
|
||||||
|
"args": ["builder/py/orchestrate.py", "run", "--profile", "demo", "--fake-legacy"],
|
||||||
|
"options": {"cwd": "${workspaceFolder}", "env": {"PYTHONPATH": "${workspaceFolder}/builder/py"}},
|
||||||
|
"problemMatcher": []
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
225
Dockerfile
225
Dockerfile
@@ -1,225 +0,0 @@
|
|||||||
FROM i386/alpine:latest AS glide-fetcher
|
|
||||||
ARG CACHE_BUST=38
|
|
||||||
RUN apk add --no-cache git ca-certificates
|
|
||||||
COPY .docker-cache/glide.ref /tmp/glide.ref
|
|
||||||
WORKDIR /src
|
|
||||||
RUN cat /tmp/glide.ref > /dev/null && \
|
|
||||||
echo "$CACHE_BUST" > /dev/null && \
|
|
||||||
git clone --depth 1 --branch retrodebian --single-branch https://gitea.chacha.ddns.net/chacha/glide.git && \
|
|
||||||
rm -Rf glide/.git
|
|
||||||
|
|
||||||
FROM i386/alpine:latest AS icons-fetcher
|
|
||||||
ARG CACHE_BUST=11
|
|
||||||
RUN apk add --no-cache git ca-certificates
|
|
||||||
COPY .docker-cache/icons.ref /tmp/icons.ref
|
|
||||||
WORKDIR /root
|
|
||||||
RUN cat /tmp/icons.ref > /dev/null && \
|
|
||||||
echo "$CACHE_BUST" > /dev/null && \
|
|
||||||
git clone --depth 1 --branch main --single-branch https://gitea.chacha.ddns.net/chacha/icons-collection.git && \
|
|
||||||
rm -Rf icons-collection/.git
|
|
||||||
|
|
||||||
# building a modified Kernel + modules + libs
|
|
||||||
FROM lpenz/debian-etch-i386-minbase AS packages-builder
|
|
||||||
ARG DEBIAN_FRONTEND=noninteractive
|
|
||||||
ARG ARCH=i386
|
|
||||||
ARG CONCURRENCY_LEVEL=4
|
|
||||||
|
|
||||||
# Preparing Environment
|
|
||||||
RUN (echo "deb http://archive.debian.org/debian etch main non-free" > /etc/apt/sources.list) && \
|
|
||||||
(echo "deb-src http://archive.debian.org/debian etch main non-free" >> /etc/apt/sources.list) && \
|
|
||||||
mkdir -p /usr/src/modules &&\
|
|
||||||
apt-get update && \
|
|
||||||
apt-get install -y aptitude build-essential quilt cvs unzip git-core ncurses-dev\
|
|
||||||
linux-headers-2.6.24-etchnhalf.1-686 \
|
|
||||||
squashfs-source-etchnhalf \
|
|
||||||
linux-source-2.6.24 && \
|
|
||||||
apt-get build-dep -y linux-image-2.6.24-etchnhalf.1-686 && \
|
|
||||||
apt-get clean
|
|
||||||
|
|
||||||
# Preparing Kernel + patchs + modules
|
|
||||||
WORKDIR /usr/src
|
|
||||||
COPY unionfs-2.2.3_for_2.6.24.diff.gz ./
|
|
||||||
COPY nvidia.patch ./
|
|
||||||
COPY --from=glide-fetcher /src/glide glide
|
|
||||||
RUN tar xjf linux-source-2.6.24.tar.bz2 && \
|
|
||||||
tar xjf etchnhalf/squashfs.tar.bz2 && \
|
|
||||||
ln -s linux-headers-2.6.24-etchnhalf.1-686/ linux-headers && \
|
|
||||||
mv glide/Device3Dfx modules/ &&\
|
|
||||||
wget http://archive.debian.org/debian-archive/debian/pool/non-free/n/nvidia-graphics-drivers-legacy-71xx/nvidia-kernel-legacy-71xx-source_71.86.15-3_i386.deb && \
|
|
||||||
dpkg-deb -x nvidia-kernel-legacy-71xx-source_71.86.15-3_i386.deb / && \
|
|
||||||
tar xjf nvidia-kernel-legacy-71xx.tar.bz2 && \
|
|
||||||
rm nvidia-kernel-legacy-71xx-source_71.86.15-3_i386.deb && \
|
|
||||||
patch -d modules/nvidia-kernel-legacy-71xx -p1 < nvidia.patch
|
|
||||||
|
|
||||||
# Building Kernel + patchs + modules
|
|
||||||
WORKDIR /usr/src/linux-source-2.6.24
|
|
||||||
COPY config-kernel ./
|
|
||||||
RUN (zcat /usr/src/unionfs-2.2.3_for_2.6.24.diff.gz | patch -p1) && \
|
|
||||||
(cat config-kernel > .config) && \
|
|
||||||
make oldconfig &&\
|
|
||||||
make-kpkg --initrd --arch $ARCH kernel_headers kernel_image modules_image
|
|
||||||
|
|
||||||
# Modified urxvt terminal
|
|
||||||
WORKDIR /usr/src
|
|
||||||
RUN apt-get build-dep -y rxvt-unicode && \
|
|
||||||
apt-get source rxvt-unicode &&\
|
|
||||||
cd rxvt-unicode-* && \
|
|
||||||
cp debian/rules debian/rules.orig && \
|
|
||||||
cp debian/changelog debian/changelog.orig && \
|
|
||||||
sed -i '/\.\/configure/ s/$/ --disable-iso14755/' debian/rules && \
|
|
||||||
perl -0pi -e 's/#if ENABLE_FRILLS \|\| ISO_14755\n\s*\/\/ ISO 14755 support/#if 0\n \/\/ ISO 14755 support/' src/command.C && \
|
|
||||||
sed -i '1s/^\([^)]* (\)\([^)]*\)\(.*\)$/\1\2+retrodebian1\3/' debian/changelog && \
|
|
||||||
dpkg-buildpackage -us -uc -b
|
|
||||||
|
|
||||||
FROM packages-builder AS voodoo-builder
|
|
||||||
# Building userspace libs
|
|
||||||
# 3Dfx
|
|
||||||
WORKDIR /usr/src
|
|
||||||
COPY buildglidepkg.sh ./
|
|
||||||
RUN apt-get install -y nasm && \
|
|
||||||
chmod +x buildglidepkg.sh
|
|
||||||
# cvg / voodoo2
|
|
||||||
WORKDIR /usr/src/glide
|
|
||||||
RUN find . -type f \( -name 'fxgasm.h' -o -name 'fxinline.h' -o -name 'fxgasm' \) -exec rm -f {} \;
|
|
||||||
# glide2x
|
|
||||||
RUN mv swlibs glide2x/
|
|
||||||
WORKDIR /usr/src/glide/glide2x/
|
|
||||||
RUN make -f makefile.linux FX_GLIDE_HW=cvg clean
|
|
||||||
RUN make -f makefile.linux FX_GLIDE_HW=cvg USE_X86=1 USE_MMX=0
|
|
||||||
RUN mv swlibs ../glide3x/
|
|
||||||
## glide3x
|
|
||||||
WORKDIR /usr/src/glide/glide3x/
|
|
||||||
RUN make -f makefile.linux FX_GLIDE_HW=cvg clean
|
|
||||||
RUN make -f makefile.linux FX_GLIDE_HW=cvg USE_X86=1 USE_MMX=1
|
|
||||||
RUN mv swlibs ../
|
|
||||||
WORKDIR /usr/src/
|
|
||||||
RUN /usr/src/buildglidepkg.sh cvg
|
|
||||||
|
|
||||||
## h3 / voodoo3 & Banshee
|
|
||||||
#WORKDIR /usr/src/glide
|
|
||||||
#RUN echo test3 && find . -type f -name 'fxgasm.h'
|
|
||||||
#RUN find . -type f \( -name 'fxgasm.h' -o -name 'fxinline.h' -o -name 'fxgasm' \) -exec rm -f {} \;
|
|
||||||
#RUN apt-get install -y libx11-dev x11proto-xf86dga-dev libxxf86vm-dev libxxf86dga-dev
|
|
||||||
### glide2x
|
|
||||||
#RUN mv swlibs glide2x/
|
|
||||||
#WORKDIR /usr/src/glide/glide2x/
|
|
||||||
#RUN make -f makefile.linux clean
|
|
||||||
#RUN make -f makefile.linux FX_GLIDE_HW=h3 USE_X86=1 USE_MMX=1
|
|
||||||
## glide3x
|
|
||||||
#RUN mv swlibs ../glide3x/
|
|
||||||
#WORKDIR /usr/src/glide/glide3x/
|
|
||||||
#RUN make -f makefile.linux clean
|
|
||||||
#RUN make -f makefile.linux FX_GLIDE_HW=h3 USE_X86=1 USE_MMX=1
|
|
||||||
#RUN mv swlibs ../
|
|
||||||
#WORKDIR /usr/src/
|
|
||||||
#RUN /usr/src/buildglidepkg.sh h3
|
|
||||||
|
|
||||||
## sst1 / voodoo1
|
|
||||||
#WORKDIR /usr/src/glide
|
|
||||||
#RUN find . -type f \( -name 'fxgasm.h' -o -name 'fxinline.h' -o -name 'fxgasm' \) -exec rm -f {} \;
|
|
||||||
## glide2x
|
|
||||||
#RUN mv swlibs glide2x/
|
|
||||||
#WORKDIR /usr/src/glide/glide2x/
|
|
||||||
#RUN make -f makefile.linux clean
|
|
||||||
#RUN make -f makefile.linux FX_GLIDE_HW=sst1 USE_X86=1 USE_MMX=1
|
|
||||||
## glide3x
|
|
||||||
#RUN mv swlibs ../glide3x/
|
|
||||||
#WORKDIR /usr/src/glide/glide3x/
|
|
||||||
#RUN make -f makefile.linux clean
|
|
||||||
#RUN make -f makefile.linux FX_GLIDE_HW=sst1 USE_X86=1 USE_MMX=1
|
|
||||||
#RUN mv swlibs ../
|
|
||||||
#WORKDIR /usr/src/
|
|
||||||
#RUN /usr/src/buildglidepkg.sh sst1
|
|
||||||
|
|
||||||
# sst96 / voodoo Rush
|
|
||||||
# cannot build driver because of missing xf86rush lib...
|
|
||||||
#WORKDIR /usr/src/
|
|
||||||
#WORKDIR /usr/src/glide
|
|
||||||
#RUN find . -type f \( -name 'fxgasm.h' -o -name 'fxinline.h' -o -name 'fxgasm' \) -exec rm -f {} \;
|
|
||||||
# # glide2x
|
|
||||||
# RUN mv swlibs glide2x/
|
|
||||||
# WORKDIR /usr/src/glide/glide2x/
|
|
||||||
# RUN make -f Makefile.linux clean
|
|
||||||
# RUN make -f Makefile.linux FX_GLIDE_HW=sst96
|
|
||||||
# # glide3x
|
|
||||||
# RUN mv swlibs ../glide3x/
|
|
||||||
# WORKDIR /usr/src/glide/glide3x/
|
|
||||||
# RUN make -f Makefile.linux clean
|
|
||||||
# RUN make -f Makefile.linux FX_GLIDE_HW=sst96 USE_X86=1 USE_MMX=1
|
|
||||||
# RUN mv swlibs ../
|
|
||||||
#WORKDIR /usr/src/
|
|
||||||
#RUN /usr/src/buildglidepkg.sh sst96
|
|
||||||
|
|
||||||
#RUN rm *.gz *.bz2 && rm -Rf glide && rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
FROM i386/alpine:latest AS ut99-builder
|
|
||||||
RUN apk add --no-cache git ca-certificates dos2unix
|
|
||||||
ARG CACHE_BUST=10
|
|
||||||
COPY .docker-cache/ut99.ref /tmp/ut99.ref
|
|
||||||
# Package UT99
|
|
||||||
WORKDIR /root
|
|
||||||
RUN cat /tmp/ut99.ref > /dev/null && \
|
|
||||||
echo "$CACHE_BUST" && \
|
|
||||||
git clone --depth 1 --branch master --single-branch https://gitea.chacha.ddns.net/chacha/UT99-Official.git ut-game && \
|
|
||||||
rm -Rf ut-game/.git
|
|
||||||
COPY games/ut99/ut-install-436.run ./
|
|
||||||
RUN chmod +x ut-install-436.run && \
|
|
||||||
./ut-install-436.run --target ./ut || true && \
|
|
||||||
tar xzf ./ut/data.tar.gz -C ut-game && \
|
|
||||||
cp ./ut/bin/x86/ut ut-game/ && \
|
|
||||||
rm ut-game/System/*.frt && \
|
|
||||||
rm ut-game/System/*.itt && \
|
|
||||||
rm ut-game/System/*.est && \
|
|
||||||
rm ut-game/System/*.exe && \
|
|
||||||
rm ut-game/System/*.dll && \
|
|
||||||
rm ut-game/System/*.url && \
|
|
||||||
rm ut-game/System/*.bat && \
|
|
||||||
rm ut-game/System/de.* && \
|
|
||||||
rm ut-game/System/UnrealTournament.ini && \
|
|
||||||
rm ut-game/System/Default.ini && \
|
|
||||||
rm ut-game/System/libSDL-1.1.so.0 && \
|
|
||||||
rm ut-game/Sounds/*est_uax && \
|
|
||||||
rm ut-game/Sounds/*frt_uax && \
|
|
||||||
rm ut-game/Sounds/*itt_uax && \
|
|
||||||
rm ut-game/DoConfig.py && \
|
|
||||||
rm ut-game/DoConfig.sh && \
|
|
||||||
rm -Rf ut-game/Web && \
|
|
||||||
rm -Rf ut-game/Help/* &&\
|
|
||||||
tar xzf ./ut/Glide.ini.tar.gz -C ut-game && \
|
|
||||||
mv ut-game/System/UnrealTournament.ini ut-game/System/Default-glide.ini && \
|
|
||||||
ls -al ./ut/ && \
|
|
||||||
tar xzf ./ut/OpenGL.ini.tar.gz -C ut-game && \
|
|
||||||
cp ut-game/System/UnrealTournament.ini ut-game/System/Default.ini && \
|
|
||||||
mv ut-game/System/UnrealTournament.ini ut-game/System/Default-opengl.ini && \
|
|
||||||
dos2unix ut-game/System/*.ini
|
|
||||||
COPY games/ut99/ut ./ut-game/ut
|
|
||||||
RUN chmod a+x,o-w ./ut-game/ut
|
|
||||||
|
|
||||||
# Note: we need to use Lenny because of live-helper
|
|
||||||
# it allows creating Etch live image though !
|
|
||||||
FROM lpenz/debian-lenny-i386-minbase
|
|
||||||
WORKDIR /root
|
|
||||||
COPY --from=packages-builder /usr/src/*.deb .
|
|
||||||
COPY --from=voodoo-builder /usr/src/*.deb .
|
|
||||||
COPY --from=ut99-builder /root/ut-game ./ut-game
|
|
||||||
COPY --from=icons-fetcher /root/icons-collection ./icons-collection
|
|
||||||
COPY /deps ./deps
|
|
||||||
COPY update-initramfs.sh .
|
|
||||||
COPY zzz-config-live.sh .
|
|
||||||
COPY desktop .
|
|
||||||
COPY wallpaper.jpg .
|
|
||||||
COPY neofetch .
|
|
||||||
COPY editions ./editions
|
|
||||||
COPY internal ./internal
|
|
||||||
RUN apt-get update && \
|
|
||||||
apt-get -y --force-yes install live-helper genisoimage syslinux squashfs-tools aptitude && \
|
|
||||||
apt-get clean
|
|
||||||
# rm -rf /var/lib/apt/lists/*
|
|
||||||
WORKDIR /root/live
|
|
||||||
|
|
||||||
#FROM voodoo-builder
|
|
||||||
#WORKDIR /usr/src
|
|
||||||
#RUN apt-get build-dep -y debian-edu-artwork-usplash && \
|
|
||||||
# apt-get source debian-edu-artwork-usplash &&\
|
|
||||||
# ls -al && \
|
|
||||||
# cd debian-edu-artwork-*
|
|
||||||
231
Jenkinsfile
vendored
231
Jenkinsfile
vendored
@@ -1,226 +1,39 @@
|
|||||||
pipeline {
|
pipeline {
|
||||||
agent {
|
agent { label 'pyDABFActory-CIAgent' }
|
||||||
label 'pyDABFActory-CIAgent'
|
|
||||||
|
parameters {
|
||||||
|
booleanParam(name: 'BUILD_ALL_PROFILES', defaultValue: true, description: 'Build all profiles one by one')
|
||||||
|
string(name: 'PROFILE', defaultValue: 'demo', description: 'Profile to build when BUILD_ALL_PROFILES is false')
|
||||||
}
|
}
|
||||||
|
|
||||||
stages {
|
stages {
|
||||||
stage('GIT get refs and download some standard things') {
|
stage('Checkout') {
|
||||||
agent {
|
|
||||||
docker {
|
|
||||||
image 'alpine:3.21'
|
|
||||||
reuseNode true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
steps {
|
steps {
|
||||||
sh '''
|
sh 'rm -Rf live artifacts'
|
||||||
set -eu
|
checkout scm
|
||||||
apk add --no-cache git jq curl
|
|
||||||
|
|
||||||
mkdir -p .docker-cache
|
|
||||||
|
|
||||||
git ls-remote https://gitea.chacha.ddns.net/chacha/glide.git refs/heads/retrodebian \
|
|
||||||
| awk '{print $1}' > .docker-cache/glide.ref
|
|
||||||
test -s .docker-cache/glide.ref
|
|
||||||
echo "glide ref: $(cat .docker-cache/glide.ref)"
|
|
||||||
|
|
||||||
git ls-remote https://gitea.chacha.ddns.net/chacha/UT99-Official.git refs/heads/master \
|
|
||||||
| awk '{print $1}' > .docker-cache/ut99.ref
|
|
||||||
test -s .docker-cache/ut99.ref
|
|
||||||
echo "ut99 ref: $(cat .docker-cache/ut99.ref)"
|
|
||||||
|
|
||||||
git ls-remote https://gitea.chacha.ddns.net/chacha/icons-collection.git refs/heads/main \
|
|
||||||
| awk '{print $1}' > .docker-cache/icons.ref
|
|
||||||
test -s .docker-cache/icons.ref
|
|
||||||
echo "icons ref: $(cat .docker-cache/icons.ref)"
|
|
||||||
|
|
||||||
curl -s "https://gitea.chacha.ddns.net/api/v1/repos/chacha/V2TMUMemTester/releases" \
|
|
||||||
| jq -r 'map(select(.draft == false)) | .[0].assets[] | select(.name=="v2-tmu-memtester") | .browser_download_url' \
|
|
||||||
| xargs -n1 curl -L -o v2-tmu-memtester
|
|
||||||
|
|
||||||
chmod +x v2-tmu-memtester
|
|
||||||
'''
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Convert splash images')
|
|
||||||
{
|
stage('Run orchestrator') {
|
||||||
agent {
|
|
||||||
docker {
|
|
||||||
image 'alpine:3.21'
|
|
||||||
reuseNode true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
steps {
|
steps {
|
||||||
sh '''
|
sh '''
|
||||||
set -eu
|
set -eu
|
||||||
apk add --no-cache imagemagick
|
CMD="python3 builder/py/orchestrate.py run"
|
||||||
found_edition=0
|
if [ "$BUILD_ALL_PROFILES" = "true" ]; then
|
||||||
for edition_dir in editions/*; do
|
CMD="$CMD --all-profiles"
|
||||||
[ -d "$edition_dir" ] || continue
|
else
|
||||||
found_edition=1
|
CMD="$CMD --profile '$PROFILE'"
|
||||||
set -- "$edition_dir"/splash-source.*
|
|
||||||
if [ ! -e "$1" ]; then
|
|
||||||
echo "ERROR: missing splash-source.* in $edition_dir" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ $# -ne 1 ]; then
|
|
||||||
echo "ERROR: multiple splash-source.* files in $edition_dir" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
src="$1"
|
|
||||||
out="$edition_dir/splash.jpg"
|
|
||||||
echo "Converting $src -> $out"
|
|
||||||
magick "$src" \
|
|
||||||
-resize 640x480! \
|
|
||||||
-background black \
|
|
||||||
-alpha remove -alpha off \
|
|
||||||
-colorspace sRGB \
|
|
||||||
-strip \
|
|
||||||
-quality 95 \
|
|
||||||
"$out"
|
|
||||||
done
|
|
||||||
|
|
||||||
if [ "$found_edition" -eq 0 ]; then
|
|
||||||
echo "ERROR: no edition directory found under editions/" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
|
eval "$CMD"
|
||||||
'''
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Create live')
|
|
||||||
{
|
|
||||||
agent {
|
|
||||||
dockerfile {
|
|
||||||
filename 'Dockerfile'
|
|
||||||
dir '.'
|
|
||||||
label 'pyDABFActory-CIAgent'
|
|
||||||
args '--privileged --security-opt seccomp=unconfined --security-opt apparmor=unconfined -u root:root'
|
|
||||||
reuseNode true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stages {
|
|
||||||
stage('Configure ISO') {
|
|
||||||
steps {
|
|
||||||
dir('root')
|
|
||||||
{
|
|
||||||
sh 'rm -Rf live artifacts'
|
|
||||||
}
|
|
||||||
dir('root/live')
|
|
||||||
{
|
|
||||||
sh '''
|
|
||||||
set -e
|
|
||||||
deb="$(ls -1 /root/linux-image-*.deb | head -n1)"
|
|
||||||
kernpkg="$(dpkg-deb -f "$deb" Package)"
|
|
||||||
echo "$kernpkg"
|
|
||||||
|
|
||||||
deb="$(ls -1 /root/squashfs-modules-*.deb | head -n1)"
|
|
||||||
squashfspkg="$(dpkg-deb -f "$deb" Package)"
|
|
||||||
echo "$squashfspkg"
|
|
||||||
|
|
||||||
lh_config \
|
|
||||||
-a i386 \
|
|
||||||
--distribution etch \
|
|
||||||
--apt apt \
|
|
||||||
--apt-options "--yes --force-yes" \
|
|
||||||
--apt-secure false \
|
|
||||||
--apt-recommends false \
|
|
||||||
--linux-packages "squashfs-modules-2.6.24 linux-image-2.6.24 device3dfx-modules-2.6.24" \
|
|
||||||
--packages-lists "desktop" \
|
|
||||||
--mirror-bootstrap http://archive.debian.org/debian/ \
|
|
||||||
--mirror-binary http://archive.debian.org/debian/ \
|
|
||||||
--mirror-binary-security http://archive.debian.org/debian-security/ \
|
|
||||||
--mirror-chroot http://archive.debian.org/debian/ \
|
|
||||||
--mirror-chroot-security http://archive.debian.org/debian-security/ \
|
|
||||||
--binary-images iso \
|
|
||||||
--bootloader syslinux \
|
|
||||||
--syslinux-timeout 5 \
|
|
||||||
--syslinux-menu true \
|
|
||||||
--bootstrap debootstrap \
|
|
||||||
--debconf-frontend noninteractive \
|
|
||||||
--debian-installer live \
|
|
||||||
--bootappend-live "elevator=deadline" \
|
|
||||||
--hostname RetroDebian \
|
|
||||||
--iso-application RetroDebian \
|
|
||||||
--syslinux-splash config/binary_syslinux/splash.jpg \
|
|
||||||
--union-filesystem unionfs \
|
|
||||||
--username bob \
|
|
||||||
--templates config/templates \
|
|
||||||
-k retrodebian1
|
|
||||||
|
|
||||||
cp -R /usr/share/live-helper/templates/* config/templates/
|
|
||||||
sed -i \
|
|
||||||
-e 's|^menu vshift.*|menu vshift 4|' \
|
|
||||||
-e 's|^menu hshift.*|menu hshift 9|' \
|
|
||||||
-e 's|^menu width.*|menu width 60|' \
|
|
||||||
-e 's|^menu color sel.*|menu color sel * #ff82c059 #c01f1f1f none|' \
|
|
||||||
-e 's|^menu color unsel.*|menu color unsel * #8082c059 #c01f1f1f none|' \
|
|
||||||
-e 's|^menu color hotkey.*|menu color hotkey * #fff01e1e #c01f1f1f none|' \
|
|
||||||
-e 's|^menu color tabmsg.*|menu color tabmsg * #ffB0B0B0 #00000000 none|' \
|
|
||||||
-e 's|^menu color timeout_msg.*|menu color timeout_msg * #ffB0B0B0 #00000000 none|' \
|
|
||||||
-e 's|^menu color timeout.*|menu color timeout * #ffff0000 #00000000 none|' \
|
|
||||||
config/templates/syslinux/menu/header.cfg
|
|
||||||
|
|
||||||
cp -R /root/internal/rootfs/* config/chroot_local-includes
|
|
||||||
|
|
||||||
chmod +x /root/update-initramfs.sh
|
|
||||||
chmod +x /root/zzz-config-live.sh
|
|
||||||
cp /root/update-initramfs.sh config/chroot_local-hooks
|
|
||||||
cp /root/zzz-config-live.sh config/chroot_local-hooks
|
|
||||||
cp /root/linux-image-*.deb config/chroot_local-packages/
|
|
||||||
cp /root/rxvt-unicode_*.deb config/chroot_local-packages/
|
|
||||||
cp /root/device3dfx-*.deb config/chroot_local-packages/
|
|
||||||
cp /root/squashfs-modules-*.deb config/chroot_local-packages/
|
|
||||||
cp /root/libglide*-cvg*_i386.deb config/chroot_local-packages/
|
|
||||||
cp /root/desktop config/chroot_local-packageslists/
|
|
||||||
mkdir -p config/chroot_local-includes/usr/share/wallpapers
|
|
||||||
cp /root/wallpaper.jpg config/chroot_local-includes/usr/share/wallpapers/retrodebian.jpg
|
|
||||||
mkdir -p config/chroot_local-includes/usr/local/bin
|
|
||||||
cp /root/neofetch config/chroot_local-includes/usr/local/bin/neofetch
|
|
||||||
chmod +x config/chroot_local-includes/usr/local/bin/neofetch
|
|
||||||
cp /root/editions/voodoo2/splash.jpg config/binary_syslinux/
|
|
||||||
cp "$WORKSPACE/v2-tmu-memtester" config/chroot_local-includes/usr/local/bin/
|
|
||||||
'''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Configure games') {
|
|
||||||
steps {
|
|
||||||
dir('root/live') {
|
|
||||||
sh '''
|
|
||||||
mkdir -p config/chroot_local-includes/usr/local/games/ut99/
|
|
||||||
ls -al /root
|
|
||||||
cp -R /root/ut-game/* config/chroot_local-includes/usr/local/games/ut99/
|
|
||||||
mkdir -p config/chroot_local-includes/usr/share/icons
|
|
||||||
cp /root/icons-collection/small/ut99.png config/chroot_local-includes/usr/share/icons/
|
|
||||||
'''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Build ISO') {
|
|
||||||
steps {
|
|
||||||
dir('root/live')
|
|
||||||
{
|
|
||||||
sh 'lh_build'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Save artifacts') {
|
|
||||||
steps {
|
|
||||||
dir('root')
|
|
||||||
{
|
|
||||||
sh '''
|
|
||||||
mkdir artifacts
|
|
||||||
mv /root/*.deb artifacts/
|
|
||||||
'''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
post {
|
post {
|
||||||
success {
|
always {
|
||||||
archiveArtifacts artifacts: 'root/live/*.iso', fingerprint: true
|
archiveArtifacts artifacts: 'artifacts/**/*', allowEmptyArchive: true
|
||||||
archiveArtifacts artifacts: 'root/artifacts/*.deb', fingerprint: true
|
archiveArtifacts artifacts: 'live/**/*', allowEmptyArchive: true
|
||||||
deleteDir()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
675
LICENSE.md
675
LICENSE.md
@@ -1,675 +0,0 @@
|
|||||||
# GNU GENERAL PUBLIC LICENSE
|
|
||||||
|
|
||||||
Version 3, 29 June 2007
|
|
||||||
|
|
||||||
Copyright (C) 2007 Free Software Foundation, Inc.
|
|
||||||
<https://fsf.org/>
|
|
||||||
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies of this
|
|
||||||
license document, but changing it is not allowed.
|
|
||||||
|
|
||||||
## Preamble
|
|
||||||
|
|
||||||
The GNU General Public License is a free, copyleft license for
|
|
||||||
software and other kinds of works.
|
|
||||||
|
|
||||||
The licenses for most software and other practical works are designed
|
|
||||||
to take away your freedom to share and change the works. By contrast,
|
|
||||||
the GNU General Public License is intended to guarantee your freedom
|
|
||||||
to share and change all versions of a program--to make sure it remains
|
|
||||||
free software for all its users. We, the Free Software Foundation, use
|
|
||||||
the GNU General Public License for most of our software; it applies
|
|
||||||
also to any other work released this way by its authors. You can apply
|
|
||||||
it to your programs, too.
|
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom, not
|
|
||||||
price. Our General Public Licenses are designed to make sure that you
|
|
||||||
have the freedom to distribute copies of free software (and charge for
|
|
||||||
them if you wish), that you receive source code or can get it if you
|
|
||||||
want it, that you can change the software or use pieces of it in new
|
|
||||||
free programs, and that you know you can do these things.
|
|
||||||
|
|
||||||
To protect your rights, we need to prevent others from denying you
|
|
||||||
these rights or asking you to surrender the rights. Therefore, you
|
|
||||||
have certain responsibilities if you distribute copies of the
|
|
||||||
software, or if you modify it: responsibilities to respect the freedom
|
|
||||||
of others.
|
|
||||||
|
|
||||||
For example, if you distribute copies of such a program, whether
|
|
||||||
gratis or for a fee, you must pass on to the recipients the same
|
|
||||||
freedoms that you received. You must make sure that they, too, receive
|
|
||||||
or can get the source code. And you must show them these terms so they
|
|
||||||
know their rights.
|
|
||||||
|
|
||||||
Developers that use the GNU GPL protect your rights with two steps:
|
|
||||||
(1) assert copyright on the software, and (2) offer you this License
|
|
||||||
giving you legal permission to copy, distribute and/or modify it.
|
|
||||||
|
|
||||||
For the developers' and authors' protection, the GPL clearly explains
|
|
||||||
that there is no warranty for this free software. For both users' and
|
|
||||||
authors' sake, the GPL requires that modified versions be marked as
|
|
||||||
changed, so that their problems will not be attributed erroneously to
|
|
||||||
authors of previous versions.
|
|
||||||
|
|
||||||
Some devices are designed to deny users access to install or run
|
|
||||||
modified versions of the software inside them, although the
|
|
||||||
manufacturer can do so. This is fundamentally incompatible with the
|
|
||||||
aim of protecting users' freedom to change the software. The
|
|
||||||
systematic pattern of such abuse occurs in the area of products for
|
|
||||||
individuals to use, which is precisely where it is most unacceptable.
|
|
||||||
Therefore, we have designed this version of the GPL to prohibit the
|
|
||||||
practice for those products. If such problems arise substantially in
|
|
||||||
other domains, we stand ready to extend this provision to those
|
|
||||||
domains in future versions of the GPL, as needed to protect the
|
|
||||||
freedom of users.
|
|
||||||
|
|
||||||
Finally, every program is threatened constantly by software patents.
|
|
||||||
States should not allow patents to restrict development and use of
|
|
||||||
software on general-purpose computers, but in those that do, we wish
|
|
||||||
to avoid the special danger that patents applied to a free program
|
|
||||||
could make it effectively proprietary. To prevent this, the GPL
|
|
||||||
assures that patents cannot be used to render the program non-free.
|
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
|
||||||
modification follow.
|
|
||||||
|
|
||||||
## TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
### 0. Definitions.
|
|
||||||
|
|
||||||
"This License" refers to version 3 of the GNU General Public License.
|
|
||||||
|
|
||||||
"Copyright" also means copyright-like laws that apply to other kinds
|
|
||||||
of works, such as semiconductor masks.
|
|
||||||
|
|
||||||
"The Program" refers to any copyrightable work licensed under this
|
|
||||||
License. Each licensee is addressed as "you". "Licensees" and
|
|
||||||
"recipients" may be individuals or organizations.
|
|
||||||
|
|
||||||
To "modify" a work means to copy from or adapt all or part of the work
|
|
||||||
in a fashion requiring copyright permission, other than the making of
|
|
||||||
an exact copy. The resulting work is called a "modified version" of
|
|
||||||
the earlier work or a work "based on" the earlier work.
|
|
||||||
|
|
||||||
A "covered work" means either the unmodified Program or a work based
|
|
||||||
on the Program.
|
|
||||||
|
|
||||||
To "propagate" a work means to do anything with it that, without
|
|
||||||
permission, would make you directly or secondarily liable for
|
|
||||||
infringement under applicable copyright law, except executing it on a
|
|
||||||
computer or modifying a private copy. Propagation includes copying,
|
|
||||||
distribution (with or without modification), making available to the
|
|
||||||
public, and in some countries other activities as well.
|
|
||||||
|
|
||||||
To "convey" a work means any kind of propagation that enables other
|
|
||||||
parties to make or receive copies. Mere interaction with a user
|
|
||||||
through a computer network, with no transfer of a copy, is not
|
|
||||||
conveying.
|
|
||||||
|
|
||||||
An interactive user interface displays "Appropriate Legal Notices" to
|
|
||||||
the extent that it includes a convenient and prominently visible
|
|
||||||
feature that (1) displays an appropriate copyright notice, and (2)
|
|
||||||
tells the user that there is no warranty for the work (except to the
|
|
||||||
extent that warranties are provided), that licensees may convey the
|
|
||||||
work under this License, and how to view a copy of this License. If
|
|
||||||
the interface presents a list of user commands or options, such as a
|
|
||||||
menu, a prominent item in the list meets this criterion.
|
|
||||||
|
|
||||||
### 1. Source Code.
|
|
||||||
|
|
||||||
The "source code" for a work means the preferred form of the work for
|
|
||||||
making modifications to it. "Object code" means any non-source form of
|
|
||||||
a work.
|
|
||||||
|
|
||||||
A "Standard Interface" means an interface that either is an official
|
|
||||||
standard defined by a recognized standards body, or, in the case of
|
|
||||||
interfaces specified for a particular programming language, one that
|
|
||||||
is widely used among developers working in that language.
|
|
||||||
|
|
||||||
The "System Libraries" of an executable work include anything, other
|
|
||||||
than the work as a whole, that (a) is included in the normal form of
|
|
||||||
packaging a Major Component, but which is not part of that Major
|
|
||||||
Component, and (b) serves only to enable use of the work with that
|
|
||||||
Major Component, or to implement a Standard Interface for which an
|
|
||||||
implementation is available to the public in source code form. A
|
|
||||||
"Major Component", in this context, means a major essential component
|
|
||||||
(kernel, window system, and so on) of the specific operating system
|
|
||||||
(if any) on which the executable work runs, or a compiler used to
|
|
||||||
produce the work, or an object code interpreter used to run it.
|
|
||||||
|
|
||||||
The "Corresponding Source" for a work in object code form means all
|
|
||||||
the source code needed to generate, install, and (for an executable
|
|
||||||
work) run the object code and to modify the work, including scripts to
|
|
||||||
control those activities. However, it does not include the work's
|
|
||||||
System Libraries, or general-purpose tools or generally available free
|
|
||||||
programs which are used unmodified in performing those activities but
|
|
||||||
which are not part of the work. For example, Corresponding Source
|
|
||||||
includes interface definition files associated with source files for
|
|
||||||
the work, and the source code for shared libraries and dynamically
|
|
||||||
linked subprograms that the work is specifically designed to require,
|
|
||||||
such as by intimate data communication or control flow between those
|
|
||||||
subprograms and other parts of the work.
|
|
||||||
|
|
||||||
The Corresponding Source need not include anything that users can
|
|
||||||
regenerate automatically from other parts of the Corresponding Source.
|
|
||||||
|
|
||||||
The Corresponding Source for a work in source code form is that same
|
|
||||||
work.
|
|
||||||
|
|
||||||
### 2. Basic Permissions.
|
|
||||||
|
|
||||||
All rights granted under this License are granted for the term of
|
|
||||||
copyright on the Program, and are irrevocable provided the stated
|
|
||||||
conditions are met. This License explicitly affirms your unlimited
|
|
||||||
permission to run the unmodified Program. The output from running a
|
|
||||||
covered work is covered by this License only if the output, given its
|
|
||||||
content, constitutes a covered work. This License acknowledges your
|
|
||||||
rights of fair use or other equivalent, as provided by copyright law.
|
|
||||||
|
|
||||||
You may make, run and propagate covered works that you do not convey,
|
|
||||||
without conditions so long as your license otherwise remains in force.
|
|
||||||
You may convey covered works to others for the sole purpose of having
|
|
||||||
them make modifications exclusively for you, or provide you with
|
|
||||||
facilities for running those works, provided that you comply with the
|
|
||||||
terms of this License in conveying all material for which you do not
|
|
||||||
control copyright. Those thus making or running the covered works for
|
|
||||||
you must do so exclusively on your behalf, under your direction and
|
|
||||||
control, on terms that prohibit them from making any copies of your
|
|
||||||
copyrighted material outside their relationship with you.
|
|
||||||
|
|
||||||
Conveying under any other circumstances is permitted solely under the
|
|
||||||
conditions stated below. Sublicensing is not allowed; section 10 makes
|
|
||||||
it unnecessary.
|
|
||||||
|
|
||||||
### 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
|
||||||
|
|
||||||
No covered work shall be deemed part of an effective technological
|
|
||||||
measure under any applicable law fulfilling obligations under article
|
|
||||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
|
||||||
similar laws prohibiting or restricting circumvention of such
|
|
||||||
measures.
|
|
||||||
|
|
||||||
When you convey a covered work, you waive any legal power to forbid
|
|
||||||
circumvention of technological measures to the extent such
|
|
||||||
circumvention is effected by exercising rights under this License with
|
|
||||||
respect to the covered work, and you disclaim any intention to limit
|
|
||||||
operation or modification of the work as a means of enforcing, against
|
|
||||||
the work's users, your or third parties' legal rights to forbid
|
|
||||||
circumvention of technological measures.
|
|
||||||
|
|
||||||
### 4. Conveying Verbatim Copies.
|
|
||||||
|
|
||||||
You may convey verbatim copies of the Program's source code as you
|
|
||||||
receive it, in any medium, provided that you conspicuously and
|
|
||||||
appropriately publish on each copy an appropriate copyright notice;
|
|
||||||
keep intact all notices stating that this License and any
|
|
||||||
non-permissive terms added in accord with section 7 apply to the code;
|
|
||||||
keep intact all notices of the absence of any warranty; and give all
|
|
||||||
recipients a copy of this License along with the Program.
|
|
||||||
|
|
||||||
You may charge any price or no price for each copy that you convey,
|
|
||||||
and you may offer support or warranty protection for a fee.
|
|
||||||
|
|
||||||
### 5. Conveying Modified Source Versions.
|
|
||||||
|
|
||||||
You may convey a work based on the Program, or the modifications to
|
|
||||||
produce it from the Program, in the form of source code under the
|
|
||||||
terms of section 4, provided that you also meet all of these
|
|
||||||
conditions:
|
|
||||||
|
|
||||||
- a) The work must carry prominent notices stating that you modified
|
|
||||||
it, and giving a relevant date.
|
|
||||||
- b) The work must carry prominent notices stating that it is
|
|
||||||
released under this License and any conditions added under
|
|
||||||
section 7. This requirement modifies the requirement in section 4
|
|
||||||
to "keep intact all notices".
|
|
||||||
- c) You must license the entire work, as a whole, under this
|
|
||||||
License to anyone who comes into possession of a copy. This
|
|
||||||
License will therefore apply, along with any applicable section 7
|
|
||||||
additional terms, to the whole of the work, and all its parts,
|
|
||||||
regardless of how they are packaged. This License gives no
|
|
||||||
permission to license the work in any other way, but it does not
|
|
||||||
invalidate such permission if you have separately received it.
|
|
||||||
- d) If the work has interactive user interfaces, each must display
|
|
||||||
Appropriate Legal Notices; however, if the Program has interactive
|
|
||||||
interfaces that do not display Appropriate Legal Notices, your
|
|
||||||
work need not make them do so.
|
|
||||||
|
|
||||||
A compilation of a covered work with other separate and independent
|
|
||||||
works, which are not by their nature extensions of the covered work,
|
|
||||||
and which are not combined with it such as to form a larger program,
|
|
||||||
in or on a volume of a storage or distribution medium, is called an
|
|
||||||
"aggregate" if the compilation and its resulting copyright are not
|
|
||||||
used to limit the access or legal rights of the compilation's users
|
|
||||||
beyond what the individual works permit. Inclusion of a covered work
|
|
||||||
in an aggregate does not cause this License to apply to the other
|
|
||||||
parts of the aggregate.
|
|
||||||
|
|
||||||
### 6. Conveying Non-Source Forms.
|
|
||||||
|
|
||||||
You may convey a covered work in object code form under the terms of
|
|
||||||
sections 4 and 5, provided that you also convey the machine-readable
|
|
||||||
Corresponding Source under the terms of this License, in one of these
|
|
||||||
ways:
|
|
||||||
|
|
||||||
- a) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by the
|
|
||||||
Corresponding Source fixed on a durable physical medium
|
|
||||||
customarily used for software interchange.
|
|
||||||
- b) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by a
|
|
||||||
written offer, valid for at least three years and valid for as
|
|
||||||
long as you offer spare parts or customer support for that product
|
|
||||||
model, to give anyone who possesses the object code either (1) a
|
|
||||||
copy of the Corresponding Source for all the software in the
|
|
||||||
product that is covered by this License, on a durable physical
|
|
||||||
medium customarily used for software interchange, for a price no
|
|
||||||
more than your reasonable cost of physically performing this
|
|
||||||
conveying of source, or (2) access to copy the Corresponding
|
|
||||||
Source from a network server at no charge.
|
|
||||||
- c) Convey individual copies of the object code with a copy of the
|
|
||||||
written offer to provide the Corresponding Source. This
|
|
||||||
alternative is allowed only occasionally and noncommercially, and
|
|
||||||
only if you received the object code with such an offer, in accord
|
|
||||||
with subsection 6b.
|
|
||||||
- d) Convey the object code by offering access from a designated
|
|
||||||
place (gratis or for a charge), and offer equivalent access to the
|
|
||||||
Corresponding Source in the same way through the same place at no
|
|
||||||
further charge. You need not require recipients to copy the
|
|
||||||
Corresponding Source along with the object code. If the place to
|
|
||||||
copy the object code is a network server, the Corresponding Source
|
|
||||||
may be on a different server (operated by you or a third party)
|
|
||||||
that supports equivalent copying facilities, provided you maintain
|
|
||||||
clear directions next to the object code saying where to find the
|
|
||||||
Corresponding Source. Regardless of what server hosts the
|
|
||||||
Corresponding Source, you remain obligated to ensure that it is
|
|
||||||
available for as long as needed to satisfy these requirements.
|
|
||||||
- e) Convey the object code using peer-to-peer transmission,
|
|
||||||
provided you inform other peers where the object code and
|
|
||||||
Corresponding Source of the work are being offered to the general
|
|
||||||
public at no charge under subsection 6d.
|
|
||||||
|
|
||||||
A separable portion of the object code, whose source code is excluded
|
|
||||||
from the Corresponding Source as a System Library, need not be
|
|
||||||
included in conveying the object code work.
|
|
||||||
|
|
||||||
A "User Product" is either (1) a "consumer product", which means any
|
|
||||||
tangible personal property which is normally used for personal,
|
|
||||||
family, or household purposes, or (2) anything designed or sold for
|
|
||||||
incorporation into a dwelling. In determining whether a product is a
|
|
||||||
consumer product, doubtful cases shall be resolved in favor of
|
|
||||||
coverage. For a particular product received by a particular user,
|
|
||||||
"normally used" refers to a typical or common use of that class of
|
|
||||||
product, regardless of the status of the particular user or of the way
|
|
||||||
in which the particular user actually uses, or expects or is expected
|
|
||||||
to use, the product. A product is a consumer product regardless of
|
|
||||||
whether the product has substantial commercial, industrial or
|
|
||||||
non-consumer uses, unless such uses represent the only significant
|
|
||||||
mode of use of the product.
|
|
||||||
|
|
||||||
"Installation Information" for a User Product means any methods,
|
|
||||||
procedures, authorization keys, or other information required to
|
|
||||||
install and execute modified versions of a covered work in that User
|
|
||||||
Product from a modified version of its Corresponding Source. The
|
|
||||||
information must suffice to ensure that the continued functioning of
|
|
||||||
the modified object code is in no case prevented or interfered with
|
|
||||||
solely because modification has been made.
|
|
||||||
|
|
||||||
If you convey an object code work under this section in, or with, or
|
|
||||||
specifically for use in, a User Product, and the conveying occurs as
|
|
||||||
part of a transaction in which the right of possession and use of the
|
|
||||||
User Product is transferred to the recipient in perpetuity or for a
|
|
||||||
fixed term (regardless of how the transaction is characterized), the
|
|
||||||
Corresponding Source conveyed under this section must be accompanied
|
|
||||||
by the Installation Information. But this requirement does not apply
|
|
||||||
if neither you nor any third party retains the ability to install
|
|
||||||
modified object code on the User Product (for example, the work has
|
|
||||||
been installed in ROM).
|
|
||||||
|
|
||||||
The requirement to provide Installation Information does not include a
|
|
||||||
requirement to continue to provide support service, warranty, or
|
|
||||||
updates for a work that has been modified or installed by the
|
|
||||||
recipient, or for the User Product in which it has been modified or
|
|
||||||
installed. Access to a network may be denied when the modification
|
|
||||||
itself materially and adversely affects the operation of the network
|
|
||||||
or violates the rules and protocols for communication across the
|
|
||||||
network.
|
|
||||||
|
|
||||||
Corresponding Source conveyed, and Installation Information provided,
|
|
||||||
in accord with this section must be in a format that is publicly
|
|
||||||
documented (and with an implementation available to the public in
|
|
||||||
source code form), and must require no special password or key for
|
|
||||||
unpacking, reading or copying.
|
|
||||||
|
|
||||||
### 7. Additional Terms.
|
|
||||||
|
|
||||||
"Additional permissions" are terms that supplement the terms of this
|
|
||||||
License by making exceptions from one or more of its conditions.
|
|
||||||
Additional permissions that are applicable to the entire Program shall
|
|
||||||
be treated as though they were included in this License, to the extent
|
|
||||||
that they are valid under applicable law. If additional permissions
|
|
||||||
apply only to part of the Program, that part may be used separately
|
|
||||||
under those permissions, but the entire Program remains governed by
|
|
||||||
this License without regard to the additional permissions.
|
|
||||||
|
|
||||||
When you convey a copy of a covered work, you may at your option
|
|
||||||
remove any additional permissions from that copy, or from any part of
|
|
||||||
it. (Additional permissions may be written to require their own
|
|
||||||
removal in certain cases when you modify the work.) You may place
|
|
||||||
additional permissions on material, added by you to a covered work,
|
|
||||||
for which you have or can give appropriate copyright permission.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, for material you
|
|
||||||
add to a covered work, you may (if authorized by the copyright holders
|
|
||||||
of that material) supplement the terms of this License with terms:
|
|
||||||
|
|
||||||
- a) Disclaiming warranty or limiting liability differently from the
|
|
||||||
terms of sections 15 and 16 of this License; or
|
|
||||||
- b) Requiring preservation of specified reasonable legal notices or
|
|
||||||
author attributions in that material or in the Appropriate Legal
|
|
||||||
Notices displayed by works containing it; or
|
|
||||||
- c) Prohibiting misrepresentation of the origin of that material,
|
|
||||||
or requiring that modified versions of such material be marked in
|
|
||||||
reasonable ways as different from the original version; or
|
|
||||||
- d) Limiting the use for publicity purposes of names of licensors
|
|
||||||
or authors of the material; or
|
|
||||||
- e) Declining to grant rights under trademark law for use of some
|
|
||||||
trade names, trademarks, or service marks; or
|
|
||||||
- f) Requiring indemnification of licensors and authors of that
|
|
||||||
material by anyone who conveys the material (or modified versions
|
|
||||||
of it) with contractual assumptions of liability to the recipient,
|
|
||||||
for any liability that these contractual assumptions directly
|
|
||||||
impose on those licensors and authors.
|
|
||||||
|
|
||||||
All other non-permissive additional terms are considered "further
|
|
||||||
restrictions" within the meaning of section 10. If the Program as you
|
|
||||||
received it, or any part of it, contains a notice stating that it is
|
|
||||||
governed by this License along with a term that is a further
|
|
||||||
restriction, you may remove that term. If a license document contains
|
|
||||||
a further restriction but permits relicensing or conveying under this
|
|
||||||
License, you may add to a covered work material governed by the terms
|
|
||||||
of that license document, provided that the further restriction does
|
|
||||||
not survive such relicensing or conveying.
|
|
||||||
|
|
||||||
If you add terms to a covered work in accord with this section, you
|
|
||||||
must place, in the relevant source files, a statement of the
|
|
||||||
additional terms that apply to those files, or a notice indicating
|
|
||||||
where to find the applicable terms.
|
|
||||||
|
|
||||||
Additional terms, permissive or non-permissive, may be stated in the
|
|
||||||
form of a separately written license, or stated as exceptions; the
|
|
||||||
above requirements apply either way.
|
|
||||||
|
|
||||||
### 8. Termination.
|
|
||||||
|
|
||||||
You may not propagate or modify a covered work except as expressly
|
|
||||||
provided under this License. Any attempt otherwise to propagate or
|
|
||||||
modify it is void, and will automatically terminate your rights under
|
|
||||||
this License (including any patent licenses granted under the third
|
|
||||||
paragraph of section 11).
|
|
||||||
|
|
||||||
However, if you cease all violation of this License, then your license
|
|
||||||
from a particular copyright holder is reinstated (a) provisionally,
|
|
||||||
unless and until the copyright holder explicitly and finally
|
|
||||||
terminates your license, and (b) permanently, if the copyright holder
|
|
||||||
fails to notify you of the violation by some reasonable means prior to
|
|
||||||
60 days after the cessation.
|
|
||||||
|
|
||||||
Moreover, your license from a particular copyright holder is
|
|
||||||
reinstated permanently if the copyright holder notifies you of the
|
|
||||||
violation by some reasonable means, this is the first time you have
|
|
||||||
received notice of violation of this License (for any work) from that
|
|
||||||
copyright holder, and you cure the violation prior to 30 days after
|
|
||||||
your receipt of the notice.
|
|
||||||
|
|
||||||
Termination of your rights under this section does not terminate the
|
|
||||||
licenses of parties who have received copies or rights from you under
|
|
||||||
this License. If your rights have been terminated and not permanently
|
|
||||||
reinstated, you do not qualify to receive new licenses for the same
|
|
||||||
material under section 10.
|
|
||||||
|
|
||||||
### 9. Acceptance Not Required for Having Copies.
|
|
||||||
|
|
||||||
You are not required to accept this License in order to receive or run
|
|
||||||
a copy of the Program. Ancillary propagation of a covered work
|
|
||||||
occurring solely as a consequence of using peer-to-peer transmission
|
|
||||||
to receive a copy likewise does not require acceptance. However,
|
|
||||||
nothing other than this License grants you permission to propagate or
|
|
||||||
modify any covered work. These actions infringe copyright if you do
|
|
||||||
not accept this License. Therefore, by modifying or propagating a
|
|
||||||
covered work, you indicate your acceptance of this License to do so.
|
|
||||||
|
|
||||||
### 10. Automatic Licensing of Downstream Recipients.
|
|
||||||
|
|
||||||
Each time you convey a covered work, the recipient automatically
|
|
||||||
receives a license from the original licensors, to run, modify and
|
|
||||||
propagate that work, subject to this License. You are not responsible
|
|
||||||
for enforcing compliance by third parties with this License.
|
|
||||||
|
|
||||||
An "entity transaction" is a transaction transferring control of an
|
|
||||||
organization, or substantially all assets of one, or subdividing an
|
|
||||||
organization, or merging organizations. If propagation of a covered
|
|
||||||
work results from an entity transaction, each party to that
|
|
||||||
transaction who receives a copy of the work also receives whatever
|
|
||||||
licenses to the work the party's predecessor in interest had or could
|
|
||||||
give under the previous paragraph, plus a right to possession of the
|
|
||||||
Corresponding Source of the work from the predecessor in interest, if
|
|
||||||
the predecessor has it or can get it with reasonable efforts.
|
|
||||||
|
|
||||||
You may not impose any further restrictions on the exercise of the
|
|
||||||
rights granted or affirmed under this License. For example, you may
|
|
||||||
not impose a license fee, royalty, or other charge for exercise of
|
|
||||||
rights granted under this License, and you may not initiate litigation
|
|
||||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
|
||||||
any patent claim is infringed by making, using, selling, offering for
|
|
||||||
sale, or importing the Program or any portion of it.
|
|
||||||
|
|
||||||
### 11. Patents.
|
|
||||||
|
|
||||||
A "contributor" is a copyright holder who authorizes use under this
|
|
||||||
License of the Program or a work on which the Program is based. The
|
|
||||||
work thus licensed is called the contributor's "contributor version".
|
|
||||||
|
|
||||||
A contributor's "essential patent claims" are all patent claims owned
|
|
||||||
or controlled by the contributor, whether already acquired or
|
|
||||||
hereafter acquired, that would be infringed by some manner, permitted
|
|
||||||
by this License, of making, using, or selling its contributor version,
|
|
||||||
but do not include claims that would be infringed only as a
|
|
||||||
consequence of further modification of the contributor version. For
|
|
||||||
purposes of this definition, "control" includes the right to grant
|
|
||||||
patent sublicenses in a manner consistent with the requirements of
|
|
||||||
this License.
|
|
||||||
|
|
||||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
|
||||||
patent license under the contributor's essential patent claims, to
|
|
||||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
|
||||||
propagate the contents of its contributor version.
|
|
||||||
|
|
||||||
In the following three paragraphs, a "patent license" is any express
|
|
||||||
agreement or commitment, however denominated, not to enforce a patent
|
|
||||||
(such as an express permission to practice a patent or covenant not to
|
|
||||||
sue for patent infringement). To "grant" such a patent license to a
|
|
||||||
party means to make such an agreement or commitment not to enforce a
|
|
||||||
patent against the party.
|
|
||||||
|
|
||||||
If you convey a covered work, knowingly relying on a patent license,
|
|
||||||
and the Corresponding Source of the work is not available for anyone
|
|
||||||
to copy, free of charge and under the terms of this License, through a
|
|
||||||
publicly available network server or other readily accessible means,
|
|
||||||
then you must either (1) cause the Corresponding Source to be so
|
|
||||||
available, or (2) arrange to deprive yourself of the benefit of the
|
|
||||||
patent license for this particular work, or (3) arrange, in a manner
|
|
||||||
consistent with the requirements of this License, to extend the patent
|
|
||||||
license to downstream recipients. "Knowingly relying" means you have
|
|
||||||
actual knowledge that, but for the patent license, your conveying the
|
|
||||||
covered work in a country, or your recipient's use of the covered work
|
|
||||||
in a country, would infringe one or more identifiable patents in that
|
|
||||||
country that you have reason to believe are valid.
|
|
||||||
|
|
||||||
If, pursuant to or in connection with a single transaction or
|
|
||||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
|
||||||
covered work, and grant a patent license to some of the parties
|
|
||||||
receiving the covered work authorizing them to use, propagate, modify
|
|
||||||
or convey a specific copy of the covered work, then the patent license
|
|
||||||
you grant is automatically extended to all recipients of the covered
|
|
||||||
work and works based on it.
|
|
||||||
|
|
||||||
A patent license is "discriminatory" if it does not include within the
|
|
||||||
scope of its coverage, prohibits the exercise of, or is conditioned on
|
|
||||||
the non-exercise of one or more of the rights that are specifically
|
|
||||||
granted under this License. You may not convey a covered work if you
|
|
||||||
are a party to an arrangement with a third party that is in the
|
|
||||||
business of distributing software, under which you make payment to the
|
|
||||||
third party based on the extent of your activity of conveying the
|
|
||||||
work, and under which the third party grants, to any of the parties
|
|
||||||
who would receive the covered work from you, a discriminatory patent
|
|
||||||
license (a) in connection with copies of the covered work conveyed by
|
|
||||||
you (or copies made from those copies), or (b) primarily for and in
|
|
||||||
connection with specific products or compilations that contain the
|
|
||||||
covered work, unless you entered into that arrangement, or that patent
|
|
||||||
license was granted, prior to 28 March 2007.
|
|
||||||
|
|
||||||
Nothing in this License shall be construed as excluding or limiting
|
|
||||||
any implied license or other defenses to infringement that may
|
|
||||||
otherwise be available to you under applicable patent law.
|
|
||||||
|
|
||||||
### 12. No Surrender of Others' Freedom.
|
|
||||||
|
|
||||||
If conditions are imposed on you (whether by court order, agreement or
|
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
|
||||||
excuse you from the conditions of this License. If you cannot convey a
|
|
||||||
covered work so as to satisfy simultaneously your obligations under
|
|
||||||
this License and any other pertinent obligations, then as a
|
|
||||||
consequence you may not convey it at all. For example, if you agree to
|
|
||||||
terms that obligate you to collect a royalty for further conveying
|
|
||||||
from those to whom you convey the Program, the only way you could
|
|
||||||
satisfy both those terms and this License would be to refrain entirely
|
|
||||||
from conveying the Program.
|
|
||||||
|
|
||||||
### 13. Use with the GNU Affero General Public License.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, you have
|
|
||||||
permission to link or combine any covered work with a work licensed
|
|
||||||
under version 3 of the GNU Affero General Public License into a single
|
|
||||||
combined work, and to convey the resulting work. The terms of this
|
|
||||||
License will continue to apply to the part which is the covered work,
|
|
||||||
but the special requirements of the GNU Affero General Public License,
|
|
||||||
section 13, concerning interaction through a network will apply to the
|
|
||||||
combination as such.
|
|
||||||
|
|
||||||
### 14. Revised Versions of this License.
|
|
||||||
|
|
||||||
The Free Software Foundation may publish revised and/or new versions
|
|
||||||
of the GNU General Public License from time to time. Such new versions
|
|
||||||
will be similar in spirit to the present version, but may differ in
|
|
||||||
detail to address new problems or concerns.
|
|
||||||
|
|
||||||
Each version is given a distinguishing version number. If the Program
|
|
||||||
specifies that a certain numbered version of the GNU General Public
|
|
||||||
License "or any later version" applies to it, you have the option of
|
|
||||||
following the terms and conditions either of that numbered version or
|
|
||||||
of any later version published by the Free Software Foundation. If the
|
|
||||||
Program does not specify a version number of the GNU General Public
|
|
||||||
License, you may choose any version ever published by the Free
|
|
||||||
Software Foundation.
|
|
||||||
|
|
||||||
If the Program specifies that a proxy can decide which future versions
|
|
||||||
of the GNU General Public License can be used, that proxy's public
|
|
||||||
statement of acceptance of a version permanently authorizes you to
|
|
||||||
choose that version for the Program.
|
|
||||||
|
|
||||||
Later license versions may give you additional or different
|
|
||||||
permissions. However, no additional obligations are imposed on any
|
|
||||||
author or copyright holder as a result of your choosing to follow a
|
|
||||||
later version.
|
|
||||||
|
|
||||||
### 15. Disclaimer of Warranty.
|
|
||||||
|
|
||||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
|
||||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
|
||||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT
|
|
||||||
WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT
|
|
||||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
||||||
A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND
|
|
||||||
PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE
|
|
||||||
DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR
|
|
||||||
CORRECTION.
|
|
||||||
|
|
||||||
### 16. Limitation of Liability.
|
|
||||||
|
|
||||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
|
||||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR
|
|
||||||
CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
|
||||||
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES
|
|
||||||
ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT
|
|
||||||
NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR
|
|
||||||
LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM
|
|
||||||
TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER
|
|
||||||
PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
|
||||||
|
|
||||||
### 17. Interpretation of Sections 15 and 16.
|
|
||||||
|
|
||||||
If the disclaimer of warranty and limitation of liability provided
|
|
||||||
above cannot be given local legal effect according to their terms,
|
|
||||||
reviewing courts shall apply local law that most closely approximates
|
|
||||||
an absolute waiver of all civil liability in connection with the
|
|
||||||
Program, unless a warranty or assumption of liability accompanies a
|
|
||||||
copy of the Program in return for a fee.
|
|
||||||
|
|
||||||
END OF TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
## How to Apply These Terms to Your New Programs
|
|
||||||
|
|
||||||
If you develop a new program, and you want it to be of the greatest
|
|
||||||
possible use to the public, the best way to achieve this is to make it
|
|
||||||
free software which everyone can redistribute and change under these
|
|
||||||
terms.
|
|
||||||
|
|
||||||
To do so, attach the following notices to the program. It is safest to
|
|
||||||
attach them to the start of each source file to most effectively state
|
|
||||||
the exclusion of warranty; and each file should have at least the
|
|
||||||
"copyright" line and a pointer to where the full notice is found.
|
|
||||||
|
|
||||||
<one line to give the program's name and a brief idea of what it does.>
|
|
||||||
Copyright (C) <year> <name of author>
|
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
This program is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper
|
|
||||||
mail.
|
|
||||||
|
|
||||||
If the program does terminal interaction, make it output a short
|
|
||||||
notice like this when it starts in an interactive mode:
|
|
||||||
|
|
||||||
<program> Copyright (C) <year> <name of author>
|
|
||||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
|
||||||
This is free software, and you are welcome to redistribute it
|
|
||||||
under certain conditions; type `show c' for details.
|
|
||||||
|
|
||||||
The hypothetical commands \`show w' and \`show c' should show the
|
|
||||||
appropriate parts of the General Public License. Of course, your
|
|
||||||
program's commands might be different; for a GUI interface, you would
|
|
||||||
use an "about box".
|
|
||||||
|
|
||||||
You should also get your employer (if you work as a programmer) or
|
|
||||||
school, if any, to sign a "copyright disclaimer" for the program, if
|
|
||||||
necessary. For more information on this, and how to apply and follow
|
|
||||||
the GNU GPL, see <https://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
The GNU General Public License does not permit incorporating your
|
|
||||||
program into proprietary programs. If your program is a subroutine
|
|
||||||
library, you may consider it more useful to permit linking proprietary
|
|
||||||
applications with the library. If this is what you want to do, use the
|
|
||||||
GNU Lesser General Public License instead of this License. But first,
|
|
||||||
please read <https://www.gnu.org/licenses/why-not-lgpl.html>.
|
|
||||||
48
README.md
48
README.md
@@ -1,45 +1,7 @@
|
|||||||
# RetroDebian Live
|
# RetroDebian Builder V2
|
||||||
|
|
||||||
RetroDebian Live is a custom live distro built on **Debian Etch** for **retro gaming on classic x86 hardware**.
|
Main entry point:
|
||||||
|
- `python3 builder/py/orchestrate.py validate`
|
||||||
|
- `python3 builder/py/orchestrate.py run --profile demo --fake-legacy`
|
||||||
|
|
||||||
It is made for machines like the **Pentium II** and **Pentium III**, with one goal:
|
`builder/py/build.py` is deprecated and intentionally does not implement the workflow anymore.
|
||||||
deliver a **fast, light, period-appropriate Linux system** for old games, old GPUs, and old hardware experiments.
|
|
||||||
|
|
||||||
This is not a modern desktop squeezed onto old hardware.
|
|
||||||
It is a purpose-built retro system.
|
|
||||||
|
|
||||||
## Features
|
|
||||||
|
|
||||||
- Debian Etch userspace
|
|
||||||
- Custom 2.6.24-based kernel
|
|
||||||
- Live boot with SquashFS + UnionFS
|
|
||||||
- Lightweight Fluxbox desktop
|
|
||||||
- Fast startup and low overhead
|
|
||||||
- Built as a base for 3dfx, Glide, UT99, and hardware test tools
|
|
||||||
|
|
||||||
## Current state
|
|
||||||
|
|
||||||
The system already boots and runs as a real live distro with the custom kernel.
|
|
||||||
|
|
||||||
The next steps are:
|
|
||||||
- desktop polish
|
|
||||||
- 3dfx integration
|
|
||||||
- custom tools
|
|
||||||
- Unreal Tournament 99
|
|
||||||
- optional installer support
|
|
||||||
|
|
||||||
## Philosophy
|
|
||||||
|
|
||||||
RetroDebian Live is built around a simple idea:
|
|
||||||
|
|
||||||
**old hardware deserves software that stays out of its way.**
|
|
||||||
|
|
||||||
Small, responsive, understandable, and tuned for retro gaming.
|
|
||||||
|
|
||||||
Multiple ISO will be generated, including different GPU Drivers.
|
|
||||||
|
|
||||||
The current focus is on 3DFX Voodoo2 :)
|
|
||||||
|
|
||||||
## Technical note
|
|
||||||
|
|
||||||
The project is built with a custom kernel, `live-helper`, Docker, and Jenkins, with the kernel and ISO handled as separate build stages.
|
|
||||||
|
|||||||
1
bases/retrodebian/chroot/README-common-base.txt
Normal file
1
bases/retrodebian/chroot/README-common-base.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
Common base chroot payload.
|
||||||
21
bases/retrodebian/docker/system/Dockerfile
Normal file
21
bases/retrodebian/docker/system/Dockerfile
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
FROM retrodebian/package-builder
|
||||||
|
RUN apt-get install -y linux-headers-2.6.24-etchnhalf.1-686 \
|
||||||
|
squashfs-source-etchnhalf \
|
||||||
|
linux-source-2.6.24 && \
|
||||||
|
apt-get build-dep -y linux-image-2.6.24-etchnhalf.1-686 && \
|
||||||
|
apt-get clean
|
||||||
|
|
||||||
|
# Preparing Kernel + patchs + modules
|
||||||
|
WORKDIR /usr/src
|
||||||
|
COPY unionfs-2.2.3_for_2.6.24.diff.gz ./
|
||||||
|
RUN tar xjf linux-source-2.6.24.tar.bz2 && \
|
||||||
|
tar xjf etchnhalf/squashfs.tar.bz2 && \
|
||||||
|
ln -s linux-headers-2.6.24-etchnhalf.1-686/ linux-headers && \
|
||||||
|
|
||||||
|
# Building Kernel + patchs + modules
|
||||||
|
WORKDIR /usr/src/linux-source-2.6.24
|
||||||
|
#COPY config-kernel ./
|
||||||
|
RUN (zcat /usr/src/unionfs-2.2.3_for_2.6.24.diff.gz | patch -p1) && \
|
||||||
|
# (cat config-kernel > .config) && \
|
||||||
|
make oldconfig &&\
|
||||||
|
make-kpkg --initrd --arch $ARCH kernel_headers kernel_image modules_image
|
||||||
36
bases/retrodebian/entry.py
Normal file
36
bases/retrodebian/entry.py
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import sys
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
THIS_FILE = Path(__file__).resolve()
|
||||||
|
PROJECT_ROOT = THIS_FILE.parents[2]
|
||||||
|
PY_ROOT = PROJECT_ROOT / 'builder' / 'py'
|
||||||
|
if str(PY_ROOT) not in sys.path:
|
||||||
|
sys.path.insert(0, str(PY_ROOT))
|
||||||
|
|
||||||
|
from retrobuilder.context import BuildContext
|
||||||
|
from retrobuilder.entrypoints import BaseEntry, cli_dispatch
|
||||||
|
from retrobuilder.model import BaseSpec
|
||||||
|
|
||||||
|
SPEC = BaseSpec(
|
||||||
|
description='Common inherited base resources shared by concrete bases.',
|
||||||
|
docker_overrides={
|
||||||
|
'pre-gen': {'dockerfile': 'bases/retrodebian/docker/system/Dockerfile'},
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
class Entry(BaseEntry):
|
||||||
|
def pre_gen(self, ctx: BuildContext) -> None:
|
||||||
|
ctx.artifacts_root.mkdir(parents=True, exist_ok=True)
|
||||||
|
(ctx.artifacts_root / 'pre-gen.txt').write_text('common-base pre-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def post_gen(self, ctx: BuildContext) -> None:
|
||||||
|
ctx.artifacts_root.mkdir(parents=True, exist_ok=True)
|
||||||
|
(ctx.artifacts_root / 'post-gen.txt').write_text('common-base post-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
raise SystemExit(cli_dispatch(SPEC, Entry))
|
||||||
14
bases/retrodebian/entry.sh
Normal file
14
bases/retrodebian/entry.sh
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
PHASE=${1:-}
|
||||||
|
[ -n "$PHASE" ] || { echo "Usage: entry.sh <phase>" >&2; exit 2; }
|
||||||
|
|
||||||
|
case "$PHASE" in
|
||||||
|
pre-feature|post-feature)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Unsupported base phase: $PHASE" >&2
|
||||||
|
exit 2
|
||||||
|
;;
|
||||||
|
esac
|
||||||
8
bases/retrodebian/generate.sh
Normal file
8
bases/retrodebian/generate.sh
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||||
|
MODULE_NAME=$(basename "$SCRIPT_DIR")
|
||||||
|
: "${ARTIFACTS_ROOT:?ARTIFACTS_ROOT is required}"
|
||||||
|
mkdir -p "$ARTIFACTS_ROOT/generated"
|
||||||
|
printf 'generated base %s\n' "$MODULE_NAME" > "$ARTIFACTS_ROOT/generated/from-generate.txt"
|
||||||
|
exit 0
|
||||||
2
bases/retrodebian/hooks/05-common-base.sh
Normal file
2
bases/retrodebian/hooks/05-common-base.sh
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
echo "common-base live hook"
|
||||||
2
bases/retrodebian/packageslists/common-base.list
Normal file
2
bases/retrodebian/packageslists/common-base.list
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
# common-base package list
|
||||||
|
nano
|
||||||
1
bases/voodoo2/chroot/etc/retrodebian-base.conf
Normal file
1
bases/voodoo2/chroot/etc/retrodebian-base.conf
Normal file
@@ -0,0 +1 @@
|
|||||||
|
BASE=sample-base
|
||||||
50
bases/voodoo2/entry.py
Normal file
50
bases/voodoo2/entry.py
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import sys
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
THIS_FILE = Path(__file__).resolve()
|
||||||
|
PROJECT_ROOT = THIS_FILE.parents[2]
|
||||||
|
PY_ROOT = PROJECT_ROOT / 'builder' / 'py'
|
||||||
|
if str(PY_ROOT) not in sys.path:
|
||||||
|
sys.path.insert(0, str(PY_ROOT))
|
||||||
|
|
||||||
|
from retrobuilder.context import BuildContext
|
||||||
|
from retrobuilder.entrypoints import BaseEntry, cli_dispatch
|
||||||
|
from retrobuilder.model import BaseSpec
|
||||||
|
|
||||||
|
SPEC = BaseSpec(
|
||||||
|
description='Sample base used to validate the V2 builder flow.',
|
||||||
|
parent='retrodebian',
|
||||||
|
docker_overrides={
|
||||||
|
# 'pre-feature': {'image': 'retrodebian/custom-lenny:latest'},
|
||||||
|
# 'post-feature': {'dockerfile': 'bases/sample-base/Dockerfile.lenny'},
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
class Entry(BaseEntry):
|
||||||
|
def _marker(self, ctx: BuildContext, name: str) -> Path:
|
||||||
|
ctx.artifacts_root.mkdir(parents=True, exist_ok=True)
|
||||||
|
return ctx.artifacts_root / name
|
||||||
|
|
||||||
|
def pre_gen(self, ctx: BuildContext) -> None:
|
||||||
|
self._marker(ctx, 'pre-gen.txt').write_text('sample-base pre-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def post_gen(self, ctx: BuildContext) -> None:
|
||||||
|
self._marker(ctx, 'post-gen.txt').write_text('sample-base post-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def pre_feature(self, ctx: BuildContext) -> None:
|
||||||
|
notes = ctx.live_dir / 'builder-notes'
|
||||||
|
notes.mkdir(parents=True, exist_ok=True)
|
||||||
|
(notes / 'base-pre-feature.txt').write_text('sample-base pre-feature\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def post_feature(self, ctx: BuildContext) -> None:
|
||||||
|
notes = ctx.live_dir / 'builder-notes'
|
||||||
|
notes.mkdir(parents=True, exist_ok=True)
|
||||||
|
(notes / 'base-post-feature.txt').write_text('sample-base post-feature\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
raise SystemExit(cli_dispatch(SPEC, Entry))
|
||||||
14
bases/voodoo2/entry.sh
Normal file
14
bases/voodoo2/entry.sh
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
PHASE=${1:-}
|
||||||
|
[ -n "$PHASE" ] || { echo "Usage: entry.sh <phase>" >&2; exit 2; }
|
||||||
|
|
||||||
|
case "$PHASE" in
|
||||||
|
pre-feature|post-feature)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Unsupported base phase: $PHASE" >&2
|
||||||
|
exit 2
|
||||||
|
;;
|
||||||
|
esac
|
||||||
7
bases/voodoo2/generate.sh
Normal file
7
bases/voodoo2/generate.sh
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
[ -n "${ARTIFACTS_ROOT:-}" ] || { echo "ARTIFACTS_ROOT is required" >&2; exit 2; }
|
||||||
|
mkdir -p "$ARTIFACTS_ROOT/generated"
|
||||||
|
printf 'generated by sample-base
|
||||||
|
' > "$ARTIFACTS_ROOT/generated/base-artifact.txt"
|
||||||
4
bases/voodoo2/hooks/10-sample-base.sh
Normal file
4
bases/voodoo2/hooks/10-sample-base.sh
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
printf 'sample base chroot hook
|
||||||
|
' > /tmp/sample-base-hook.txt
|
||||||
23
builder/bash/common.sh
Executable file
23
builder/bash/common.sh
Executable file
@@ -0,0 +1,23 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
fail() {
|
||||||
|
echo "ERROR: $*" >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
require_file() {
|
||||||
|
[ -f "$1" ] || fail "Missing file: $1"
|
||||||
|
}
|
||||||
|
|
||||||
|
require_dir() {
|
||||||
|
[ -d "$1" ] || fail "Missing directory: $1"
|
||||||
|
}
|
||||||
|
|
||||||
|
load_env_file() {
|
||||||
|
ENV_FILE="$1"
|
||||||
|
require_file "$ENV_FILE"
|
||||||
|
set -a
|
||||||
|
. "$ENV_FILE"
|
||||||
|
set +a
|
||||||
|
}
|
||||||
|
|
||||||
18
builder/bash/run_entry.sh
Executable file
18
builder/bash/run_entry.sh
Executable file
@@ -0,0 +1,18 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
SELF_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||||
|
. "$SELF_DIR/common.sh"
|
||||||
|
|
||||||
|
MODULE_DIR=${1:-}
|
||||||
|
ENV_FILE=${2:-}
|
||||||
|
PHASE=${3:-}
|
||||||
|
[ -n "$MODULE_DIR" ] || fail "Usage: run_entry.sh <module-dir> <env-file> <phase>"
|
||||||
|
[ -n "$ENV_FILE" ] || fail "Usage: run_entry.sh <module-dir> <env-file> <phase>"
|
||||||
|
[ -n "$PHASE" ] || fail "Usage: run_entry.sh <module-dir> <env-file> <phase>"
|
||||||
|
|
||||||
|
require_dir "$MODULE_DIR"
|
||||||
|
load_env_file "$ENV_FILE"
|
||||||
|
require_file "$MODULE_DIR/entry.sh"
|
||||||
|
|
||||||
|
exec /bin/sh "$MODULE_DIR/entry.sh" "$PHASE"
|
||||||
16
builder/bash/run_generate.sh
Executable file
16
builder/bash/run_generate.sh
Executable file
@@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
SELF_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||||
|
. "$SELF_DIR/common.sh"
|
||||||
|
|
||||||
|
MODULE_DIR=${1:-}
|
||||||
|
ENV_FILE=${2:-}
|
||||||
|
[ -n "$MODULE_DIR" ] || fail "Usage: run_generate.sh <module-dir> <env-file>"
|
||||||
|
[ -n "$ENV_FILE" ] || fail "Usage: run_generate.sh <module-dir> <env-file>"
|
||||||
|
|
||||||
|
require_dir "$MODULE_DIR"
|
||||||
|
load_env_file "$ENV_FILE"
|
||||||
|
require_file "$MODULE_DIR/generate.sh"
|
||||||
|
|
||||||
|
exec /bin/sh "$MODULE_DIR/generate.sh"
|
||||||
17
builder/bash/run_profile_build.sh
Executable file
17
builder/bash/run_profile_build.sh
Executable file
@@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
#set -eu # lh_build or even included packages might have error or unset variables..
|
||||||
|
set +e
|
||||||
|
|
||||||
|
SELF_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||||
|
. "$SELF_DIR/common.sh"
|
||||||
|
|
||||||
|
ENV_FILE=${1:-}
|
||||||
|
[ -n "$ENV_FILE" ] || fail "Usage: run_profile_build.sh <env-file>"
|
||||||
|
load_env_file "$ENV_FILE"
|
||||||
|
|
||||||
|
[ -n "${LIVE_DIR:-}" ] || fail "LIVE_DIR is required"
|
||||||
|
[ -n "${ARTIFACTS_ROOT:-}" ] || fail "ARTIFACTS_ROOT is required"
|
||||||
|
mkdir -p "$ARTIFACTS_ROOT/final"
|
||||||
|
|
||||||
|
cd "$LIVE_DIR" && exec lh_build
|
||||||
44
builder/bash/run_profile_config.sh
Executable file
44
builder/bash/run_profile_config.sh
Executable file
@@ -0,0 +1,44 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
#set -eu # lh_build or even included packages might have error or unset variables..
|
||||||
|
set +e
|
||||||
|
|
||||||
|
SELF_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||||
|
. "$SELF_DIR/common.sh"
|
||||||
|
|
||||||
|
ENV_FILE=${1:-}
|
||||||
|
[ -n "$ENV_FILE" ] || fail "Usage: run_profile_config.sh <env-file>"
|
||||||
|
load_env_file "$ENV_FILE"
|
||||||
|
|
||||||
|
[ -n "${LIVE_DIR:-}" ] || fail "LIVE_DIR is required"
|
||||||
|
mkdir -p "$LIVE_DIR"
|
||||||
|
|
||||||
|
env
|
||||||
|
cd "$LIVE_DIR" && exec lh_config \
|
||||||
|
-a $BASE__ARCH \
|
||||||
|
--distribution $BASE__DISTRIBUTION \
|
||||||
|
--apt $BASE__APT \
|
||||||
|
--apt-options "$BASE__APT_OPTIONS" \
|
||||||
|
--apt-secure $BASE__APT_SECURE \
|
||||||
|
--apt-recommends $BASE__APT_RECOMMENDS \
|
||||||
|
--mirror-bootstrap "$BASE__REPO_URL" \
|
||||||
|
--mirror-binary "$BASE__REPO_URL" \
|
||||||
|
--mirror-binary-security "$BASE__SECURITY_REPO_URL" \
|
||||||
|
--mirror-chroot "$BASE__REPO_URL" \
|
||||||
|
--mirror-chroot-security "$BASE__SECURITY_REPO_URL" \
|
||||||
|
--binary-images $BASE__BINARY_IMAGES \
|
||||||
|
--bootloader syslinux \
|
||||||
|
--syslinux-timeout 5 \
|
||||||
|
--syslinux-menu true \
|
||||||
|
--bootstrap debootstrap \
|
||||||
|
--debconf-frontend noninteractive \
|
||||||
|
--debian-installer live \
|
||||||
|
--bootappend-live "$BASE__BOOTAPPEND_LIVE" \
|
||||||
|
--linux-packages "$BASE__LINUX_PACKAGES" \
|
||||||
|
--union-filesystem $BASE__UNION_FILESYSTEM \
|
||||||
|
--packages-lists "$BASE__PACKAGES_LISTS" \
|
||||||
|
--iso-application $BASE__ISO_APPLICATION \
|
||||||
|
--hostname $BASE__HOSTNAME \
|
||||||
|
--username $BASE__USERNAME \
|
||||||
|
--templates config/templates \
|
||||||
|
"$LIVE_DIR"
|
||||||
6
builder/docker/live-helper/Dockerfile
Normal file
6
builder/docker/live-helper/Dockerfile
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
FROM lpenz/debian-lenny-i386-minbase AS live-helper
|
||||||
|
ARG DEBIAN_FRONTEND=noninteractive
|
||||||
|
ARG ARCH=i386
|
||||||
|
RUN apt-get update && \
|
||||||
|
apt-get -y --force-yes install live-helper genisoimage syslinux squashfs-tools aptitude && \
|
||||||
|
apt-get clean
|
||||||
2
builder/docker/orchestrator/Dockerfile
Normal file
2
builder/docker/orchestrator/Dockerfile
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
FROM python:3.14-alpine AS orchestrator
|
||||||
|
RUN apk add --no-cache git ca-certificates
|
||||||
12
builder/docker/package-builder/Dockerfile
Normal file
12
builder/docker/package-builder/Dockerfile
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# building a modified Kernel + modules
|
||||||
|
FROM lpenz/debian-etch-i386-minbase AS package-builder
|
||||||
|
ARG DEBIAN_FRONTEND=noninteractive
|
||||||
|
ARG ARCH=i386
|
||||||
|
ARG CONCURRENCY_LEVEL=4
|
||||||
|
|
||||||
|
# Preparing Environment
|
||||||
|
RUN (echo "deb http://archive.debian.org/debian etch main contrib non-free" > /etc/apt/sources.list) && \
|
||||||
|
(echo "deb-src http://archive.debian.org/debian etch main contrib non-free" >> /etc/apt/sources.list) && \
|
||||||
|
mkdir -p /usr/src/modules &&\
|
||||||
|
apt-get update && \
|
||||||
|
apt-get install -y aptitude build-essential quilt cvs unzip git-core ncurses-dev
|
||||||
2
builder/py/build.py
Normal file
2
builder/py/build.py
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
raise SystemExit("Deprecated: use builder/py/orchestrate.py")
|
||||||
348
builder/py/orchestrate.py
Normal file
348
builder/py/orchestrate.py
Normal file
@@ -0,0 +1,348 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import argparse
|
||||||
|
import os
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
import uuid
|
||||||
|
from dataclasses import dataclass
|
||||||
|
from pathlib import Path
|
||||||
|
from typing import Iterable
|
||||||
|
|
||||||
|
THIS_DIR = Path(__file__).resolve().parent
|
||||||
|
if str(THIS_DIR) not in sys.path:
|
||||||
|
sys.path.insert(0, str(THIS_DIR))
|
||||||
|
|
||||||
|
from retrobuilder.context import BuildContext
|
||||||
|
from retrobuilder.envfile import write_env_file
|
||||||
|
from retrobuilder.loader import (
|
||||||
|
load_base_chain,
|
||||||
|
load_module_entry,
|
||||||
|
load_module_spec,
|
||||||
|
load_profile,
|
||||||
|
resolve_module_config,
|
||||||
|
resolve_module_docker_override,
|
||||||
|
)
|
||||||
|
from retrobuilder.operations import (
|
||||||
|
apply_profile_common_configuration,
|
||||||
|
clear_directory_contents,
|
||||||
|
ensure_live_structure,
|
||||||
|
inject_module_resources,
|
||||||
|
profile_finalize,
|
||||||
|
profile_pre_build,
|
||||||
|
save_feature_metadata,
|
||||||
|
save_profile_metadata,
|
||||||
|
)
|
||||||
|
from retrobuilder.paths import base_artifacts_dir, base_dir, feature_artifacts_dir, feature_dir, profile_artifacts_dir, project_root_from
|
||||||
|
|
||||||
|
ORCHESTRATOR_RUNTIME = "orchestrator"
|
||||||
|
PACKAGE_BUILDER_RUNTIME = "package-builder"
|
||||||
|
LIVE_HELPER_RUNTIME = "live-helper"
|
||||||
|
DEFAULT_RUNTIME_DOCKERFILES = {
|
||||||
|
ORCHESTRATOR_RUNTIME: "builder/docker/orchestrator/Dockerfile",
|
||||||
|
PACKAGE_BUILDER_RUNTIME: "builder/docker/package-builder/Dockerfile",
|
||||||
|
LIVE_HELPER_RUNTIME: "builder/docker/live-helper/Dockerfile",
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
def sh(cmd: list[str], *, cwd: Path | None = None, capture: bool = False) -> str:
|
||||||
|
proc = subprocess.run(cmd, cwd=cwd, text=True, check=True, stdout=subprocess.PIPE if capture else None)
|
||||||
|
return proc.stdout.strip() if capture else ""
|
||||||
|
|
||||||
|
|
||||||
|
def root_dir() -> Path:
|
||||||
|
return project_root_from(Path.cwd())
|
||||||
|
|
||||||
|
|
||||||
|
def list_names(path: Path) -> list[str]:
|
||||||
|
if not path.exists():
|
||||||
|
return []
|
||||||
|
if path.name == "profiles":
|
||||||
|
return sorted(p.stem for p in path.iterdir() if p.is_file() and p.suffix == ".py")
|
||||||
|
return sorted(p.name for p in path.iterdir() if p.is_dir())
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class RuntimeConfig:
|
||||||
|
image: str = ""
|
||||||
|
dockerfile: str = ""
|
||||||
|
context: str = "."
|
||||||
|
privileged: bool = False
|
||||||
|
|
||||||
|
|
||||||
|
class DockerRuntime:
|
||||||
|
def __init__(self, root: Path, name: str, image: str, privileged: bool = False) -> None:
|
||||||
|
self.root = root
|
||||||
|
self.name = name
|
||||||
|
self.image = image
|
||||||
|
self.container = f"retrodebian-{name}-{uuid.uuid4().hex[:8]}"
|
||||||
|
self.started = False
|
||||||
|
self.privileged = privileged
|
||||||
|
|
||||||
|
def start(self) -> None:
|
||||||
|
if self.started:
|
||||||
|
return
|
||||||
|
user = f"{os.getuid()}:{os.getgid()}" if hasattr(os, "getuid") else "0:0"
|
||||||
|
cmd = [
|
||||||
|
"docker",
|
||||||
|
"run",
|
||||||
|
"-d",
|
||||||
|
"--name",
|
||||||
|
self.container,
|
||||||
|
]
|
||||||
|
if self.privileged:
|
||||||
|
cmd.append("--privileged")
|
||||||
|
cmd.append("--user")
|
||||||
|
cmd.append(user)
|
||||||
|
cmd.append("-w")
|
||||||
|
cmd.append(str(self.root))
|
||||||
|
cmd.append("-v")
|
||||||
|
cmd.append(f"{self.root}:{self.root}:rw")
|
||||||
|
cmd.append(self.image)
|
||||||
|
cmd.append("sleep")
|
||||||
|
cmd.append("infinity")
|
||||||
|
sh(cmd)
|
||||||
|
self.started = True
|
||||||
|
|
||||||
|
def exec(self, argv: list[str], env: dict[str, str] | None = None) -> None:
|
||||||
|
self.start()
|
||||||
|
cmd = ["docker", "exec"]
|
||||||
|
for k, v in (env or {}).items():
|
||||||
|
cmd += ["-e", f"{k}={v}"]
|
||||||
|
sh(cmd + [self.container] + argv)
|
||||||
|
|
||||||
|
def stop(self) -> None:
|
||||||
|
if self.started:
|
||||||
|
try:
|
||||||
|
sh(["docker", "stop", self.container])
|
||||||
|
finally:
|
||||||
|
self.started = False
|
||||||
|
|
||||||
|
def rm(self) -> None:
|
||||||
|
sh(["docker", "rm", "-f", self.container])
|
||||||
|
|
||||||
|
|
||||||
|
class RuntimePool:
|
||||||
|
def __init__(self, root: Path, configs: dict[str, RuntimeConfig], keep: bool = False) -> None:
|
||||||
|
self.root = root
|
||||||
|
self.keep = keep
|
||||||
|
self.defaults = {name: DockerRuntime(root, name, self._image(name, cfg), cfg.privileged) for name, cfg in configs.items()}
|
||||||
|
|
||||||
|
def _image(self, name: str, cfg: RuntimeConfig) -> str:
|
||||||
|
if cfg.dockerfile:
|
||||||
|
image = cfg.image or f"retrodebian/{name}:local"
|
||||||
|
sh(["docker", "build", "-t", image, "-f", cfg.dockerfile, cfg.context or "."], cwd=self.root)
|
||||||
|
return image
|
||||||
|
if cfg.image:
|
||||||
|
return cfg.image
|
||||||
|
raise ValueError(f"Missing image for runtime {name}")
|
||||||
|
|
||||||
|
def start(self) -> None:
|
||||||
|
for runtime in self.defaults.values():
|
||||||
|
runtime.start()
|
||||||
|
|
||||||
|
def close(self) -> None:
|
||||||
|
for runtime in self.defaults.values():
|
||||||
|
try: runtime.stop()
|
||||||
|
except Exception: pass
|
||||||
|
if not self.keep:
|
||||||
|
for runtime in self.defaults.values():
|
||||||
|
try: runtime.rm()
|
||||||
|
except Exception: pass
|
||||||
|
|
||||||
|
def resolve(self, runtime_name: str, override: RuntimeConfig | None = None) -> tuple[DockerRuntime, bool]:
|
||||||
|
if not override or not (override.image or override.dockerfile):
|
||||||
|
return self.defaults[runtime_name], False
|
||||||
|
runtime = DockerRuntime(self.root, f"{runtime_name}-override", self._image(f"{runtime_name}-override-{uuid.uuid4().hex[:6]}", override), override.privileged)
|
||||||
|
runtime.start()
|
||||||
|
return runtime, True
|
||||||
|
|
||||||
|
|
||||||
|
class Orchestrator:
|
||||||
|
def __init__(self, root: Path, runtimes: RuntimePool) -> None:
|
||||||
|
self.root = root
|
||||||
|
self.runtimes = runtimes
|
||||||
|
|
||||||
|
def validate(self) -> None:
|
||||||
|
for profile_name in list_names(self.root / "profiles"):
|
||||||
|
profile = load_profile(self.root, profile_name)
|
||||||
|
load_base_chain(self.root, profile.base)
|
||||||
|
for feature_name in profile.features:
|
||||||
|
load_module_spec(self.root, "feature", feature_name)
|
||||||
|
print("Validation OK")
|
||||||
|
|
||||||
|
def context(self, phase: str, kind: str, *, profile_name: str = "", base_name: str = "", feature_name: str = "") -> BuildContext:
|
||||||
|
profile = load_profile(self.root, profile_name) if profile_name else None
|
||||||
|
base_name = base_name or (profile.base if profile else "")
|
||||||
|
feature_names = tuple(profile.features) if profile else ()
|
||||||
|
return BuildContext(
|
||||||
|
project_root=self.root,
|
||||||
|
live_dir=self.root / "live",
|
||||||
|
artifacts_root=self.root / "artifacts",
|
||||||
|
phase=phase,
|
||||||
|
kind=kind,
|
||||||
|
name=feature_name or base_name or profile_name,
|
||||||
|
profile_name=profile_name,
|
||||||
|
base_name=base_name,
|
||||||
|
feature_name=feature_name,
|
||||||
|
profile={**(profile.config if profile else {}), "base": base_name, "features": feature_names, "edition": profile.edition if profile else "", "description": profile.description if profile else "", "splash": profile.splash if profile else ""},
|
||||||
|
base=resolve_module_config(self.root, "base", base_name) if base_name else {},
|
||||||
|
features={name: resolve_module_config(self.root, "feature", name) for name in feature_names},
|
||||||
|
)
|
||||||
|
|
||||||
|
def env_file(self, ctx: BuildContext, path: Path) -> Path:
|
||||||
|
values = ctx.to_env()
|
||||||
|
write_env_file(path, values)
|
||||||
|
return path
|
||||||
|
|
||||||
|
def override(self, kind: str, name: str, phase: str) -> RuntimeConfig | None:
|
||||||
|
stage = resolve_module_docker_override(self.root, kind, name, phase)
|
||||||
|
if not stage or not stage.is_set():
|
||||||
|
return None
|
||||||
|
|
||||||
|
image = stage.image or ""
|
||||||
|
dockerfile = stage.dockerfile or ""
|
||||||
|
docker_context = stage.docker_context or ""
|
||||||
|
|
||||||
|
return RuntimeConfig(image, dockerfile, docker_context)
|
||||||
|
|
||||||
|
def run_python(self, kind: str, name: str, phase: str, *, profile_name: str = "", base_name: str = "", feature_name: str = "") -> None:
|
||||||
|
module_dir = (base_dir if kind == "base" else feature_dir)(self.root, name)
|
||||||
|
runtime, owned = self.runtimes.resolve(ORCHESTRATOR_RUNTIME, self.override(kind, name, phase))
|
||||||
|
try:
|
||||||
|
runtime.exec(["python3", str(module_dir / "entry.py"), phase], self.context(phase, kind, profile_name=profile_name, base_name=base_name, feature_name=feature_name).to_env())
|
||||||
|
finally:
|
||||||
|
if owned:
|
||||||
|
runtime.stop()
|
||||||
|
if not self.runtimes.keep:
|
||||||
|
runtime.rm()
|
||||||
|
|
||||||
|
def run_generate(self, kind: str, name: str, env_path: Path) -> None:
|
||||||
|
module_dir = (base_dir if kind == "base" else feature_dir)(self.root, name)
|
||||||
|
runtime, owned = self.runtimes.resolve(PACKAGE_BUILDER_RUNTIME, self.override(kind, name, "generate"))
|
||||||
|
try:
|
||||||
|
runtime.exec(["builder/bash/run_generate.sh", str(module_dir), str(env_path)])
|
||||||
|
finally:
|
||||||
|
if owned:
|
||||||
|
runtime.stop()
|
||||||
|
if not self.runtimes.keep:
|
||||||
|
runtime.rm()
|
||||||
|
|
||||||
|
def run_shell(self, kind: str, name: str, phase: str, env_path: Path) -> None:
|
||||||
|
module_dir = (base_dir if kind == "base" else feature_dir)(self.root, name)
|
||||||
|
runtime, owned = self.runtimes.resolve(LIVE_HELPER_RUNTIME, self.override(kind, name, phase))
|
||||||
|
try:
|
||||||
|
runtime.exec(["builder/bash/run_entry.sh", str(module_dir), str(env_path), phase])
|
||||||
|
finally:
|
||||||
|
if owned:
|
||||||
|
runtime.stop()
|
||||||
|
if not self.runtimes.keep:
|
||||||
|
runtime.rm()
|
||||||
|
|
||||||
|
def build_common_features(self, profile_hint: str) -> None:
|
||||||
|
for feature_name in list_names(self.root / "features"):
|
||||||
|
ctx = self.context("pre-gen", "feature", profile_name=profile_hint, feature_name=feature_name)
|
||||||
|
self.run_python("feature", feature_name, "pre-gen", profile_name=profile_hint, feature_name=feature_name)
|
||||||
|
self.run_generate("feature", feature_name, self.env_file(ctx, feature_artifacts_dir(self.root, feature_name) / "runtime.env"))
|
||||||
|
self.run_python("feature", feature_name, "post-gen", profile_name=profile_hint, feature_name=feature_name)
|
||||||
|
|
||||||
|
def build_base_chain(self, profile_name: str, base_chain: list[tuple[str, object]]) -> None:
|
||||||
|
for base_name, _ in base_chain:
|
||||||
|
ctx = self.context("pre-gen", "base", profile_name=profile_name, base_name=base_name)
|
||||||
|
self.run_python("base", base_name, "pre-gen", profile_name=profile_name, base_name=base_name)
|
||||||
|
self.run_generate("base", base_name, self.env_file(ctx, base_artifacts_dir(self.root, base_name) / "runtime.env"))
|
||||||
|
self.run_python("base", base_name, "post-gen", profile_name=profile_name, base_name=base_name)
|
||||||
|
|
||||||
|
def configure_profile(self, profile_name: str, profile, base_chain: list[tuple[str, object]]) -> None:
|
||||||
|
clear_directory_contents(self.root / "live")
|
||||||
|
ensure_live_structure(self.root / "live")
|
||||||
|
save_profile_metadata(profile_artifacts_dir(self.root, profile_name) / "profile.json", profile_name, profile, profile.base, load_module_spec(self.root, "base", profile.base), base_chain)
|
||||||
|
self.runtimes.defaults[LIVE_HELPER_RUNTIME].exec(["builder/bash/run_profile_config.sh", str(self.env_file(self.context("config", "profile", profile_name=profile_name), profile_artifacts_dir(self.root, profile_name) / "profile-config.env"))])
|
||||||
|
apply_profile_common_configuration(self.root, self.root / "live", profile_name, profile)
|
||||||
|
for base_name, _ in base_chain:
|
||||||
|
inject_module_resources(base_dir(self.root, base_name), self.root / "live", base_name)
|
||||||
|
|
||||||
|
def inject_features(self, profile_name: str, base_name: str, feature_names: Iterable[str]) -> None:
|
||||||
|
pre = self.context("pre-feature", "base", profile_name=profile_name, base_name=base_name)
|
||||||
|
pre_env = self.env_file(pre, base_artifacts_dir(self.root, base_name) / "pre-feature.env")
|
||||||
|
self.run_python("base", base_name, "pre-feature", profile_name=profile_name, base_name=base_name)
|
||||||
|
self.run_shell("base", base_name, "pre-feature", pre_env)
|
||||||
|
for feature_name in feature_names:
|
||||||
|
save_feature_metadata(profile_artifacts_dir(self.root, profile_name) / "features" / f"{feature_name}.json", feature_name, load_module_spec(self.root, "feature", feature_name))
|
||||||
|
pre = self.context("pre-inj", "feature", profile_name=profile_name, base_name=base_name, feature_name=feature_name)
|
||||||
|
pre_env = self.env_file(pre, feature_artifacts_dir(self.root, feature_name) / "pre-inj.env")
|
||||||
|
self.run_python("feature", feature_name, "pre-inj", profile_name=profile_name, base_name=base_name, feature_name=feature_name)
|
||||||
|
self.run_shell("feature", feature_name, "pre-inj", pre_env)
|
||||||
|
inject_module_resources(feature_dir(self.root, feature_name), self.root / "live", feature_name)
|
||||||
|
post = self.context("post-inj", "feature", profile_name=profile_name, base_name=base_name, feature_name=feature_name)
|
||||||
|
post_env = self.env_file(post, feature_artifacts_dir(self.root, feature_name) / "post-inj.env")
|
||||||
|
self.run_shell("feature", feature_name, "post-inj", post_env)
|
||||||
|
self.run_python("feature", feature_name, "post-inj", profile_name=profile_name, base_name=base_name, feature_name=feature_name)
|
||||||
|
post = self.context("post-feature", "base", profile_name=profile_name, base_name=base_name)
|
||||||
|
post_env = self.env_file(post, base_artifacts_dir(self.root, base_name) / "post-feature.env")
|
||||||
|
self.run_python("base", base_name, "post-feature", profile_name=profile_name, base_name=base_name)
|
||||||
|
self.run_shell("base", base_name, "post-feature", post_env)
|
||||||
|
|
||||||
|
def finalize_profile(self, profile_name: str) -> None:
|
||||||
|
profile_pre_build(self.root / "live", profile_name)
|
||||||
|
build_env = self.env_file(self.context("build", "profile", profile_name=profile_name), profile_artifacts_dir(self.root, profile_name) / "profile-build.env")
|
||||||
|
self.runtimes.defaults[LIVE_HELPER_RUNTIME].exec(["builder/bash/run_profile_build.sh", str(build_env)])
|
||||||
|
profile_finalize(self.root, profile_name)
|
||||||
|
|
||||||
|
def build_profile(self, profile_name: str) -> None:
|
||||||
|
profile = load_profile(self.root, profile_name)
|
||||||
|
base_chain = load_base_chain(self.root, profile.base)
|
||||||
|
self.build_base_chain(profile_name, base_chain)
|
||||||
|
self.configure_profile(profile_name, profile, base_chain)
|
||||||
|
self.inject_features(profile_name, profile.base, profile.features)
|
||||||
|
self.finalize_profile(profile_name)
|
||||||
|
|
||||||
|
def run(self, all_profiles: bool, profile_name: str = "") -> None:
|
||||||
|
self.runtimes.start()
|
||||||
|
try:
|
||||||
|
self.validate()
|
||||||
|
self.build_common_features(profile_name or "demo")
|
||||||
|
for name in (list_names(self.root / "profiles") if all_profiles else [profile_name]):
|
||||||
|
self.build_profile(name)
|
||||||
|
finally:
|
||||||
|
self.runtimes.close()
|
||||||
|
|
||||||
|
|
||||||
|
def parser() -> argparse.ArgumentParser:
|
||||||
|
p = argparse.ArgumentParser(description="RetroDebian orchestrator")
|
||||||
|
sub = p.add_subparsers(dest="command", required=True)
|
||||||
|
sub.add_parser("validate")
|
||||||
|
runp = sub.add_parser("run")
|
||||||
|
grp = runp.add_mutually_exclusive_group(required=True)
|
||||||
|
grp.add_argument("--profile")
|
||||||
|
grp.add_argument("--all-profiles", action="store_true")
|
||||||
|
for runtime in (ORCHESTRATOR_RUNTIME, PACKAGE_BUILDER_RUNTIME, LIVE_HELPER_RUNTIME):
|
||||||
|
opt = runtime.replace("-", "_")
|
||||||
|
runp.add_argument(f"--{opt}-image", default="")
|
||||||
|
runp.add_argument(f"--{opt}-dockerfile", default=DEFAULT_RUNTIME_DOCKERFILES[runtime])
|
||||||
|
runp.add_argument(f"--{opt}-context", default=".")
|
||||||
|
return p
|
||||||
|
|
||||||
|
|
||||||
|
def main() -> int:
|
||||||
|
args = parser().parse_args()
|
||||||
|
root = root_dir()
|
||||||
|
if args.command == "validate":
|
||||||
|
Orchestrator(root, RuntimePool(root, {
|
||||||
|
ORCHESTRATOR_RUNTIME: RuntimeConfig(image="noop"),
|
||||||
|
PACKAGE_BUILDER_RUNTIME: RuntimeConfig(image="noop"),
|
||||||
|
LIVE_HELPER_RUNTIME: RuntimeConfig(image="noop"),
|
||||||
|
}, keep=True)).validate()
|
||||||
|
return 0
|
||||||
|
runtimes = RuntimePool(root, {
|
||||||
|
ORCHESTRATOR_RUNTIME: RuntimeConfig(args.orchestrator_image, args.orchestrator_dockerfile, args.orchestrator_context),
|
||||||
|
PACKAGE_BUILDER_RUNTIME: RuntimeConfig(args.package_builder_image, args.package_builder_dockerfile, args.package_builder_context),
|
||||||
|
LIVE_HELPER_RUNTIME: RuntimeConfig(args.live_helper_image, args.live_helper_dockerfile, args.live_helper_context, True),
|
||||||
|
})
|
||||||
|
Orchestrator(root, runtimes).run(args.all_profiles, args.profile or "")
|
||||||
|
return 0
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
raise SystemExit(main())
|
||||||
9
builder/py/retrobuilder/__init__.py
Normal file
9
builder/py/retrobuilder/__init__.py
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
__all__ = [
|
||||||
|
'context',
|
||||||
|
'entrypoints',
|
||||||
|
'envfile',
|
||||||
|
'loader',
|
||||||
|
'model',
|
||||||
|
'operations',
|
||||||
|
'paths',
|
||||||
|
]
|
||||||
117
builder/py/retrobuilder/context.py
Normal file
117
builder/py/retrobuilder/context.py
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from dataclasses import dataclass, field
|
||||||
|
from pathlib import Path
|
||||||
|
from typing import Any, Mapping
|
||||||
|
|
||||||
|
|
||||||
|
def _norm(name: str) -> str:
|
||||||
|
return "".join(ch if ch.isalnum() else "_" for ch in name.upper())
|
||||||
|
|
||||||
|
|
||||||
|
class Node(dict):
|
||||||
|
__getattr__ = dict.get
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def wrap(cls, value: Any) -> Any:
|
||||||
|
if isinstance(value, dict):
|
||||||
|
return cls({k: cls.wrap(v) for k, v in value.items()})
|
||||||
|
if isinstance(value, (list, tuple)):
|
||||||
|
return [cls.wrap(v) for v in value]
|
||||||
|
return value
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class BuildContext:
|
||||||
|
project_root: Path
|
||||||
|
live_dir: Path
|
||||||
|
artifacts_root: Path
|
||||||
|
phase: str
|
||||||
|
kind: str
|
||||||
|
name: str
|
||||||
|
profile_name: str = ""
|
||||||
|
base_name: str = ""
|
||||||
|
feature_name: str = ""
|
||||||
|
profile: Mapping[str, Any] = field(default_factory=dict)
|
||||||
|
base: Mapping[str, Any] = field(default_factory=dict)
|
||||||
|
features: Mapping[str, Mapping[str, Any]] = field(default_factory=dict)
|
||||||
|
|
||||||
|
def __post_init__(self) -> None:
|
||||||
|
object.__setattr__(self, "profile", Node.wrap(dict(self.profile)))
|
||||||
|
object.__setattr__(self, "base", Node.wrap(dict(self.base)))
|
||||||
|
object.__setattr__(self, "features", {k: Node.wrap(dict(v)) for k, v in self.features.items()})
|
||||||
|
|
||||||
|
def to_env(self) -> dict[str, str]:
|
||||||
|
env = {
|
||||||
|
"PROJECT_ROOT": str(self.project_root),
|
||||||
|
"LIVE_DIR": str(self.live_dir),
|
||||||
|
"ARTIFACTS_ROOT": str(self.artifacts_root),
|
||||||
|
"PHASE": self.phase,
|
||||||
|
"CURRENT_KIND": self.kind,
|
||||||
|
"CURRENT_NAME": self.name,
|
||||||
|
"PROFILE_NAME": self.profile_name,
|
||||||
|
"BASE_NAME": self.base_name,
|
||||||
|
"FEATURE_NAME": self.feature_name,
|
||||||
|
"FEATURE_NAMES": "|".join(self.features.keys()),
|
||||||
|
}
|
||||||
|
env.update(_flatten("PROFILE", self.profile))
|
||||||
|
env.update(_flatten("BASE", self.base))
|
||||||
|
for feat_name, feat_cfg in self.features.items():
|
||||||
|
env.update(_flatten(f"FEAT__{_norm(feat_name)}", feat_cfg))
|
||||||
|
return env
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def from_env(cls, env: Mapping[str, str]) -> "BuildContext":
|
||||||
|
feature_names = [x for x in env.get("FEATURE_NAMES", "").split("|") if x]
|
||||||
|
profile = _inflate("PROFILE", env)
|
||||||
|
base = _inflate("BASE", env)
|
||||||
|
features = {name: _inflate(f"FEAT__{_norm(name)}", env) for name in feature_names}
|
||||||
|
return cls(
|
||||||
|
project_root=Path(env["PROJECT_ROOT"]),
|
||||||
|
live_dir=Path(env["LIVE_DIR"]),
|
||||||
|
artifacts_root=Path(env["ARTIFACTS_ROOT"]),
|
||||||
|
phase=env["PHASE"],
|
||||||
|
kind=env["CURRENT_KIND"],
|
||||||
|
name=env["CURRENT_NAME"],
|
||||||
|
profile_name=env.get("PROFILE_NAME", ""),
|
||||||
|
base_name=env.get("BASE_NAME", ""),
|
||||||
|
feature_name=env.get("FEATURE_NAME", ""),
|
||||||
|
profile=profile,
|
||||||
|
base=base,
|
||||||
|
features=features,
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
def _stringify(value: Any) -> str:
|
||||||
|
if isinstance(value, bool):
|
||||||
|
return "True" if value else "False"
|
||||||
|
if value is None:
|
||||||
|
return ""
|
||||||
|
if isinstance(value, (list, tuple)):
|
||||||
|
return "|".join(_stringify(v) for v in value)
|
||||||
|
return str(value)
|
||||||
|
|
||||||
|
|
||||||
|
def _flatten(prefix: str, data: Mapping[str, Any]) -> dict[str, str]:
|
||||||
|
out: dict[str, str] = {}
|
||||||
|
for key, value in data.items():
|
||||||
|
name = f"{prefix}__{_norm(str(key))}"
|
||||||
|
if isinstance(value, dict):
|
||||||
|
out.update(_flatten(name, value))
|
||||||
|
else:
|
||||||
|
out[name] = _stringify(value)
|
||||||
|
return out
|
||||||
|
|
||||||
|
|
||||||
|
def _inflate(prefix: str, env: Mapping[str, str]) -> dict[str, Any]:
|
||||||
|
root: dict[str, Any] = {}
|
||||||
|
marker = f"{prefix}__"
|
||||||
|
for key, value in env.items():
|
||||||
|
if not key.startswith(marker):
|
||||||
|
continue
|
||||||
|
parts = key[len(marker):].split("__")
|
||||||
|
node = root
|
||||||
|
for part in parts[:-1]:
|
||||||
|
node = node.setdefault(part.lower(), {})
|
||||||
|
node[parts[-1].lower()] = value
|
||||||
|
return root
|
||||||
38
builder/py/retrobuilder/entrypoints.py
Normal file
38
builder/py/retrobuilder/entrypoints.py
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import os
|
||||||
|
import sys
|
||||||
|
from abc import ABC
|
||||||
|
|
||||||
|
from retrobuilder.context import BuildContext
|
||||||
|
|
||||||
|
|
||||||
|
class BaseEntry(ABC):
|
||||||
|
def pre_gen(self, ctx: BuildContext) -> None: return None
|
||||||
|
def post_gen(self, ctx: BuildContext) -> None: return None
|
||||||
|
def pre_feature(self, ctx: BuildContext) -> None: return None
|
||||||
|
def post_feature(self, ctx: BuildContext) -> None: return None
|
||||||
|
|
||||||
|
|
||||||
|
class FeatureEntry(ABC):
|
||||||
|
def pre_gen(self, ctx: BuildContext) -> None: return None
|
||||||
|
def post_gen(self, ctx: BuildContext) -> None: return None
|
||||||
|
def pre_inj(self, ctx: BuildContext) -> None: return None
|
||||||
|
def post_inj(self, ctx: BuildContext) -> None: return None
|
||||||
|
|
||||||
|
|
||||||
|
def cli_dispatch(spec, entry_cls) -> int:
|
||||||
|
if len(sys.argv) < 2:
|
||||||
|
print("Usage: entry.py <spec|phase>", file=sys.stderr)
|
||||||
|
return 2
|
||||||
|
command = sys.argv[1]
|
||||||
|
if command == "spec":
|
||||||
|
print(spec.to_dict())
|
||||||
|
return 0
|
||||||
|
entry = entry_cls()
|
||||||
|
method = getattr(entry, command.replace("-", "_"), None)
|
||||||
|
if method is None:
|
||||||
|
print(f"Unsupported phase: {command}", file=sys.stderr)
|
||||||
|
return 2
|
||||||
|
method(BuildContext.from_env(os.environ))
|
||||||
|
return 0
|
||||||
15
builder/py/retrobuilder/envfile.py
Normal file
15
builder/py/retrobuilder/envfile.py
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from pathlib import Path
|
||||||
|
from typing import Mapping
|
||||||
|
|
||||||
|
|
||||||
|
def _escape(value: str) -> str:
|
||||||
|
value = value.replace('\\', '\\\\').replace('"', '\\"')
|
||||||
|
return f'"{value}"'
|
||||||
|
|
||||||
|
def write_env_file(path: Path, values: Mapping[str, str]) -> None:
|
||||||
|
path.parent.mkdir(parents=True, exist_ok=True)
|
||||||
|
with path.open('w', encoding='utf-8') as handle:
|
||||||
|
for key in sorted(values):
|
||||||
|
handle.write(f'{key}={_escape(str(values[key]))}\n')
|
||||||
92
builder/py/retrobuilder/loader.py
Normal file
92
builder/py/retrobuilder/loader.py
Normal file
@@ -0,0 +1,92 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import importlib.util
|
||||||
|
from pathlib import Path
|
||||||
|
from types import ModuleType
|
||||||
|
from typing import Any
|
||||||
|
from dataclasses import asdict
|
||||||
|
|
||||||
|
from retrobuilder.model import BaseSpec, FeatureSpec, ProfileSpec
|
||||||
|
from retrobuilder.paths import base_dir, feature_dir, profile_file
|
||||||
|
|
||||||
|
|
||||||
|
def _load_module(path: Path, name: str) -> ModuleType:
|
||||||
|
spec = importlib.util.spec_from_file_location(name, path)
|
||||||
|
if spec is None or spec.loader is None:
|
||||||
|
raise RuntimeError(f"Cannot load module from {path}")
|
||||||
|
module = importlib.util.module_from_spec(spec)
|
||||||
|
spec.loader.exec_module(module)
|
||||||
|
return module
|
||||||
|
|
||||||
|
|
||||||
|
def load_profile(root: Path, name: str) -> ProfileSpec:
|
||||||
|
module = _load_module(profile_file(root, name), f"profile_{name}")
|
||||||
|
profile = getattr(module, "PROFILE", None)
|
||||||
|
if not isinstance(profile, ProfileSpec):
|
||||||
|
raise TypeError(f"profiles/{name}.py must define PROFILE as ProfileSpec")
|
||||||
|
return profile
|
||||||
|
|
||||||
|
|
||||||
|
def _load_module_py(root: Path, kind: str, name: str) -> ModuleType:
|
||||||
|
path = (base_dir if kind == "base" else feature_dir)(root, name) / "entry.py"
|
||||||
|
return _load_module(path, f"{kind}_{name}")
|
||||||
|
|
||||||
|
|
||||||
|
def load_module_spec(root: Path, kind: str, name: str):
|
||||||
|
module = _load_module_py(root, kind, name)
|
||||||
|
spec = getattr(module, "SPEC", None)
|
||||||
|
expected = BaseSpec if kind == "base" else FeatureSpec
|
||||||
|
if not isinstance(spec, expected):
|
||||||
|
raise TypeError(f"{kind}s/{name}/entry.py must define SPEC as {expected.__name__}")
|
||||||
|
return spec
|
||||||
|
|
||||||
|
|
||||||
|
def load_module_entry(root: Path, kind: str, name: str):
|
||||||
|
module = _load_module_py(root, kind, name)
|
||||||
|
entry = getattr(module, "Entry", None)
|
||||||
|
if entry is None:
|
||||||
|
raise TypeError(f"{kind}s/{name}/entry.py must define Entry")
|
||||||
|
return entry
|
||||||
|
|
||||||
|
|
||||||
|
def load_base_chain(root: Path, name: str):
|
||||||
|
return load_module_chain(root, "base", name)
|
||||||
|
|
||||||
|
|
||||||
|
def load_module_chain(root: Path, kind: str, name: str):
|
||||||
|
chain: list[tuple[str, Any]] = []
|
||||||
|
seen: set[str] = set()
|
||||||
|
current = name
|
||||||
|
while current:
|
||||||
|
if current in seen:
|
||||||
|
raise RuntimeError(f"{kind} inheritance loop detected at {current}")
|
||||||
|
seen.add(current)
|
||||||
|
spec = load_module_spec(root, kind, current)
|
||||||
|
chain.append((current, spec))
|
||||||
|
current = spec.parent or ""
|
||||||
|
chain.reverse()
|
||||||
|
return chain
|
||||||
|
|
||||||
|
|
||||||
|
def resolve_module_config(root: Path, kind: str, name: str) -> dict[str, Any]:
|
||||||
|
merged: dict[str, Any] = {}
|
||||||
|
for _name, spec in load_module_chain(root, kind, name):
|
||||||
|
data = asdict(spec)
|
||||||
|
|
||||||
|
data.pop("description", None)
|
||||||
|
data.pop("parent", None)
|
||||||
|
data.pop("docker_overrides", None)
|
||||||
|
extra = data.pop("config", {}) or {}
|
||||||
|
|
||||||
|
merged.update(data)
|
||||||
|
merged.update(extra)
|
||||||
|
|
||||||
|
return merged
|
||||||
|
|
||||||
|
|
||||||
|
def resolve_module_docker_override(root: Path, kind: str, name: str, phase: str):
|
||||||
|
resolved = None
|
||||||
|
for _name, spec in load_module_chain(root, kind, name):
|
||||||
|
if phase in spec.docker_overrides:
|
||||||
|
resolved = spec.docker_overrides[phase]
|
||||||
|
return resolved
|
||||||
66
builder/py/retrobuilder/model.py
Normal file
66
builder/py/retrobuilder/model.py
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from dataclasses import asdict, dataclass, field
|
||||||
|
from typing import Any, Mapping
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class DockerStageSpec:
|
||||||
|
image: str = ""
|
||||||
|
dockerfile: str = ""
|
||||||
|
docker_context: str = "."
|
||||||
|
|
||||||
|
def is_set(self) -> bool:
|
||||||
|
return bool(self.image or self.dockerfile)
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class ModuleSpec:
|
||||||
|
description: str = ""
|
||||||
|
parent: str = ""
|
||||||
|
docker_overrides: Mapping[str, DockerStageSpec] = field(default_factory=dict)
|
||||||
|
config: Mapping[str, Any] = field(default_factory=dict)
|
||||||
|
|
||||||
|
def to_dict(self) -> dict[str, Any]:
|
||||||
|
return asdict(self)
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class BaseSpec(ModuleSpec):
|
||||||
|
arch: str = "i386"
|
||||||
|
distribution: str = "etch"
|
||||||
|
apt: str = "apt"
|
||||||
|
apt_options: str = "--yes --force-yes"
|
||||||
|
apt_secure: bool = False
|
||||||
|
apt_recommends: bool = False
|
||||||
|
repo_url: str = "http://archive.debian.org/debian/"
|
||||||
|
security_repo_url: str = "http://archive.debian.org/debian-security/"
|
||||||
|
linux_packages: str = "squashfs-modules linux-image"
|
||||||
|
packages_lists: str = ""
|
||||||
|
binary_images: str = "iso"
|
||||||
|
iso_application: str = "RetroDebian"
|
||||||
|
hostname: str = "RetroDebian"
|
||||||
|
bootappend_live: str = ""
|
||||||
|
union_filesystem: str = "unionfs"
|
||||||
|
username: str = "bob"
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class FeatureSpec(ModuleSpec):
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
@dataclass(frozen=True)
|
||||||
|
class ProfileSpec:
|
||||||
|
base: str
|
||||||
|
features: tuple[str, ...] = ()
|
||||||
|
edition: str = ""
|
||||||
|
description: str = ""
|
||||||
|
splash: str = ""
|
||||||
|
config: Mapping[str, Any] = field(default_factory=dict)
|
||||||
|
|
||||||
|
def __post_init__(self) -> None:
|
||||||
|
if not isinstance(self.features, tuple):
|
||||||
|
object.__setattr__(self, "features", tuple(self.features))
|
||||||
|
|
||||||
|
def to_dict(self) -> dict[str, Any]:
|
||||||
|
return asdict(self)
|
||||||
127
builder/py/retrobuilder/operations.py
Normal file
127
builder/py/retrobuilder/operations.py
Normal file
@@ -0,0 +1,127 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import json
|
||||||
|
import shutil
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
from retrobuilder.model import BaseSpec, FeatureSpec, ProfileSpec
|
||||||
|
|
||||||
|
|
||||||
|
LIVE_DIR_STRUCTURE = (
|
||||||
|
'config/chroot_local-packageslists',
|
||||||
|
'config/chroot_local-packages',
|
||||||
|
'config/chroot_local-includes',
|
||||||
|
'config/chroot_local-hooks',
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
def ensure_live_structure(live_dir: Path) -> None:
|
||||||
|
for relative in LIVE_DIR_STRUCTURE:
|
||||||
|
(live_dir / relative).mkdir(parents=True, exist_ok=True)
|
||||||
|
|
||||||
|
|
||||||
|
def clear_directory_contents(path: Path) -> None:
|
||||||
|
path.mkdir(parents=True, exist_ok=True)
|
||||||
|
for child in path.iterdir():
|
||||||
|
if child.name == '.gitkeep':
|
||||||
|
continue
|
||||||
|
if child.is_dir() and not child.is_symlink():
|
||||||
|
shutil.rmtree(child)
|
||||||
|
else:
|
||||||
|
child.unlink()
|
||||||
|
|
||||||
|
|
||||||
|
def copy_tree_contents(src: Path, dst: Path) -> None:
|
||||||
|
if not src.exists():
|
||||||
|
return
|
||||||
|
dst.mkdir(parents=True, exist_ok=True)
|
||||||
|
for child in src.iterdir():
|
||||||
|
target = dst / child.name
|
||||||
|
if child.is_dir():
|
||||||
|
shutil.copytree(child, target, dirs_exist_ok=True)
|
||||||
|
else:
|
||||||
|
shutil.copy2(child, target)
|
||||||
|
|
||||||
|
|
||||||
|
def copy_glob(src_dir: Path, pattern: str, dst_dir: Path, prefix: str = '') -> None:
|
||||||
|
if not src_dir.exists():
|
||||||
|
return
|
||||||
|
dst_dir.mkdir(parents=True, exist_ok=True)
|
||||||
|
for src in sorted(src_dir.glob(pattern)):
|
||||||
|
if src.is_dir():
|
||||||
|
continue
|
||||||
|
name = f'{prefix}{src.name}' if prefix else src.name
|
||||||
|
shutil.copy2(src, dst_dir / name)
|
||||||
|
|
||||||
|
|
||||||
|
def save_json(path: Path, payload: dict) -> None:
|
||||||
|
path.parent.mkdir(parents=True, exist_ok=True)
|
||||||
|
path.write_text(json.dumps(payload, indent=2, sort_keys=True) + '\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
def save_profile_metadata(
|
||||||
|
path: Path,
|
||||||
|
profile_name: str,
|
||||||
|
profile: ProfileSpec,
|
||||||
|
base_name: str,
|
||||||
|
base: BaseSpec,
|
||||||
|
base_chain: list[tuple[str, BaseSpec]] | None = None,
|
||||||
|
) -> None:
|
||||||
|
save_json(path, {
|
||||||
|
'profile_name': profile_name,
|
||||||
|
'profile': profile.to_dict(),
|
||||||
|
'base_name': base_name,
|
||||||
|
'base': base.to_dict(),
|
||||||
|
'base_chain': [
|
||||||
|
{'name': item_name, 'spec': item_spec.to_dict()}
|
||||||
|
for item_name, item_spec in (base_chain or [(base_name, base)])
|
||||||
|
],
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
def save_feature_metadata(path: Path, feature_name: str, feature: FeatureSpec) -> None:
|
||||||
|
save_json(path, {'feature_name': feature_name, 'feature': feature.to_dict()})
|
||||||
|
|
||||||
|
|
||||||
|
def apply_profile_common_configuration(root: Path, live_dir: Path, profile_name: str, profile: ProfileSpec) -> None:
|
||||||
|
ensure_live_structure(live_dir)
|
||||||
|
notes_dir = live_dir / 'builder-notes'
|
||||||
|
notes_dir.mkdir(parents=True, exist_ok=True)
|
||||||
|
notes = [
|
||||||
|
f'profile={profile_name}',
|
||||||
|
f'base={profile.base}',
|
||||||
|
f'features={"|".join(profile.features)}',
|
||||||
|
]
|
||||||
|
if profile.splash:
|
||||||
|
splash_src = root / profile.splash
|
||||||
|
if splash_src.exists():
|
||||||
|
splash_dst = notes_dir / splash_src.name
|
||||||
|
shutil.copy2(splash_src, splash_dst)
|
||||||
|
notes.append(f'splash={profile.splash}')
|
||||||
|
(notes_dir / 'profile-common.txt').write_text('\n'.join(notes) + '\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
def inject_module_resources(module_dir: Path, live_dir: Path, prefix: str) -> None:
|
||||||
|
copy_tree_contents(module_dir / 'packageslists', live_dir / 'config' / 'chroot_local-packageslists')
|
||||||
|
copy_tree_contents(module_dir / 'packages', live_dir / 'config' / 'chroot_local-packages')
|
||||||
|
copy_tree_contents(module_dir / 'chroot', live_dir / 'config' / 'chroot_local-includes')
|
||||||
|
copy_glob(module_dir / 'hooks', '*.sh', live_dir / 'config' / 'chroot_local-hooks', prefix=f'{prefix}_')
|
||||||
|
|
||||||
|
|
||||||
|
def profile_pre_build(live_dir: Path, profile_name: str) -> None:
|
||||||
|
marker = live_dir / 'builder-notes' / 'pre-build.txt'
|
||||||
|
marker.parent.mkdir(parents=True, exist_ok=True)
|
||||||
|
marker.write_text(f'pre-build profile={profile_name}\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
def profile_finalize(root: Path, profile_name: str) -> None:
|
||||||
|
live_dir = root / 'live'
|
||||||
|
out_dir = root / 'artifacts' / 'profiles' / profile_name / 'final'
|
||||||
|
out_dir.mkdir(parents=True, exist_ok=True)
|
||||||
|
summary = out_dir / 'summary.txt'
|
||||||
|
summary.write_text(
|
||||||
|
'Profile finalization complete.\n'
|
||||||
|
f'profile={profile_name}\n'
|
||||||
|
f'live_exists={live_dir.exists()}\n',
|
||||||
|
encoding='utf-8',
|
||||||
|
)
|
||||||
35
builder/py/retrobuilder/paths.py
Normal file
35
builder/py/retrobuilder/paths.py
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
|
||||||
|
def project_root_from(start: Path) -> Path:
|
||||||
|
current = start.resolve()
|
||||||
|
for candidate in (current, *current.parents):
|
||||||
|
if (candidate / 'builder' / 'py').exists() and (candidate / 'profiles').exists():
|
||||||
|
return candidate
|
||||||
|
raise RuntimeError(f'Could not locate project root from {start}')
|
||||||
|
|
||||||
|
|
||||||
|
def feature_dir(root: Path, name: str) -> Path:
|
||||||
|
return root / 'features' / name
|
||||||
|
|
||||||
|
|
||||||
|
def base_dir(root: Path, name: str) -> Path:
|
||||||
|
return root / 'bases' / name
|
||||||
|
|
||||||
|
|
||||||
|
def profile_file(root: Path, name: str) -> Path:
|
||||||
|
return root / 'profiles' / f'{name}.py'
|
||||||
|
|
||||||
|
|
||||||
|
def feature_artifacts_dir(root: Path, name: str) -> Path:
|
||||||
|
return root / 'artifacts' / 'features' / name
|
||||||
|
|
||||||
|
|
||||||
|
def base_artifacts_dir(root: Path, name: str) -> Path:
|
||||||
|
return root / 'artifacts' / 'bases' / name
|
||||||
|
|
||||||
|
|
||||||
|
def profile_artifacts_dir(root: Path, name: str) -> Path:
|
||||||
|
return root / 'artifacts' / 'profiles' / name
|
||||||
149
buildglidepkg.sh
149
buildglidepkg.sh
@@ -1,149 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
set -euo pipefail
|
|
||||||
|
|
||||||
FLAVOUR="${1:-cvg}"
|
|
||||||
ARCH="${ARCH:-i386}"
|
|
||||||
OUTDIR="${OUTDIR:-$(pwd)}"
|
|
||||||
|
|
||||||
if [[ "$FLAVOUR" == "sst1" ]]; then
|
|
||||||
GLIDE2_SRC="/usr/src/glide/glide2x/sst1/lib/sst1"
|
|
||||||
GLIDE3_SRC="/usr/src/glide/glide3x/sst1/lib/sst1"
|
|
||||||
elif [[ "$FLAVOUR" == "sst96" ]]; then
|
|
||||||
GLIDE2_SRC="/usr/src/glide/glide2x/sst1/lib/sst96"
|
|
||||||
GLIDE3_SRC="/usr/src/glide/glide3x/sst1/lib/sst96"
|
|
||||||
else
|
|
||||||
GLIDE2_SRC="/usr/src/glide/glide2x/${FLAVOUR}/lib"
|
|
||||||
GLIDE3_SRC="/usr/src/glide/glide3x/${FLAVOUR}/lib"
|
|
||||||
fi
|
|
||||||
|
|
||||||
PKG2="libglide2-${FLAVOUR}"
|
|
||||||
PKG3="libglide3-${FLAVOUR}"
|
|
||||||
|
|
||||||
BUILDROOT="$(pwd)/pkg-glide"
|
|
||||||
rm -rf "${BUILDROOT}"
|
|
||||||
mkdir -p "${BUILDROOT}" "${OUTDIR}"
|
|
||||||
|
|
||||||
find_unique_regular_file() {
|
|
||||||
local dir="$1"
|
|
||||||
local pattern="$2"
|
|
||||||
local matches=()
|
|
||||||
|
|
||||||
while IFS= read -r -d '' f; do
|
|
||||||
matches+=("$f")
|
|
||||||
done < <(find "$dir" -maxdepth 1 -type f -name "$pattern" -print0)
|
|
||||||
|
|
||||||
if [[ ${#matches[@]} -eq 0 ]]; then
|
|
||||||
echo "ERROR: no regular file matching '${pattern}' found in '${dir}'" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ${#matches[@]} -ne 1 ]]; then
|
|
||||||
echo "ERROR: multiple regular files matching '${pattern}' found in '${dir}':" >&2
|
|
||||||
printf ' %s\n' "${matches[@]}" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
basename "${matches[0]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
extract_glide2_pkg_version() {
|
|
||||||
local real_so="$1"
|
|
||||||
local ver="${real_so#libglide.so.}"
|
|
||||||
echo "${ver}-1"
|
|
||||||
}
|
|
||||||
|
|
||||||
extract_glide3_pkg_version() {
|
|
||||||
local real_so="$1"
|
|
||||||
local ver="${real_so#libglide3.so.}"
|
|
||||||
echo "${ver}-1"
|
|
||||||
}
|
|
||||||
|
|
||||||
build_pkg_glide2() {
|
|
||||||
local PKGDIR="${BUILDROOT}/${PKG2}"
|
|
||||||
local REAL_SO
|
|
||||||
local STATIC_A="libglide.a"
|
|
||||||
local PKG_VERSION
|
|
||||||
|
|
||||||
mkdir -p "${PKGDIR}/DEBIAN" "${PKGDIR}/usr/lib"
|
|
||||||
|
|
||||||
REAL_SO="$(find_unique_regular_file "${GLIDE2_SRC}" 'libglide.so.2.*')"
|
|
||||||
PKG_VERSION="$(extract_glide2_pkg_version "${REAL_SO}")"
|
|
||||||
|
|
||||||
ls -al "${GLIDE2_SRC}/"
|
|
||||||
|
|
||||||
cp -a "${GLIDE2_SRC}/${REAL_SO}" "${PKGDIR}/usr/lib/"
|
|
||||||
cp -a "${GLIDE2_SRC}/${STATIC_A}" "${PKGDIR}/usr/lib/"
|
|
||||||
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide.so.2"
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide.so"
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide2x.so"
|
|
||||||
|
|
||||||
cat > "${PKGDIR}/DEBIAN/control" <<EOF
|
|
||||||
Package: ${PKG2}
|
|
||||||
Version: ${PKG_VERSION}
|
|
||||||
Section: libs
|
|
||||||
Priority: optional
|
|
||||||
Architecture: ${ARCH}
|
|
||||||
Maintainer: RetroDebian <root@retrodebian.local>
|
|
||||||
Provides: libglide2
|
|
||||||
Conflicts: libglide2, libglide2-sst1, libglide2-cvg, libglide2-h3, libglide2-h5
|
|
||||||
Replaces: libglide2, libglide2-sst1, libglide2-cvg, libglide2-h3, libglide2-h5
|
|
||||||
Description: Glide 2 libraries for 3Dfx ${FLAVOUR}
|
|
||||||
Glide 2 runtime and static libraries for the 3Dfx ${FLAVOUR} family.
|
|
||||||
EOF
|
|
||||||
|
|
||||||
sed -i "s/, ${PKG2}//" "${PKGDIR}/DEBIAN/control"
|
|
||||||
|
|
||||||
dpkg-deb --build "${PKGDIR}" "${OUTDIR}/${PKG2}_${PKG_VERSION}_${ARCH}.deb"
|
|
||||||
}
|
|
||||||
|
|
||||||
build_pkg_glide3() {
|
|
||||||
local PKGDIR="${BUILDROOT}/${PKG3}"
|
|
||||||
local REAL_SO
|
|
||||||
local STATIC_A="libglide3.a"
|
|
||||||
local PKG_VERSION
|
|
||||||
|
|
||||||
mkdir -p "${PKGDIR}/DEBIAN" "${PKGDIR}/usr/lib"
|
|
||||||
|
|
||||||
REAL_SO="$(find_unique_regular_file "${GLIDE3_SRC}" 'libglide3.so.3.*')"
|
|
||||||
PKG_VERSION="$(extract_glide3_pkg_version "${REAL_SO}")"
|
|
||||||
|
|
||||||
ls -al "${GLIDE3_SRC}/"
|
|
||||||
|
|
||||||
cp -a "${GLIDE3_SRC}/${REAL_SO}" "${PKGDIR}/usr/lib/"
|
|
||||||
cp -a "${GLIDE3_SRC}/${STATIC_A}" "${PKGDIR}/usr/lib/"
|
|
||||||
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide3.so.3"
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide3.so"
|
|
||||||
ln -s "${REAL_SO}" "${PKGDIR}/usr/lib/libglide3x.so"
|
|
||||||
|
|
||||||
cat > "${PKGDIR}/DEBIAN/control" <<EOF
|
|
||||||
Package: ${PKG3}
|
|
||||||
Version: ${PKG_VERSION}
|
|
||||||
Section: libs
|
|
||||||
Priority: optional
|
|
||||||
Architecture: ${ARCH}
|
|
||||||
Maintainer: RetroDebian <root@retrodebian.local>
|
|
||||||
Provides: libglide3
|
|
||||||
Conflicts: libglide3, libglide3-sst1, libglide3-cvg, libglide3-h3, libglide3-h5
|
|
||||||
Replaces: libglide3, libglide3-sst1, libglide3-cvg, libglide3-h3, libglide3-h5
|
|
||||||
Description: Glide 3 libraries for 3Dfx ${FLAVOUR}
|
|
||||||
Glide 3 runtime and static libraries for the 3Dfx ${FLAVOUR} family.
|
|
||||||
EOF
|
|
||||||
|
|
||||||
sed -i "s/, ${PKG3}//" "${PKGDIR}/DEBIAN/control"
|
|
||||||
|
|
||||||
dpkg-deb --build "${PKGDIR}" "${OUTDIR}/${PKG3}_${PKG_VERSION}_${ARCH}.deb"
|
|
||||||
}
|
|
||||||
|
|
||||||
build_pkg_glide2
|
|
||||||
build_pkg_glide3
|
|
||||||
|
|
||||||
REAL_SO2="$(find_unique_regular_file "${GLIDE2_SRC}" 'libglide.so.2.*')"
|
|
||||||
REAL_SO3="$(find_unique_regular_file "${GLIDE3_SRC}" 'libglide3.so.3.*')"
|
|
||||||
PKG_VERSION2="$(extract_glide2_pkg_version "${REAL_SO2}")"
|
|
||||||
PKG_VERSION3="$(extract_glide3_pkg_version "${REAL_SO3}")"
|
|
||||||
|
|
||||||
echo "Packages created:"
|
|
||||||
echo " ${OUTDIR}/${PKG2}_${PKG_VERSION2}_${ARCH}.deb"
|
|
||||||
echo " ${OUTDIR}/${PKG3}_${PKG_VERSION3}_${ARCH}.deb"
|
|
||||||
1713
config-kernel
1713
config-kernel
File diff suppressed because it is too large
Load Diff
BIN
deps/theme-AdwaitaDark.tar
vendored
BIN
deps/theme-AdwaitaDark.tar
vendored
Binary file not shown.
70
desktop
70
desktop
@@ -1,70 +0,0 @@
|
|||||||
xserver-xorg
|
|
||||||
xserver-xorg-input-evdev
|
|
||||||
xbase-clients
|
|
||||||
xterm
|
|
||||||
locales
|
|
||||||
gsetroot
|
|
||||||
rxvt-unicode
|
|
||||||
xfonts-base
|
|
||||||
xfonts-100dpi
|
|
||||||
xfonts-75dpi
|
|
||||||
xfonts-scalable
|
|
||||||
xfonts-terminus
|
|
||||||
xfonts-terminus-oblique
|
|
||||||
fluxbox
|
|
||||||
hicolor-icon-theme
|
|
||||||
gnome-icon-theme
|
|
||||||
gtk2-engines
|
|
||||||
menu
|
|
||||||
pcmanfm
|
|
||||||
leafpad
|
|
||||||
dbus
|
|
||||||
hal
|
|
||||||
pmount
|
|
||||||
sudo
|
|
||||||
alsa-base
|
|
||||||
alsa-utils
|
|
||||||
pciutils
|
|
||||||
usbutils
|
|
||||||
psmisc
|
|
||||||
wget
|
|
||||||
curl
|
|
||||||
less
|
|
||||||
unzip
|
|
||||||
zip
|
|
||||||
vim
|
|
||||||
ntp
|
|
||||||
htop
|
|
||||||
libsdl1.2debian
|
|
||||||
libsdl1.2debian-alsa
|
|
||||||
mesa-utils
|
|
||||||
xmms
|
|
||||||
smbclient
|
|
||||||
libopenal0a
|
|
||||||
libxft2
|
|
||||||
cpp
|
|
||||||
inotify-tools
|
|
||||||
xpdf
|
|
||||||
gsfonts-x11
|
|
||||||
gimageview
|
|
||||||
mplayer
|
|
||||||
xarchiver
|
|
||||||
numlockx
|
|
||||||
geany
|
|
||||||
idesk
|
|
||||||
wmnd
|
|
||||||
wmmixer
|
|
||||||
unclutter
|
|
||||||
xdialog
|
|
||||||
smbfs
|
|
||||||
xeji
|
|
||||||
gksu
|
|
||||||
xscreensaver
|
|
||||||
beep
|
|
||||||
xclip
|
|
||||||
xsel
|
|
||||||
linneighborhood
|
|
||||||
mktemp
|
|
||||||
gparted
|
|
||||||
wmcpuload
|
|
||||||
wmmemload
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 690 KiB |
@@ -0,0 +1 @@
|
|||||||
|
sample feature payload
|
||||||
50
features/sample-feature/entry.py
Normal file
50
features/sample-feature/entry.py
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import sys
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
THIS_FILE = Path(__file__).resolve()
|
||||||
|
PROJECT_ROOT = THIS_FILE.parents[2]
|
||||||
|
PY_ROOT = PROJECT_ROOT / 'builder' / 'py'
|
||||||
|
if str(PY_ROOT) not in sys.path:
|
||||||
|
sys.path.insert(0, str(PY_ROOT))
|
||||||
|
|
||||||
|
from retrobuilder.context import BuildContext
|
||||||
|
from retrobuilder.entrypoints import FeatureEntry, cli_dispatch
|
||||||
|
from retrobuilder.model import FeatureSpec
|
||||||
|
|
||||||
|
SPEC = FeatureSpec(
|
||||||
|
description='Sample feature used to validate the V2 builder flow.',
|
||||||
|
docker_overrides={
|
||||||
|
# 'pre-gen': {'image': 'python:3.11-alpine'},
|
||||||
|
# 'post-gen': {'dockerfile': 'features/sample-feature/Dockerfile.python'},
|
||||||
|
# 'pre-inj': {'image': 'retrodebian/custom-lenny:latest'},
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
class Entry(FeatureEntry):
|
||||||
|
def _marker(self, ctx: BuildContext, name: str) -> Path:
|
||||||
|
ctx.artifacts_root.mkdir(parents=True, exist_ok=True)
|
||||||
|
return ctx.artifacts_root / name
|
||||||
|
|
||||||
|
def pre_gen(self, ctx: BuildContext) -> None:
|
||||||
|
self._marker(ctx, 'pre-gen.txt').write_text('sample-feature pre-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def post_gen(self, ctx: BuildContext) -> None:
|
||||||
|
self._marker(ctx, 'post-gen.txt').write_text('sample-feature post-gen\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def pre_inj(self, ctx: BuildContext) -> None:
|
||||||
|
notes = ctx.live_dir / 'builder-notes'
|
||||||
|
notes.mkdir(parents=True, exist_ok=True)
|
||||||
|
(notes / 'feature-pre-inj.txt').write_text('sample-feature pre-inj\n', encoding='utf-8')
|
||||||
|
|
||||||
|
def post_inj(self, ctx: BuildContext) -> None:
|
||||||
|
notes = ctx.live_dir / 'builder-notes'
|
||||||
|
notes.mkdir(parents=True, exist_ok=True)
|
||||||
|
(notes / 'feature-post-inj.txt').write_text('sample-feature post-inj\n', encoding='utf-8')
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
raise SystemExit(cli_dispatch(SPEC, Entry))
|
||||||
17
features/sample-feature/entry.sh
Executable file
17
features/sample-feature/entry.sh
Executable file
@@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
PHASE=${1:-}
|
||||||
|
[ -n "$PHASE" ] || { echo "Usage: entry.sh <phase>" >&2; exit 2; }
|
||||||
|
|
||||||
|
case "$PHASE" in
|
||||||
|
pre-inj|post-inj)
|
||||||
|
mkdir -p "$LIVE_DIR/builder-notes"
|
||||||
|
printf 'sample-feature entry.sh %s
|
||||||
|
' "$PHASE" > "$LIVE_DIR/builder-notes/feature-entry-${PHASE}.txt"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Unsupported feature phase: $PHASE" >&2
|
||||||
|
exit 2
|
||||||
|
;;
|
||||||
|
esac
|
||||||
7
features/sample-feature/generate.sh
Executable file
7
features/sample-feature/generate.sh
Executable file
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
[ -n "${ARTIFACTS_ROOT:-}" ] || { echo "ARTIFACTS_ROOT is required" >&2; exit 2; }
|
||||||
|
mkdir -p "$ARTIFACTS_ROOT/generated"
|
||||||
|
printf 'generated by sample-feature
|
||||||
|
' > "$ARTIFACTS_ROOT/generated/feature-artifact.txt"
|
||||||
4
features/sample-feature/hooks/20-sample-feature.sh
Executable file
4
features/sample-feature/hooks/20-sample-feature.sh
Executable file
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
printf 'sample feature chroot hook
|
||||||
|
' > /tmp/sample-feature-hook.txt
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
placeholder deb artifact for sample feature
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
htop
|
||||||
297
games/ut99/ut
297
games/ut99/ut
@@ -1,297 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
ini_set_key() {
|
|
||||||
local file="$1"
|
|
||||||
local section="$2"
|
|
||||||
local key="$3"
|
|
||||||
local value="$4"
|
|
||||||
local tmp
|
|
||||||
|
|
||||||
tmp="${file}.tmp.$$"
|
|
||||||
|
|
||||||
awk -v section="$section" -v key="$key" -v value="$value" '
|
|
||||||
BEGIN {
|
|
||||||
in_section = 0
|
|
||||||
section_found = 0
|
|
||||||
key_done = 0
|
|
||||||
}
|
|
||||||
|
|
||||||
function flush_missing_key() {
|
|
||||||
if (in_section && !key_done) {
|
|
||||||
print key "=" value
|
|
||||||
key_done = 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/^\[[^]]+\]$/ {
|
|
||||||
if (in_section) {
|
|
||||||
flush_missing_key()
|
|
||||||
in_section = 0
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($0 == "[" section "]") {
|
|
||||||
in_section = 1
|
|
||||||
section_found = 1
|
|
||||||
}
|
|
||||||
|
|
||||||
print
|
|
||||||
next
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
if (in_section && $0 ~ ("^" key "=")) {
|
|
||||||
if (!key_done) {
|
|
||||||
print key "=" value
|
|
||||||
key_done = 1
|
|
||||||
}
|
|
||||||
next
|
|
||||||
}
|
|
||||||
|
|
||||||
print
|
|
||||||
}
|
|
||||||
|
|
||||||
END {
|
|
||||||
if (in_section) {
|
|
||||||
flush_missing_key()
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!section_found) {
|
|
||||||
print "[" section "]"
|
|
||||||
print key "=" value
|
|
||||||
}
|
|
||||||
}' "$file" > "$tmp" && mv "$tmp" "$file"
|
|
||||||
}
|
|
||||||
|
|
||||||
ini_del_key() {
|
|
||||||
local file="$1"
|
|
||||||
local section="$2"
|
|
||||||
local key="$3"
|
|
||||||
local tmp
|
|
||||||
|
|
||||||
tmp="${file}.tmp.$$"
|
|
||||||
|
|
||||||
awk -v section="$section" -v key="$key" '
|
|
||||||
BEGIN {
|
|
||||||
in_section = 0
|
|
||||||
}
|
|
||||||
|
|
||||||
/^\[[^]]+\]$/ {
|
|
||||||
in_section = ($0 == "[" section "]")
|
|
||||||
print
|
|
||||||
next
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
if (in_section && $0 ~ ("^" key "=")) {
|
|
||||||
next
|
|
||||||
}
|
|
||||||
print
|
|
||||||
}' "$file" > "$tmp" && mv "$tmp" "$file"
|
|
||||||
}
|
|
||||||
|
|
||||||
GAME_BINARY="ut-bin"
|
|
||||||
SYSTEM_DIR="System"
|
|
||||||
|
|
||||||
# Additional commandline options for mods etc.
|
|
||||||
CMD_ARGS=()
|
|
||||||
|
|
||||||
# don't use US keyboard layout
|
|
||||||
#NOUSLAYOUT="true"
|
|
||||||
|
|
||||||
resolve_link() {
|
|
||||||
local path target dir
|
|
||||||
path="$1"
|
|
||||||
|
|
||||||
[ -L "$path" ] || return 1
|
|
||||||
|
|
||||||
target="$(LC_ALL=C ls -l "$path" 2>/dev/null)"
|
|
||||||
target="${target##* -> }"
|
|
||||||
|
|
||||||
case "$target" in
|
|
||||||
/*) printf '%s\n' "$target" ;;
|
|
||||||
*)
|
|
||||||
dir="$(dirname "$path")"
|
|
||||||
printf '%s\n' "$dir/$target"
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
}
|
|
||||||
|
|
||||||
LANG=POSIX
|
|
||||||
export LANG
|
|
||||||
script="$0"
|
|
||||||
count=0
|
|
||||||
while [ -L "$script" ]
|
|
||||||
do
|
|
||||||
script="$(resolve_link "$script")"
|
|
||||||
count=$((count + 1))
|
|
||||||
if [ "$count" -gt 100 ]
|
|
||||||
then
|
|
||||||
echo "Too many symbolic links"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
GAME_DIR="$(cd "$(dirname "$script")" && pwd)"
|
|
||||||
GAME_SYSTEM_DIR="${GAME_DIR}/${SYSTEM_DIR}"
|
|
||||||
USER_UT_DIR="${HOME}/.loki/ut/${SYSTEM_DIR}"
|
|
||||||
SYSTEM_DEFAULT_GLIDE="${GAME_SYSTEM_DIR}/Default-glide.ini"
|
|
||||||
SYSTEM_DEFAULT_OPENGL="${GAME_SYSTEM_DIR}/Default-opengl.ini"
|
|
||||||
SYSTEM_DEFAULT_USER="${GAME_SYSTEM_DIR}/DefUser.ini"
|
|
||||||
USER_UT_INI="${USER_UT_DIR}/UnrealTournament.ini"
|
|
||||||
USER_USER_INI="${USER_UT_DIR}/User.ini"
|
|
||||||
|
|
||||||
if [ ! -d "${USER_UT_DIR}" ]
|
|
||||||
then
|
|
||||||
mkdir -p "${USER_UT_DIR}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
detect_renderer() {
|
|
||||||
if [ -e /usr/lib/libglide2x.so ] || [ -e /usr/local/lib/libglide2x.so ]; then
|
|
||||||
echo "glide"
|
|
||||||
else
|
|
||||||
echo "opengl"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
install_ini_profile() {
|
|
||||||
local renderer="$1"
|
|
||||||
|
|
||||||
case "$renderer" in
|
|
||||||
glide)
|
|
||||||
if [ -r "${SYSTEM_DEFAULT_GLIDE}" ]; then
|
|
||||||
cp -f "${SYSTEM_DEFAULT_GLIDE}" "${USER_UT_INI}"
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
opengl)
|
|
||||||
if [ -r "${SYSTEM_DEFAULT_OPENGL}" ]; then
|
|
||||||
cp -f "${SYSTEM_DEFAULT_OPENGL}" "${USER_UT_INI}"
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
return 1
|
|
||||||
}
|
|
||||||
|
|
||||||
if [ ! -f "${USER_UT_INI}" ]; then
|
|
||||||
RENDERER="$(detect_renderer)"
|
|
||||||
install_ini_profile "${RENDERER}" || {
|
|
||||||
echo "Failed to install renderer profile: ${RENDERER}"
|
|
||||||
exit 1
|
|
||||||
}
|
|
||||||
ini_set_key "${USER_UT_INI}" "Engine.Engine" "AudioDevice" "Audio.GenericAudioSubsystem"
|
|
||||||
ini_set_key "${USER_UT_INI}" "Core.System" "CacheSizeMegs" "32"
|
|
||||||
ini_set_key "${USER_UT_INI}" "WinDrv.WindowsClient" "FullscreenViewportX" "800"
|
|
||||||
ini_set_key "${USER_UT_INI}" "WinDrv.WindowsClient" "FullscreenViewportY" "600"
|
|
||||||
ini_set_key "${USER_UT_INI}" "Audio.GenericAudioSubsystem" "UseSpatial" "True"
|
|
||||||
ini_set_key "${USER_UT_INI}" "Audio.GenericAudioSubsystem" "UseReverb" "True"
|
|
||||||
ini_set_key "${USER_UT_INI}" "Audio.GenericAudioSubsystem" "OutputRate" "44100Hz"
|
|
||||||
ini_set_key "${USER_UT_INI}" "IpDrv.TcpNetDriver" "ConfiguredInternetSpeed" "25000"
|
|
||||||
|
|
||||||
if ! grep -q '^\[UBrowser\.UBrowserFavoritesFact\]$' "${USER_UT_INI}"; then
|
|
||||||
printf '%s\n' \
|
|
||||||
'[UBrowser.UBrowserFavoritesFact]' \
|
|
||||||
'FavoriteCount=1' \
|
|
||||||
'Favorites[0]=Vogons\5.196.92.222\5091\False' \
|
|
||||||
>> "${USER_UT_INI}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Remove passwords from UnrealTournament.ini
|
|
||||||
if [ -r "${USER_UT_INI}" ]
|
|
||||||
then
|
|
||||||
sed -i \
|
|
||||||
-e 's/^\(SavedPasswords\[[0-9]*\]=\).*/\1/' \
|
|
||||||
-e 's/^\(PasswordHistory\[[0-9]*\]=\).*/\1/' \
|
|
||||||
"${USER_UT_INI}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
set_random_ut_name() {
|
|
||||||
local target_file="$1"
|
|
||||||
|
|
||||||
[ -n "$target_file" ] || return 1
|
|
||||||
[ -f "$target_file" ] || return 1
|
|
||||||
|
|
||||||
local names='
|
|
||||||
Phobos
|
|
||||||
Vortex
|
|
||||||
Raptor
|
|
||||||
Hexer
|
|
||||||
Cobra
|
|
||||||
Grendel
|
|
||||||
Nyx
|
|
||||||
Blitz
|
|
||||||
Talon
|
|
||||||
Havoc
|
|
||||||
Stryker
|
|
||||||
Wraith
|
|
||||||
Nova
|
|
||||||
Reaper
|
|
||||||
Goliath
|
|
||||||
Drift
|
|
||||||
Razor
|
|
||||||
Pixel
|
|
||||||
Onyx
|
|
||||||
Fury
|
|
||||||
'
|
|
||||||
|
|
||||||
local count=$(printf '%s\n' "$names" | sed '/^$/d' | wc -l)
|
|
||||||
local idx=$(( (RANDOM % count) + 1 ))
|
|
||||||
local base_name=$(printf '%s\n' "$names" | sed '/^$/d' | sed -n "${idx}p")
|
|
||||||
local suffix=$(printf '%02d' $((RANDOM % 100)))
|
|
||||||
local new_name="${base_name}${suffix}"
|
|
||||||
|
|
||||||
sed -i "s/^Name=Player$/Name=${new_name}/" "$target_file"
|
|
||||||
}
|
|
||||||
|
|
||||||
if [ ! -f "${USER_USER_INI}" ]; then
|
|
||||||
if [ ! -r "${SYSTEM_DEFAULT_USER}" ]; then
|
|
||||||
echo "Missing ${SYSTEM_DEFAULT_USER}"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
cp -f "${SYSTEM_DEFAULT_USER}" "${USER_USER_INI}"
|
|
||||||
set_random_ut_name "${USER_USER_INI}"
|
|
||||||
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Left"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Up"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Right"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Down"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Z"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "Q"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "S"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.Input" "D"
|
|
||||||
ini_del_key "${USER_USER_INI}" "Engine.PlayerPawn" "DodgeClickTime"
|
|
||||||
|
|
||||||
ini_set_key "${USER_USER_INI}" "Engine.Input" "W" "MoveForward"
|
|
||||||
ini_set_key "${USER_USER_INI}" "Engine.Input" "A" "StrafeLeft"
|
|
||||||
ini_set_key "${USER_USER_INI}" "Engine.Input" "S" "MoveBackward"
|
|
||||||
ini_set_key "${USER_USER_INI}" "Engine.Input" "D" "StrafeRight"
|
|
||||||
ini_set_key "${USER_USER_INI}" "Engine.PlayerPawn" "0.250000"
|
|
||||||
|
|
||||||
fi
|
|
||||||
|
|
||||||
# games run better with US keyboard layout
|
|
||||||
restore_xkb() {
|
|
||||||
[ -n "$OLD_XKB_LAYOUT" ] && setxkbmap "$OLD_XKB_LAYOUT" >/dev/null 2>&1 || true
|
|
||||||
}
|
|
||||||
|
|
||||||
OLD_XKB_LAYOUT="$(setxkbmap -query 2>/dev/null | awk '$1=="layout:" {print $2}')"
|
|
||||||
trap restore_xkb EXIT
|
|
||||||
setxkbmap us >/dev/null 2>&1 || true
|
|
||||||
|
|
||||||
LD_LIBRARY_PATH="${GAME_SYSTEM_DIR}:${LD_LIBRARY_PATH}"
|
|
||||||
export LD_LIBRARY_PATH
|
|
||||||
|
|
||||||
cd "${GAME_SYSTEM_DIR}" || exit 1
|
|
||||||
|
|
||||||
# start the game
|
|
||||||
if nice -n -5 true >/dev/null 2>&1; then
|
|
||||||
echo "Launching UT99 with elevated priority"
|
|
||||||
exec nice -n -5 -- "./$GAME_BINARY" "${CMD_ARGS[@]}" "$@"
|
|
||||||
else
|
|
||||||
echo "Negative nice not permitted, launching normally"
|
|
||||||
exec "./$GAME_BINARY" "${CMD_ARGS[@]}" "$@"
|
|
||||||
fi
|
|
||||||
Binary file not shown.
@@ -1 +0,0 @@
|
|||||||
deb [trusted=yes] http://archive.debian.org/debian-backports/ etch-backports main
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
SSTV2_FASTMEM_RAS_READS=1
|
|
||||||
SSTV2_FASTMEM_READ=1
|
|
||||||
SSTV2_FASTMEM=1
|
|
||||||
SSTV2_FASTPCIRD=1
|
|
||||||
SSTV2_GRXCLK=90
|
|
||||||
SSTV2_SLIM_VOUT_CLKDEL=0
|
|
||||||
SSTV2_SLIM_VIN_CLKDEL=0
|
|
||||||
SSTV2_SLIS_VOUT_CLKDEL=0
|
|
||||||
SSTV2_SLIS_VIN_CLKDEL=0
|
|
||||||
SSTV2_SWAPINTERVAL=0
|
|
||||||
FX_GLIDE_SWAPINTERVAL=0
|
|
||||||
SSTV2_GAMMA=1.3
|
|
||||||
SSTV2_MISMATCHED_SLI=1
|
|
||||||
SSTV2_SWAP_EN_WAIT_ON_VSYNC=0
|
|
||||||
SSTV2_SCREENREFRESH=75
|
|
||||||
FX_GLIDE_SHAMELESS_PLUG=1
|
|
||||||
MESA_GLX_FX=f
|
|
||||||
MESA_FX_INFO=1
|
|
||||||
@@ -1,34 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
### BEGIN INIT INFO
|
|
||||||
# Provides: retrodebian-fluxbox-watch-menu
|
|
||||||
# Required-Start: $local_fs
|
|
||||||
# Required-Stop:
|
|
||||||
# Default-Start: 2 3 4 5
|
|
||||||
# Default-Stop: 0 1 6
|
|
||||||
# Short-Description: Watch and filter Fluxbox generated menu
|
|
||||||
### END INIT INFO
|
|
||||||
|
|
||||||
DAEMON=/opt/retrodebian/fluxbox/watch-menu.sh
|
|
||||||
PIDFILE=/var/run/retrodebian-fluxbox-watch-menu.pid
|
|
||||||
|
|
||||||
case "$1" in
|
|
||||||
start)
|
|
||||||
echo "Starting retrodebian-fluxbox-watch-menu"
|
|
||||||
start-stop-daemon --start --background --make-pidfile --pidfile "$PIDFILE" --exec "$DAEMON"
|
|
||||||
;;
|
|
||||||
stop)
|
|
||||||
echo "Stopping retrodebian-fluxbox-watch-menu"
|
|
||||||
start-stop-daemon --stop --pidfile "$PIDFILE" --retry 5
|
|
||||||
rm -f "$PIDFILE"
|
|
||||||
;;
|
|
||||||
restart)
|
|
||||||
$0 stop
|
|
||||||
$0 start
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
echo "Usage: $0 {start|stop|restart}"
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,34 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
### BEGIN INIT INFO
|
|
||||||
# Provides: retrodebian-xorg-autoconfig
|
|
||||||
# Required-Start: $local_fs
|
|
||||||
# Required-Stop:
|
|
||||||
# Default-Start: S
|
|
||||||
# Default-Stop:
|
|
||||||
# Short-Description: Generate xorg.conf for RetroDebian at boot
|
|
||||||
# Description: Detect video hardware and generate /etc/X11/xorg.conf
|
|
||||||
### END INIT INFO
|
|
||||||
|
|
||||||
FLAG_FILE="/var/lib/retrodebian/xorg-autoconfig.done"
|
|
||||||
XORG_CONF="/etc/X11/xorg.conf"
|
|
||||||
AUTOCONFIG_BIN="/opt/retrodebian/xorg/autoconfig.sh"
|
|
||||||
|
|
||||||
case "$1" in
|
|
||||||
start)
|
|
||||||
[ -f "$FLAG_FILE" ] && exit 0
|
|
||||||
[ -x "$AUTOCONFIG_BIN" ] || exit 0
|
|
||||||
|
|
||||||
mkdir -p /var/lib/retrodebian || exit 0
|
|
||||||
|
|
||||||
"$AUTOCONFIG_BIN" "$XORG_CONF" || exit 0
|
|
||||||
touch "$FLAG_FILE" || exit 0
|
|
||||||
;;
|
|
||||||
stop|restart|force-reload)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
echo "Usage: $0 start" >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
/usr/local/lib
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
URxvt*font: xft:DejaVu Sans Mono:size=9
|
|
||||||
URxvt*foreground: #7186e3
|
|
||||||
URxvt*background: #303030
|
|
||||||
URxvt*cursorColor: #65adc7
|
|
||||||
URxvt*scrollBar: false
|
|
||||||
URxvt*internalBorder: 6
|
|
||||||
|
|
||||||
URxvt.perl-ext-common: default,clipboard
|
|
||||||
URxvt.keysym.Shift-Control-C: perl:clipboard:copy
|
|
||||||
URxvt.keysym.Mod4-c: perl:clipboard:copy
|
|
||||||
URxvt.keysym.Mod4-v: perl:clipboard:paste
|
|
||||||
URxvt.keysym.C-v: perl:clipboard:paste
|
|
||||||
URxvt.clipboard.autocopy: false
|
|
||||||
URxvt.clipboard.copycmd: sh -c 'xsel -i -b'
|
|
||||||
URxvt.clipboard.pastecmd: sh -c 'xsel -o -b'
|
|
||||||
|
|
||||||
XTerm*faceName: DejaVu Sans Mono
|
|
||||||
XTerm*faceSize: 9
|
|
||||||
XTerm*foreground: #7186e3
|
|
||||||
XTerm*background: #303030
|
|
||||||
XTerm*cursorColor: #65adc7
|
|
||||||
|
|
||||||
Xft.antialias: 1
|
|
||||||
Xft.hinting: 1
|
|
||||||
Xft.hintstyle: hintslight
|
|
||||||
Xft.rgba: none
|
|
||||||
Xft.dpi: 96
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
if [ -f "$HOME/.profile" ]; then
|
|
||||||
. "$HOME/.profile"
|
|
||||||
fi
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
PS1='${debian_chroot:+($debian_chroot)}\[\033[0;37m\]\u@\h\[\033[0m\]:\[\033[0;36m\]\w\[\033[0m\]\$ '
|
|
||||||
alias apt='apt-get'
|
|
||||||
|
|
||||||
if [ -x /usr/bin/dircolors ]; then
|
|
||||||
eval "$(dircolors -b)"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Softer moonlight palette for ls
|
|
||||||
LS_COLORS="di=0;36:ln=1;36:so=1;35:pi=0;33:ex=1;32:bd=1;33:cd=1;33:su=0;37;41:sg=0;30;43:tw=0;30;42:ow=0;34;42:or=1;31:mi=1;31"
|
|
||||||
export LS_COLORS
|
|
||||||
|
|
||||||
alias ls='ls --color=auto'
|
|
||||||
alias ll='ls --color=auto -l'
|
|
||||||
alias la='ls --color=auto -la'
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
session.styleFile: /usr/share/fluxbox/styles/BlueNight
|
|
||||||
session.menuFile: /var/run/retrodebian/final-fluxbox-menu
|
|
||||||
session.screen0.rootCommand: Esetroot /usr/share/wallpapers/retrodebian.jpg
|
|
||||||
session.screen0.menu.alpha: 128
|
|
||||||
session.configVersion: 1
|
|
||||||
menu.frame.font: Sans-9
|
|
||||||
menu.title.font: Sans:bold-9
|
|
||||||
toolbar.clock.font: Sans-9
|
|
||||||
toolbar.workspace.font: Sans-9
|
|
||||||
window.font: Sans-9
|
|
||||||
@@ -1,94 +0,0 @@
|
|||||||
# Clic sur le bureau pour afficher les menus
|
|
||||||
OnDesktop Mouse1 :HideMenus
|
|
||||||
OnDesktop Mouse2 :WorkspaceMenu
|
|
||||||
OnDesktop Mouse3 :RootMenu
|
|
||||||
# Scroll sur le bureau pour changer de bureau
|
|
||||||
OnDesktop Mouse4 :PrevWorkspace
|
|
||||||
OnDesktop Mouse5 :NextWorkspace
|
|
||||||
# Scroll sur la barre fluxbox pour changer de fenetre
|
|
||||||
OnToolbar Mouse4 :PrevWindow {static groups} (iconhidden=no)
|
|
||||||
OnToolbar Mouse5 :NextWindow {static groups} (iconhidden=no)
|
|
||||||
# Alt et clic gauche ou droite pour deplacer ou agrandir la fenetre
|
|
||||||
OnWindow Mod1 Mouse1 :MacroCmd {Raise} {Focus} {StartMoving}
|
|
||||||
OnWindowBorder Move1 :StartMoving
|
|
||||||
OnWindow Mod1 Mouse3 :MacroCmd {Raise} {Focus} {StartResizing NearestCorner}
|
|
||||||
OnLeftGrip Move1 :StartResizing bottomleft
|
|
||||||
OnRightGrip Move1 :StartResizing bottomright
|
|
||||||
# control-click a window's titlebar and drag to attach windows
|
|
||||||
OnTitlebar Control Mouse1 :StartTabbing
|
|
||||||
# Double clic sur la barre on agrandit (ou Windows + Fleche haut
|
|
||||||
OnTitlebar Double Mouse1 :Maximize
|
|
||||||
# Déplacer la fenetre quand on clic sur la barre de titre
|
|
||||||
OnTitlebar Mouse1 :MacroCmd {Raise} {Focus} {ActivateTab}
|
|
||||||
OnTitlebar Move1 :StartMoving
|
|
||||||
# Reduire si clic milieu
|
|
||||||
OnTitlebar Mouse2 :Lower
|
|
||||||
# Clic droit sur la fenetre affiche les options
|
|
||||||
OnTitlebar Mouse3 :WindowMenu
|
|
||||||
# Alt Tab
|
|
||||||
Mod1 Tab :NextWindow {groups} (workspace=[current])
|
|
||||||
Mod1 Shift Tab :PrevWindow {groups} (workspace=[current])
|
|
||||||
# open a terminal
|
|
||||||
Mod1 F1 :Exec xterm
|
|
||||||
# Ouvrir la fenetre rapide de programme avec Alt F2
|
|
||||||
Mod1 F2 :Exec fbrun
|
|
||||||
# Commande de fenetre
|
|
||||||
Mod1 F4 :Close
|
|
||||||
#Mod1 F5 :Kill
|
|
||||||
Mod1 F9 :Minimize
|
|
||||||
Mod1 F10 :Maximize
|
|
||||||
Mod1 F11 :Fullscreen
|
|
||||||
# exit fluxbox
|
|
||||||
Control Mod1 Delete :Exit
|
|
||||||
# change to previous/next workspace
|
|
||||||
#Control Mod1 Left :PrevWorkspace
|
|
||||||
#Control Mod1 Right :NextWorkspace
|
|
||||||
# send the current window to previous/next workspace
|
|
||||||
#Mod4 Left :SendToPrevWorkspace
|
|
||||||
#Mod4 Right :SendToNextWorkspace
|
|
||||||
# send the current window and follow it to previous/next workspace
|
|
||||||
#Control Mod4 Left :TakeToPrevWorkspace
|
|
||||||
#Control Mod4 Right :TakeToNextWorkspace
|
|
||||||
# Changer de bureau
|
|
||||||
Control F1 :Workspace 1
|
|
||||||
Control F2 :Workspace 2
|
|
||||||
Control F3 :Workspace 3
|
|
||||||
Control F4 :Workspace 4
|
|
||||||
Control F5 :Workspace 5
|
|
||||||
Control F6 :Workspace 6
|
|
||||||
Control F7 :Workspace 7
|
|
||||||
Control F8 :Workspace 8
|
|
||||||
Control F9 :Workspace 9
|
|
||||||
Control F10 :Workspace 10
|
|
||||||
Control F11 :Workspace 11
|
|
||||||
Control F12 :Workspace 12
|
|
||||||
# send the current window to a specific workspace
|
|
||||||
#Mod4 F1 :SendToWorkspace 1
|
|
||||||
#Mod4 F2 :SendToWorkspace 2
|
|
||||||
#Mod4 F3 :SendToWorkspace 3
|
|
||||||
#Mod4 F4 :SendToWorkspace 4
|
|
||||||
#Mod4 F5 :SendToWorkspace 5
|
|
||||||
#Mod4 F6 :SendToWorkspace 6
|
|
||||||
#Mod4 F7 :SendToWorkspace 7
|
|
||||||
#Mod4 F8 :SendToWorkspace 8
|
|
||||||
#Mod4 F9 :SendToWorkspace 9
|
|
||||||
#Mod4 F10 :SendToWorkspace 10
|
|
||||||
#Mod4 F11 :SendToWorkspace 11
|
|
||||||
#Mod4 F12 :SendToWorkspace 12
|
|
||||||
# send the current window and change to a specific workspace
|
|
||||||
#Control Mod4 F1 :TakeToWorkspace 1
|
|
||||||
#Control Mod4 F2 :TakeToWorkspace 2
|
|
||||||
#Control Mod4 F3 :TakeToWorkspace 3
|
|
||||||
#Control Mod4 F4 :TakeToWorkspace 4
|
|
||||||
#Control Mod4 F5 :TakeToWorkspace 5
|
|
||||||
#Control Mod4 F6 :TakeToWorkspace 6
|
|
||||||
#Control Mod4 F7 :TakeToWorkspace 7
|
|
||||||
#Control Mod4 F8 :TakeToWorkspace 8
|
|
||||||
#Control Mod4 F9 :TakeToWorkspace 9
|
|
||||||
#Control Mod4 F10 :TakeToWorkspace 10
|
|
||||||
#Control Mod4 F11 :TakeToWorkspace 11
|
|
||||||
#Control Mod4 F12 :TakeToWorkspace 12
|
|
||||||
|
|
||||||
None XF86AudioRaiseVolume : Exec amixer sset Master,0 3000+
|
|
||||||
None XF86AudioLowerVolume : Exec amixer sset Master,0 3000-
|
|
||||||
None XF86AudioMute : Exec amixer sset Master,0 toggle
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
fbsetroot -f /usr/share/wallpapers/retrodebian.jpg
|
|
||||||
|
|
||||||
numlockx on
|
|
||||||
|
|
||||||
idesk &
|
|
||||||
unclutter -idle 2 &
|
|
||||||
wmnd &
|
|
||||||
wmmixer -w &
|
|
||||||
wmcpuload -bl -lc rgb:80/B0/A0 &
|
|
||||||
wmmemload -bl -lc rgb:80/B0/A0 &
|
|
||||||
xscreensaver &
|
|
||||||
#exec /usr/bin/fluxbox -log "$HOME/.fluxbox/log"
|
|
||||||
exec /usr/bin/fluxbox
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
style "force-dark"
|
|
||||||
{
|
|
||||||
bg[NORMAL] = "#303030"
|
|
||||||
bg[ACTIVE] = "#404040"
|
|
||||||
bg[PRELIGHT] = "#505050"
|
|
||||||
bg[SELECTED] = "#506070"
|
|
||||||
|
|
||||||
fg[NORMAL] = "#f0f0f0"
|
|
||||||
fg[ACTIVE] = "#ffffff"
|
|
||||||
fg[PRELIGHT] = "#ffffff"
|
|
||||||
fg[SELECTED] = "#ffffff"
|
|
||||||
|
|
||||||
base[NORMAL] = "#202020"
|
|
||||||
base[ACTIVE] = "#303030"
|
|
||||||
base[PRELIGHT] = "#404040"
|
|
||||||
base[SELECTED] = "#506070"
|
|
||||||
|
|
||||||
text[NORMAL] = "#f0f0f0"
|
|
||||||
text[ACTIVE] = "#ffffff"
|
|
||||||
text[PRELIGHT] = "#ffffff"
|
|
||||||
text[SELECTED] = "#ffffff"
|
|
||||||
|
|
||||||
GtkWidget::cursor-color = "#b0c0d0"
|
|
||||||
GtkWidget::secondary-cursor-color = "#b0c0d0"
|
|
||||||
}
|
|
||||||
|
|
||||||
class "*" style "force-dark"
|
|
||||||
|
|
||||||
gtk-font-name="Sans 8"
|
|
||||||
gtk-icon-theme-name="Tango"
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
table Config
|
|
||||||
FontName: xft:DejaVu Sans
|
|
||||||
FontSize: 10
|
|
||||||
FontColor: #f0f0f0
|
|
||||||
ToolTip.FontSize: 11
|
|
||||||
ToolTip.FontName: xft:DejaVu Sans
|
|
||||||
ToolTip.ForeColor: #0000FF
|
|
||||||
ToolTip.BackColor: #FFFFFF
|
|
||||||
ToolTip.CaptionOnHover: true
|
|
||||||
ToolTip.CaptionPlacement: Right
|
|
||||||
Locked: false
|
|
||||||
Transparency: 100
|
|
||||||
Shadow: true
|
|
||||||
ShadowColor: #000000
|
|
||||||
ShadowX: 1
|
|
||||||
ShadowY: 1
|
|
||||||
Bold: true
|
|
||||||
ClickDelay: 300
|
|
||||||
IconSnap: true
|
|
||||||
SnapWidth: 20
|
|
||||||
SnapHeight: 20
|
|
||||||
SnapOrigin: BottomRight
|
|
||||||
SnapShadow: false
|
|
||||||
SnapShadowTrans: 200
|
|
||||||
CaptionOnHover: false
|
|
||||||
CaptionPlacement: bottom
|
|
||||||
FillStyle: fillinvert
|
|
||||||
Background.File: /usr/share/wallpapers/retrodebian.jpg
|
|
||||||
end
|
|
||||||
|
|
||||||
table Actions
|
|
||||||
Lock: control right doubleClk
|
|
||||||
Reload: middle doubleClk
|
|
||||||
Drag: left hold
|
|
||||||
EndDrag: left singleClk
|
|
||||||
Execute[0]: left doubleClk
|
|
||||||
Execute[1]: right doubleClk
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: Files
|
|
||||||
CaptionTip: Open files browser (pcmanfm)
|
|
||||||
Command: pcmanfm
|
|
||||||
Icon: /usr/share/icons/gnome/48x48/apps/drawer.png
|
|
||||||
X: 38
|
|
||||||
Y: 2
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: Task Manager
|
|
||||||
CaptionTip: Open htop
|
|
||||||
Command: urxvt -e htop
|
|
||||||
Icon: /usr/share/icons/gnome/48x48/apps/gnome-monitor.png
|
|
||||||
X: 38
|
|
||||||
Y: 82
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: Terminal
|
|
||||||
CaptionTip: Open a new terminal
|
|
||||||
Command: urxvt
|
|
||||||
Icon: /usr/share/icons/gnome/48x48/apps/gnome-terminal.png
|
|
||||||
X: 38
|
|
||||||
Y: 242
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: Text Edit
|
|
||||||
CaptionTip: Open leafpad
|
|
||||||
Command: leafpad
|
|
||||||
Icon: /usr/share/icons/gnome/48x48/apps/text-editor.png
|
|
||||||
X: 38
|
|
||||||
Y: 162
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: UT99
|
|
||||||
CaptionTip: Unreal Tournament 99
|
|
||||||
Command: /usr/local/games/ut99/ut
|
|
||||||
Icon: /usr/share/icons/ut99.png
|
|
||||||
X: 38
|
|
||||||
Y: 322
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
table Icon
|
|
||||||
Caption: v2-tmu-memtester
|
|
||||||
CaptionTip: Voodoo 2 Diag
|
|
||||||
Command: urxvt -e sh -c '/usr/local/bin/v2-tmu-memtester --help; exec bash'
|
|
||||||
Icon: /usr/share/icons/gnome/48x48/devices/gnome-dev-memory.png
|
|
||||||
X: 38
|
|
||||||
Y: 402
|
|
||||||
Width: 48
|
|
||||||
Height: 48
|
|
||||||
end
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
[MIME Cache]
|
|
||||||
text/x-c=geany
|
|
||||||
text/x-c++=geany
|
|
||||||
text/x-java=geany
|
|
||||||
text/x-python=geany
|
|
||||||
text/x-makefile=geany
|
|
||||||
application/x-desktop=geany
|
|
||||||
text/plain=leafpad
|
|
||||||
text/x-log=leafpad
|
|
||||||
application/xml=geany
|
|
||||||
text/html=geany
|
|
||||||
application/x-shellscript=geany
|
|
||||||
image/jpeg=gimageview
|
|
||||||
image/png=gimageview
|
|
||||||
image/gif=gimageview
|
|
||||||
image/bmp=gimageview
|
|
||||||
image/x-xpixmap=gimageview
|
|
||||||
application/pdf=xpdf
|
|
||||||
inode/directory=pcmanfm
|
|
||||||
audio/mpeg=xmms
|
|
||||||
audio/x-wav=xmms
|
|
||||||
audio/ogg=xmms
|
|
||||||
video/x-msvideo=mplayer
|
|
||||||
video/mpeg=mplayer
|
|
||||||
video/mp4=mplayer
|
|
||||||
video/x-matroska=mplayer
|
|
||||||
application/postscript=xpdf
|
|
||||||
application/x-bzip2=xarchiver
|
|
||||||
application/x-gzip-compressed=xarchiver
|
|
||||||
application/x-compressed-tar=xarchiver
|
|
||||||
application/x-tgz=xarchiver
|
|
||||||
application/x-bzip-compressed-tar=xarchiver
|
|
||||||
application/zip=xarchiver
|
|
||||||
application/x-tar=xarchiver
|
|
||||||
application/x-bzip=xarchiver
|
|
||||||
application/x-gzip=xarchiver
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
if [ -z "$DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
|
|
||||||
exec startx
|
|
||||||
fi
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
: "${DISPLAY:=:0}"
|
|
||||||
export DISPLAY
|
|
||||||
|
|
||||||
if [ -f "$HOME/.resolution.config" ]; then
|
|
||||||
RES="$(sed -n '1p' "$HOME/.resolution.config")"
|
|
||||||
if [ -n "$RES" ]; then
|
|
||||||
xrandr -s "$RES"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
xrdb -merge "$HOME/.Xresources"
|
|
||||||
|
|
||||||
exec startfluxbox
|
|
||||||
@@ -1,328 +0,0 @@
|
|||||||
# XScreenSaver Preferences File
|
|
||||||
# Written by xscreensaver-demo 4.24 for bob on Mon Mar 23 14:48:12 2026.
|
|
||||||
# http://www.jwz.org/xscreensaver/
|
|
||||||
|
|
||||||
timeout: 0:10:00
|
|
||||||
cycle: 0:10:00
|
|
||||||
lock: False
|
|
||||||
lockTimeout: 0:20:00
|
|
||||||
passwdTimeout: 0:00:30
|
|
||||||
visualID: default
|
|
||||||
installColormap: True
|
|
||||||
verbose: False
|
|
||||||
timestamp: True
|
|
||||||
splash: False
|
|
||||||
splashDuration: 0:00:05
|
|
||||||
quad: False
|
|
||||||
demoCommand: xscreensaver-demo
|
|
||||||
prefsCommand: xscreensaver-demo -prefs
|
|
||||||
nice: 10
|
|
||||||
memoryLimit: 0
|
|
||||||
fade: False
|
|
||||||
unfade: False
|
|
||||||
fadeSeconds: 0:00:03
|
|
||||||
fadeTicks: 20
|
|
||||||
captureStderr: False
|
|
||||||
ignoreUninstalledPrograms:False
|
|
||||||
font: *-medium-r-*-140-*-m-*
|
|
||||||
dpmsEnabled: False
|
|
||||||
dpmsStandby: 1:00:00
|
|
||||||
dpmsSuspend: 1:00:00
|
|
||||||
dpmsOff: 2:00:00
|
|
||||||
grabDesktopImages: False
|
|
||||||
grabVideoFrames: False
|
|
||||||
chooseRandomImages: False
|
|
||||||
imageDirectory:
|
|
||||||
|
|
||||||
mode: one
|
|
||||||
selected: 96
|
|
||||||
|
|
||||||
textMode: date
|
|
||||||
textLiteral: XScreenSaver
|
|
||||||
textFile: /usr/share/doc/xserver-common/copyright
|
|
||||||
textProgram: fortune
|
|
||||||
textURL: http://planet.debian.org/rss20.xml
|
|
||||||
|
|
||||||
programs: \
|
|
||||||
"Qix (solid)" qix -root -solid -segments 100 \n\
|
|
||||||
"Qix (transparent)" qix -root -count 4 -solid -transparent \n\
|
|
||||||
"Qix (linear)" qix -root -count 5 -solid -transparent \
|
|
||||||
-linear -segments 250 -size 100 \n\
|
|
||||||
- "Qix (xor)" qix -root -linear -count 5 -size 200 \
|
|
||||||
-spread 30 -segments 75 -solid -xor \n\
|
|
||||||
"Attraction (balls)" attraction -root -mode balls \n\
|
|
||||||
"Attraction (lines)" attraction -root -mode lines -points 3 \
|
|
||||||
-segments 200 \n\
|
|
||||||
- "Attraction (poly)" attraction -root -mode polygons \n\
|
|
||||||
"Attraction (splines)" attraction -root -mode splines -segments \
|
|
||||||
300 \n\
|
|
||||||
"Attraction (orbital)" attraction -root -mode lines -radius 300 \
|
|
||||||
-orbit -vmult 0.5 \n\
|
|
||||||
pyro -root \n\
|
|
||||||
rocks -root \n\
|
|
||||||
helix -root \n\
|
|
||||||
pedal -root \n\
|
|
||||||
rorschach -root -offset 7 \n\
|
|
||||||
hopalong -root \n\
|
|
||||||
greynetic -root \n\
|
|
||||||
imsmap -root \n\
|
|
||||||
slidescreen -root \n\
|
|
||||||
decayscreen -root \n\
|
|
||||||
jigsaw -root \n\
|
|
||||||
blitspin -root -grab \n\
|
|
||||||
slip -root \n\
|
|
||||||
distort -root \n\
|
|
||||||
spotlight -root \n\
|
|
||||||
"Ripples (oily)" ripples -root -oily -light 2 \n\
|
|
||||||
"Ripples (stir)" ripples -root -oily -light 2 -stir \n\
|
|
||||||
"Ripples (desktop)" ripples -root -water -light 6 \n\
|
|
||||||
hypercube -root \n\
|
|
||||||
- hyperball -root \n\
|
|
||||||
halo -root \n\
|
|
||||||
maze -root \n\
|
|
||||||
noseguy -root \n\
|
|
||||||
flame -root \n\
|
|
||||||
- lmorph -root \n\
|
|
||||||
deco -root \n\
|
|
||||||
moire -root \n\
|
|
||||||
moire2 -root \n\
|
|
||||||
lightning -root \n\
|
|
||||||
strange -root \n\
|
|
||||||
- spiral -root \n\
|
|
||||||
laser -root \n\
|
|
||||||
grav -root \n\
|
|
||||||
"Grav (trails)" grav -root -trail -decay \n\
|
|
||||||
drift -root \n\
|
|
||||||
ifs -root \n\
|
|
||||||
julia -root \n\
|
|
||||||
penrose -root \n\
|
|
||||||
- sierpinski -root \n\
|
|
||||||
braid -root \n\
|
|
||||||
galaxy -root \n\
|
|
||||||
bouboule -root \n\
|
|
||||||
swirl -root \n\
|
|
||||||
flag -root \n\
|
|
||||||
sphere -root \n\
|
|
||||||
forest -root \n\
|
|
||||||
- lisa -root \n\
|
|
||||||
- lissie -root \n\
|
|
||||||
goop -root -max-velocity 0.5 -elasticity \
|
|
||||||
0.9 \n\
|
|
||||||
starfish -root \n\
|
|
||||||
"Starfish (blob)" starfish -root -blob \n\
|
|
||||||
munch -root \n\
|
|
||||||
mismunch -root \n\
|
|
||||||
fadeplot -root \n\
|
|
||||||
coral -root -delay 0 \n\
|
|
||||||
mountain -root \n\
|
|
||||||
triangle -root -delay 1 \n\
|
|
||||||
- worm -root \n\
|
|
||||||
- rotor -root \n\
|
|
||||||
- demon -root \n\
|
|
||||||
- loop -root \n\
|
|
||||||
- vines -root \n\
|
|
||||||
kaleidescope -root \n\
|
|
||||||
xjack -root \n\
|
|
||||||
xlyap -root -randomize \n\
|
|
||||||
cynosure -root \n\
|
|
||||||
flow -root \n\
|
|
||||||
epicycle -root \n\
|
|
||||||
interference -root \n\
|
|
||||||
truchet -root -randomize \n\
|
|
||||||
bsod -root \n\
|
|
||||||
crystal -root \n\
|
|
||||||
discrete -root \n\
|
|
||||||
kumppa -root \n\
|
|
||||||
rd-bomb -root \n\
|
|
||||||
"RD-Bomb (mobile)" rd-bomb -root -speed 1 -size 0.1 \n\
|
|
||||||
sonar -root \n\
|
|
||||||
t3d -root \n\
|
|
||||||
penetrate -root \n\
|
|
||||||
deluxe -root \n\
|
|
||||||
compass -root \n\
|
|
||||||
squiral -root \n\
|
|
||||||
xflame -root \n\
|
|
||||||
wander -root \n\
|
|
||||||
"Wander (spots)" wander -root -advance 0 -size 10 -circles \
|
|
||||||
-length 10000 -reset 100000 \n\
|
|
||||||
- critical -root \n\
|
|
||||||
phosphor -root \n\
|
|
||||||
xmatrix -root -small -delay 12842 -trace \
|
|
||||||
-knock-knock \n\
|
|
||||||
petri -root -size 2 -count 20 \n\
|
|
||||||
"Petri 2" petri -root -minlifespeed 0.02 \
|
|
||||||
-maxlifespeed 0.03 -minlifespan 1 \
|
|
||||||
-maxlifespan 1 -instantdeathchan 0 \
|
|
||||||
-minorchan 0 -anychan 0.3 \n\
|
|
||||||
shadebobs -root \n\
|
|
||||||
ccurve -root \n\
|
|
||||||
blaster -root \n\
|
|
||||||
bumps -root \n\
|
|
||||||
xteevee -root \n\
|
|
||||||
xanalogtv -root \n\
|
|
||||||
xspirograph -root \n\
|
|
||||||
nerverot -root \n\
|
|
||||||
- "NerveRot (dense)" nerverot -root -count 1000 \n\
|
|
||||||
- "NerveRot (thick)" nerverot -root -count 100 -line-width 4 \
|
|
||||||
-max-nerve-radius 0.8 -nervousness 0.5 \
|
|
||||||
-db \n\
|
|
||||||
xrayswarm -root \n\
|
|
||||||
- "Zoom (Fatbits)" zoom -root \n\
|
|
||||||
"Zoom (Lenses)" zoom -root -lenses \n\
|
|
||||||
rotzoomer -root \n\
|
|
||||||
- "RotZoomer (mobile)" rotzoomer -root -move \n\
|
|
||||||
- "RotZoomer (sweep)" rotzoomer -root -sweep \n\
|
|
||||||
whirlwindwarp -root \n\
|
|
||||||
whirlygig -root \n\
|
|
||||||
speedmine -root \n\
|
|
||||||
"SpeedWorm" speedmine -root -worm \n\
|
|
||||||
vermiculate -root \n\
|
|
||||||
twang -root \n\
|
|
||||||
apollonian -root \n\
|
|
||||||
euler2d -root \n\
|
|
||||||
"Euler2d (dense)" euler2d -root -count 4000 -eulertail 400 \
|
|
||||||
-ncolors 230 \n\
|
|
||||||
- juggle -root \n\
|
|
||||||
polyominoes -root \n\
|
|
||||||
- thornbird -root \n\
|
|
||||||
fluidballs -root \n\
|
|
||||||
anemone -root \n\
|
|
||||||
halftone -root \n\
|
|
||||||
metaballs -root \n\
|
|
||||||
eruption -root \n\
|
|
||||||
popsquares -root \n\
|
|
||||||
barcode -root \n\
|
|
||||||
piecewise -root \n\
|
|
||||||
cloudlife -root \n\
|
|
||||||
fontglide -root -page \n\
|
|
||||||
"FontGlide (scroller)" fontglide -root -scroll \n\
|
|
||||||
apple2 -root \n\
|
|
||||||
bubbles -root \n\
|
|
||||||
pong -root \n\
|
|
||||||
wormhole -root \n\
|
|
||||||
pacman -root \n\
|
|
||||||
fuzzyflakes -root \n\
|
|
||||||
anemotaxis -root \n\
|
|
||||||
memscroller -root \n\
|
|
||||||
substrate -root \n\
|
|
||||||
"Substrate (circles)" substrate -root -circle-percent 33 \n\
|
|
||||||
intermomentary -root \n\
|
|
||||||
interaggregate -root \n\
|
|
||||||
fireworkx -root \n\
|
|
||||||
fiberlamp -root \n\
|
|
||||||
boxfit -root \n\
|
|
||||||
celtic -root \n\
|
|
||||||
- default-n: webcollage -root \n\
|
|
||||||
- default-n: "WebCollage (whacked)" \
|
|
||||||
webcollage -root -filter 'vidwhacker \
|
|
||||||
-stdin -stdout' \n\
|
|
||||||
- default-n: vidwhacker -root \n\
|
|
||||||
- GL: gears -root \n\
|
|
||||||
- GL: "Gears (planetary)" gears -root -planetary \n\
|
|
||||||
- GL: superquadrics -root \n\
|
|
||||||
- GL: morph3d -root \n\
|
|
||||||
- GL: cage -root \n\
|
|
||||||
- GL: moebius -root \n\
|
|
||||||
- GL: stairs -root \n\
|
|
||||||
- GL: pipes -root \n\
|
|
||||||
- GL: sproingies -root \n\
|
|
||||||
- GL: rubik -root \n\
|
|
||||||
- GL: atlantis -root -gradient \n\
|
|
||||||
- GL: lament -root \n\
|
|
||||||
- GL: bubble3d -root \n\
|
|
||||||
- GL: glplanet -root \n\
|
|
||||||
- GL: flurry -root -preset random \n\
|
|
||||||
- GL: pulsar -root \n\
|
|
||||||
- GL: "Pulsar (textures)" pulsar -root -texture -mipmap \
|
|
||||||
-texture_quality -light -fog \n\
|
|
||||||
- GL: extrusion -root \n\
|
|
||||||
- GL: sierpinski3d -root \n\
|
|
||||||
- GL: menger -root \n\
|
|
||||||
- GL: gflux -root \n\
|
|
||||||
- GL: "GFlux (grab)" gflux -root -mode grab \n\
|
|
||||||
- GL: stonerview -root \n\
|
|
||||||
- GL: starwars -root \n\
|
|
||||||
- GL: gltext -root \n\
|
|
||||||
- GL: "GLText (clock)" gltext -text "%A%n%d %b %Y%n%r" -root \n\
|
|
||||||
- GL: molecule -root -shells \n\
|
|
||||||
- GL: dangerball -root \n\
|
|
||||||
- GL: circuit -root \n\
|
|
||||||
- GL: engine -root \n\
|
|
||||||
- GL: flipscreen3d -root \n\
|
|
||||||
- GL: glsnake -root \n\
|
|
||||||
- GL: boxed -root \n\
|
|
||||||
- GL: glforestfire -root \n\
|
|
||||||
- GL: "GLForestFire (rain)" glforestfire -root -count 0 \n\
|
|
||||||
- GL: sballs -root \n\
|
|
||||||
- GL: cubenetic -root \n\
|
|
||||||
- GL: spheremonics -root \n\
|
|
||||||
- GL: lavalite -root \n\
|
|
||||||
- GL: queens -root \n\
|
|
||||||
- GL: endgame -root \n\
|
|
||||||
- GL: glblur -root \n\
|
|
||||||
- GL: atunnel -root \n\
|
|
||||||
- GL: flyingtoasters -root \n\
|
|
||||||
- GL: bouncingcow -root \n\
|
|
||||||
- GL: jigglypuff -root -random \n\
|
|
||||||
- GL: klein -root -random \n\
|
|
||||||
- GL: "HyperTorus (striped)" hypertorus -root \n\
|
|
||||||
- GL: "HyperTorus (solid)" hypertorus -root -solid -transparent \n\
|
|
||||||
- GL: glmatrix -root \n\
|
|
||||||
- GL: cubestorm -root \n\
|
|
||||||
- GL: glknots -root \n\
|
|
||||||
- GL: blocktube -root \n\
|
|
||||||
- GL: flipflop -root \n\
|
|
||||||
- GL: antspotlight -root \n\
|
|
||||||
- GL: glslideshow -root \n\
|
|
||||||
- GL: polytopes -root \n\
|
|
||||||
- GL: gleidescope -root \n\
|
|
||||||
- GL: mirrorblob -root \n\
|
|
||||||
- GL: "MirrorBlob (color only)" mirrorblob -root -colour -no-texture \n\
|
|
||||||
- GL: blinkbox -root \n\
|
|
||||||
- GL: noof -root \n\
|
|
||||||
- GL: polyhedra -root \n\
|
|
||||||
- GL: antinspect -root \n\
|
|
||||||
- GL: providence -root \n\
|
|
||||||
- GL: "Pinion (large gears)" pinion -root \n\
|
|
||||||
- GL: "Pinion (small gears)" pinion -root -size 0.2 -scroll 0.3 \n\
|
|
||||||
- GL: boing -root -lighting -smooth \n\
|
|
||||||
- GL: carousel -root \n\
|
|
||||||
- GL: fliptext -root \n\
|
|
||||||
- GL: antmaze -root \n\
|
|
||||||
- GL: tangram -root \n\
|
|
||||||
- GL: crackberg -root -flat -lit -crack -color \
|
|
||||||
random \n\
|
|
||||||
- GL: glhanoi -root \n\
|
|
||||||
- GL: cube21 -root -colormode six \n\
|
|
||||||
- GL: timetunnel -root \n\
|
|
||||||
- GL: juggler3d -root \n\
|
|
||||||
- xdaliclock -root -builtin3 -cycle \n\
|
|
||||||
- default-n: xearth -nofork -nostars -ncolors 50 \
|
|
||||||
-night 3 -wait 0 -timewarp 400.0 -pos \
|
|
||||||
sunrel/38/-30 \n\
|
|
||||||
- xplanet -vroot -wait 1 -timewarp 90000 \
|
|
||||||
-label -origin moon \n\
|
|
||||||
- xmountains -b -M -Z 0 -r 1 \n\
|
|
||||||
- "XMountains (top)" xmountains -b -M -Z 0 -r 1 -m \n\
|
|
||||||
- xaos -root -autopilot -nogui -delay 10000 \
|
|
||||||
-maxframerate 30 -incoloring -1 \
|
|
||||||
-outcoloring -1 \n\
|
|
||||||
- xfishtank -d -s \n\
|
|
||||||
- xsnow \n\
|
|
||||||
- goban -root \n\
|
|
||||||
- electricsheep \n\
|
|
||||||
- cosmos -root \n\
|
|
||||||
- GL: sphereEversion --root \n\
|
|
||||||
- GL: fireflies -root \n\
|
|
||||||
|
|
||||||
|
|
||||||
pointerPollTime: 0:00:05
|
|
||||||
pointerHysteresis: 10
|
|
||||||
windowCreationTimeout:0:00:30
|
|
||||||
initialDelay: 0:00:00
|
|
||||||
sgiSaverExtension: True
|
|
||||||
xidleExtension: True
|
|
||||||
GetViewPortIsFullOfLies:False
|
|
||||||
procInterrupts: True
|
|
||||||
overlayStderr: True
|
|
||||||
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
SUBSYSTEM=="3dfx", KERNEL=="3dfx", NAME="3dfx", MODE="0666"
|
|
||||||
@@ -1,21 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
MODE="${1:-}"
|
|
||||||
|
|
||||||
case "$MODE" in
|
|
||||||
640x480|800x600|1024x768) ;;
|
|
||||||
*)
|
|
||||||
echo "Usage: $0 {640x480|800x600|1024x768}" >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
echo "$MODE" > "$HOME/.resolution.config"
|
|
||||||
|
|
||||||
if xmessage -center -buttons Yes:0,No:1 \
|
|
||||||
"Changed resolution to $MODE.
|
|
||||||
Should we restart X now ?"; then
|
|
||||||
echo "$MODE" > "$HOME/.resolution.config"
|
|
||||||
killall fluxbox
|
|
||||||
fi
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
[submenu] (RetroDebian) </usr/share/icons/gnome/24x24/apps/gnome-favorites.png>
|
|
||||||
[exec] (Terminal) {urxvt} </usr/share/icons/gnome/24x24/apps/gnome-terminal.png>
|
|
||||||
[exec] (Terminal (root\)) {gksu urxvt} </usr/share/icons/gnome/24x24/apps/gnome-terminal.png>
|
|
||||||
[exec] (Files) {pcmanfm} </usr/share/icons/gnome/32x32/apps/file-manager.png>
|
|
||||||
[exec] (Text Editor) {leafpad} </usr/share/icons/gnome/24x24/apps/text-editor.png>
|
|
||||||
[exec] (Task Manager) {urxvt -e htop} </usr/share/icons/gnome/24x24/apps/gnome-monitor.png>
|
|
||||||
[exec] (Samba Mount) {LinNeighborhood} </usr/share/icons/LinNeighborhood.xpm>
|
|
||||||
[exec] (Archives) {xarchiver} </usr/share/icons/xarchiver.png>
|
|
||||||
[separator]
|
|
||||||
[exec] (xeji) {xeji} </usr/share/icons/gnome/48x48/apps/eyes.png>
|
|
||||||
[separator]
|
|
||||||
[submenu] (Resolution) </usr/share/icons/gnome/24x24/apps/gnome-monitor.png>
|
|
||||||
[exec] (640x480) {/opt/retrodebian/bin/set-resolution 640x480}
|
|
||||||
[exec] (800x600) {/opt/retrodebian/bin/set-resolution 800x600}
|
|
||||||
[exec] (1024x768) {/opt/retrodebian/bin/set-resolution 1024x768}
|
|
||||||
[end]
|
|
||||||
[submenu] (Games) </usr/share/icons/gnome/24x24/apps/gnome-joystick.png>
|
|
||||||
[exec] (ut99) {/usr/local/games/ut99/ut} </usr/share/icons/ut99.png>
|
|
||||||
[end]
|
|
||||||
[submenu] (Tools) </usr/share/icons/gnome/24x24/apps/gnome-control-center.png>
|
|
||||||
[end]
|
|
||||||
[submenu] (Diags) </usr/share/icons/gnome/24x24/apps/gnome-cpu.png>
|
|
||||||
[exec] (v2-tmu-memtester) {urxvt -e sh -c '/usr/local/bin/v2-tmu-memtester --help; exec bash'}
|
|
||||||
[end]
|
|
||||||
[end]
|
|
||||||
[separator]
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
SRC="/etc/X11/fluxbox/fluxbox-menu"
|
|
||||||
DST_DIR="/var/run/retrodebian"
|
|
||||||
DST="$DST_DIR/final-fluxbox-menu"
|
|
||||||
TEMPLATE="/opt/retrodebian/fluxbox/retrodebian-menu.section"
|
|
||||||
|
|
||||||
mkdir -p "$DST_DIR"
|
|
||||||
|
|
||||||
TMP="$DST.tmp"
|
|
||||||
|
|
||||||
logger -t "fluxbox/update-menu.sh" "Regenerating menus..."
|
|
||||||
|
|
||||||
sed \
|
|
||||||
-e '/(Eterm/d' \
|
|
||||||
-e '/(Rxvt-Unicode (Black/d' \
|
|
||||||
-e '/(XTerm/d' \
|
|
||||||
"$SRC" > "$TMP.base"
|
|
||||||
|
|
||||||
if [ -f "$TEMPLATE" ]; then
|
|
||||||
awk -v template="$TEMPLATE" '
|
|
||||||
BEGIN { inserted = 0 }
|
|
||||||
{
|
|
||||||
print
|
|
||||||
if (!inserted && $0 ~ /^\[begin\] /) {
|
|
||||||
while ((getline line < template) > 0) {
|
|
||||||
print line
|
|
||||||
}
|
|
||||||
close(template)
|
|
||||||
inserted = 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
' "$TMP.base" > "$TMP"
|
|
||||||
else
|
|
||||||
mv "$TMP.base" "$TMP"
|
|
||||||
fi
|
|
||||||
|
|
||||||
rm -f "$TMP.base"
|
|
||||||
mv "$TMP" "$DST"
|
|
||||||
|
|
||||||
fluxbox-remote reconfigure >/dev/null 2>&1 || true
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
SRC="/etc/X11/fluxbox/fluxbox-menu"
|
|
||||||
UPD_SCRIPT="/opt/retrodebian/fluxbox/update-menu.sh"
|
|
||||||
|
|
||||||
# initial generate
|
|
||||||
"$UPD_SCRIPT"
|
|
||||||
|
|
||||||
inotifywait -m -e modify -e move_self -e close_write "$SRC" 2>/dev/null |
|
|
||||||
while read dummy; do
|
|
||||||
"$UPD_SCRIPT"
|
|
||||||
done
|
|
||||||
@@ -1,128 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# autoconfig.sh
|
|
||||||
# search and map pci gpu deviced to xorg modules
|
|
||||||
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
DEST_XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$DEST_XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
pci_line="$(lspci -nnm | grep -F '[0300]' | head -1)" || exit 1
|
|
||||||
PCI_ADDR="$(echo "$pci_line" | awk '{print $1}')"
|
|
||||||
|
|
||||||
pci_line_raw="$(lspci -nm -s "$PCI_ADDR" | head -1)" || exit 1
|
|
||||||
|
|
||||||
PCI_VENDOR_ID="$(echo "$pci_line_raw" | awk -F'"' '{print $4}')"
|
|
||||||
PCI_DEVICE_ID="$(echo "$pci_line_raw" | awk -F'"' '{print $6}')"
|
|
||||||
|
|
||||||
RAW_BUS="$(echo "$pci_line_raw" | awk '{print $1}')"
|
|
||||||
|
|
||||||
case "$RAW_BUS" in
|
|
||||||
*:*:*.*)
|
|
||||||
PCI_DOMAIN="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $1}')"
|
|
||||||
PCI_BUS="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $2}')"
|
|
||||||
PCI_DEV="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $3}')"
|
|
||||||
PCI_FUNC="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $4}')"
|
|
||||||
;;
|
|
||||||
*:*.*)
|
|
||||||
PCI_DOMAIN="0000"
|
|
||||||
PCI_BUS="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $1}')"
|
|
||||||
PCI_DEV="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $2}')"
|
|
||||||
PCI_FUNC="$(echo "$RAW_BUS" | awk -F'[:.]' '{print $3}')"
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
echo "ERROR: invalid PCI address format: $RAW_BUS" >&2
|
|
||||||
exit 2
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [ "$PCI_DOMAIN" = "0000" ]; then
|
|
||||||
XORG_BUSID="PCI:$((16#$PCI_BUS)):$((16#$PCI_DEV)):$PCI_FUNC"
|
|
||||||
else
|
|
||||||
XORG_BUSID=""
|
|
||||||
echo "WARNING: non-zero PCI domain detected, skipping BusID on old Xorg"
|
|
||||||
fi
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "GPU detected !"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Line : $pci_line"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Address : $PCI_ADDR"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Vendor : $PCI_VENDOR_ID"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Device : $PCI_DEVICE_ID"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " RawBus : $RAW_BUS"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Domain : $PCI_DOMAIN"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Bus : $PCI_BUS"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Dev : $PCI_DEV"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " Func : $PCI_FUNC"
|
|
||||||
logger -t retrodebian-xorg-autoconfig " XorgBusID : $XORG_BUSID"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ROOT_DIR="/opt/retrodebian/xorg"
|
|
||||||
XORG_FILE_BASENAME="xorg.conf"
|
|
||||||
TEMPLATE_XORG_FILE="${XORG_FILE_BASENAME}.template"
|
|
||||||
TMP_XORG_FILE_PATH="$(mktemp)"
|
|
||||||
|
|
||||||
cp "${ROOT_DIR}/${TEMPLATE_XORG_FILE}" "${TMP_XORG_FILE_PATH}"
|
|
||||||
|
|
||||||
MATCHED=0
|
|
||||||
|
|
||||||
for module in "${ROOT_DIR}/video-detect.d/"*.sh; do
|
|
||||||
[ -f "$module" ] || continue
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Trying module: $module"
|
|
||||||
|
|
||||||
if PCI_ADDR="$PCI_ADDR" \
|
|
||||||
PCI_VENDOR_ID="$PCI_VENDOR_ID" \
|
|
||||||
PCI_DEVICE_ID="$PCI_DEVICE_ID" \
|
|
||||||
XORG_BUSID="$XORG_BUSID" \
|
|
||||||
"$module" "${TMP_XORG_FILE_PATH}"
|
|
||||||
then
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Matched module: $module"
|
|
||||||
MATCHED=1
|
|
||||||
break
|
|
||||||
else
|
|
||||||
rc=$?
|
|
||||||
if [ "$rc" -ne 1 ]; then
|
|
||||||
logger -p daemon.err -t retrodebian-xorg-autoconfig "ERROR: module failed: $module"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
if [ -n "$XORG_BUSID" ]; then
|
|
||||||
sed -i -e "s|{DeviceBusID}|$XORG_BUSID|g" "${TMP_XORG_FILE_PATH}" || exit 2
|
|
||||||
else
|
|
||||||
sed -i \
|
|
||||||
-e '/^[[:space:]]*BusID[[:space:]]*"{DeviceBusID}"[[:space:]]*$/d' \
|
|
||||||
"${TMP_XORG_FILE_PATH}" || exit 2
|
|
||||||
fi
|
|
||||||
|
|
||||||
[ "$MATCHED" -eq 1 ] || exit 2
|
|
||||||
|
|
||||||
MATCHED=0
|
|
||||||
|
|
||||||
for module in "${ROOT_DIR}/mouse-detect.d/"*.sh; do
|
|
||||||
[ -f "$module" ] || continue
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Trying module: $module"
|
|
||||||
|
|
||||||
if "$module" "${TMP_XORG_FILE_PATH}"
|
|
||||||
then
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Matched module: $module"
|
|
||||||
MATCHED=1
|
|
||||||
break
|
|
||||||
else
|
|
||||||
rc=$?
|
|
||||||
if [ "$rc" -ne 1 ]; then
|
|
||||||
logger -p daemon.err -t retrodebian-xorg-autoconfig "ERROR: module failed: $module"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
[ "$MATCHED" -eq 1 ] || exit 2
|
|
||||||
|
|
||||||
cp -f "${TMP_XORG_FILE_PATH}" "$DEST_XORG_CONF"
|
|
||||||
rm -f "${TMP_XORG_FILE_PATH}"
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 01000-mouse-qemu-tablet.sh
|
|
||||||
# Prefer QEMU USB Tablet when present
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
[ -r /proc/bus/input/devices ] || exit 1
|
|
||||||
|
|
||||||
EVENT_DEV="$(awk '
|
|
||||||
BEGIN { RS=""; FS="\n" }
|
|
||||||
$0 ~ /QEMU USB Tablet/ {
|
|
||||||
for (i = 1; i <= NF; i++) {
|
|
||||||
if ($i ~ /^H: Handlers=/ && match($i, /event[0-9]+/)) {
|
|
||||||
print "/dev/input/" substr($i, RSTART, RLENGTH)
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}' /proc/bus/input/devices)"
|
|
||||||
|
|
||||||
[ -n "$EVENT_DEV" ] || exit 1
|
|
||||||
[ -e "$EVENT_DEV" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring QEMU tablet mouse: $EVENT_DEV"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{InputDeviceDriver}|evdev|g" \
|
|
||||||
-e "s|{InputDeviceDevice}|$EVENT_DEV|g" \
|
|
||||||
-e "s|{InputDeviceProtocol}|auto|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 02000-mouse-wacom.sh
|
|
||||||
# Prefer wacom for explicit Wacom devices
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
[ -r /proc/bus/input/devices ] || exit 1
|
|
||||||
|
|
||||||
EVENT_DEV="$(awk '
|
|
||||||
BEGIN { RS=""; FS="\n" }
|
|
||||||
$0 ~ /Wacom/ {
|
|
||||||
for (i = 1; i <= NF; i++) {
|
|
||||||
if ($i ~ /^H: Handlers=/ && match($i, /event[0-9]+/)) {
|
|
||||||
print "/dev/input/" substr($i, RSTART, RLENGTH)
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}' /proc/bus/input/devices)"
|
|
||||||
|
|
||||||
[ -n "$EVENT_DEV" ] || exit 1
|
|
||||||
[ -e "$EVENT_DEV" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring Wacom pointer: $EVENT_DEV"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{InputDeviceDriver}|wacom|g" \
|
|
||||||
-e "s|{InputDeviceDevice}|$EVENT_DEV|g" \
|
|
||||||
-e "s|{InputDeviceProtocol}|auto|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 03000-mouse-synaptics.sh
|
|
||||||
# Prefer synaptics for obvious touchpads
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
[ -r /proc/bus/input/devices ] || exit 1
|
|
||||||
|
|
||||||
EVENT_DEV="$(awk '
|
|
||||||
BEGIN { RS=""; FS="\n" }
|
|
||||||
$0 ~ /SynPS\/2/ || $0 ~ /TouchPad/ || $0 ~ /Touchpad/ || $0 ~ /ALPS/ || $0 ~ /Synaptics/ {
|
|
||||||
for (i = 1; i <= NF; i++) {
|
|
||||||
if ($i ~ /^H: Handlers=/ && match($i, /event[0-9]+/)) {
|
|
||||||
print "/dev/input/" substr($i, RSTART, RLENGTH)
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}' /proc/bus/input/devices)"
|
|
||||||
|
|
||||||
[ -n "$EVENT_DEV" ] || exit 1
|
|
||||||
[ -e "$EVENT_DEV" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring Synaptics touchpad: $EVENT_DEV"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{InputDeviceDriver}|synaptics|g" \
|
|
||||||
-e "s|{InputDeviceDevice}|$EVENT_DEV|g" \
|
|
||||||
-e "s|{InputDeviceProtocol}|auto-dev|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 09900-mouse-proc-handler.sh
|
|
||||||
# prefer a direct /dev/input/mouseN handler over /dev/input/mice
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
[ -r /proc/bus/input/devices ] || exit 1
|
|
||||||
|
|
||||||
MOUSE_DEV="$(awk '
|
|
||||||
BEGIN { RS=""; FS="\n" }
|
|
||||||
{
|
|
||||||
for (i = 1; i <= NF; i++) {
|
|
||||||
if ($i ~ /^H: Handlers=/ && match($i, /mouse[0-9]+/)) {
|
|
||||||
print "/dev/input/" substr($i, RSTART, RLENGTH)
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}' /proc/bus/input/devices)"
|
|
||||||
|
|
||||||
[ -n "$MOUSE_DEV" ] || exit 1
|
|
||||||
[ -e "$MOUSE_DEV" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring direct mouse handler fallback: $MOUSE_DEV"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{InputDeviceDriver}|mouse|g" \
|
|
||||||
-e "s|{InputDeviceDevice}|$MOUSE_DEV|g" \
|
|
||||||
-e "s|{InputDeviceProtocol}|ImPS/2|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 99999-mouse-fallback.sh
|
|
||||||
# ultimate fallback
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring ultimate Mouse fallback"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{InputDeviceDriver}|mouse|g" \
|
|
||||||
-e "s|{InputDeviceDevice}|/dev/input/mice|g" \
|
|
||||||
-e "s|{InputDeviceProtocol}|auto|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 01000-i810.sh
|
|
||||||
# Intel i810/i815/830M/845G/852GM/855GM/865G family
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "8086" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
7121|7123|7125|1132|3577|3582|358e|2562|2572)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring Intel i810-family for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i -e 's|{DeviceDriver}|i810|g' "$XORG_CONF" || exit 2
|
|
||||||
exit 0
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 01050-i740.sh
|
|
||||||
# Intel i740
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "8086" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
7800)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring Intel i740 for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i -e 's|{DeviceDriver}|i740|g' "$XORG_CONF" || exit 2
|
|
||||||
exit 0
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 1100-3dfx-banshee-voodoo345.sh
|
|
||||||
# match 3dfx cards supported by Xorg tdfx driver
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "121a" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
0003|0004|0005|0009)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring 3dfx tdfx for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|tdfx|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 2000-nvidia-generic.sh
|
|
||||||
# match old NVIDIA cards supported by Xorg nv driver
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "10de" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring NVIDIA nv for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|nv|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 3000-ati-generic.sh
|
|
||||||
# match ATI cards through Xorg ati wrapper
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "1002" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring ATI ati for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|ati|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 4000-s3-trio.sh
|
|
||||||
# match S3 Trio family
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "5333" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
8810|8811|8812|8813|8814)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring S3 Trio s3 for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|s3|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 4100-s3-virge.sh
|
|
||||||
# match S3 ViRGE family
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "5333" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
5631|883d|8a01)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring S3 ViRGE s3virge for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|s3virge|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 5000-sis-generic.sh
|
|
||||||
# match common SiS families supported by Xorg sis driver
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "1039" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
0200|0300|0310|0325|0330|6306|6325|6326)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring SiS sis for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|sis|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 6000-matrox-generic.sh
|
|
||||||
# match Matrox cards through Xorg mga driver
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "102b" ] || exit 1
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring Matrox mga for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|mga|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# 7000-s3-savage-generic.sh
|
|
||||||
# match S3 Savage family through Xorg savage driver
|
|
||||||
|
|
||||||
XORG_CONF="$1"
|
|
||||||
|
|
||||||
[ -n "$XORG_CONF" ] || exit 2
|
|
||||||
[ -f "$XORG_CONF" ] || exit 2
|
|
||||||
|
|
||||||
[ "$PCI_VENDOR_ID" = "5333" ] || exit 1
|
|
||||||
|
|
||||||
case "$PCI_DEVICE_ID" in
|
|
||||||
8a20|8a21|8a22|8a23|8c10|8c11|8c12|8c13|9102|9104|9105|9106|9107|9110|9111|9112|9113|9120|9121|9122|9123|8d01|8d02|8d03|8d04)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
logger -t retrodebian-xorg-autoconfig "Configuring S3 Savage savage for $PCI_DEVICE_NAME [$PCI_DEVICE_ID]"
|
|
||||||
|
|
||||||
sed -i \
|
|
||||||
-e "s|{DeviceDriver}|savage|g" \
|
|
||||||
"$XORG_CONF" || exit 2
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user