lua.scm
| 1 | ;;; GNU Guix --- Functional package management for GNU |
| 2 | ;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu> |
| 3 | ;;; |
| 4 | ;;; This file is part of GNU Guix. |
| 5 | ;;; |
| 6 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
| 7 | ;;; under the terms of the GNU General Public License as published by |
| 8 | ;;; the Free Software Foundation; either version 3 of the License, or (at |
| 9 | ;;; your option) any later version. |
| 10 | ;;; |
| 11 | ;;; GNU Guix is distributed in the hope that it will be useful, but |
| 12 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 | ;;; GNU General Public License for more details. |
| 15 | ;;; |
| 16 | ;;; You should have received a copy of the GNU General Public License |
| 17 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. |
| 18 | |
| 19 | (define-module (more packages lua) |
| 20 | #:use-module (guix packages) |
| 21 | #:use-module (guix download) |
| 22 | #:use-module (guix hg-download) |
| 23 | #:use-module (guix build-system cmake) |
| 24 | #:use-module (guix build-system gnu) |
| 25 | #:use-module (guix build-system trivial) |
| 26 | #:use-module ((guix licenses) #:prefix license:) |
| 27 | #:use-module (gnu packages) |
| 28 | #:use-module (more packages boost) |
| 29 | #:use-module (gnu packages lua)) |
| 30 | |
| 31 | (define-public ryzom-cmake |
| 32 | (package |
| 33 | (name "ryzom-cmake") |
| 34 | (version "0") |
| 35 | (source (origin |
| 36 | (method hg-fetch) |
| 37 | (uri (hg-reference |
| 38 | (url "http://hg.kervala.net/cmake") |
| 39 | (changeset "56f5e1fd7677"))) |
| 40 | (sha256 |
| 41 | (base32 |
| 42 | "1n7gs9g9igls1xw3dndr6x8ww6xza0ig7igrrn9x382vpn9dw3g7")))) |
| 43 | (build-system trivial-build-system) |
| 44 | (arguments |
| 45 | `(#:modules ((guix build utils)) |
| 46 | #:builder (begin |
| 47 | (use-modules (guix build utils)) |
| 48 | (let* ((source (assoc-ref %build-inputs "source")) |
| 49 | (output (assoc-ref %outputs "out")) |
| 50 | (vardir (string-append output "/share/cmake"))) |
| 51 | (chdir source) |
| 52 | (for-each |
| 53 | (lambda (file) |
| 54 | (mkdir-p (dirname (string-append vardir "/" file))) |
| 55 | (copy-file file (string-append vardir "/" file))) |
| 56 | (find-files "." "[^/]*")))))) |
| 57 | (home-page "") |
| 58 | (synopsis "") |
| 59 | (description "") |
| 60 | (license license:gpl3+))) |
| 61 | |
| 62 | (define-public luabind |
| 63 | (package |
| 64 | (name "luabind") |
| 65 | (version "0.9.2") |
| 66 | (source (origin |
| 67 | (method hg-fetch) |
| 68 | (uri (hg-reference |
| 69 | (url "http://hg.kervala.net/luabind") |
| 70 | (changeset "3333deedec4a"))) |
| 71 | ;(uri (git-reference |
| 72 | ; (url "https://github.com/luabind/luabind") |
| 73 | ; (commit "cc743c37a7fffc72c809aed39e75385a34502ece"))) |
| 74 | ;(method url-fetch) |
| 75 | ;(uri (string-append "https://github.com/luabind/luabind/archive/v" |
| 76 | ; version ".tar.gz")) |
| 77 | ;(uri (string-append "mirror://sourceforge/luabind/luabind/" |
| 78 | ; version "/luabind-" version ".tar.gz")) |
| 79 | (sha256 |
| 80 | (base32 |
| 81 | ;"1bma96ba9ahzwax1kis4yx5zfirj9fij4fxcdn7dsy46j425xpl0")))) |
| 82 | ;"0bgz0lpq8ml6gsfck8j6ds40r40g499nzypji2cd4s3nl18asphf")))) |
| 83 | ;"0j6lm48yz2y0hxk3qznilfdv1nqfql7cybhih781kq4d6kvccz5n")))) |
| 84 | "0y6qyb49gsf3dhvyy7sqihcivkhjryyq6cc9q9y3s0flg0gifsw2")))) |
| 85 | ;(build-system gnu-build-system) |
| 86 | (build-system cmake-build-system) |
| 87 | ;(native-inputs |
| 88 | ; `(("boost-build" ,boost-build))) |
| 89 | (inputs |
| 90 | `(("boost" ,boost-fix) |
| 91 | ("lua" ,lua-5.1))) |
| 92 | (native-inputs |
| 93 | `(("ryzom-cmake" ,ryzom-cmake))) |
| 94 | (arguments |
| 95 | `(#:out-of-source? #t |
| 96 | #:tests? #f |
| 97 | #:phases |
| 98 | (modify-phases %standard-phases |
| 99 | (add-before 'configure 'export |
| 100 | (lambda _ |
| 101 | (setenv "CMAKE_MODULE_PATH" |
| 102 | (string-append (assoc-ref %build-inputs "ryzom-cmake") |
| 103 | "/share/cmake/modules")) |
| 104 | (format #t (getenv "CMAKE_MODULE_PATH"))))))) |
| 105 | ;(arguments |
| 106 | ; `(#:tests? #f |
| 107 | ; #:phases |
| 108 | ; (modify-phases %standard-phases |
| 109 | ; (delete 'configure) |
| 110 | ; (replace 'build |
| 111 | ; (lambda* (#:key inputs #:allow-other-keys) |
| 112 | ; (substitute* "luabind/object.hpp" |
| 113 | ; ((" LUABIND_OPERATOR_ADL_WKND.*") "")) |
| 114 | ; (setenv "LUA_PATH" (assoc-ref inputs "lua")) |
| 115 | ; (zero? (system* "b2")))) |
| 116 | ; (replace 'install |
| 117 | ; (lambda* (#:key outputs #:allow-other-keys) |
| 118 | ; (zero? (system* "b2" "install" |
| 119 | ; (string-append "--prefix=" |
| 120 | ; (assoc-ref outputs "out"))))))))) |
| 121 | (home-page "http://www.rasterbar.com/products/luabind.html") |
| 122 | (synopsis "") |
| 123 | (description "") |
| 124 | (license license:expat))) |
| 125 |