10000 fix(rocks): add lib64 plugin directory to package.cpath by carbon-steel · Pull Request #1717 · folke/lazy.nvim · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

fix(rocks): add lib64 plugin directory to package.cpath #1717

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

Merged
merged 1 commit into from
Aug 31, 2024

Conversation

carbon-steel
Copy link
Contributor
@carbon-steel carbon-steel commented Aug 17, 2024

Description

package.cpath is missing the lib64 directory for plugins that have luarocks dependencies.

Context

I found this issue when I was working on my new Neovim plugin on my Fedora 39 machine. I added the luasockets dependency to rockspec file in my plugin like so:

rockspec_format = "3.0"
package = "typeracer.nvim"
version = "scm-1"
source = {
	url = "git+https://github.com/carbon-steel/typeracer.nvim",
}
dependencies = {
	"luasocket",
}
test_dependencies = {
	"nlua",
}
build = {
	type = "builtin",
	copy_directories = {},
}

I found that the dynamic libraries from the luasockets dependency were installed like so: /home/username/.local/share/nvim/lazy-rocks/typeracer.nvim/lib64/lua/5.1/socket/core.so. However, the only entry related to my plugin typeracer.nvim was: /home/glyph/.local/share/nvim/lazy-rocks/typeracer.nvim/lib/lua/5.1/?.so. The issue is that we only have the plugin's lib directory in package.cpath and not lib64.

I looked through lazy.nvim's code and I think adding the lib64 directory should fix the issue. I don't know if we also want to worry about lib32 as well, but so far, this change works for me.

@carbon-steel carbon-steel changed the title Add lib64 rocks directory to package.cpath fix(rocks): Add lib64 rocks directory to package.cpath Aug 17, 2024
@carbon-steel carbon-steel changed the title fix(rocks): Add lib64 rocks directory to package.cpath fix(rocks): Add lib64 plugin directory to package.cpath Aug 17, 2024
@carbon-steel
Copy link
Contributor Author

I'm not sure how to fix the failing PR title job :/

@folke folke changed the title fix(rocks): Add lib64 plugin directory to package.cpath fix(rocks): add lib64 plugin directory to package.cpath Aug 31, 2024
@folke folke merged commit 80da254 into folke:main Aug 31, 2024
9 of 10 checks passed
@folke
Copy link
Owner
folke commented Aug 31, 2024

ty!

folke pushed a commit that referenced this pull request Nov 11, 2024
🤖 I have created a release *beep* *boop*
---


##
[11.14.2](v11.14.1...v11.14.2)
(2024-11-10)


### Bug Fixes

* **bootstrap:** single forward slash. Fixes
[#1747](#1747)
([aca30f6](aca30f6))
* **completion:** check if command string is a prefix of Lazy
([#1760](#1760))
([e9fd76e](e9fd76e)),
closes [#1758](#1758)
* **docs:** always update helptags for local plugins
([60cf258](60cf258))
* **luarocks:** try to install from root manifest
([#1687](#1687))
([591ef40](591ef40))
* **rocks:** add lib64 plugin directory to package.cpath
([#1717](#1717))
([80da254](80da254))
* **rockspec:** allow binary lua files. Fixes
[#1800](#1800)
([408449a](408449a))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0