all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
@ 2020-08-06 16:05 Eric S Fraga
  2020-08-06 17:40 ` Robert Pluim
  0 siblings, 1 reply; 8+ messages in thread
From: Eric S Fraga @ 2020-08-06 16:05 UTC (permalink / raw)
  To: help-gnu-emacs

Hello,

Without giving all the gory details, I am trying to build a recent emacs
28.x version (from git) on an old computer running Debian Jessie,
i.e. Linux circa 2014-2015.

I can configure and compile Emacs if I use --with-gnutls=ifavailable but
not having libgnutls-dev or libgmp-dev installed.  This Emacs then runs
but has problems with accessing email (gnus).  I can live with this to
some degree as it meets one of my main requirements which is for writing
prose.  But it would be nice to have email on it as well.

If I install the gnutls library, this brings in libgmp and then Emacs
does not build.  I get error messages along the lines of:

,----
| floatfns.o: In function `Fabs':
| /home/ucecesf/git/emacs/src/floatfns.c:279: undefined reference to `mpz_sgn'
| /home/ucecesf/git/emacs/src/floatfns.c:281: undefined reference to `mpz_neg'
`----

The strange thing is that mpz_sgn, for instance, is a #define in gpm.h
but is not in gmpxx.h.  Both of these include files come from
libgmp-dev.  It could be that Emacs's configure script picks up the
wrong one?

The versions of the two packages in question are:

libgmp-dev:armhf        2:6.0.0+dfsg-6
libgnutls28-dev:armhf   3.3.8-6+deb8u7   

Am I doing something incredibly stupid (I have RTFMed but haven't seen
anything that would help)?  Do I need to build those packages from
source maybe?   

Thank you.
-- 
Eric S Fraga via Emacs 28.0.50 & org 9.3.7 on Debian bullseye/sid




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-06 16:05 problems building emacs with libgpm & gnutls on an old Debian system (Jessie) Eric S Fraga
@ 2020-08-06 17:40 ` Robert Pluim
  2020-08-07 10:18   ` Eric S Fraga
  0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2020-08-06 17:40 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: help-gnu-emacs

>>>>> On Thu, 06 Aug 2020 17:05:16 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:

    Eric> Hello,
    Eric> Without giving all the gory details, I am trying to build a recent emacs
    Eric> 28.x version (from git) on an old computer running Debian Jessie,
    Eric> i.e. Linux circa 2014-2015.

    Eric> I can configure and compile Emacs if I use --with-gnutls=ifavailable but
    Eric> not having libgnutls-dev or libgmp-dev installed.  This Emacs then runs
    Eric> but has problems with accessing email (gnus).  I can live with this to
    Eric> some degree as it meets one of my main requirements which is for writing
    Eric> prose.  But it would be nice to have email on it as well.

Nothing stops you from using  lisp/obsolete/{tls,starttls}.el , which
will wrap gnutls-cli or 'openssl s_client' for you, although itʼs not
a path I'drecommend.

    Eric> If I install the gnutls library, this brings in libgmp and then Emacs
    Eric> does not build.  I get error messages along the lines of:

    Eric> ,----
    Eric> | floatfns.o: In function `Fabs':
    Eric> | /home/ucecesf/git/emacs/src/floatfns.c:279: undefined reference to `mpz_sgn'
    Eric> | /home/ucecesf/git/emacs/src/floatfns.c:281: undefined reference to `mpz_neg'
    Eric> `----

    Eric> The strange thing is that mpz_sgn, for instance, is a #define in gpm.h
    Eric> but is not in gmpxx.h.  Both of these include files come from
    Eric> libgmp-dev.  It could be that Emacs's configure script picks up the
    Eric> wrong one?

    Eric> The versions of the two packages in question are:

    Eric> libgmp-dev:armhf        2:6.0.0+dfsg-6
    Eric> libgnutls28-dev:armhf   3.3.8-6+deb8u7   

    Eric> Am I doing something incredibly stupid (I have RTFMed but haven't seen
    Eric> anything that would help)?  Do I need to build those packages from
    Eric> source maybe?   

I think you can configure emacs using '--without-libgmp', then it will
use a builtin version of gmp. Iʼm assuming that linking to libgnutls
only has a runtime dependency on libgmp, not a requirement to have
access to gmp headers.

Maybe just uninstalling libgmp-dev but leaving libgmp installed is
enough?

Robert



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-06 17:40 ` Robert Pluim
@ 2020-08-07 10:18   ` Eric S Fraga
  2020-08-07 10:49     ` Robert Pluim
  0 siblings, 1 reply; 8+ messages in thread
From: Eric S Fraga @ 2020-08-07 10:18 UTC (permalink / raw)
  To: help-gnu-emacs

On Thursday,  6 Aug 2020 at 19:40, Robert Pluim wrote:
> I think you can configure emacs using '--without-libgmp', then it will
> use a builtin version of gmp. Iʼm assuming that linking to libgnutls
> only has a runtime dependency on libgmp, not a requirement to have
> access to gmp headers.

Hi Robert,

Thank you.  This worked, in the sense that Emacs compiles with GNUTLS
enabled and GMP disabled.

However, when I try to open servers in gnus, I get the following error
message for each server (whether pop, imap, or nntp):

,----
| Decrypting /home/ucecesf/s/dotfiles/authinfo.gpg...done 
| Mail source (pop :server XXX :user YYY :port 995) error (Getting random data).
| Continue? (y or n) 
`----

I have a feeling that this is gnutls related but I am not sure.  Any
pointers would again be very welcome!

I may have to consider upgrading that computer to Debian stretch... but
that would be my last resort.

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.3.7 on Debian bullseye/sid




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-07 10:18   ` Eric S Fraga
@ 2020-08-07 10:49     ` Robert Pluim
  2020-08-10 11:17       ` Eric S Fraga
  0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2020-08-07 10:49 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: help-gnu-emacs

>>>>> On Fri, 07 Aug 2020 11:18:45 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:

    Eric> On Thursday,  6 Aug 2020 at 19:40, Robert Pluim wrote:
    >> I think you can configure emacs using '--without-libgmp', then it will
    >> use a builtin version of gmp. Iʼm assuming that linking to libgnutls
    >> only has a runtime dependency on libgmp, not a requirement to have
    >> access to gmp headers.

    Eric> Hi Robert,

    Eric> Thank you.  This worked, in the sense that Emacs compiles with GNUTLS
    Eric> enabled and GMP disabled.

Good.

    Eric> However, when I try to open servers in gnus, I get the following error
    Eric> message for each server (whether pop, imap, or nntp):

    Eric> ,----
    Eric> | Decrypting /home/ucecesf/s/dotfiles/authinfo.gpg...done 
    Eric> | Mail source (pop :server XXX :user YYY :port 995) error (Getting random data).
    Eric> | Continue? (y or n) 
    Eric> `----

That means 'getrandom' is failing. Do you have HAVE_GETRANDOM set in
src/config.h? If not, emacs will use the gnulib version. Itʼs entirely
possible that itʼs not working quite right on such an old
system. Looking at the code, it will try to open "/dev/random" or
"/dev/urandom".

Or the system one is failing, in which case you can try the gnulib one
by unsetting HAVE_GETRANDOM in src/config.h

    Eric> I have a feeling that this is gnutls related but I am not sure.  Any
    Eric> pointers would again be very welcome!

    Eric> I may have to consider upgrading that computer to Debian stretch... but
    Eric> that would be my last resort.

I suspect that would take quite some doing.

Robert



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-07 10:49     ` Robert Pluim
@ 2020-08-10 11:17       ` Eric S Fraga
  2020-08-10 13:01         ` Robert Pluim
  0 siblings, 1 reply; 8+ messages in thread
From: Eric S Fraga @ 2020-08-10 11:17 UTC (permalink / raw)
  To: help-gnu-emacs

On Friday,  7 Aug 2020 at 12:49, Robert Pluim wrote:
> Or the system one is failing, in which case you can try the gnulib one
> by unsetting HAVE_GETRANDOM in src/config.h

This worked!  Thank you.  I am not sure why the system one is failing
but it does seem to be the case.  In any case, I now have a working
Emacs built from src with gnus, org, twittering, etc.

It would be nice to have the option to control the use of getrandom from
the configure script to avoid having to change the generated config
files afterwards.

Thanks again,
eric

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.3.7 on Debian bullseye/sid




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-10 11:17       ` Eric S Fraga
@ 2020-08-10 13:01         ` Robert Pluim
  2020-08-10 14:10           ` Eric S Fraga
  0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2020-08-10 13:01 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: help-gnu-emacs

>>>>> On Mon, 10 Aug 2020 12:17:57 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:

    Eric> On Friday,  7 Aug 2020 at 12:49, Robert Pluim wrote:
    >> Or the system one is failing, in which case you can try the gnulib one
    >> by unsetting HAVE_GETRANDOM in src/config.h

    Eric> This worked!  Thank you.  I am not sure why the system one is failing
    Eric> but it does seem to be the case.  In any case, I now have a working
    Eric> Emacs built from src with gnus, org, twittering, etc.

Glad it worked. Which millenium was this sytem from again? ;-)

    Eric> It would be nice to have the option to control the use of getrandom from
    Eric> the configure script to avoid having to change the generated config
    Eric> files afterwards.

Emacs uses gnulib for this kind of stuff, and since itʼs all low-level
system calls, there are no configure level switches for turning it
off. Itʼs not like itʼs TLS support or an image library, which are optional.

Robert



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-10 13:01         ` Robert Pluim
@ 2020-08-10 14:10           ` Eric S Fraga
  2020-08-10 14:21             ` Robert Pluim
  0 siblings, 1 reply; 8+ messages in thread
From: Eric S Fraga @ 2020-08-10 14:10 UTC (permalink / raw)
  To: help-gnu-emacs

On Monday, 10 Aug 2020 at 15:01, Robert Pluim wrote:
> Glad it worked. Which millenium was this sytem from again? ;-)

Software 6 years old and hardware 10 years old which in computing means
16th century? ;-)

But, more seriously, it's depressing that I keep going back to some of
my old systems in preference to "newer supposedly more advanced"
systems.  In this case, it's a wee OpenPandora palmtop which still works
better than an 8 year later iteration from another company.

The same applies to one of my phones: my Nokia N900 (2008 vintage) still
runs metaphoric rings around any Android phone including my S20+, brand
new this year. But I haven't tried getting Emacs running on the
N900... :-)

> Emacs uses gnulib for this kind of stuff, and since itʼs all low-level
> system calls, there are no configure level switches for turning it
> off. Itʼs not like itʼs TLS support or an image library, which are optional.

Understood.  Sounds reasonable.  At least I know what I have to do now.

Thanks again for all your help (and your patience!),
eric

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.3.7 on Debian bullseye/sid




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: problems building emacs with libgpm & gnutls on an old Debian system (Jessie)
  2020-08-10 14:10           ` Eric S Fraga
@ 2020-08-10 14:21             ` Robert Pluim
  0 siblings, 0 replies; 8+ messages in thread
From: Robert Pluim @ 2020-08-10 14:21 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: help-gnu-emacs

>>>>> On Mon, 10 Aug 2020 15:10:28 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:

    Eric> On Monday, 10 Aug 2020 at 15:01, Robert Pluim wrote:
    >> Glad it worked. Which millenium was this sytem from again? ;-)

    Eric> Software 6 years old and hardware 10 years old which in computing means
    Eric> 16th century? ;-)

GNU/Linux distributions tend to move quite fast.

    >> Emacs uses gnulib for this kind of stuff, and since itʼs all low-level
    >> system calls, there are no configure level switches for turning it
    >> off. Itʼs not like itʼs TLS support or an image library, which are optional.

    Eric> Understood.  Sounds reasonable.  At least I know what I have to do now.

    Eric> Thanks again for all your help (and your patience!),

Iʼm not a patient person, I just play one on the Internet :-)

Robert



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-08-10 14:21 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-06 16:05 problems building emacs with libgpm & gnutls on an old Debian system (Jessie) Eric S Fraga
2020-08-06 17:40 ` Robert Pluim
2020-08-07 10:18   ` Eric S Fraga
2020-08-07 10:49     ` Robert Pluim
2020-08-10 11:17       ` Eric S Fraga
2020-08-10 13:01         ` Robert Pluim
2020-08-10 14:10           ` Eric S Fraga
2020-08-10 14:21             ` Robert Pluim

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.