Re: [sage-devel] problem building maxima

2021-05-15 Thread Jan Groenewald
Hi

On Fri, 14 May 2021 at 15:05, Dima Pasechnik  wrote:

> Thanks. Indeed, libffi is alive and well:
>
> ...
> checking for ffi_closure_alloc in -lffi... yes
> checking ffi/ffi.h usability... no
> checking ffi/ffi.h presence... no
> checking for ffi/ffi.h... no
> checking ffi.h usability... yes
> checking ffi.h presence... yes
> checking for ffi.h... yes
> checking whether we can use the existing libffi library ... yes
>

Something else is also going on:

0 jan@debian:/tmp$nl ecl-21.2.1.log |grep ffi|grep "checking whet"
   102 checking whether we can use the existing libffi library ... yes
  4732 checking whether we can use the existing libffi library ... no
0 jan@debian:/tmp$nl ecl-21.2.1.log |grep onfiguring
36 Configuring ecl-21.2.1
  4666 Configuring ecl-21.2.1
  4733 configure: Configuring included libffi library:
0 jan@debian:/tmp$nl ecl-21.2.1.log |grep Apr
12 Linux fermat 5.4.0-72-generic #80-Ubuntu SMP Mon Apr 12 17:35:00 UTC
2021 x86_64 x86_64 x86_64 GNU/Linux
  4642 Linux fermat 5.4.0-72-generic #80-Ubuntu SMP Mon Apr 12 17:35:00 UTC
2021 x86_64 x86_64 x86_64 GNU/Linux
0 jan@debian:/tmp$

Why does it look like it was building it twice, with different results?

Regards,
Jan
-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAOAPrp92D%2B4tTS8jUrU_BzAzAN_Hx%2BJKgDrxh_hFqB14OYEX7w%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
Thanks. Indeed, libffi is alive and well:

...
checking for ffi_closure_alloc in -lffi... yes
checking ffi/ffi.h usability... no
checking ffi/ffi.h presence... no
checking for ffi/ffi.h... no
checking ffi.h usability... yes
checking ffi.h presence... yes
checking for ffi.h... yes
checking whether we can use the existing libffi library ... yes
...

;;;   gcc -o libecl.so
-L/usr/local/sage/sage-9.3/local/var/tmp/sage/build/ecl-21.2.1/src/build/
c/main.o c/all_symbols2.o liblsp.a libeclmin.a
-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/ -shared
-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib
-L/usr/local/sage/sage-9.3/local/lib
-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib
-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib
-L/usr/local/sage/sage-9.3/local/lib
-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib
-Wl,-soname,libecl.so.21.2 -lgmp -lgc -lffi -lgc -ldl -lm

Comparing with the failed call

Error code 1 when executing
(EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas"
"-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit0kBo2G.o"
"binary-ecl/maxima-package.o"
"-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared"
"-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" "-L/usr
/local/sage/sage-9.3/local/lib"
"-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib"
"-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib"
"-L/usr/local/sage/sage-9.3/local/lib"
"-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc"
...)):
/usr/bin/ld: cannot find -lffi

does not seem to reveal anything interesting.

On Fri, May 14, 2021 at 1:46 PM John Cremona  wrote:
>
> Here is the ECL log.
>
> John
>
> On Fri, 14 May 2021 at 13:20, Michael Orlitzky  wrote:
> >
> > On Fri, 2021-05-14 at 12:12 +0100, Dima Pasechnik wrote:
> > > >
> > > > The other possibility is that the linker is told not to look for
> > > > system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
> > > >
> > > > On the other hand, it's a bug in maxima, which does not try to check
> > > > for presense of libffi, just assumes it's there.
> > >
> > > oops, I meant to say, it's a bug in ECL, as this failing call to gcc
> > > is emitted by ECL.
> > >
> >
> > I ran into a problem recently that sounds relevant:
> >
> >   https://sourceforge.net/p/maxima/bugs/3759/
> >
> > I wonder how hard it would be at this point to teach Sage to use the
> > system copy of Maxima. That will be the long-term solution anyway.
> >
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "sage-devel" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to sage-devel+unsubscr...@googlegroups.com.
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/sage-devel/e53fd6c259f8bd2284938c2627f8902c07af455e.camel%40orlitzky.com.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-devel+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-devel/CAD0p0K5B2t%3DLiwJ0j%2Bm_RtrTyy%2BNvpD414ACYkOrNr3dxk7qww%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAWYfq0YkNC4aPkqHaUui%2BYzG1aDNVoFYou%3DWu7Vr3uWG98xVg%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
On Fri, May 14, 2021 at 1:20 PM Michael Orlitzky  wrote:
>
> On Fri, 2021-05-14 at 12:12 +0100, Dima Pasechnik wrote:
> > >
> > > The other possibility is that the linker is told not to look for
> > > system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
> > >
> > > On the other hand, it's a bug in maxima, which does not try to check
> > > for presense of libffi, just assumes it's there.
> >
> > oops, I meant to say, it's a bug in ECL, as this failing call to gcc
> > is emitted by ECL.
> >
>
> I ran into a problem recently that sounds relevant:
>
>   https://sourceforge.net/p/maxima/bugs/3759/
>
the ECL issue mentioned there sounds relevant:
https://gitlab.com/embeddable-common-lisp/ecl/-/issues/636 - I've left
a comment there.


> I wonder how hard it would be at this point to teach Sage to use the
> system copy of Maxima. That will be the long-term solution anyway.

Well, we know from the system ECL trac ticket that it's not going to
be very easy.

>
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-devel+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-devel/e53fd6c259f8bd2284938c2627f8902c07af455e.camel%40orlitzky.com.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAWYfq0HXO4KMPgr6y_GNfg-HCXtcGeJq2hnDS%3DxEJy83GwfPQ%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Michael Orlitzky
On Fri, 2021-05-14 at 12:12 +0100, Dima Pasechnik wrote:
> > 
> > The other possibility is that the linker is told not to look for
> > system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
> > 
> > On the other hand, it's a bug in maxima, which does not try to check
> > for presense of libffi, just assumes it's there.
> 
> oops, I meant to say, it's a bug in ECL, as this failing call to gcc
> is emitted by ECL.
> 

I ran into a problem recently that sounds relevant:

  https://sourceforge.net/p/maxima/bugs/3759/

I wonder how hard it would be at this point to teach Sage to use the
system copy of Maxima. That will be the long-term solution anyway.


-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/e53fd6c259f8bd2284938c2627f8902c07af455e.camel%40orlitzky.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
On Fri, May 14, 2021 at 12:17 PM Jan Groenewald  wrote:
>
> Hi
>
> On Fri, 14 May 2021 at 13:12, Dima Pasechnik  wrote:
>>
>> On Fri, May 14, 2021 at 11:53 AM Dima Pasechnik  wrote:
>> >
>> > On Fri, May 14, 2021 at 11:21 AM Jan Groenewald  wrote:
>> > >
>> > > Hi
>> > >
>> > > On Fri, 14 May 2021 at 11:26, François Bissey  
>> > > wrote:
>> > >>
>> > >> It looks like maxima.fas has not been built. Last time I saw that happen
>> > >> in sage-on-gentoo was because the patch to build it was missing.
>> > >> Not sure how it could happen on your setup, the log needs further 
>> > >> inspection.
>> > >>
>> > >> > On 14/05/2021, at 21:18, John Cremona  wrote:
>> > >> >
>> > >> > I have been installing sage-9.3 from the tarball on a few ubuntu
>> > >> > machines, just doing ./configure and then make.  On one machine
>> > >> > running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
>> > >> > the log files.
>> > >> >
>> > >> > This is a machine on which I tried a few weeks ago to help the build
>> > >> > process by installing as many of the dependencies as possible.  My
>> > >> > experience so far has been that this has caused so many things to go
>> > >> > wrong that I prefer the old way -- build everything -- since that just
>> > >> > takes more computer time, while the new way (so far) uses a lot more
>> > >> > of my time.
>> > >
>> > >
>> > > config.log:
>> > > ## Checking whether SageMath should install SPKG libffi... ##
>> > > ## --- ##
>> > > configure:24887: checking for LIBFFI
>> > > configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
>> > > configure:24897: $? = 0
>> > > configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
>> > > configure:24914: $? = 0
>> > > configure:25100: result: yes
>> > > configure:25108: will use system package and not install SPKG libffi
>> > >
>> > > maxima log:
>> > > Condition of type: SIMPLE-ERROR
>> > > Error code 1 when executing
>> > > (EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas" 
>> > > "-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit8GQbdq.o" 
>> > > "binary-ecl/maxima-package.o" 
>> > > "-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared" 
>> > > "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
>> > > "-L/usr/local/sage/sage-9.3/local/lib" 
>> > > "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" 
>> > > "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
>> > > "-L/usr/local/sage/sage-9.3/local/lib" 
>> > > "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc" 
>> > > ...)):
>> > > /usr/bin/ld: cannot find -lffi
>> > > collect2: error: ld returned 1 exit status
>> > > Available restarts:
>> > >
>> > > 1. (CONTINUE) Continues anyway.
>> > > 2. (RESTART-TOPLEVEL) Go back to Top-Level REPL.
>> > >
>> > > Broken at DO-COMPILE-ECL.
>> > >  File: 
>> > > #P"/usr/local/sage/sage-9.3/local/var/tmp/sage/build/maxima-5.44.0/src/src/maxima.system"
>> > >  (Position #1601)
>> > >
>> > >
>> > >
>> > > Do you perhaps need to sudo apt install libffi-dev?
>> >
>> >
>> > One way I can explain this is a broken system-wide install of libffi-dev
>> > I don't know how this can be achieved, other than having multiple
>> > system-wide copies of libffi,
>> > or stuff manually removed.
>> >
>> > The other possibility is that the linker is told not to look for
>> > system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
>> >
>> > On the other hand, it's a bug in maxima, which does not try to check
>> > for presense of libffi, just assumes it's there.
>>
>> oops, I meant to say, it's a bug in ECL, as this failing call to gcc
>> is emitted by ECL.
>
>
> Why did SageMath say this? Was it checking for runtime libffi or headers?

it's checking with pkg-config first of all.
see build/pkgs/libffi/spkg-configure.m4

If this test succeeds, it's assumed everything is fine.
Note that libffi is a pre-req for ECL, and ECL is built just fine,
as far as one can see.

I gather it must be a bug in ECL, which struggles to create a correct
incantation of C compiler calls
from a unique (Copyright JEC 2021 :-)) concostion of gmp built by Sage
and libffi provided by the system.

ECL checks for libffi carefully in its configure, as far as I know.


John, can you post logs/pkgs/ecl-21.2.1.log ?





>
> config.log:
> ## Checking whether SageMath should install SPKG libffi... ##
> ## --- ##
> configure:24887: checking for LIBFFI
> configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
> configure:24897: $? = 0
> configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
> configure:24914: $? = 0
> configure:25100: result: yes
> configure:25108: will use system package and not install SPKG libffi
>
> Regards,
> Jan
> --
>   .~.
>   /V\ Jan Groenewald
>  /( )\www.aims.ac.za
>  ^^-^^
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from 

Re: [sage-devel] problem building maxima

2021-05-14 Thread Jan Groenewald
Hi

On Fri, 14 May 2021 at 13:12, Dima Pasechnik  wrote:

> On Fri, May 14, 2021 at 11:53 AM Dima Pasechnik  wrote:
> >
> > On Fri, May 14, 2021 at 11:21 AM Jan Groenewald  wrote:
> > >
> > > Hi
> > >
> > > On Fri, 14 May 2021 at 11:26, François Bissey 
> wrote:
> > >>
> > >> It looks like maxima.fas has not been built. Last time I saw that
> happen
> > >> in sage-on-gentoo was because the patch to build it was missing.
> > >> Not sure how it could happen on your setup, the log needs further
> inspection.
> > >>
> > >> > On 14/05/2021, at 21:18, John Cremona 
> wrote:
> > >> >
> > >> > I have been installing sage-9.3 from the tarball on a few ubuntu
> > >> > machines, just doing ./configure and then make.  On one machine
> > >> > running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
> > >> > the log files.
> > >> >
> > >> > This is a machine on which I tried a few weeks ago to help the build
> > >> > process by installing as many of the dependencies as possible.  My
> > >> > experience so far has been that this has caused so many things to go
> > >> > wrong that I prefer the old way -- build everything -- since that
> just
> > >> > takes more computer time, while the new way (so far) uses a lot more
> > >> > of my time.
> > >
> > >
> > > config.log:
> > > ## Checking whether SageMath should install SPKG libffi... ##
> > > ## --- ##
> > > configure:24887: checking for LIBFFI
> > > configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
> > > configure:24897: $? = 0
> > > configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
> > > configure:24914: $? = 0
> > > configure:25100: result: yes
> > > configure:25108: will use system package and not install SPKG libffi
> > >
> > > maxima log:
> > > Condition of type: SIMPLE-ERROR
> > > Error code 1 when executing
> > > (EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas"
> "-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit8GQbdq.o"
> "binary-ecl/maxima-package.o"
> "-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared"
> "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib"
> "-L/usr/local/sage/sage-9.3/local/lib"
> "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib"
> "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib"
> "-L/usr/local/sage/sage-9.3/local/lib"
> "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc"
> ...)):
> > > /usr/bin/ld: cannot find -lffi
> > > collect2: error: ld returned 1 exit status
> > > Available restarts:
> > >
> > > 1. (CONTINUE) Continues anyway.
> > > 2. (RESTART-TOPLEVEL) Go back to Top-Level REPL.
> > >
> > > Broken at DO-COMPILE-ECL.
> > >  File:
> #P"/usr/local/sage/sage-9.3/local/var/tmp/sage/build/maxima-5.44.0/src/src/maxima.system"
> (Position #1601)
> > >
> > >
> > >
> > > Do you perhaps need to sudo apt install libffi-dev?
> >
> >
> > One way I can explain this is a broken system-wide install of libffi-dev
> > I don't know how this can be achieved, other than having multiple
> > system-wide copies of libffi,
> > or stuff manually removed.
> >
> > The other possibility is that the linker is told not to look for
> > system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
> >
> > On the other hand, it's a bug in maxima, which does not try to check
> > for presense of libffi, just assumes it's there.
>
> oops, I meant to say, it's a bug in ECL, as this failing call to gcc
> is emitted by ECL.
>

Why did SageMath say this? Was it checking for runtime libffi or headers?

config.log:
## Checking whether SageMath should install SPKG libffi... ##
## --- ##
configure:24887: checking for LIBFFI
configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
configure:24897: $? = 0
configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
configure:24914: $? = 0
configure:25100: result: yes
*configure:25108: will use system package and not install SPKG libffi*

Regards,
Jan
-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAg%3Dp_3J7QyF7yTjYY3ecPz5U5uA6E2bw_iBiHYcXw4b0siBEA%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
On Fri, May 14, 2021 at 11:53 AM Dima Pasechnik  wrote:
>
> On Fri, May 14, 2021 at 11:21 AM Jan Groenewald  wrote:
> >
> > Hi
> >
> > On Fri, 14 May 2021 at 11:26, François Bissey  wrote:
> >>
> >> It looks like maxima.fas has not been built. Last time I saw that happen
> >> in sage-on-gentoo was because the patch to build it was missing.
> >> Not sure how it could happen on your setup, the log needs further 
> >> inspection.
> >>
> >> > On 14/05/2021, at 21:18, John Cremona  wrote:
> >> >
> >> > I have been installing sage-9.3 from the tarball on a few ubuntu
> >> > machines, just doing ./configure and then make.  On one machine
> >> > running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
> >> > the log files.
> >> >
> >> > This is a machine on which I tried a few weeks ago to help the build
> >> > process by installing as many of the dependencies as possible.  My
> >> > experience so far has been that this has caused so many things to go
> >> > wrong that I prefer the old way -- build everything -- since that just
> >> > takes more computer time, while the new way (so far) uses a lot more
> >> > of my time.
> >
> >
> > config.log:
> > ## Checking whether SageMath should install SPKG libffi... ##
> > ## --- ##
> > configure:24887: checking for LIBFFI
> > configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
> > configure:24897: $? = 0
> > configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
> > configure:24914: $? = 0
> > configure:25100: result: yes
> > configure:25108: will use system package and not install SPKG libffi
> >
> > maxima log:
> > Condition of type: SIMPLE-ERROR
> > Error code 1 when executing
> > (EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas" 
> > "-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit8GQbdq.o" 
> > "binary-ecl/maxima-package.o" 
> > "-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared" 
> > "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
> > "-L/usr/local/sage/sage-9.3/local/lib" 
> > "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" 
> > "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
> > "-L/usr/local/sage/sage-9.3/local/lib" 
> > "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc" 
> > ...)):
> > /usr/bin/ld: cannot find -lffi
> > collect2: error: ld returned 1 exit status
> > Available restarts:
> >
> > 1. (CONTINUE) Continues anyway.
> > 2. (RESTART-TOPLEVEL) Go back to Top-Level REPL.
> >
> > Broken at DO-COMPILE-ECL.
> >  File: 
> > #P"/usr/local/sage/sage-9.3/local/var/tmp/sage/build/maxima-5.44.0/src/src/maxima.system"
> >  (Position #1601)
> >
> >
> >
> > Do you perhaps need to sudo apt install libffi-dev?
>
>
> One way I can explain this is a broken system-wide install of libffi-dev
> I don't know how this can be achieved, other than having multiple
> system-wide copies of libffi,
> or stuff manually removed.
>
> The other possibility is that the linker is told not to look for
> system-wide libffi - can this be achieved with -L and -Wl,-rpath ?
>
> On the other hand, it's a bug in maxima, which does not try to check
> for presense of libffi, just assumes it's there.

oops, I meant to say, it's a bug in ECL, as this failing call to gcc
is emitted by ECL.


>
>
> > It is listed as a dependency here: 
> > https://doc.sagemath.org/html/en/installation/source.html
> >
> > (also see https://bugzilla.redhat.com/show_bug.cgi?id=837102 from 2012)
> >
> > Regards,
> > Jan
> >
> > --
> >   .~.
> >   /V\ Jan Groenewald
> >  /( )\www.aims.ac.za
> >  ^^-^^
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "sage-devel" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to sage-devel+unsubscr...@googlegroups.com.
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/sage-devel/CAAg%3Dp_33NMuyuZ_zQn8%2B3oQjDhR%3DCAMAcausjD7TYoi_x9EoXQ%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAWYfq269jhMDPq%3DSweNKAWB9eyxjh0bbh39tdHdpE3hoiLJoA%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
On Fri, May 14, 2021 at 11:21 AM Jan Groenewald  wrote:
>
> Hi
>
> On Fri, 14 May 2021 at 11:26, François Bissey  wrote:
>>
>> It looks like maxima.fas has not been built. Last time I saw that happen
>> in sage-on-gentoo was because the patch to build it was missing.
>> Not sure how it could happen on your setup, the log needs further inspection.
>>
>> > On 14/05/2021, at 21:18, John Cremona  wrote:
>> >
>> > I have been installing sage-9.3 from the tarball on a few ubuntu
>> > machines, just doing ./configure and then make.  On one machine
>> > running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
>> > the log files.
>> >
>> > This is a machine on which I tried a few weeks ago to help the build
>> > process by installing as many of the dependencies as possible.  My
>> > experience so far has been that this has caused so many things to go
>> > wrong that I prefer the old way -- build everything -- since that just
>> > takes more computer time, while the new way (so far) uses a lot more
>> > of my time.
>
>
> config.log:
> ## Checking whether SageMath should install SPKG libffi... ##
> ## --- ##
> configure:24887: checking for LIBFFI
> configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
> configure:24897: $? = 0
> configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
> configure:24914: $? = 0
> configure:25100: result: yes
> configure:25108: will use system package and not install SPKG libffi
>
> maxima log:
> Condition of type: SIMPLE-ERROR
> Error code 1 when executing
> (EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas" 
> "-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit8GQbdq.o" 
> "binary-ecl/maxima-package.o" 
> "-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared" 
> "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
> "-L/usr/local/sage/sage-9.3/local/lib" 
> "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" 
> "-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib" 
> "-L/usr/local/sage/sage-9.3/local/lib" 
> "-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc" ...)):
> /usr/bin/ld: cannot find -lffi
> collect2: error: ld returned 1 exit status
> Available restarts:
>
> 1. (CONTINUE) Continues anyway.
> 2. (RESTART-TOPLEVEL) Go back to Top-Level REPL.
>
> Broken at DO-COMPILE-ECL.
>  File: 
> #P"/usr/local/sage/sage-9.3/local/var/tmp/sage/build/maxima-5.44.0/src/src/maxima.system"
>  (Position #1601)
>
>
>
> Do you perhaps need to sudo apt install libffi-dev?


One way I can explain this is a broken system-wide install of libffi-dev
I don't know how this can be achieved, other than having multiple
system-wide copies of libffi,
or stuff manually removed.

The other possibility is that the linker is told not to look for
system-wide libffi - can this be achieved with -L and -Wl,-rpath ?

On the other hand, it's a bug in maxima, which does not try to check
for presense of libffi, just assumes it's there.


> It is listed as a dependency here: 
> https://doc.sagemath.org/html/en/installation/source.html
>
> (also see https://bugzilla.redhat.com/show_bug.cgi?id=837102 from 2012)
>
> Regards,
> Jan
>
> --
>   .~.
>   /V\ Jan Groenewald
>  /( )\www.aims.ac.za
>  ^^-^^
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-devel+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-devel/CAAg%3Dp_33NMuyuZ_zQn8%2B3oQjDhR%3DCAMAcausjD7TYoi_x9EoXQ%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAWYfq2gFHukombrSGYFc61uLPXyyDM-SoSYdUrx-KuGA%2BeD7w%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Jan Groenewald
Hi

On Fri, 14 May 2021 at 11:26, François Bissey  wrote:

> It looks like maxima.fas has not been built. Last time I saw that happen
> in sage-on-gentoo was because the patch to build it was missing.
> Not sure how it could happen on your setup, the log needs further
> inspection.
>
> > On 14/05/2021, at 21:18, John Cremona  wrote:
> >
> > I have been installing sage-9.3 from the tarball on a few ubuntu
> > machines, just doing ./configure and then make.  On one machine
> > running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
> > the log files.
> >
> > This is a machine on which I tried a few weeks ago to help the build
> > process by installing as many of the dependencies as possible.  My
> > experience so far has been that this has caused so many things to go
> > wrong that I prefer the old way -- build everything -- since that just
> > takes more computer time, while the new way (so far) uses a lot more
> > of my time.
>

config.log:
## Checking whether SageMath should install SPKG libffi... ##
## --- ##
configure:24887: checking for LIBFFI
configure:24894: $PKG_CONFIG --exists --print-errors "libffi"
configure:24897: $? = 0
configure:24911: $PKG_CONFIG --exists --print-errors "libffi"
configure:24914: $? = 0
configure:25100: result: yes
*configure:25108: will use system package and not install SPKG libffi*

maxima log:
Condition of type: SIMPLE-ERROR
Error code 1 when executing
(EXT:RUN-PROGRAM "gcc" ("-o" "binary-ecl/maxima-package.fas"
"-L/usr/local/sage/sage-9.3/local/lib/" "/tmp/eclinit8GQbdq.o"
"binary-ecl/maxima-package.o"
"-Wl,--rpath,/usr/local/sage/sage-9.3/local/lib/" "-shared"
"-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib"
"-L/usr/local/sage/sage-9.3/local/lib"
"-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib"
"-Wl,-rpath-link,/usr/local/sage/sage-9.3/local/lib"
"-L/usr/local/sage/sage-9.3/local/lib"
"-Wl,-rpath,/usr/local/sage/sage-9.3/local/lib" "-lecl" "-lgmp" "-lgc"
...)):
*/usr/bin/ld: cannot find -lffi*
collect2: error: ld returned 1 exit status
Available restarts:

1. (CONTINUE) Continues anyway.
2. (RESTART-TOPLEVEL) Go back to Top-Level REPL.

Broken at DO-COMPILE-ECL.
 File:
#P"/usr/local/sage/sage-9.3/local/var/tmp/sage/build/maxima-5.44.0/src/src/maxima.system"
(Position #1601)



Do you perhaps need to sudo apt install libffi-dev?
It is listed as a dependency here:
https://doc.sagemath.org/html/en/installation/source.html

(also see https://bugzilla.redhat.com/show_bug.cgi?id=837102 from 2012)

Regards,
Jan

-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAg%3Dp_33NMuyuZ_zQn8%2B3oQjDhR%3DCAMAcausjD7TYoi_x9EoXQ%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread Dima Pasechnik
On Fri, May 14, 2021 at 10:19 AM John Cremona  wrote:
>
> I have been installing sage-9.3 from the tarball on a few ubuntu
> machines, just doing ./configure and then make.  On one machine
> running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
> the log files.
>
> This is a machine on which I tried a few weeks ago to help the build
> process by installing as many of the dependencies as possible.  My
> experience so far has been that this has caused so many things to go
> wrong that I prefer the old way -- build everything -- since that just

without your feedback one cannot improve things going wrong...

> takes more computer time, while the new way (so far) uses a lot more
> of my time.

Do you have a system-wide install of ecl?
This is something that potentially might interfere.

>
> John
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-devel+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-devel/CAD0p0K7VWKz7ActzBjT9FZdW_yo3bkK99bSDEWd0n-zWkQsyNw%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/CAAWYfq1n-dmFsQsXjFjXAuC1Zm4JGrrAZ9M4ZGxkQxUTBtVdig%40mail.gmail.com.


Re: [sage-devel] problem building maxima

2021-05-14 Thread François Bissey
It looks like maxima.fas has not been built. Last time I saw that happen
in sage-on-gentoo was because the patch to build it was missing.
Not sure how it could happen on your setup, the log needs further inspection.

> On 14/05/2021, at 21:18, John Cremona  wrote:
> 
> I have been installing sage-9.3 from the tarball on a few ubuntu
> machines, just doing ./configure and then make.  On one machine
> running ubuntu 20.04.02 LTS maxima fails to build.  I have attached
> the log files.
> 
> This is a machine on which I tried a few weeks ago to help the build
> process by installing as many of the dependencies as possible.  My
> experience so far has been that this has caused so many things to go
> wrong that I prefer the old way -- build everything -- since that just
> takes more computer time, while the new way (so far) uses a lot more
> of my time.
> 
> John
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-devel+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-devel/CAD0p0K7VWKz7ActzBjT9FZdW_yo3bkK99bSDEWd0n-zWkQsyNw%40mail.gmail.com.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/7DE9A1AD-82F1-4058-B34A-A02C00E6950D%40gmail.com.