Subject: bug#30261: segfault on simultaneous initialization

From: Sheheryar Parvaz <[email-masked]>
Date: Sat, 27 Jan 2018 00:58:06 +0000

Are there any decent workarounds for this? I considered scm_init_guile, however
according to the documentation, it is non-portable. For modules, I have no idea how
I would initialize them.
________________________________
From: Mark H Weaver <[email-masked]>
Sent: January 26, 2018 6:41 PM
To: Sheheryar Parvaz
Cc: [email-masked]
Subject: Re: bug#30261: segfault on simultaneous initialization

Hi,

Sheheryar Parvaz <[email-masked]> writes:
> If the initial call to scm_with_guile is on a thread and in the main
> thread at the same time, a segmentation fault occurs.

Yes, this is a known issue.  At present, Guile must be fully initialized
in one thread before it can be safely used from any other thread.
Furthermore, when loading modules, you must ensure that no other thread
attempts to load or use the same module while it's being loaded.  If
possible, please arrange to load all modules that your program will need
before accessing Guile from other threads.

We'd like to fix this at some point, but for various reasons it's a
non-trivial project.

     Thanks,
       Mark