umtx_lock and friends
Daniel Eischen
deischen at freebsd.org
Wed Jun 10 01:03:55 UTC 2015
On Tue, 9 Jun 2015, Daniel Eischen wrote:
> On Tue, 9 Jun 2015, Russell L. Carter wrote:
>
>> On FreeBSD 10-stable r283752 amd64, here is the compile line:
>>
>> /usr/bin/cc -O -Wall tester.cpp -o tester
>> /tmp/tester-b681b3.o: In function `main':
>> tester.cpp:(.text+0x35): undefined reference to `_umtx_lock(umtx*)'
>> tester.cpp:(.text+0x5c): undefined reference to `_umtx_unlock(umtx*)'
>>
>> Compilers don't matter, linking against libthr or libstdthreads
>> doesn't matter.
>
> Is cc doing something special because it thinks it is C++?
> I'm on 10-stable amd64 and that example (saved as tester.c)
> works just fine.
Try:
/usr/bin/cc -O -Wall -x c tester.cpp -o tester
--
DE
More information about the freebsd-hackers
mailing list