From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: Re: Circular dependencies in gnu/packages, weird error message Date: Sun, 6 Nov 2016 21:50:14 +0100 Message-ID: <20161106215014.4158e14f@scratchpost.org> References: <20161104022451.4c7690eb@scratchpost.org> <871syr1fb3.fsf@gnu.org> <20161104222622.2dac6487@scratchpost.org> <878tsw1pel.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51841) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c3UOa-0004Hj-7J for guix-devel@gnu.org; Sun, 06 Nov 2016 15:50:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c3UOV-0001CA-DX for guix-devel@gnu.org; Sun, 06 Nov 2016 15:50:28 -0500 In-Reply-To: <878tsw1pel.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Ludovic =?ISO-8859-1?Q?Court=E8s?= Cc: guix-devel@gnu.org Hi Ludo, On Sun, 06 Nov 2016 18:36:34 +0100 ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > Danny Milosavljevic skribis: >=20 > > diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm > > index 1d577c7..44ab171 100644 > > --- a/gnu/packages/admin.scm > > +++ b/gnu/packages/admin.scm > > @@ -43,6 +43,8 @@ > > #:use-module (guix build-system trivial) > > #:use-module (gnu packages) > > #:use-module (gnu packages base) > > + #:use-module (gnu packages cross-base) > > +; #:use-module ((gnu packages cross-base) #:select (cross-gcc cross-b= inutils cross-libc)) =20 >=20 > Never use #:select for (gnu packages =E2=80=A6) modules. >=20 > > - `(("pkg-config" ,pkg-config))) > > + `(("pkg-config" ,pkg-config) > > + ("cross-binutils" ,(cross-binutils "arm-linux-gnueabihf")) > > + ("cross-gcc" ,(cross-gcc "arm-linux-gnueabihf" #:libc (cross-li= bc "arm-linux-gnueabihf"))) =20 >=20 > =E2=80=98cross-gcc=E2=80=99 doesn=E2=80=99t have a #:libc parameter. Sho= uld be >=20 > (let ((triplet "arm-linux-gnueabihf")) > (cross-gcc triplet > (cross-binutils triplet) > (cross-libc triplet))) Okay, thanks! After I did that, the error message doesn't change, though: Backtrace: In guix/ui.scm: 1220: 19 [run-guix-command package "-i" ...] In ice-9/boot-9.scm: 157: 18 [catch srfi-34 # ...] 157: 17 [catch system-error # ...] In ice-9/eval.scm: 481: 16 [lp (# #) (# #t)] 481: 15 [lp (#) (#t)] 481: 14 [lp (#) (#)] 432: 13 [eval # #] In guix/ui.scm: 706: 12 [show-manifest-transaction # # # ...] In srfi/srfi-1.scm: 601: 11 [map # ...] In guix/ui.scm: 664: 10 [upgrade-string "sunxi-tools" "1.4.1" ...] In guix/packages.scm: 1141: 9 [package-output # # "out" ...] 793: 8 [cache! # # # ...] 1099: 7 [thunk] 793: 6 [cache! # # # ...] 894: 5 [thunk] In ice-9/eval.scm: 387: 4 [eval # #] 387: 3 [eval # #] 387: 2 [eval # #] 387: 1 [eval # #] In unknown file: ?: 0 [struct-ref # 1] ERROR: In procedure struct-ref: ERROR: In procedure struct-ref: Wrong type argument in position 1 (expectin= g struct): # Chunks I used: + #:use-module (gnu packages cross-base) ... + (let ((triplet "arm-linux-gnueabihf")) + (package + (name "sunxi-tools") + (version "1.4.1") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/linux-sunxi/" + "sunxi-tools/archive/v" version ".tar.gz")) + (sha256 + (base32 "06qd2b4dlzbmzfy4q9n8v5rkkbmgcfdbv4nkkcp4nysi10k7cpfs")) + (modules '((guix build utils))) + (snippet + ;; Remove binaries contained in the tarball which are only for t= he + ;; target and can be regenerated anyway. + '(delete-file-recursively "bin")) + (file-name (string-append name "-" version ".tar.gz")))) + (native-inputs + `(("pkg-config" ,pkg-config) + ("cross-gcc" ,(cross-gcc triplet + (cross-binutils triplet) + (cross-libc triplet))))) + (inputs + `(("libusb" ,libusb))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no tests exist + #:make-flags (list (string-append "PREFIX=3D" + (assoc-ref %outputs "out")) + (string-append "CROSS_COMPILE=3D" + ,triplet "-") + "CC=3Dgcc" + "all") + #:phases + (modify-phases %standard-phases + (delete 'configure) + (replace 'install + (lambda* (#:key make-flags #:allow-other-keys) + (zero? (apply system* "make" "install-all" "install-misc" + make-flags))))))) + (home-page "https://github.com/linux-sunxi/sunxi-tools") + (synopsis "Hardware management tools for Allwinner computers") + (description "This package contains tools for Allwinner devices: ...") + (license license:gpl2+))))