summaryrefslogtreecommitdiff
path: root/src/luarocks/deps.lua (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* check types in report_missing_dependenciesHisham Muhammad2018-04-131-0/+6
|
* Add support for build-only dependenciesHisham Muhammad2018-04-131-3/+4
| | | | | | | | Adds the `build_dependencies` key to the rockspec format, for dependencies that are only triggered when building from source (e.g. via `luarocks build` or running `luarocks install` on a rockspec) and not when building from a packaged `.rock` file using `luarocks install`.
* Try to isolate uses of namespaced name stringsHisham Muhammad2018-04-111-1/+1
| | | | | | | | | | | | | Add asserts to uses of `name` arguments to check that they are not namespaced; rename namespace-able name arguments to `ns_name` and avoid some unrelated uses of the `name` argument that don't represent rock names (there are still others around, to be fixed eventually). This may cause some failures in some untested code paths with namespaced packages, but we hope to catch them with better testing. Better to be safe here than to perform filesystem operations on incorrect paths.
* Add support for namespaces.Hisham Muhammad2018-04-111-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For details of the new feature, see https://github.com/luarocks/luarocks/wiki/Namespaces This ended up being a huge commit because of some major refactoring motivated by the new feature: * new modules for some object types: * `luarocks.queries` - all functions that look for rocks in local or remote repositories now use objects constructed by this module: query objects contain the name, namespace and query constraints. Dependencies in a rockspec are also stored as query objects. * `luarocks.results` - all individual results produces from queries are returned in this format: result objects contain the name, namespace, version, arch and repo. * the `results` object was renamed to `result_tree`, to better reflect that it is not an array of `result` objects. * `luarocks.vers` was removed, its functionality was moved to better locations. Specifically on namespaces: * Commands that take a rock `name` can now take `namespace/name` (and alternately `--flags=namespace` so that URLs can be also installed with a nominal namespace). * Rocks installed from a namespace now create a `rock_namespace` file alongside `rock_manifest`, which is used when matching namespaced dependencies against locally-installed rocks. * Using namespaced dependencies in a rockspec, requires `rockspec_format = "3.0"`. * Tests under the `#namespaces` hashtag, all using a local repository.
* Beginning support for namespaced queriesHisham Muhammad2018-04-111-3/+3
|
* Do not require core modules from outside corePeter Melnichenko2016-11-131-1/+1
|
* Split pure version/deps operations into luarocks.vers modulePeter Melnichenko2016-11-131-142/+8
| | | | | | | luarocks.deps module used to contain version and dependency parsing functions as well as some high-level dependency handling: matching and resolving them. A lot of modules only need the parsing half. Split it into its own module, luarocks.vers.
* Fix merge of rocks_provided.Hisham2016-10-311-5/+7
| | | | | | | | | | This is now a parameter, because depending on the rockspec version the set of default rocks_provided for a rockspec may change. This is to maintain compatibility with rocks provided by LuaRocks versions in rockspec format 1.0. When checking dependencies for a rockspec, we ensure we respect that to keep backward compatibility. When we check dependencies for the manifest as a whole, we can use the larger set of rocks_provided known by the current LuaRocks version.
* Merge branch 'new-cmd-dir'Hisham2016-10-301-207/+37
|\
| * Move admin commands to luarocks.admin.cmd.*; fix references to modules.Hisham2016-10-291-1/+1
| |
| * Core modules reorganization.Hisham2016-06-301-199/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Isolate all modules used by luarocks.loader in a luarocks.core.* namespace. Core modules can only require other core modules, and they only use require() at the top-level chunk. In other words, after luarocks.loader is setup, package.path can be altered at will and it should not affect the ability of luarocks.loader to run, and the luarocks.loader modules should not interfere with modules loaded later. This was motivated by @robooo's GSoC work on porting the LuaRocks test suite to Lua using Busted. Busted itself runs using luarocks.loader, and we need to ensure that the modules loaded by the tests do not conflict with the ones used by luarocks.loader. A circular dependency between luarocks.manif and luarocks.search was removed by creating a separate luarocks.manif.writer module. Also, luarocks-admin commands were moved to a luarocks.admin.* namespace.
| * Remove now unused function deps.deps_mode_to_flagPeter Melnichenko2016-06-131-4/+0
| |
| * Merge branch 'master' into luarocks-3Peter Melnichenko2016-06-131-1/+1
| |\
| * \ Merge branch 'master' into luarocks-3Peter Melnichenko2016-06-131-69/+60
| |\ \
| * \ \ Merge branch 'master' into luarocks-3Hisham2016-05-031-1/+1
| |\ \ \
| * \ \ \ Merge branch 'master' into luarocks-3mpeterv2016-04-161-9/+13
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/luarocks/deps.lua
| * | | | | avoid "missing dependency" errors for defaultsPierre Chapuis2016-01-021-1/+4
| | | | | |
| * | | | | Merge branch 'master' into luarocks-3Hisham Muhammad2015-12-051-19/+34
| |\ \ \ \ \
| * | | | | | Support "luajit" as a provided dependency in rockspec format 3.0Hisham Muhammad2015-10-191-9/+13
| | | | | | |
| * | | | | | Check that rockspec format is at least 3.0 before fetching submodulesmpeterv2015-06-261-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | For utility, add deps.format_is_at_least(rockspec, version) function.
* | | | | | | Get rid of repeated missing deps checksPeter Melnichenko2016-10-301-34/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not report missing dependencies on manifest update, which is now done more often. Instead do it at the end of commands that may alter manifest (install, build, make, remove - excluding purge). For reporting reuse format used when showing missing deps to be installed. Do not report missing indirect dependencies, only direct ones.
* | | | | | | Remove some unused locals and importsPeter Melnichenko2016-10-201-1/+0
| |_|_|_|_|/ |/| | | | |
* | | | | | Use install.command instead of install.run in luarocks.depsPeter Melnichenko2016-06-131-1/+1
| |_|_|_|/ |/| | | |
* | | | | Remove commented module() callsPeter Melnichenko2016-05-311-1/+0
| | | | |
* | | | | Refactor match_dep()Peter Melnichenko2016-05-161-31/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Instead of applying blacklist and sorting versions in separate steps do a single pass over the list. * On success return just the version instead of {name = name, version = version} since rock name is stored inside dependency table already.
* | | | | Return missing deps listing in `luarocks install` outputPeter Melnichenko2016-05-141-4/+21
| | | | |
* | | | | Announce each missing dep before its installPeter Melnichenko2016-05-101-41/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of lising all missing deps before installing all of them, announce each missing dep right before installing it. Also show current rock versions for missing deps.
* | | | | Shorten logging for `luarocks install`Peter Melnichenko2016-05-101-0/+1
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of mentioning URL twice in Installing URL... Using URL... switching to 'build' mode simply print Installing URL and don't print URL at all when it's the argument to `luarocks install` (it's a bit redundant), only when it's a result of a search.
* | | | Show search error in functions using find_suitable_rockmpeterv2016-04-191-1/+1
| |_|/ |/| |
* | | Don't handle multiple rock queries in find_suitable_rockmpeterv2016-03-201-4/+4
| | | | | | | | | | | | | | | | | | In practice search.find_suitable_rock is always called with a precise query (no fuzzy name matching), and not all callers handle table as return value correctly.
* | | Make sure deps-mode is respected when recursing the dependency chain.Hisham2016-03-011-1/+1
| | |
* | | Fix trailing space in dep.show_dep on dep without constraintsmpeterv2016-02-131-5/+9
| |/ |/|
* | Process external deps in sorted ordermpeterv2015-12-051-2/+2
| | | | | | | | | | Ensure consistent output for Lua 5.3 where key order of pairs() can change between two runs.
* | Show candidate files when external deps are missingmpeterv2015-12-051-18/+33
|/
* Isolate the convenience hack, for readability.Hisham Muhammad2014-11-101-0/+2
|
* Unmoduled core modules with package.loaded trick + fixed locals shadowing ↵mpeterv2014-03-201-37/+41
| | | | | | module table Thanks to Metalua for the possibility to automate this.
* Removed some unused variablesmpeterv2014-03-131-1/+0
|
* Have separate fs.dir and fs.list_dir functions.Hisham Muhammad2014-02-081-1/+1
| | | | The first returns an iterator, the second one a table.
* Performance improvementsHisham Muhammad2014-01-091-1/+1
|
* Fix regressions caused by #194. Thank you, integrated testing!Hisham Muhammad2013-12-201-10/+10
|
* Merge pull request #194 from rtsisyk/gh-177-option-for-builtin-packagesHisham Muhammad2013-12-201-12/+6
|\ | | | | Add a configuration option to specify manually installed rocks (#177)
| * Add a configuration option to specify manually installed rocks.Roman Tsisyk2013-11-301-12/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The patch adds a new configuration option - cfg.rocks_provided. This option contains a list of packages that are either builtin or manually installed outside of LuaRocks package management system: rocks_provided = { [module_name] = module_version.."-"..rockspec_version, -- ... } These settings are taken into account during dependency resolution and when search and install commands are used. An attempt to install a rock from the list causes an error. LuaRocks automatically adds following modules to the list: rocks_provided = { lua = lua_version.."-1", -- For Lua 5.2 or later: bit32 = lua_version.."-1", -- For LuaJIT: luajit = lj_version.."-1", jit = lj_version.."-1", ffi = lj_version.."-1", bit = lj_version.."-1", luabitop = lj_version.."-1" } where lua_version extracted from _VERSION (e.g. 5.2), lj_version extracted from jit.version (e.g. 2.0.2). Built-in values can be overridden by configuration options. Closes #177.
* | Prioritize "scm" over "cvs". This was underspecified before.Hisham Muhammad2013-12-181-1/+1
|/
* Don't loop in case of circular dependenciesHisham Muhammad2013-10-291-0/+1
|
* support for tables in (runtime_)external_deps_subdirs.*Philipp Janda2013-09-261-9/+27
|
* Whitelist bit32 as a pre-satisfied dependency when running Lua 5.2.Hisham Muhammad2013-09-201-13/+22
|
* accept numbers as first character of a rock name in a dependencyHisham Muhammad2013-08-291-1/+1
|
* Merge branch 'master' into remove_on_installHisham Muhammad2013-07-041-8/+13
|\
| * fixed bad varnameThijs Schreijer2013-07-041-1/+1
| |
| * fixed return valueThijs Schreijer2013-07-041-1/+1
| |