This is the mail archive of the cgen@sourceware.org mailing list for the CGEN project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

cgen 'gas-test' errors


Hi all,

I'm working on a new port for binutils/gcc for a custom microcontroller
using CGEN (the latest snapshot version: 20080101).

My host platform is a recent Ubuntu Linux system, with either guile 1.6
or guile 1.8 installed.

When I launch 'make gas-test' (with xc16x in the example) as shown in
the docs, the guile invocation fails with:

cd build-cgen && make gas-test ARCH=xc16x
make[1]: Entering directory `/tmp/build-cgen'
"`if test -f ../guile/libguile/guile ; then echo ../guile/libguile/guile; else echo guile ; fi` -l guile -s" ../cgen-20080101/cgen/cgen-gas.scm \
                -s ../cgen-20080101/cgen \
                -v \
                -a ../cgen-20080101/cgen/../../cpu/xc16x.cpu \
                -i "all" \
                -m "all" \
                -B gas-build.sh \
                -E gas-allinsn.exp
/bin/bash: guile -l guile -s: command not found
make[1]: *** [gas-test] Error 127

This error comes from the invocation of guile in the Makefile, hopefuly the
patch below fixes it.

But even after applying the patch, it fails later with a runtime Scheme error:

make[1]: Entering directory `/tmp/build-cgen'
`if test -f ../guile/libguile/guile ; then echo ../guile/libguile/guile; else echo guile ; fi` -l ../cgen-20080101/cgen/guile.scm -s ../cgen-20080101/cgen/cgen-gas.scm \
                -s ../cgen-20080101/cgen \
                -v \
                -a ../cgen-20080101/cgen/cpu/xc16x.cpu \
                -i "all" \
                -m "all" \
                -B gas-build.sh \
                -E gas-allinsn.exp
Skipping slib/sort, already loaded.
Skipping slib/random, already loaded.
cgen -s ../cgen-20080101/cgen/cgen-gas.scm -s ../cgen-20080101/cgen -v -a ../cgen-20080101/cgen/cpu/xc16x.cpu -i all -m all -B gas-build.sh -E gas-allinsn.exp 
Loading cpu description ../cgen-20080101/cgen/cpu/xc16x.cpu
Including file ../cgen-20080101/cgen/cpu/simplify.inc ...
Analyzing instruction set ...
Done analysis.
Generating gas-build.sh ...
ERROR: In procedure string-append:
ERROR: Wrong type argument (expecting STRINGP): dpp0
No backtrace available.
make[1]: *** [gas-test] Error 1

This is probably related to my version of guile (1.6 instead of 1.4)...

Can somebody please help me here ? My Scheme skills are very close to zero.

If the changes required to the source are not trivial, I could install guile
1.4 . But I'd rather avoid it if possible.

Thanks !

Stelian.

diff --git a/cgen/Makefile.am b/cgen/Makefile.am
index 0532ed7..a53f386 100644
--- a/cgen/Makefile.am
+++ b/cgen/Makefile.am
@@ -4,10 +4,10 @@ AUTOMAKE_OPTIONS = cygnus
 
 SUBDIRS = doc
 
-GUILE = "`if test -f ../guile/libguile/guile ; then echo ../guile/libguile/guile; else echo guile ; fi` -l guile -s"
+GUILE = `if test -f ../guile/libguile/guile ; then echo ../guile/libguile/guile; else echo guile ; fi` -l $(srcdir)/guile.scm -s
 CGENFLAGS = -v
 ARCH = @arch@
-ARCHFILE = $(srcroot)/../cpu/$(ARCH).cpu
+ARCHFILE = $(srcdir)/cpu/$(ARCH).cpu
 
 # for various utility rules
 MACHS = all


-- 
Stelian Pop <stelian@popies.net>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]