Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 196176 - dev-lisp/clisp - ffcall/configure fails on sparc/hppa
Summary: dev-lisp/clisp - ffcall/configure fails on sparc/hppa
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Common Lisp Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 229217
  Show dependency tree
 
Reported: 2007-10-17 14:55 UTC by Marijn Schouten (RETIRED)
Modified: 2018-01-30 21:33 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
clisp_sparc.log (clisp_sparc.log,52.75 KB, text/plain)
2007-10-17 15:09 UTC, Marijn Schouten (RETIRED)
Details
dev-lisp:clisp-2.43:20071119-155737.log HPPA (20071119-155737.log,51.71 KB, text/plain)
2007-11-19 17:12 UTC, Jeroen Roovers (RETIRED)
Details
dev-lisp-clisp-2.48-r1:20100520-175852.log [hppa, fail] (20100520-175852.log,93.41 KB, text/plain)
2010-05-20 18:21 UTC, Jeroen Roovers (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Marijn Schouten (RETIRED) gentoo-dev 2007-10-17 14:55:40 UTC
For documentation purposes, the failure of clisp on sparc.
Comment 1 Marijn Schouten (RETIRED) gentoo-dev 2007-10-17 15:09:20 UTC
Created attachment 133675 [details]
clisp_sparc.log
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2007-11-19 17:12:12 UTC
Created attachment 136399 [details]
dev-lisp:clisp-2.43:20071119-155737.log HPPA
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2007-11-19 17:45:46 UTC
With --without-dynamic-ffi instead of --with-dynamic-ffi, configure does not fail on HPPA.
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2007-11-24 19:58:48 UTC
In gentoo-x86/profiles/default-linux/hppa/package.use.mask:
# Jeroen Roovers <jer@gentoo.org> (19 Nov 2007)
# This pulls in dev-scheme/drscheme which needs gjc to build
# or dev-lisp/clisp which has many build issues
dev-lang/swig mzscheme clisp
Comment 5 Marijn Schouten (RETIRED) gentoo-dev 2007-11-24 21:53:37 UTC
wrong bug and drscheme does NOT use gcj
Comment 6 Raúl Porcel (RETIRED) gentoo-dev 2008-06-29 20:44:35 UTC
2.44.1-r1 fails differently on sparc

gcc  -O2 -mcpu=ultrasparc -pipe -Igllib -W -Wswitch -Wcomment -Wpointer-arith -Wimplicit -Wreturn-type -Wmissing-declarations -Wno-sign-compare -O -DUNICODE -DDYNAMIC_FFI -DNO_READLINE -I. -c lisparit.c
In file included from ../src/lisparit.d:8:
../src/lispbibl.d:741: warning: call-clobbered register used for global register variable
In file included from ../src/lisparit.d:8:
../src/lispbibl.d:9152: warning: register used for two global register variables
In file included from ../src/lisparit.d:8:
../src/lispbibl.d:11501: warning: register used for two global register variables
../src/lispbibl.d:11510: warning: register used for two global register variables
../src/lispbibl.d:11704: warning: register used for two global register variables
In file included from ../src/lisparit.d:28:
../src/arilev1.d:253:30: error: arisparc.c: No such file or directory
make: *** [lisparit.o] Error 1
Comment 7 Ferris McCormick (RETIRED) gentoo-dev 2008-09-10 11:43:41 UTC
(In reply to comment #6)
> 2.44.1-r1 fails differently on sparc
> 
> gcc  -O2 -mcpu=ultrasparc -pipe -Igllib -W -Wswitch -Wcomment -Wpointer-arith
> -Wimplicit -Wreturn-type -Wmissing-declarations -Wno-sign-compare -O -DUNICODE
> -DDYNAMIC_FFI -DNO_READLINE -I. -c lisparit.c
> In file included from ../src/lisparit.d:8:
> ../src/lispbibl.d:741: warning: call-clobbered register used for global
> register variable
> In file included from ../src/lisparit.d:8:
> ../src/lispbibl.d:9152: warning: register used for two global register
> variables
> In file included from ../src/lisparit.d:8:
> ../src/lispbibl.d:11501: warning: register used for two global register
> variables
> ../src/lispbibl.d:11510: warning: register used for two global register
> variables
> ../src/lispbibl.d:11704: warning: register used for two global register
> variables
> In file included from ../src/lisparit.d:28:
> ../src/arilev1.d:253:30: error: arisparc.c: No such file or directory
> make: *** [lisparit.o] Error 1
> 

I can force it to build using
CFLAGS='-O1 -mcpu=ultraspaec3 -pipe -DSPARC64'  (thanks to aballier for the suggestion).  But then it gets to this:
==============================
mkdir data
cd data && ln -s ../../utils/unicode/UnicodeDataFull.txt .
cd data && ln -s ../../doc/Symbol-Table.text .
gcc -O1 -pipe -mcpu=ultrasparc3 -DSPARC64 -W -Wswitch -Wcomment -Wpointer-arith -Wimplicit -Wreturn-type -Wmissing-declarations -Wno-sign-compare -O -falign-functions=4 -DUNICODE -DDYNAMIC_FFI -DDYNAMIC_MODULES -I. -Wl,-O1  -x none -Wl,-export-dynamic spvw.o spvwtabf.o spvwtabs.o spvwtabo.o eval.o control.o encoding.o pathname.o stream.o socket.o io.o funarg.o array.o hashtabl.o list.o package.o record.o weak.o sequence.o charstrg.o debug.o error.o misc.o time.o predtype.o symbol.o lisparit.o i18n.o foreign.o unixaux.o built.o arisparc64.o gllib/uniwidth/width.o gllib/uniname/uniname.o gllib/localcharset.o modules.o /usr/lib/libreadline.so -lncurses -ldl /usr/lib/libavcall.a /usr/lib/libcallback.a  -L/usr/lib -lsigsegv -L/usr/lib -lc -o lisp.run
./lisp.run -B . -N locale -E UTF-8 -Epathname 1:1 -Emisc 1:1 -norc -m 2MW -lp ../src/ -x '(and (load "../src/init.lisp") (sys::%saveinitmem) (ext::exit)) (ext::exit t)'
make: *** [interpreted.mem] Segmentation fault
========================================

When this builds, with or without -DSPARC64, we see a huge number of unpleasant warnings, such as:
../src/lispbibl.d:14948: warning: right shift count >= width of type
../src/lispbibl.d:14948: warning: cast to pointer from integer of different size

warnings about assigning two global variables to the same register at the same time, assigned registers wiped out by various procedure calls, and so on.
Comment 8 Marijn Schouten (RETIRED) gentoo-dev 2009-07-29 11:35:15 UTC
Does clisp-2.48 still have the same failure?
Comment 9 Jeroen Roovers (RETIRED) gentoo-dev 2010-05-20 18:21:34 UTC
Created attachment 232261 [details]
dev-lisp-clisp-2.48-r1:20100520-175852.log [hppa, fail]

(In reply to comment #5)
> wrong bug and drscheme does NOT use gcj

I'm sure you could have read comment #4 more attentively.

2.48 does configure nicely, it seems, but it then tries to use some weird assembly which may or may not be HPPA1.0 or 1.1 and probably intended for HP-UX and not GNU/Linux, or perhaps something completely random like x86 asm, which makes it error out in <spvw.c>.

I've tried out the workarounds that ALPHA and IA64 deploy in the ebuild to get it to build, but they are not sufficient for HPPA it seems. Having `append-flags -DNO_ASM' does not help either.
Comment 10 Chema Alonso Josa (RETIRED) gentoo-dev 2018-01-30 21:33:10 UTC
According to Bruno Haible's email sent to the Common Lisp Project email on Nov 2017, this has been fixed in libffcall-2.0 (dev-libs/ffcall-2.0).