You can fix this in Compiler Explorer by disabling the backend singleton check:
quill::BackendOptions backend_options;
backend_options.check_backend_singleton_instance = false;
quill::Backend::start(backend_options);
Quill runs a runtime safety check to ensure there’s only one backend worker thread instance.
On Windows, it uses a named mutex.
On Linux/Unix, it uses a named semaphore.
This helps catch subtle linking issues (e.g. mixing static and shared libraries), but in restricted environments like Compiler Explorer, creating a named semaphore isn’t possible. That’s why you see:
Failed to create semaphore - errno: 2 error: No such file or directory
Since the check is optional, you can safely turn it off in such environments.
👉 The Quill README already includes a working Compiler Explorer example in the Introduction section, with a note about this option.