Error keeps showing up while trying to build nodejs onto Synology DS1511+

I've tried for quite some time to build node.js onto my Synology DS1511+. I've read this tutorial along with the comments, but I still hit a strange error that I cannot figure out how to build it. After I run sudo make it runs the build fine for about 15 to 20 minutes, but then I get this:

/volume1/homes/admin/node/out/../deps/uv/src/unix/thread.c:286: undefined reference to `pthread_condattr_setclock'
collect2: ld returned 1 exit status
make[1]: *** [/volume1/homes/admin/node/out/Release/node] Error 1
make[1]: Leaving directory `/volume1/homes/admin/node/out'
make: *** [node] Error 2

From the error, it seems like it's related to the pthread libraries, but I really don't know if that's the case, especially since I replaced the pthread libraries according to the tutorial. BTW, the tutorial shows how to build node for an ARM based processor, but the Synology I'm building on is i686.

Anybody know how I can overcome this issue building node.js on the DS1511+

I just ran into the same problem. It seems the default glibc libpthread.so (this is on RHEL 4) does not include pthread_condattr_setclock (even though the man-page says it should do and the include file also specifies it), I had a quick look around and found that the nosegneg version (from the same glibc package) does have this functionality. I am not sure what the implications are, but after I ran configure for the node, I hacked the pyg (out/node.target.mk) script to look like:

LDFLAGS_Debug := \
    -L/lib/tls/i686/nosegneg/ -lpthread-2.3.4 \
    -rdynamic \
    -m32 \
    -pthread

LDFLAGS_Release := \
    -L/lib/tls/i686/nosegneg/ -lpthread-2.3.4 \
    -rdynamic \
    -m32 \
    -pthread   

LIBS := \
    -lc-2.3.4 \
    -lm-2.3.4 \ 
    -ldl \
    -lrt-2.3.4 

where 2.3.4 is our current glibc version. And the node compiles fine now. Will have to do some tests to see if it runs ok.