From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12544 invoked by alias); 15 Nov 2008 14:46:44 -0000 Received: (qmail 12433 invoked by uid 22791); 15 Nov 2008 14:46:43 -0000 X-Spam-Check-By: sourceware.org Received: from elasmtp-kukur.atl.sa.earthlink.net (HELO elasmtp-kukur.atl.sa.earthlink.net) (209.86.89.65) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 15 Nov 2008 14:45:35 +0000 Received: from [209.128.140.171] (helo=[10.0.1.201]) by elasmtp-kukur.atl.sa.earthlink.net with esmtpa (Exim 4.67) (envelope-from ) id 1L1MOz-0000El-PP; Sat, 15 Nov 2008 09:45:33 -0500 In-Reply-To: References: Mime-Version: 1.0 (Apple Message framework v753.1) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <0327DC3F-4E47-4557-92D9-75DFB7536259@earthlink.net> Cc: Alan Lehotsky Content-Transfer-Encoding: 7bit From: Alan Lehotsky Subject: Re: opcodes port instructions in cgen.info yield "unbound variable: opc-file-path " Date: Sat, 15 Nov 2008 14:46:00 -0000 To: cgen@sourceware.org X-Mailer: Apple Mail (2.753.1) X-ELNK-Trace: 9e0cfd4f457cc6ab94f5150ab1c16ac0eafd45f126befae253f15b0d440da3aef4bbb53ec8eced9e350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c Mailing-List: contact cgen-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cgen-owner@sourceware.org X-SW-Source: 2008-q4/txt/msg00011.txt.bz2 I see what my problem was. I was expecting too much from running interactively. The suggestion regarding running various generators (like the `(cgen- asm.in)' is going to always fail complaining about the unbound variable. You would need to invoke guile and cgen with all the appropriate flags that are hidden in the make files. The porting suggestion is directed to the idea that you run interactively, looking at the generated .c and .h files as they flash by on the screen. Once you're happy, then you go off and do the make stamp-TARGET or whatever in the subdirs. I will see if I can write up a patch to the docs regarding this. On Nov 11, 2008, at 00:18, Alan Lehotsky wrote: > > - I've got a TARGET.cpu and TARGET.opc file. > - I've done > > cd src/cgen > guile > guile> (load "dev.scm") > guile> (load-opc) > guile> (cload #:arch "TARGET") > ...... ;; no errors or warnings here > guile> (cgen-asm.in) > > (cgen-asm.in) > Generating atdsp-asm.in ... > > > Backtrace: > In ./opc-asmdis.scm: > 89: 0* (opc-file-path) > 89: 1 [gen-extra-asm.c ... > In ./utils.scm: > 414: 2* [#] > 414: 3 [-string-write #(print-state 0) ... > 412: 4* (cond ((string? expr) (display expr)) ((symbol? expr) > (display expr)) ...) > 403: 5* [-string-write #(print-state 0) #] > In unknown file: > ?: 6* [# #] > In ./utils.scm: > 403: 7* [for-each # (" > " # " > " ...)] > 401: 8 (let* ((pstate (make-print-state))) (set! -current-print- > state pstate) ...) > In ./opc-asmdis.scm: > 86: 9 [string-write " > " # ...] > In standard input: > 5: 10* [cgen-asm.in] > > ./opc-asmdis.scm:89:32: In expression (opc-file-path): > ./opc-asmdis.scm:89:32: Unbound variable: opc-file-path > ABORT: (unbound-variable) > > > I get that unbound variable complaint for ALL the file generation