guix: pack.

This commit is contained in:
tecnovert 2022-11-20 22:22:10 +02:00
parent d15cf3dd6f
commit 47c1237f6d
No known key found for this signature in database
GPG Key ID: 8ED6D8750C4E3F93
3 changed files with 64 additions and 40 deletions

View File

@ -22,19 +22,7 @@ Not ready for real-world use.
Discuss development and help with testing in the matrix channel [#basicswap:matrix.org](https://riot.im/app/#/room/#basicswap:matrix.org) Discuss development and help with testing in the matrix channel [#basicswap:matrix.org](https://riot.im/app/#/room/#basicswap:matrix.org)
## Guix ## Install notes
Start a development environment Please see [doc/install.md](doc/install.md)
guix shell --pure -D -f guix.scm
Run tests
export PYTHONPATH=$(pwd)
# Prepare coin binaries - required once
python ./bin/basicswap-prepare.py -preparebinonly --withcoins=monero,bitcoin,particl,litecoin
pytest -vs tests/basicswap/test_run.py::Test::test_02_part_ltc

25
doc/guix.md Normal file
View File

@ -0,0 +1,25 @@
## Guix
Start a development environment
guix shell --pure -L. -D basicswap
Run tests
export PYTHONPATH=$(pwd)
# Prepare coin binaries - required once
python ./bin/basicswap-prepare.py -preparebinonly --withcoins=monero,bitcoin,particl,litecoin
pytest -vs tests/basicswap/test_run.py::Test::test_02_part_ltc
Install package
guix package --install -L. basicswap
Create a guix pack
guix pack -RR -S /opt/gnu/bin=bin -L. basicswap

View File

@ -1,25 +1,25 @@
(use-modules (define-module (guix)
(guix packages) #:use-module (guix packages)
((guix licenses) #:prefix license:) #:use-module ((guix licenses) #:prefix license:)
(guix build-system python) #:use-module (guix build-system python)
(guix build-system gnu) #:use-module (guix build-system gnu)
(guix git-download) #:use-module (guix git-download)
(guix download) #:use-module (guix download)
(gnu packages) #:use-module (gnu packages)
(gnu packages pkg-config) #:use-module (gnu packages pkg-config)
(gnu packages autotools) #:use-module (gnu packages autotools)
(gnu packages certs) #:use-module (gnu packages certs)
(gnu packages check) #:use-module (gnu packages check)
(gnu packages databases) #:use-module (gnu packages databases)
(gnu packages finance) #:use-module (gnu packages finance)
(gnu packages gnupg) #:use-module (gnu packages gnupg)
(gnu packages protobuf) #:use-module (gnu packages protobuf)
(gnu packages python) #:use-module (gnu packages python)
(gnu packages python-build) #:use-module (gnu packages python-build)
(gnu packages python-crypto) #:use-module (gnu packages python-crypto)
(gnu packages python-xyz) #:use-module (gnu packages python-xyz)
(gnu packages libffi) #:use-module (gnu packages libffi)
(gnu packages license)) #:use-module (gnu packages license))
(define libsecp256k1-anonswap (define libsecp256k1-anonswap
(package (package
@ -112,19 +112,27 @@
(sha256 (sha256
(base32 "09sx2lghywnm7qj1xm8xc3xrgj40bndfh2hbiaq4cfvm71h8k541")))))) (base32 "09sx2lghywnm7qj1xm8xc3xrgj40bndfh2hbiaq4cfvm71h8k541"))))))
(define-public basicswap
(package (package
(name "basicswap") (name "basicswap")
(version "0.11.49") (version "0.11.49")
(source #f) (source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/tecnovert/basicswap")
(commit "d15cf3dd6fd45ce16cbc804a2d26260567b44d75")))
(sha256
(base32
"023yhncqhp22h7wmkmkj0wc0627vbwlbr6mp5cpjwccalvxziskv"))
(file-name (git-file-name name version))))
(build-system python-build-system) (build-system python-build-system)
(arguments `(#:tests? #f)) ; TODO: Add coin binaries
(propagated-inputs (propagated-inputs
(list (list
gnupg gnupg
nss-certs nss-certs
python-coincurve-anonswap python-coincurve-anonswap
python-pycryptodome python-pycryptodome
python-pylint
python-pyflakes
python-pytest python-pytest
python-protobuf python-protobuf
python-sqlalchemy-1.4.39 python-sqlalchemy-1.4.39
@ -137,8 +145,11 @@
(native-inputs (native-inputs
(list (list
python-setuptools python-setuptools
python-wheel
python-pylint
python-pyflakes
)) ))
(synopsis "Simple Atomic Swap Network - Proof of Concept") (synopsis "Simple Atomic Swap Network - Proof of Concept")
(description #f) (description #f)
(home-page "https://github.com/tecnovert/basicswap") (home-page "https://github.com/tecnovert/basicswap")
(license license:bsd-3)) (license license:bsd-3)))