From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: Graceful handling of missing patches Date: Tue, 20 Jan 2015 15:01:32 +0100 Message-ID: <87egqpim9v.fsf@gnu.org> References: <20150118132526.GA15628@debian> <87zj9gcgpe.fsf@gnu.org> <20150118161010.GA20517@debian> <87a91gcamz.fsf@gnu.org> <20150118164207.GA21387@debian> <87d269kdr4.fsf_-_@gnu.org> <20150120093702.GA4495@debian.math.u-bordeaux1.fr> 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]:43514) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDZNE-0005oe-N4 for guix-devel@gnu.org; Tue, 20 Jan 2015 09:01:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YDZN9-0003DV-Ns for guix-devel@gnu.org; Tue, 20 Jan 2015 09:01:40 -0500 Received: from hera.aquilenet.fr ([2a01:474::1]:47659) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDZN9-0003DM-AL for guix-devel@gnu.org; Tue, 20 Jan 2015 09:01:35 -0500 In-Reply-To: <20150120093702.GA4495@debian.math.u-bordeaux1.fr> (Andreas Enge's message of "Tue, 20 Jan 2015 10:37:02 +0100") 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-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Andreas Enge Cc: guix-devel@gnu.org Andreas Enge skribis: > On Tue, Jan 20, 2015 at 10:22:39AM +0100, Ludovic Court=C3=A8s wrote: >> With commits 6b1f972 and dbab515, patch-not-found errors are now >> gracefully handled at run time: >>=20 >> $ ./pre-inst-env guix build findutils >> guix build: error: WHAT?.patch: patch not found >>=20 >> This introduces an ABI change, so make sure to run: >>=20 >> make clean-go && make > > Compilation now fails for me with > /bin/mkdir -p `dirname "guix/scripts/refresh.go"` ; \ > LC_ALL=3DC \ > ./pre-inst-env \ > /usr/bin/guild compile -L "." -L "." \ > -Wformat -Wunbound-variable -Warity-mismatch \ > --target=3D"x86_64-unknown-linux-gnu" = \ > -o "guix/scripts/refresh.go" "guix/scripts/refresh.scm" > ;;; note: source file ./guix/config.scm > ;;; newer than compiled /usr/local/guix-git/share/guile/site/2.0/gu= ix/config.go > ;;; note: source file ./gnu/packages.scm > ;;; newer than compiled /usr/local/guix-git/share/guile/site/2.0/gn= u/packages.go > ;;; note: source file ./gnu/packages/guile.scm > ;;; newer than compiled /usr/local/guix-git/share/guile/site/2.0/gn= u/packages/guile.go > ;;; note: source file ./gnu/packages/gnome.scm > ;;; newer than compiled /usr/local/guix-git/share/guile/site/2.0/gn= u/packages/gnome.go > Backtrace: > In ice-9/boot-9.scm: > 2111: 19 [save-module-excursion #] > In language/scheme/compile-tree-il.scm: > 31: 18 [#] > In ice-9/psyntax.scm: > 1101: 17 [expand-top-sequence ((define-module # # # ...)) () ((top)) ...] > 986: 16 [scan ((define-module (guix scripts refresh) #:use-module ...)) = () ...] > 270: 15 [scan ((#(syntax-object let # ...) (#) (# #) ...)) () ...] > In ice-9/eval.scm: > 392: 14 [eval # ()] > In ice-9/boot-9.scm: > 2667: 13 [define-module* (guix scripts refresh) #:filename ...] > 2642: 12 [resolve-imports (((guix ui)) ((guix hash)) ((guix store)) ...)] > 2580: 11 [resolve-interface (gnu packages commencement) #:select ...] > 2505: 10 [# # ...] > 2772: 9 [try-module-autoload (gnu packages commencement) #f] > 2111: 8 [save-module-excursion #] > 2783: 7 [#] > In unknown file: > ?: 6 [primitive-load-path "gnu/packages/commencement" #f] > In gnu/packages/commencement.scm: > 613: 5 [#] > In guix/utils.scm: > 428: 4 [# #] > In gnu/packages/bootstrap.scm: > 147: 3 [# #] > 77: 2 [bootstrap-origin #] > In unknown file: > ?: 1 [scm-error wrong-type-arg "map" ...] > In ice-9/boot-9.scm: > 106: 0 [# = wrong-type-arg ...] > > ice-9/boot-9.scm:106:20: In procedure #: > ice-9/boot-9.scm:106:20: In procedure map: Not a list: # > Makefile:4030: die Regel f=C3=BCr Ziel =E2=80=9Eguix/scripts/refresh.go= =E2=80=9C scheiterte Clearly this is a symptom of an old, ABI-incompatible .go being used. After some discussion and investigation we found out that, during compilation, =E2=80=98guild compile=E2=80=99 could end up loading the alrea= dy-installed .go files if their mtime is newer that than of the corresponding .scm files in the source tree, which is often the case if the user ran =E2=80=98= make install=E2=80=99 recently. Commit 28561d8 fixes that by resetting GUILE_LOAD_COMPILED_PATH altogether during compilation. Thanks, Ludo=E2=80=99.