1. 概要
発生は、2024年7月8日。
「FreeBSD 13.3 RELEASE」「FreeBSD 14.0 RELEASE」で発生しました。
「python 3.11」以外の「python」のバージョンで発生するのかは、わかりません。
2. 状況
$ portversion -v | grep '<'
[Reading data from pkg(8) ... - 599 packages found - done]
py311-certifi-2024.6.2 < needs updating (port has 2024.7.4)
py311-myst-parser-3.0.1 < needs updating (port has 3.0.1_1)
py311-six-1.16.0 < needs updating (port has 1.16.0_1)
py311-toml-0.10.2 < needs updating (port has 0.10.2_1)
py311-xml2rfc-3.22.0 < needs updating (port has 3.22.0_1)
という状況で。
portupgrade -Rr py311-xml2rfc
すると。
[Reading data from pkg(8) ... - 687 packages found - done]
[Gathering depends for textproc/xml2rfc ................................. done]
[Exclude up-to-date packages ............. done]
---> Upgrading 'py311-xml2rfc-3.22.0' to 'py311-xml2rfc-3.22.0_1' (textproc/xml2rfc)
---> Building '/usr/ports/textproc/xml2rfc'
===> Cleaning for py311-pyyaml-6.0.1
・・・ 略 ・・・
===> Checking if py311-pyyaml is already installed
===> Registering installation for py311-pyyaml-6.0.1 as automatic
Installing py311-pyyaml-6.0.1...
pkg-static: py311-pyyaml-6.0.1 conflicts with py311-yaml-6.0.1 (installs files into the same place). Problematic file: /usr/local/lib/python3.11/site-packages/PyYAML-6.0.1-py3.11.egg-info/PKG-INFO
*** Error code 1
Stop.
make[2]: stopped in /usr/ports/devel/py-pyyaml
*** Error code 1
Stop.
make[1]: stopped in /usr/ports/devel/py-pyyaml
*** Error code 1
Stop.
make: stopped in /usr/ports/textproc/xml2rfc
egrep: empty (sub)expression
** Command failed [exit code 1]: /usr/bin/script -qa /tmp/portupgrade20240708-1339-5i98mf env UPGRADE_TOOL=portupgrade UPGRADE_PORT=py311-xml2rfc-3.22.0 UPGRADE_PORT_VER=3.22.0 make
** Fix the problem and try again.
** Listing the failed packages (-:ignored / *:skipped / !:failed)
! textproc/xml2rfc (py311-xml2rfc-3.22.0) (unknown build error)
ちゅうことになります。
なんか、「conflicts」が発生しちょる、ちゅうことです。
3. 試行錯誤
とりあえず、「py311-pyyaml」ちゅうのをアンインストールしてみます。
cd /usr/ports/devel/py-pyyaml
make deinstall clean
その上で。
portupgrade -Rr py311-xml2rfc
しても同じ結果になります。
4. 解決
仕方ないので、いささか強引なことをします。
rm -R /usr/local/lib/python3.11/site-packages/PyYAML-6.0.1-py3.11.egg-info
して。
pkg remove py311-yaml
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 3 packages (of 0 packages in the universe):
Installed packages to be REMOVED:
py311-myst-parser: 3.0.1
py311-xml2rfc: 3.22.0
py311-yaml: 6.0.1
Number of packages to be removed: 3
The operation will free 6 MiB.
Proceed with deinstalling packages? [y/N]:
yEnter します。
そのうえで。
cd /usr/ports/devel/py-pyyaml
make deinstall clean
make
make reinstall
次に。
cd /usr/ports/textproc/xml2rfc
make deinstall clean
make
make reinstall
これで、アップグレードできたようです。