summaryrefslogtreecommitdiff
path: root/tests/crate.scm
Commit message (Collapse)AuthorAge
* guix: import: parametrized importing of dev dependenciesseries-2798Martin Becze2020-02-04
| | | | | | | | | This changes the behavoir of the recusive crate importer so that it will include the importing of development dependencies for the top level package but will not inculded the development dependencies for any other imported package. * guix/import/crate.scm (crate->guix-package, make-crate-sexp) <guix import crate>: added new parameter
* guix: import: utils: trim patch version from namesMartin Becze2020-02-04
| | | | | * guix/import/utils.scm (package->definition): trim patch version from names * tests/crate.scm: updated the tests
* guix: import: crate: Use semver to resovle module versionsMartin Becze2020-02-04
| | | | | | | | * guix/import/crate.scm (make-crate-sexp): formatting, added '#:skip-build?' to build system args; added package definition geneation * guix/import/crate.scm (crate->guix-package): Use semver to resolve the correct module versions * tests/crate.scm: added version data to (recursuve-import) test
* import: crate: Export 'string->license'.Ludovic Courtès2020-01-16
| | | | | * guix/import/crate.scm (string->license): Export. * tests/crate.scm (string->license): Remove.
* import: crate: Better handle license expressions.Brice Waegeneire2019-12-11
| | | | | | | | * guix/import/crate.scm (%dual-license-rx): Removed function. (crate->guix-package): Handle most of the multi-licensing cases. * tests/crate.scm (licenses): Add tests for some licenses. Co-authored-by: Ludovic Courtès <ludo@gnu.org>
* import: crate: Add recursive import test.Brian Leung2019-12-11
| | | | | | | | | | | | | | | | * tests/crate.scm (test-crate): Rename to... (test-foo-crate): ... this. (test-dependencies): Rename to... (test-foo-dependencies): ... this. (test-root-crate, test-root-dependencies, test-intermediate-1-crate) (test-intermediate-1-dependencies, test-intermediate-2-crate) (test-intermediate-2-dependencies, test-leaf-alice-crate) (test-leaf-alice-dependencies, test-leaf-bob-crate) (test-leaf-bob-dependencies): New variables. ("crate->guix-package"): Adjust accordingly. ("cargo-recursive-import"): New test. Co-authored-by: Ludovic Courtès <ludo@gnu.org>
* import: crate: Correct interpretation of dual-licensing strings.Ludovic Courtès2019-09-04
| | | | | | | * guix/import/crate.scm (%dual-license-rx): New variable. (crate->guix-package)[string->license]: Rewrite to match it. * tests/crate.scm (test-crate): Adjust "license" field to current practice.
* import: crate: Separate crates.io API from actual conversion.Ludovic Courtès2019-09-04
| | | | | | | | | | | | | | | | | | | | This provides a clean separation between bindings to the https://crates.io/api/v1 API and actual conversion to Guix package sexps. As a side-effect, it fixes things like "guix import blake2-rfc", "guix refresh -t crates", etc. * guix/import/crate.scm (<crate>, <crate-version>, <crate-dependency>): New record types. (lookup-crate, crate-version-dependencies): New procedures. (crate-fetch): Remove. (crate->guix-package): Rewrite to use the new API. (latest-release): Likewise. * guix/build-system/cargo.scm (%crate-base-url): New variable. * tests/crate.scm (test-crate): Update accordingly. fixlet
* guix: import: crate: fix redundant inputs list nestingIvan Petkov2019-06-30
| | | | | | | * guix/import/crate.scm (maybe-cargo-inputs): Remove one level of lists. * guix/import/crate.scm (maybe-cargo-development-inputs): Same. * tests/crate.scm: (crate->guix-package)[package]<#:arguments>: Remove one level of list nesting.
* import: crate: Define dependencies as arguments.Ivan Petkov2019-06-11
| | | | | | | | | | | | | | | | | | * guix/import/crate.scm: (crate-fetch)[input-crates]: Rename to dev-crates. [native-input-crates]: Rename to dev-dep-crates. [inputs]: Rename to cargo-inputs. [native-inputs]: Rename to cargo-development-inputs. (maybe-cargo-inputs, maybe-cargo-development-inputs, maybe-arguments): Add them. (make-crate-sexp)[inputs]: Rename to cargo-inputs. [native-inputs]: Rename to cargo-development-inputs. [maybe-native-inputs, maybe-inputs]: Replace with maybe-arguments. * guix/import/utils.scm: (package-names->package-inputs): Make public. Add docstring. * tests/crate.scm (crate->guix-package): Update the match pattern. Signed-off-by: Chris Marusich <cmmarusich@gmail.com>
* Switch to Guile-Gcrypt.Ludovic Courtès2018-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes (guix hash) and (guix pk-crypto), which now live as part of Guile-Gcrypt (version 0.1.0.) * guix/gcrypt.scm, guix/hash.scm, guix/pk-crypto.scm, tests/hash.scm, tests/pk-crypto.scm: Remove. * configure.ac: Test for Guile-Gcrypt. Remove LIBGCRYPT and LIBGCRYPT_LIBDIR assignments. * m4/guix.m4 (GUIX_ASSERT_LIBGCRYPT_USABLE): Remove. * README: Add Guile-Gcrypt to the dependencies; move libgcrypt as "required unless --disable-daemon". * doc/guix.texi (Requirements): Likewise. * gnu/packages/bash.scm, guix/derivations.scm, guix/docker.scm, guix/git.scm, guix/http-client.scm, guix/import/cpan.scm, guix/import/cran.scm, guix/import/crate.scm, guix/import/elpa.scm, guix/import/gnu.scm, guix/import/hackage.scm, guix/import/texlive.scm, guix/import/utils.scm, guix/nar.scm, guix/pki.scm, guix/scripts/archive.scm, guix/scripts/authenticate.scm, guix/scripts/download.scm, guix/scripts/hash.scm, guix/scripts/pack.scm, guix/scripts/publish.scm, guix/scripts/refresh.scm, guix/scripts/substitute.scm, guix/store.scm, guix/store/deduplication.scm, guix/tests.scm, tests/base32.scm, tests/builders.scm, tests/challenge.scm, tests/cpan.scm, tests/crate.scm, tests/derivations.scm, tests/gem.scm, tests/nar.scm, tests/opam.scm, tests/pki.scm, tests/publish.scm, tests/pypi.scm, tests/store-deduplication.scm, tests/store.scm, tests/substitute.scm: Adjust imports. * gnu/system/vm.scm: Likewise. (guile-sqlite3&co): Rename to... (gcrypt-sqlite3&co): ... this. Add GUILE-GCRYPT. (expression->derivation-in-linux-vm)[config]: Remove. (iso9660-image)[config]: Remove. (qemu-image)[config]: Remove. (system-docker-image)[config]: Remove. * guix/scripts/pack.scm: Adjust imports. (guile-sqlite3&co): Rename to... (gcrypt-sqlite3&co): ... this. Add GUILE-GCRYPT. (self-contained-tarball)[build]: Call 'make-config.scm' without #:libgcrypt argument. (squashfs-image)[libgcrypt]: Remove. [build]: Call 'make-config.scm' without #:libgcrypt. (docker-image)[config, json]: Remove. [build]: Add GUILE-GCRYPT to the extensions Remove (guix config) from the imported modules. * guix/self.scm (specification->package): Remove "libgcrypt", add "guile-gcrypt". (compiled-guix): Remove #:libgcrypt. [guile-gcrypt]: New variable. [dependencies]: Add it. [*core-modules*]: Remove #:libgcrypt from 'make-config.scm' call. Add #:extensions. [*config*]: Remove #:libgcrypt from 'make-config.scm' call. (%dependency-variables): Remove %libgcrypt. (make-config.scm): Remove #:libgcrypt. * build-aux/build-self.scm (guile-gcrypt): New variable. (make-config.scm): Remove #:libgcrypt. (build-program)[fake-gcrypt-hash]: New variable. Add (gcrypt hash) to the imported modules. Adjust load path assignments. * gnu/packages/package-management.scm (guix)[propagated-inputs]: Add GUILE-GCRYPT. [arguments]: In 'wrap-program' phase, add GUILE-GCRYPT to the search path.
* tests: Adjust for 'http-fetch' change in (guix import json).Ludovic Courtès2017-02-13
| | | | | | | | | | | This is a followup to commit 81e0bc1834490a1a8092c75a0733b15c2b407285. * tests/cpan.scm ("cpan->guix-package"): Add a 'rest' argument to the lambda that mocks 'http-fetch'. * tests/crate.scm ("crate->guix-package"): Likewise. * tests/gem.scm ("gem->guix-package"): Likewise. * tests/pypi.scm ("pypi->guix-package"): Likewise. ("pypi->guix-package, wheels"): Likewise.
* build-system: cargo: Handle Cargo.lock file not present.David Craven2017-01-01
| | | | | | | | | | | | | | | | | | * guix/build-system/cargo.scm (cargo-build): Add src output. (private-keywords): Add #:outputs. * guix/build/cargo-build-system.scm (configure): Use /share/rust-source when replacing inputs. (build, check): Don't do anything when there isn't a Cargo.lock file present. (install): Install sources to src output. When a Cargo.lock file is present use cargo install to install binaries to out. * guix/import/crate.scm (make-crate-sexp): Importer uses the src output for crate inputs by default. * guix/import/utils.scm (package-names->package-inputs, maybe-inputs, maybe-native-inputs): Take an optional output argument. * tests/crate.scm (crate->guix-package test): Update. Problem reported by Francisco Gómez García <espectalll@kydara.com>.
* import: crate: Provide a default home-page value.David Craven2017-01-01
| | | | | | | | * guix/import/crate.scm (make-crate-sexp): Provide a default home-page value. * tests/crate.scm (test-crate): Add repository field. Problem reported by ng0 <ng0@libertad.pw>.
* import: Add importer for rust crates.David Craven2016-12-14
* guix/import/crate.scm: New file. * guix/scripts/import/crate.scm: New file. * guix/scripts/import.scm (importers): Add crate importer. * tests/crate.scm: New file. * doc/guix.texi: Add crate importer to table. * Makefile.am (MODULES, SCM_TESTS): Add files.