diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2020-02-07 23:56:36 +0100 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2020-02-08 00:16:04 +0100 |
commit | 4898e06abcdfc17146b6a0640a50fdefcf4f8431 (patch) | |
tree | 11ca14616b57bfa45857f3d8b0a438ee1cbc577c | |
parent | 1fd4b99ea888fe6118c8451b51ae46596612f90a (diff) |
gnu: Add lua-ldoc.
* gnu/packages/lua.scm (lua-ldoc): New variable.
-rw-r--r-- | gnu/packages/lua.scm | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/gnu/packages/lua.scm b/gnu/packages/lua.scm index ee7480a852..45e08e066a 100644 --- a/gnu/packages/lua.scm +++ b/gnu/packages/lua.scm @@ -380,6 +380,55 @@ path management. Much of the functionality is inspired by the Python standard libraries.") (license license:expat))) +(define-public lua-ldoc + (package + (name "lua-ldoc") + (version "1.4.6") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/stevedonovan/LDoc.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1h0cf7bp4am54r0j8lhjs2l1c7q5vz74ba0jvw9qdbaqimls46g8")))) + (build-system gnu-build-system) + (inputs + `(("lua" ,lua))) + (propagated-inputs + `(("lua-penlight" ,lua-penlight))) + (arguments + `(#:tests? #f ;tests must run after installation. + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-installation-directory + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (lua-version ,(version-major+minor (package-version lua)))) + (substitute* "makefile" + (("LUA=.*") "#\n") + (("(LUA_PREFIX=).*" _ prefix) + (string-append prefix out "\n")) + (("(LUA_BINDIR=).*" _ prefix) + (string-append prefix out "/bin\n")) + (("(LUA_SHAREDIR=).*" _ prefix) + (string-append prefix out "/share/lua/" lua-version "\n")))) + #t)) + (delete 'configure) + (add-before 'install 'create-bin-directory + (lambda* (#:key outputs #:allow-other-keys) + (mkdir-p (string-append (assoc-ref outputs "out") "/bin")) + #t))))) + (home-page "http://stevedonovan.github.io/ldoc/") + (synopsis "Lua documentation generator") + (description + "LDoc is a LuaDoc-compatible documentation generation system for +Lua source code. It parses the declaration and documentation comments +in a set of Lua source files and produces a set of XHTML pages +describing the commented declarations and functions.") + (license license:expat))) + (define (make-lua-lgi name lua) (package (name name) |