diff options
author | Zhu Zihao <all_but_last@163.com> | 2022-07-03 17:39:27 +0800 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2022-07-04 12:29:05 +0200 |
commit | 84d413d2fddca60860c54c8a0fb6612a131901ea (patch) | |
tree | f27b7e91308f7609a41391cd83e657742929b755 /gnu/packages | |
parent | b49c2e558daee907c47c451b6ded316153d9c702 (diff) | |
download | guix-84d413d2fddca60860c54c8a0fb6612a131901ea.tar.gz guix-84d413d2fddca60860c54c8a0fb6612a131901ea.zip |
gnu: solidity: Update to 0.8.15.
* gnu/packages/solidity.scm (solidity): Update to 0.8.15.
[source]: Use Github release.
[arguments]<#:phases>: Remove phase 'create-commit_hash.txt'.
Restore phase 'configure' and phase 'install'.
Remove modifications applied to the phase 'build' and phase 'check'.
Add phase 'unbundle-3rd-party-dependencies'.
[inputs]: Add fmt-for-solidity, range-v3.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/solidity.scm | 94 |
1 files changed, 37 insertions, 57 deletions
diff --git a/gnu/packages/solidity.scm b/gnu/packages/solidity.scm index 29a0c477f2..9ab555b919 100644 --- a/gnu/packages/solidity.scm +++ b/gnu/packages/solidity.scm @@ -19,72 +19,52 @@ (define-module (gnu packages solidity) #:use-module (gnu packages base) #:use-module (gnu packages boost) + #:use-module (gnu packages cpp) #:use-module (gnu packages maths) #:use-module (gnu packages serialization) #:use-module (gnu packages python) #:use-module (gnu packages ncurses) + #:use-module (gnu packages pretty-print) #:use-module (guix packages) #:use-module (guix gexp) - #:use-module (guix git-download) + #:use-module (guix download) #:use-module (guix build-system cmake) #:use-module ((guix licenses) #:prefix license:)) (define-public solidity - (let ((commit "3f05b770bdbf60eca866382049ea191dd701409a")) - (package - (name "solidity") - (version "0.7.4") - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/ethereum/solidity") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 "1mswhjymiwnd3n7h3sjvjx5x8223yih0yvfcr0zpqr4aizpfx5z8")))) - (build-system cmake-build-system) - (arguments - (list #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'create-commit_hash.txt - (lambda _ - (with-output-to-file "commit_hash.txt" - (lambda _ - (display - (substring #$commit 0 8)))))) - (delete 'configure) - (delete 'install) - (replace 'build - (lambda* (#:key outputs #:allow-other-keys) - ;; Unbundle jsoncpp - (delete-file "./cmake/jsoncpp.cmake") - (substitute* "CMakeLists.txt" - (("include\\(jsoncpp\\)") "")) - ;; Bug list is always sorted since we only build releases - (substitute* "./test/cmdlineTests.sh" - (("\"\\$REPO_ROOT\"/scripts/update_bugs_by_version\\.py") "")) - (substitute* "./scripts/build.sh" - (("sudo\\ make\\ install") "make install") - (("cmake\\ ..") - (string-append "cmake .. -DCMAKE_INSTALL_PREFIX=" - (assoc-ref outputs "out")))) - (setenv "CIRCLECI" "1") - (invoke "./scripts/build.sh"))) - (replace 'check - (lambda _ - (invoke "./scripts/tests.sh")))))) - (inputs - (list boost-static jsoncpp z3)) - (native-inputs - (list python - ncurses ;for 'tput' - findutils)) ;for 'xargs' - (home-page "https://solidity.readthedocs.io") - (synopsis "Contract-Oriented Programming Language") - (description - "Solidity is a statically-typed curly-braces programming language + (package + (name "solidity") + (version "0.8.15") + (source + (origin + (method url-fetch) + (uri + (string-append "https://github.com/ethereum/solidity/releases/download/v" + version "/solidity_" version ".tar.gz")) + (sha256 + (base32 "0j9a8y5fizarl9yhbnwvd0x1nm6qsbskqb7j1fwsyqx47w5sa82p")))) + (build-system cmake-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'unbundle-3rd-party-dependencies + (lambda _ + (substitute* "CMakeLists.txt" + (("include\\(fmtlib\\)") + "find_package(fmt)") + (("include\\(range-v3\\)") + "find_package(range-v3)") + (("include\\(jsoncpp\\)") + "find_package(jsoncpp)"))))))) + (inputs + (list boost-static fmt-for-solidity jsoncpp range-v3 z3)) + (native-inputs + (list python ncurses findutils)) + (home-page "https://solidity.readthedocs.io") + (synopsis "Contract-Oriented Programming Language") + (description + "Solidity is a statically-typed curly-braces programming language designed for developing smart contracts that run on the Ethereum Virtual Machine.") - (license license:gpl3+)))) + (license license:gpl3+))) |