erplibre/script/install/install_dev.sh
Mathieu Benoit 7120732c25 [ADD] install: openSUSE support, mirrors and packages
Tumbleweed is the only catalog entry whose qpdf already clears the pikepdf
threshold: 12.3.2 against 12.2 required, so the half-hour qpdf build under
s390x emulation never runs there. It is also the only family foreign to
both RHEL and Debian, and it brings zypper, absent from the repository:
wired into the install_dev.sh dispatch, a dependency script, the remote
bootstrap and the desktop block.

Four SUSE traps, all met on real machines. Global options precede the
subcommand, and misplaced ones abort the call; without
"--auto-agree-with-licenses" zypper waits for an answer nobody gives in a
detached install. A compat package that PROVIDES another under a different
name makes zypper raise a conflict and drop the whole batch, so only what
nothing already provides is requested. pkg-config no longer exists as an
RPM, only as a capability. And a single mirror, unreachable one day, sent
everyone back to Europe -- three are probed in order now.

CentOS Stream is dropped again: it served as a canary but 10 duplicates
what Alma and Rocky already cover.

--- FR ---

Tumbleweed est la seule entrée du catalogue dont qpdf franchit déjà le
seuil de pikepdf : 12.3.2 contre 12.2 exigé, si bien que la demi-heure de
compilation de qpdf sous émulation s390x ne s'y déclenche jamais. C'est
aussi la seule famille étrangère à RHEL comme à Debian, et elle apporte
zypper, absent du dépôt : câblé dans l'aiguillage d'install_dev.sh, un
script de dépendances, l'amorçage distant et le bloc bureau.

Quatre pièges SUSE, tous rencontrés sur machine réelle. Les options
globales précèdent la sous-commande, mal placées elles arrêtent l'appel ;
sans « --auto-agree-with-licenses » zypper attend une réponse que personne
ne donne dans une installation détachée. Un paquet compat qui FOURNIT un
autre sous un nom différent fait lever un conflit à zypper, qui abandonne
le lot entier : on ne demande donc que ce que rien ne fournit déjà.
pkg-config n'existe plus comme RPM, seulement comme capacité. Et un miroir
unique, injoignable un jour, renvoyait tout le monde en Europe — trois
sont désormais sondés dans l'ordre.

CentOS Stream repart : il servait de canari, mais 10 double ce qu'Alma et
Rocky couvrent déjà.

Assisted-by: Claude Opus 5
2026-08-16 23:33:49 -04:00

59 lines
3 KiB
Bash
Executable file

#!/usr/bin/env bash
# « $OSTYPE » ne decrit PAS le systeme : bash le fige au triplet avec lequel il
# a ete compile. openSUSE batit bash en « x86_64-suse-linux » et le renseigne
# donc a « linux », la ou Debian et Fedora donnent « linux-gnu ». Le test
# echouait, sans else, donc sans une ligne de sortie ni code d'erreur : AUCUNE
# dependance systeme n'etait posee, install_system() rendait 0, et
# l'installation s'arretait une heure plus tard sur « [Errno 2] ... 'cc' ».
# « uname -s » interroge le noyau et ne depend pas de la facon dont bash a ete
# bati. install_dev_extra_ubuntu.sh garde OSTYPE : il ne vise qu'Ubuntu.
OS_KERNEL="$(uname -s)"
if [[ "${OS_KERNEL}" == "Linux" ]]; then
source /etc/os-release
if [[ "${ID}" == "ubuntu" ]]; then
# 20.04 et 22.04 retirees : leur chaine d'outils ne suffit plus a ERPLibre
# (pikepdf exige qpdf >= 12.2, en C++20, quand focal livre GCC 9). Les
# versions intermediaires EOL (22.10, 23.04, 23.10, 25.04) partent avec.
if [[ "${VERSION_ID}" == "24.04" || "${VERSION_ID}" == "25.10" || "${VERSION_ID}" == "26.04" ]]; then
echo "\n---- linux-gnu installation process started ----"
./script/install/install_debian_dependency.sh
else
echo "Your version is not supported, only support 24.04, 25.10, 26.04 : ${VERSION_ID}"
exit 1
fi
elif [[ "${ID}" == "linuxmint" ]]; then
if [[ "${VERSION_ID}" == "22.3" ]]; then
echo "\n---- linux-gnu installation process started ----"
./script/install/install_debian_dependency.sh
else
echo "Your version is not supported, only support 22.3 : ${VERSION_ID}"
fi
elif [[ "${ID}" == "debian" ]]; then
./script/install/install_debian_dependency.sh
elif [[ "${ID}" == "arch" ]]; then
./script/install/install_arch_linux.sh
elif [[ "${ID}" == opensuse* || "${ID_LIKE}" == *"suse"* ]]; then
# openSUSE Tumbleweed / Leap, SLES : gestionnaire zypper.
echo "\n---- SUSE installation process started ----"
./script/install/install_suse_dependency.sh
elif [[ "${ID}" == "fedora" || "${ID_LIKE}" == *"fedora"* || "${ID_LIKE}" == *"rhel"* ]]; then
# AlmaLinux et Rocky declarent ID_LIKE="rhel centos fedora" : elles passent
# donc par ce meme script, qui aiguille dnf.
echo "\n---- Fedora/RHEL installation process started ----"
./script/install/install_fedora_dependency.sh
else
./script/install/install_debian_dependency.sh
echo "Your Linux system is not supported, only support Ubuntu 24.04, 25.10, 26.04, Linux Mint 22.3, Debian, Fedora, AlmaLinux, Rocky Linux, openSUSE, Arch."
fi
elif [[ "${OS_KERNEL}" == "Darwin" ]]; then
echo "\n---- Darwin installation process started ----"
./script/install/install_OSX_dependency.sh
else
# Un aiguillage muet qui rend 0 est le pire des cas : l'installation continue
# sur un systeme depourvu de tout. Meme sans savoir quoi poser, on le dit et
# on arrete.
echo "Systeme non reconnu (uname -s = ${OS_KERNEL}) : aucune dependance installee."
exit 1
fi