Skip to content
This repository has been archived by the owner on Oct 28, 2021. It is now read-only.

cmake: undefined reference to 'pthread_create' #5911

Open
jasonclinx opened this issue Jul 2, 2020 · 2 comments
Open

cmake: undefined reference to 'pthread_create' #5911

jasonclinx opened this issue Jul 2, 2020 · 2 comments

Comments

@jasonclinx
Copy link

Hi is there anyone encountering this error when building aleth? My build process stopped at ERROR and I found undefined reference to 'pthread_create' from CMakeError.log.

How to fix this error?

@chfast
Copy link
Member

chfast commented Sep 18, 2020

You must link with pthread, but it depends which target is failing.

@MichaelAnthonyP96
Copy link

If you'd like, I can edit the CMakeLists.txt so that the failure occurs at the configure stage, and warns the builder that they are missing pthread. Otherwise all will proceed normally until the linker attempts to locate something called "pthread_create" and fail at link time.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants