Skip to content

Commit

Permalink
vim: ensure python3 is linked dynamically on Linux
Browse files Browse the repository at this point in the history
Currently, the python3 interpreter is linked statically on Linux.
However, the embedded interpreter still needs the Python runtime to
function, and this runtime is provided by the linked Python formula.
The interpreter thus breaks whenever Python is updated, since it can no
longer find the runtime.

Let's try to fix this by making sure the interpreter is linked
dynamically instead.

See discussion at #113036.
  • Loading branch information
carlocab committed Oct 14, 2022
1 parent 534720b commit 8b6b34c
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions Formula/vim.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,8 @@ class Vim < Formula
depends_on "python@3.10"
depends_on "ruby"

conflicts_with "ex-vi",
because: "vim and ex-vi both install bin/ex and bin/view"

conflicts_with "macvim",
because: "vim and macvim both install vi* binaries"
conflicts_with "ex-vi", because: "vim and ex-vi both install bin/ex and bin/view"
conflicts_with "macvim", because: "vim and macvim both install vi* binaries"

def install
ENV.prepend_path "PATH", Formula["python@3.10"].opt_libexec/"bin"
Expand All @@ -57,12 +54,12 @@ def install
"--mandir=#{man}",
"--enable-multibyte",
"--with-tlib=ncurses",
"--with-compiledby=Homebrew",
"--with-compiledby=#{tap.user}",
"--enable-cscope",
"--enable-terminal",
"--enable-perlinterp",
"--enable-rubyinterp",
"--enable-python3interp",
"--enable-python3interp#{"=dynamic" if OS.linux?}",
"--disable-gui",
"--without-x",
"--enable-luainterp",
Expand Down

0 comments on commit 8b6b34c

Please sign in to comment.