RHEL 5: tests: Use gnulib.

Gnulib defines O_CLOEXEC which is missing on RHEL 5.