Bug 1392563

Summary: Build clisp for F25+
Product: [Fedora] Fedora Reporter: Pavel Raiskup <praiskup>
Component: clispAssignee: Jerry James <loganjerry>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: fweimer, green, loganjerry
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: clisp-2.49-20.20161111hg.fc25 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-19 21:17:12 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Pavel Raiskup 2016-11-07 18:49:21 UTC
I don't know whether there's FTBFS (probably is, but here's not yet finished
scratch build for f26):
http://koji.fedoraproject.org/koji/taskinfo?taskID=16339113
FWIW, my box (x86_64) builds x86_64 fine in F26 (rawhide) mock.

Fedora 26 seems to inherit fc24 builds now, but that's not truth for aarch64,
ppc64le, etc.  Could we build clisp so other architectures get the binary
packages, too?

Comment 1 Florian Weimer 2016-11-07 19:40:00 UTC
Looks like CLISP needs to build with --without-ffcall on aarch64.

I don't know why it doesn't use libffi, which is the standard library for that.

Comment 2 Pavel Raiskup 2016-11-07 21:27:21 UTC
Hmm, agreed.  Aarch64 fails with the following:

DEBUG util.py:502:  Executing command: ['/usr/bin/dnf', 'builddep', '--installroot', '/var/lib/mock/f26-build-6784491-664432/root/', '/var/lib/mock/f26-build-6784491-664432/root//builddir/build/SRPMS/clisp-2.49-19.20130208hg.fc26.src.rpm', '--setopt=tsflags=nocontexts'] with env {'LANG': 'en_US.UTF-8', 'PS1': '<mock-chroot> \\s-\\v\\$ ', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'HOME': '/builddir', 'PROMPT_COMMAND': 'printf "\\033]0;<mock-chroot>\\007"', 'SHELL': '/bin/bash', 'LC_MESSAGES': 'C', 'HOSTNAME': 'mock', 'TERM': 'vt100'} and shell False
DEBUG util.py:421:  Last metadata expiration check: 0:01:49 ago on Mon Nov  7 19:27:40 2016.
DEBUG util.py:421:  No matching package to install: 'ffcall'
DEBUG util.py:421:  Not all dependencies satisfied

Ppc64 fails with:

2.49/build/gllib -I/builddir/build/BUILD/clisp-2.49/src/gllib -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mcpu=power8 -mtune=power8 -Wa,--noexecstack -L/usr/lib64/readline5 -W -Wswitch -Wcomment -Wpointer-arith -Wreturn-type -Wmissing-declarations -Wimplicit -Wno-sign-compare -Wno-format-nonliteral -O2 -falign-functions=4 -DENABLE_UNICODE -DDYNAMIC_FFI -DDYNAMIC_MODULES -c spvw.c
In file included from ../src/spvw.d:23:0:
../src/lispbibl.d:2869:7: error: #error oint_addr_mask does not cover MALLOC_ADDRESS_RANGE !!
      #error oint_addr_mask does not cover MALLOC_ADDRESS_RANGE !!
       ^~~~~
../src/lispbibl.d:8982:3: warning: optimization may eliminate reads and

There's this in spec file:
# See Red Hat bugs 238954 (ppc64) and 925155 (aarch64)
ExcludeArch:   %{power64} aarch64

But the "resolution" of bug 925155 not entirely right -- one should use
%configure (not ./configure) to automatically patch config.status/config.guess.
But %configure is probably not usable for clisp.  So one could use someting
like:

    find -name config.guess -exec cp /usr/lib/rpm/redhat/config.guess {} +

Comment 3 Florian Weimer 2016-11-08 08:54:58 UTC
Ugh, I forgot that CLISP needs an excessive number of pointer bits.  The code is completely non-portable and only works by accident on most 64-bit targets (including x86_64).

It's probably best to drop CLISP from Fedora until this is fixed upstream.

Comment 4 Pavel Raiskup 2016-11-08 09:03:34 UTC
Is this discussed somewhere upstream?

Comment 5 Florian Weimer 2016-11-08 10:27:22 UTC
I started a discussion upstream: https://sourceforge.net/p/clisp/mailman/message/35478071/

Comment 6 Jerry James 2016-11-11 17:03:16 UTC
(In reply to Florian Weimer from comment #1)
> Looks like CLISP needs to build with --without-ffcall on aarch64.

That won't help.  Clisp itself contains assembly code (see src/ariarm.d, for exmaple), which is missing for aarch64 and ppc64.  And if somebody wants to write that assembly, they may as well write the missing assembly for ffcall, too.

> I don't know why it doesn't use libffi, which is the standard library for
> that.

Because libffi didn't even exist until 1996, a full decade after clisp was launched.

(In reply to Pavel Raiskup from comment #2)
> But the "resolution" of bug 925155 not entirely right -- one should use
> %configure (not ./configure) to automatically patch
> config.status/config.guess.
> But %configure is probably not usable for clisp.  So one could use someting
> like:
> 
>     find -name config.guess -exec cp /usr/lib/rpm/redhat/config.guess {} +

The resolution of that bug was correct at the time it was closed, but things have changed since then.  I'll add something like your solution to the spec file.  Thanks.

(In reply to Florian Weimer from comment #3)
> It's probably best to drop CLISP from Fedora until this is fixed upstream.

That's rather extreme, isn't it?  Why drop it from platforms where it works?

Comment 7 Fedora Update System 2016-11-11 18:57:40 UTC
clisp-2.49-20.20161111hg.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2016-a8ec65bdfe

Comment 8 Fedora Update System 2016-11-12 18:23:42 UTC
clisp-2.49-20.20161111hg.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-a8ec65bdfe

Comment 9 Fedora Update System 2016-11-19 21:17:12 UTC
clisp-2.49-20.20161111hg.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.