aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/lua.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-12-09 18:11:14 +0100
committerLudovic Courtès <ludo@gnu.org>2016-12-09 18:11:14 +0100
commitf80b4d2ce09b0b7770cbdf2f90704d41b0a168c5 (patch)
treeec47c7ee5d5579cfa00f13b5038ff3d8c87e4a48 /gnu/packages/lua.scm
parent13b5f44b475aa385d580f7e19b907210bc1d6d99 (diff)
parent2608e40988ba8cf51723fe0d21bdedf6b3997c9c (diff)
downloadguix-f80b4d2ce09b0b7770cbdf2f90704d41b0a168c5.tar
guix-f80b4d2ce09b0b7770cbdf2f90704d41b0a168c5.tar.gz
Merge remote-tracking branch 'origin/master' into staging
Diffstat (limited to 'gnu/packages/lua.scm')
-rw-r--r--gnu/packages/lua.scm36
1 files changed, 36 insertions, 0 deletions
diff --git a/gnu/packages/lua.scm b/gnu/packages/lua.scm
index f95da3587d..65c335d373 100644
--- a/gnu/packages/lua.scm
+++ b/gnu/packages/lua.scm
@@ -7,6 +7,7 @@
;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2016 doncatnip <gnopap@gmail.com>
;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
+;;; Copyright © 2016 José Miguel Sánchez García <jmi2k@openmailbox.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -27,6 +28,7 @@
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
+ #:use-module (guix utils)
#:use-module (guix build-system gnu)
#:use-module (gnu packages)
#:use-module (gnu packages readline)
@@ -365,3 +367,37 @@ secure session between the peers.")
based libraries. It allows using GObject-based libraries directly from Lua.
Notable examples are GTK+, GStreamer and Webkit.")
(license license:expat)))
+
+(define-public lua-lpeg
+ (package
+ (name "lua-lpeg")
+ (version "1.0.0")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://www.inf.puc-rio.br/~roberto/lpeg/lpeg-"
+ version ".tar.gz"))
+ (sha256
+ (base32 "13mz18s359wlkwm9d9iqlyyrrwjc6iqfpa99ai0icam2b3khl68h"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (delete 'configure)
+ ;; `make install` isn't available, so we have to do it manually
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (lua-version ,(version-major+minor (package-version lua))))
+ (install-file "lpeg.so"
+ (string-append out "/lib/lua/" lua-version))
+ (install-file "re.lua"
+ (string-append out "/share/lua/" lua-version))
+ #t))))
+ #:test-target "test"))
+ (inputs `(("lua", lua)))
+ (synopsis "Pattern-matching library for Lua")
+ (description
+ "LPeg is a pattern-matching library for Lua, based on Parsing Expression
+Grammars (PEGs).")
+ (home-page "http://www.inf.puc-rio.br/~roberto/lpeg")
+ (license license:expat)))