diff -Naur pl-6.0.2/src/configure.in pl-6.0.2-haiku/src/configure.in
|
old
|
new
|
|
| 689 | 689 | AC_DEFINE(_THREAD_SAFE, 1, |
| 690 | 690 | [Required in FreeBSD for compiling thread-safe code]) |
| 691 | 691 | ;; |
| | 692 | *haiku*) |
| | 693 | pthread_ok=true |
| | 694 | CFLAGS="$CFLAGS -lroot" |
| | 695 | ;; |
| 692 | 696 | *-win32|*-win64) |
| 693 | 697 | pthread_ok=true |
| 694 | 698 | AC_CHECK_LIB(pthreadGC2, pthread_create) |
diff -Naur pl-6.0.2/src/os/pl-files.c pl-6.0.2-haiku/src/os/pl-files.c
|
old
|
new
|
|
| 239 | 239 | return TRUE; |
| 240 | 240 | } |
| 241 | 241 | |
| 242 | | #ifdef __unix__ /* doesn't work on most not Unix's */ |
| | 242 | #if defined(__unix__) || defined(__HAIKU__) /* doesn't work on most not Unix's */ |
| 243 | 243 | { statstruct buf1; |
| 244 | 244 | statstruct buf2; |
| 245 | 245 | char tmp[MAXPATHLEN]; |
diff -Naur pl-6.0.2/src/os/pl-os.c pl-6.0.2-haiku/src/os/pl-os.c
|
old
|
new
|
|
| 590 | 590 | } |
| 591 | 591 | |
| 592 | 592 | retry: |
| 593 | | #ifdef __unix__ |
| | 593 | #if defined(__unix__) || defined(__HAIKU__) |
| 594 | 594 | { static int MTOK_temp_counter = 0; |
| 595 | 595 | const char *sep = id[0] ? "_" : ""; |
| 596 | 596 | |
| … |
… |
|
| 732 | 732 | } |
| 733 | 733 | #endif /* O_HPFS */ |
| 734 | 734 | |
| 735 | | #ifdef __unix__ |
| | 735 | #if defined(__unix__) || defined(__HAIKU__) |
| 736 | 736 | char * |
| 737 | 737 | PrologPath(const char *p, char *buf, size_t len) |
| 738 | 738 | { strncpy(buf, p, len); |
| … |
… |
|
| 2436 | 2436 | return strcpy(buffer, file ? file : buf); |
| 2437 | 2437 | } |
| 2438 | 2438 | |
| 2439 | | #ifdef __unix__ |
| | 2439 | #if defined(__unix__) || defined(__HAIKU__) |
| 2440 | 2440 | static char * |
| 2441 | 2441 | okToExec(const char *s) |
| 2442 | 2442 | { statstruct stbuff; |
diff -Naur pl-6.0.2/src/pl-term.c pl-6.0.2-haiku/src/pl-term.c
|
old
|
new
|
|
| 296 | 296 | term_t r = A1; |
| 297 | 297 | term_t c = A2; |
| 298 | 298 | |
| 299 | | #ifdef __unix__ |
| | 299 | #if defined(__unix__) || defined(__HAIKU__) |
| 300 | 300 | int iorval; |
| 301 | 301 | |
| 302 | 302 | #ifdef TIOCGSIZE |