aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorRenato Maia <maia.renato@gmail.com>2025-04-27 17:03:33 -0300
committerHisham Muhammad <hisham@gobolinux.org>2025-05-19 11:30:51 -0300
commit3b7bf479568790a8b04772a36c1b3e712fed4579 (patch)
tree01b97d4dacb07ee45082b23bb9c664013f41655e /docs
parent4d7b546602b906f924ac91a01276cd3b2569ca9f (diff)
downloadluarocks-3b7bf479568790a8b04772a36c1b3e712fed4579.tar.gz
luarocks-3b7bf479568790a8b04772a36c1b3e712fed4579.tar.bz2
luarocks-3b7bf479568790a8b04772a36c1b3e712fed4579.zip
feat: add build vars. for rockspecs with the dir. of its deps.
Rockspecs can access the directory of its dependencies using variables in the format 'foo_ROCKDIR' where 'foo' is the name of a dependency. This is used to be able to access files of the rock like 'conf', 'docs' and more.
Diffstat (limited to 'docs')
-rw-r--r--docs/creating_a_rock.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/creating_a_rock.md b/docs/creating_a_rock.md
index 1d42b07f..a5441ea4 100644
--- a/docs/creating_a_rock.md
+++ b/docs/creating_a_rock.md
@@ -148,6 +148,14 @@ and `5.3`, but not yet-to-be-released `5.4`. There are a few other operators
148for specifying version constraints, see 148for specifying version constraints, see
149[Rockspec format](rockspec_format.md#dependency-information). 149[Rockspec format](rockspec_format.md#dependency-information).
150 150
151Rockspecs from [`rockspec_format = "3.1"`](rockspec_format.md#package-metadata)),
152have access to special variables with the path of the installed rocks of its
153dependencies. See the [section below](#including-documentation-and-other-files)
154for information on how rocks can include files in their installation. Each
155variable is the name of the dependency followed by the suffix `_ROCKDIR`. For
156the example above, variable `LUAKNIFE_ROCKDIR` will be provided with the path of
157the installed rock.
158
151#### C modules linking to external libraries 159#### C modules linking to external libraries
152 160
153*If your code does not use third-party libraries, you may skip this subsection.* 161*If your code does not use third-party libraries, you may skip this subsection.*