luarocks / luarocks-site

LuaRocks website and module host
http://luarocks.org
175 stars 38 forks source link

Problem with cmake rockspec #162

Closed blobule closed 3 years ago

blobule commented 3 years ago

I uploaded a module "nef" which must be built using cmake. Installing using: luarocks --local install nef result in: Error: Couldn't extract archive /tmp/luarocks_nef-0.1.0-0-7436482/lua-nef.git: unrecognized filename extension

However, if you get the git repo and install manually, it works fine: git clone https://gitlab.com/labv3d/lua-nef.git cd lua-nef luarocks --local make rockspec/nef-0.1.0-0.rockspec

works perfectly.

I have no clue how to fix the rockspec or if this is a bug. Thanks!

leafo commented 3 years ago

The rockspec appears to be broken: https://gitlab.com/labv3d/lua-nef/-/blob/master/rockspec/nef-0.1.0-0.rockspec

I believe the source field should point directly to a archive file if using the https:// protocol and git:// for git repositories: https://github.com/luarocks/luarocks/wiki/Rockspec-format#build-rules

BTW, this is the repo for the luarocks website, not the command line tool. If you found a bug you might want to post there: https://github.com/luarocks/luarocks/issues

blobule commented 3 years ago

Success! in gitlab, the access is through ssh, so this worked perfectly: source = { url = "git+ssh://git@gitlab.com:labv3d/lua-nef.git" , tag = "v0.1" } Thanks!