![无法在 FreeBsd 中安装新版本的端口 -- Elixir 1.5.1 -- “2 个模块中有 1 个失败 -- 将拒绝保存到 Makefile.rej”](https://linux22.com/image/709116/%E6%97%A0%E6%B3%95%E5%9C%A8%20FreeBsd%20%E4%B8%AD%E5%AE%89%E8%A3%85%E6%96%B0%E7%89%88%E6%9C%AC%E7%9A%84%E7%AB%AF%E5%8F%A3%20--%20Elixir%201.5.1%20--%20%E2%80%9C2%20%E4%B8%AA%E6%A8%A1%E5%9D%97%E4%B8%AD%E6%9C%89%201%20%E4%B8%AA%E5%A4%B1%E8%B4%A5%20--%20%E5%B0%86%E6%8B%92%E7%BB%9D%E4%BF%9D%E5%AD%98%E5%88%B0%20Makefile.rej%E2%80%9D.png)
我正在尝试安装 Elixir 1.5 和 OTP 20。我这样做了:
pkg install erlang-runtime20
portsnap fetch extract update
并且我已将 /usr/ports/lang/elixir/Makefile 更改为指向 Elixir 和 erlang 的最新版本:
PORTVERSION= 1.5.1
BUILD_DEPENDS= erlang>=20:lang/erlang
RUN_DEPENDS= erlang>=20:lang/erlang
和
make makesum
但有一个例外:
$ sudo make install
===> License APACHE20 accepted by the user
===> elixir-1.5.1_1 depends on file: /usr/local/sbin/pkg - found
===> Fetching all distfiles required by elixir-1.5.1_1 for building
===> Extracting for elixir-1.5.1_1
=> SHA256 Checksum OK for elixir/1.5.1/Docs.zip.
=> SHA256 Checksum OK for elixir/1.5.1/elixir-lang-elixir-v1.5.1_GH0.tar.gz.
===> Patching for elixir-1.5.1_1
===> Applying FreeBSD patches for elixir-1.5.1_1
1 out of 2 hunks failed--saving rejects to Makefile.rej
=> FreeBSD patch patch-Makefile failed to apply cleanly.
*** Error code 1
Stop.
make[1]: stopped in /usr/ports/lang/elixir
*** Error code 1
Stop.
make: stopped in /usr/ports/lang/elixir
如何修复?
答案1
好吧,你不能只是碰一下PORTVERSION
然后指望它能正常工作。要么给维护者发邮件要求端口更新,要么亲自动手 - 弄清楚那个补丁有什么用,是否仍需应用,如果仍需,则刷新它。
要生成新的补丁,请将原始内容复制Makefile
到Makefile.orig
,编辑Makefile
,然后运行make makepatch
。