MacOS : Subversion (SVN) ne répond plus

Aujourd’hui, je mets à jour un de mes plugins WordPress sur le dépôt officiel et subversion ne répond plus sous MacOS:

svn stat
-bash: svn: command not found

Ah tiens, il y avait longtemps. Cela doit être dû à une des mises à jour Mac ou alors d’homebrew.

Installer Subversion avec homebrew

On installe donc subversion avec homebrew:

brew install subversion

Une fois subversion installé, je relance la commande:

svn stat
-bash: svn: command not found

Oh! Je le réinstalle une nouvelle fois. Nouveau message d’erreur:

svn stat
dyld[62247]: Symbol not found: _apr_crypto_block_cleanup
  Referenced from: /usr/local/Cellar/subversion/1.14.2/lib/libsvn_subr-1.0.dylib
  Expected in: /usr/lib/libaprutil-1.0.dylib
Abort trap: 6Code language: JavaScript (javascript)

La solution de cette erreur est toute simple, il faut réinstaller le paquet apr-util :

brew reinstall apr-util

Résultat:

==> Downloading https://ghcr.io/v2/homebrew/core/apr-util/manifests/1.6.1_3
######################################################################## 100.0%
==> Downloading https://ghcr.io/v2/homebrew/core/apr-util/blobs/sha256:4459e0d3d15a973db35fb64b1da85d2185afc41e77d2989186db5574d3c75234
==> Downloading from https://pkg-containers.githubusercontent.com/ghcr1/blobs/sha256:4459e0d3d15a973db35fb64b1da85d2185afc41e77d2989186db
######################################################################## 100.0%
==> Reinstalling apr-util
==> Pouring apr-util--1.6.1_3.monterey.bottle.tar.gz
🍺  /usr/local/Cellar/apr-util/1.6.1_3: 54 files, 851.6KB
==> Running `brew cleanup apr-util`...
Disable this behaviour by setting HOMEBREW_NO_INSTALL_CLEANUP.
Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).Code language: PHP (php)

Si l’on relance de nouveau notre commande svn, tout fonctionne:

svn stat
M       trunk/better-comments.php
M       trunk/changelog.txt
M       trunk/composer.lock
M       trunk/includes/options.php
M       trunk/readme.txt
M       trunk/vendor/composer/ClassLoader.php

Et voilà, problème réglé – subversion est de nouveau opérationnel.

Recherchez-vous un expert WordPress ou WooCommerce sur qui vous pouvez compter? Ne cherchez plus.

Faites confiance à mon expertise »

Articles conseillés :

Opinions