linux port compiles but segfaults