GNU bug report logs - #30106
Loading file /sources/emacs/lisp/emacs-lisp/ert.elc failed to provide feature `mod-test'

Previous Next

Package: emacs;

Reported by: Jean Louis <bugs <at> gnu.support>

Date: Sun, 14 Jan 2018 06:35:01 UTC

Severity: normal

Fixed in version 27.1

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Forwarded to https://github.com/anse1/emacs-libpq/issues/8

Full log


Message #82 received at 30106 <at> debbugs.gnu.org (full text, mbox):

From: Philipp Stephani <p.stephani2 <at> gmail.com>
To: Glenn Morris <rgm <at> gnu.org>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 30106 <at> debbugs.gnu.org, bugs <at> gnu.support
Subject: Re: bug#30106: Loading file /sources/emacs/lisp/emacs-lisp/ert.elc
 failed to provide feature `mod-test'
Date: Wed, 17 Jan 2018 22:16:58 +0000
[Message part 1 (text/plain, inline)]
Glenn Morris <rgm <at> gnu.org> schrieb am Mi., 17. Jan. 2018 um 21:31 Uhr:

> Eli Zaretskii wrote:
>
> >> Same error on rhel 7.4 if configure with --without-threads
> --with-modules.
> >>
> >>   Emacs module assertion: Module function called from outside the
> current
> >>   Lisp thread
> >
> > Does this go away if you put
> >
> >   return true;
> >
> > at the end of in_current_thread, outside of all the #ifdef's?
>
> No.
>
>
>
>
>
The current implementation of in_current_thread is definitely bogus if
threads are disabled; I can't even compile temacs with --without-threads
--with-modules:

*emacs-module.c:814:42: **error: **incompatible integer to pointer
conversion passing 'sys_thread_t' (aka 'int') to parameter of type
'pthread_t _Nullable'*

*      (aka 'struct _opaque_pthread_t *') [-Werror,-Wint-conversion]*

  return pthread_equal (pthread_self (), current_thread->thread_id);

*                                         ^~~~~~~~~~~~~~~~~~~~~~~~~*

*/usr/include/pthread.h:340:59: note: *passing argument to parameter here

int pthread_equal(pthread_t _Nullable, pthread_t _Nullable);


because if threads are disabled, the thread ID is an int.

The function also doesn't handle the case where neither HAVE_PTHREAD nor
WINDOWSNT are defined (but maybe we don't have such platforms).

Maybe systhread.h should have a function

extern sys_thread_t sys_thread_self ();

so emacs-module.c doesn't have to care about the threading implementations.
[Message part 2 (text/html, inline)]

This bug report was last modified 6 years and 34 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.