luarocks' rocks tree location: %{_libdir}/luarocks, %{_prefix}/lib/luarocks, or %{_var}/lib/luarocks?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

I'm overhauling luarocks' packaging (TL;DR, it's the Lua equivalent of
Python's pip or Rust's cargo).

Previously it flipped from being a noarch package (because the files
shipped are pure Lua code) to arched (because it hardcoded some
settings based on the system it's built on).

With recent luarocks that's no longer necessary as it can auto-detect
the installed Lua environment (I added a little patch to make it prefer
/usr/lib64 if it is available).

This works well, but ... luarocks keeps a 'rocks tree' (basically a
record of which rocks are installed and their checksums):

```
$ luarocks config | grep ROCKS
   ROCKS_TREE = "/usr/lib/luarocks/rocks-5.4",
```

The files here are mostly noarch but if the user compiles a binary
module it does record the checksum of the binary as well. e.g.

```
$ cat /usr/lib/luarocks/rocks-5.4/bit32/5.3.5.1-1/rock_manifest  
rock_manifest = {
   ["bit32-5.3.5.1-1.rockspec"] = "63172097de28df84f5de587c25d866d0",
   doc = {
      LICENSE = "47a1db9761ff46e15d0f65fbc87d4bd5",
      ["README.md"] = "0f5f506e9b1697622bf4a2e0faeb1746"
   },
   lib = {
      ["bit32.so"] = "5b35079ba129529a30f6a7f9adba309e"
   }
}
```

Would %{_var}/lib/luarocks be a better location for this? (since it's
in effect similar to /var/lib/rpm and /var/lib/dnf). Either that
location or /usr/lib would be fine for now.

If we ever want to, say, use luarocks to build lua module RPMs, this
might be a problem if we ever want 64-bit and 32-bit RPMs to be
installable. We can always get around it by stripping the rock
manifests though.

Thanks,

-- 
Michel Alexandre Salim
profile: https://keyoxide.org/michel@xxxxxxxxxxxxxxx

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
packaging mailing list -- packaging@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to packaging-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/packaging@xxxxxxxxxxxxxxxxxxxxxxx

[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite Forum]     [KDE Users]

  Powered by Linux