Update pipe build system to match the one on Windows

Otherwise we run into PIC issues with GCC on Linux.