manolis837@gmail.com (2017-08-06 22:48 +0300) wrote:
[...]
Toggle quote (10 lines)
> +(define-public ogre> + (package> + (name "ogre")> + (version "1.10.7")> + (source> + (origin> + (method url-fetch)> + (uri (string-append "https://github.com/OGRECave/" name> + "/archive/v" version ".tar.gz"))
Please add 'file-name' to avoid "/gnu/store/…-v1.10.7.tar.gz" name:
(file-name (string-append name "-" version ".tar.gz"))
This is reported by "guix lint ogre".
Toggle quote (10 lines)
> + (sha256> + (base32> + "1ab354bmwwryxr4zgxchfkm6h4z38mjgif8yn89x640rsrgw5ipj"))))> + (build-system cmake-build-system)> + (arguments> + '(#:phases> + (modify-phases %standard-phases> + (add-before 'configure 'pre-configure> + (lambda* (#:key inputs #:allow-other-keys)
'inputs' are not used here, so just: (lambda _ ...)
Toggle quote (6 lines)
> + ;; It expects googletest source to be downloaded and> + ;; be in a specific place.> + (substitute* "Tests/CMakeLists.txt"> + (("URL(.*)$" _ suffix) (string-append "URL " suffix> +"\t\tURL_HASH MD5=16877098823401d1bf2ed7891d7dce36\n")))
This string shouldn't start from the beginning of the line. I see theproblem is that a properly indented line would be too long. I wouldwrite it like this:
(substitute* "Tests/CMakeLists.txt" (("URL(.*)$" _ suffix) (string-append "URL " suffix "\t\tURL_HASH " "MD5=16877098823401d1bf2ed7891d7dce36\n")))
Toggle quote (6 lines)
> + #t))> + (add-before 'build 'pre-build> + (lambda* (#:key inputs #:allow-other-keys)> + (copy-file (assoc-ref inputs "googletest-source")> + (string-append (getcwd)> + "/Tests/googletest-prefix/src/release-1.8.0.tar.gz")) ^^^^same here: (string-append ...) and the next line are not indentedproperly. I would write:
(copy-file (assoc-ref inputs "googletest-source") (string-append (getcwd) "/Tests/googletest-prefix/src" "/release-1.8.0.tar.gz"))
The rest looks good to me, thanks!
-- Alex