-
-
Notifications
You must be signed in to change notification settings - Fork 265
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Luarocks fails to install on macOS BigSur #180
Comments
Yeah, that's nvim-lua/plenary.nvim#4 (and the same fix - setting env var MACOSX_DEPLOYMENT_TARGET to 10.15 - works to fix it). I'm considering setting that env var by default in |
Note that you only need to set that variable once when you install the first rock (because that's when So doing this manually with |
@wbthomason that resolved the issue for me, I'm happy to close this or otherwise leave it here so you can track against doing something automagically for users or maybe to track against documenting the fix if not, whatever you prefer. |
Might be good to leave open (and pin?) for now, at least until the Readme is finalized with such instructions? |
Hi, I am having trouble running PackerSync I think it is related to this issue since it fails to spawn a plenary.nvim process and I am running macOS BigSur with the m1 chip. Any ideas on how to solve this issue?
|
@mherna: this error occurs when you run |
@wbthomason, thanks for the reply. I reinstalled neovim, and the issue got solved. Weirdly it was happening just when I ran |
@mherna Did you only reinstall neovim or did you also clean any packer packages in |
@matu3ba I cleaned |
@wbthomason I feel like "clean $HOME/.local/share/nvim/site/pack/start and $HOME/.local/share/nvim/site/pack/opt" belongs to the FAQ. The alternative is to have logging+instructions, if you want to investigate further. |
Notes from discussion with @clason on Gitter/Matrix:
|
I think I'm getting something related to this:
As far as I can tell, the The |
@garymh Your error message doesn't seem obviously related to |
@wbthomason I guess it could be something different- I'm just using a very slimmed down packer setup and still getting it. The only thing I could pick out that looked off from my packer compiled file was the luarocks path. Here is my packer loading code: local packer = nil
local function init()
if packer == nil then
packer = require('packer')
util = require("packer/util")
packer.init({
compile_path = util.join_paths(vim.fn.stdpath("config"),
"vimscript", "packer_compiled.vim"),
max_jobs = 10
})
end
local use = packer.use
packer.reset()
use {"wbthomason/packer.nvim", opt = true}
use {
"AndrewRadev/switch.vim",
cmd = {"Switch", "SwitchReverse"},
config = function()
vim.g.switch_custom_definitions =
{
{"assert", "refute"}, {"if", "unless"}, {"[ ]", "[x]"},
{"yes", "no"}, {"let g:", "vim.g."}
}
end
}
end
local plugins = setmetatable({}, {
__index = function(_, key)
init()
return packer[key]
end
})
return plugins The error message comes up when I use the |
Yeah - it seems to be something with lazy loading? 🤷 I removed all the |
I had this issue on linux. For me, the issue was that the There was no error on my end though, even though things weren't working. The hererocks install just went infinitely. |
@jacksonludwig: Thanks for the report. Could you please start a new issue with the contents of |
I just set my |
If you already have Luarocks installed via |
You can add |
Which is proper solution here? Setting up |
The environment variable is the easiest fix. Note that it is only needed to be set the very first time you install something for the |
Thanks @clason, will add what Folke posted above. I do understand importance of it on initial install only, want to have it in my dots for fresh installations anyway. Thanks guys! |
🤔 still facing the same issue |
This works for me. Cheers! |
NOTE: Use your own Mac version. I had # Possibly optional.
ln -s /usr/local/bin/python3 /usr/local/bin/python
# Start from scratch.
rm -rf ~/.cache/nvim
nvim
:lua vim.fn.setenv("MACOSX_DEPLOYMENT_TARGET", "10.15")
:PackerSync
:qa!
# If the above fails, install manually:
export MACOSX_DEPLOYMENT_TARGET=10.15
cd ~/.cache/nvim/packer_hererocks
rm -rf 2.1.0-beta3
python3 hererocks.py -j "2.1.0-beta3" "2.1.0-beta3"
# Reattempt:
nvim
:PackerSync
:qa! EDIT: The # Pretend that Lua 5.1 is LuaJIT 2.1.0-beta3:
export MACOSX_DEPLOYMENT_TARGET=10.15
cd ~/.cache/nvim/packer_hererocks
rm -rf 2.1.0-beta3
python3 hererocks.py -l "5.1" "2.1.0-beta3"
# Install rock (e.g. fzy):
nvim
:PackerSync
:qa!
# Pretend 5.4 is 5.1 is 2.1.0-beta3:
ln -s ~/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.4 \
~/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1
# Repent:
echo "Father, I repent." |
[packer.nvim](https://github.com/wbthomason/packer.nvim) has some anti-features and bugs that were a deal breaker for me: - Bootstrapping is not straightforward - Snapshots are fundamentally broken, i.e. if I removed a plugin I tried to restore a snapshot packer would not work. - Luarocks install doesn't work on macos - Packer compilation step is annoying and sometimes makes config files out of sync with the current setup, which makes debugging and plugin development awkward [lazy.nvim](https://github.com/folke/lazy.nvim) doesn't have a compilation step, doesn't require [impatient.nvim](https://github.com/lewis6991/impatient.nvim) for speeding up modules initialization, has a straightforward bootstrap process and in general has a better design than [packer.nvim](https://github.com/wbthomason/packer.nvim). SEE: wbthomason/packer.nvim#814 SEE: wbthomason/packer.nvim#1010 SEE: wbthomason/packer.nvim#180
[packer.nvim](https://github.com/wbthomason/packer.nvim) has some anti-features and bugs that were a deal breaker for me: - Bootstrapping is not straightforward - Snapshots are fundamentally broken, i.e. if I removed a plugin I tried to restore a snapshot packer would not work. - Luarocks install doesn't work on macos - Packer compilation step is annoying and sometimes makes config files out of sync with the current setup, which makes debugging and plugin development awkward [lazy.nvim](https://github.com/folke/lazy.nvim) doesn't have a compilation step, doesn't require [impatient.nvim](https://github.com/lewis6991/impatient.nvim) for speeding up modules initialization, has a straightforward bootstrap process and in general has a better design than [packer.nvim](https://github.com/wbthomason/packer.nvim). SEE: wbthomason/packer.nvim#814 SEE: wbthomason/packer.nvim#1010 SEE: wbthomason/packer.nvim#180
Just tried out my config (which I recently added a rock to) on my work mac (running BigSur not sure if that matters) and found that although the same install process seems to happen to setup luarocks via packer, the install process appears to finish but I don't think luarocks is correctly installed since further calls to install try to install luarocks again. The rock I also specified (
penlight
) is also not installed.The text was updated successfully, but these errors were encountered: