Error using pthread on Windows with Mingw

前端 未结 2 1061
慢半拍i
慢半拍i 2021-01-25 21:53

I\'m trying to use threads on a Windows C program, compiled on an Eclipse environment and Mingw.

I\'ve also put -lpthread and -pthread on the compilation command, and in

2条回答
  •  隐瞒了意图╮
    2021-01-25 22:19

    Solved!

    AFAIK there is no portable pthread library for Windows under Mingw.

    I solved my problem using CreateThread(), and let Mingw resolves it using Windows native threads.

提交回复
热议问题