Upgrade dependencies and install xapian from sources

This commit is contained in:
2024-06-22 21:15:37 +02:00
parent ee437649f0
commit 5416d88c97
5 changed files with 852 additions and 666 deletions

View File

@ -9,7 +9,6 @@ Certaines dépendances sont nécessaires niveau système :
* poetry
* libssl
* libjpeg
* libxapian-dev
* zlib1g-dev
* python
* gettext
@ -76,13 +75,13 @@ Sur Ubuntu
# Sait-on jamais
sudo apt update
sudo apt install python-is-python3 # Permet d'utiliser python au lieu de python3, c'est optionel
sudo apt install python-is-python3 # Permet d'utiliser python au lieu de python3, c'est optionnel
sudo apt install build-essentials libssl-dev libjpeg-dev zlib1g-dev python-dev \
libffi-dev python-dev-is-python3 libgraphviz-dev pkg-config libxapian-dev \
gettext git
libffi-dev python-dev-is-python3 libgraphviz-dev pkg-config \
gettext git pipx
curl -sSL https://install.python-poetry.org | python -
pipx install poetry
.. note::
@ -92,22 +91,21 @@ Sur Ubuntu
Sur MacOS
~~~~~~~~~
Pour installer les dépendances, il est fortement recommandé d'installer le gestionnaire de paquets `homebrew <https://brew.sh/index_fr>`_.
Pour installer les dépendances, il est fortement recommandé d'installer le gestionnaire de paquets `homebrew <https://brew.sh/index_fr>`_.
Il est également nécessaire d'avoir installé xcode
.. sourcecode:: bash
brew install git python xapian graphviz poetry
# Si vous aviez une version de python ne venant pas de homebrew
brew link --overwrite python
echo 'export PATH="$(brew --prefix graphviz)/bin:$PATH"' >> ~/.zshrc
echo 'export CFLAGS="-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I $(brew --prefix graphviz)/include"' >> ~/.zshrc
echo 'export LDFLAGS="-L /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib -L $(brew --prefix graphviz)/lib"' >> ~/.zshrc
brew install git python graphviz pipx
pipx install poetry
# Pour bien configurer gettext
brew link gettext # (suivez bien les instructions supplémentaires affichées)
# Pour installer poetry
pip3 install poetry
.. note::
Si vous rencontrez des erreurs lors de votre configuration, n'hésitez pas à vérifier l'état de votre installation homebrew avec :code:`brew doctor`
@ -134,6 +132,9 @@ Finaliser l'installation
# Activation de l'environnement virtuel
poetry shell
# Installe xapian
python manage.py install_xapian
# Prépare la base de données
python manage.py setup