Index: eglib/test/Makefile.am =================================================================== --- eglib/test/Makefile.am (revision 101922) +++ eglib/test/Makefile.am (working copy) @@ -28,7 +28,8 @@ test_eglib_SOURCES = $(SOURCES) test_eglib_CFLAGS = -Wall -Werror -D_FORTIFY_SOURCE=2 -I$(srcdir)/../src -I../src -DDRIVER_NAME=\"EGlib\" -test_eglib_LDADD = ../src/libeglib.la -ldl +#test_eglib_LDADD = ../src/libeglib.la -ldl +test_eglib_LDADD = ../src/libeglib.la run-eglib: all ./test-eglib Index: eglib/src/gunicode.c =================================================================== --- eglib/src/gunicode.c (revision 101922) +++ eglib/src/gunicode.c (working copy) @@ -43,7 +43,7 @@ typedef int iconv_t; #else -#include +//#include #include #endif @@ -183,6 +183,13 @@ sprintf (buf, "CP%u", GetACP ()); *charset = buf; is_utf8 = FALSE; +#elif defined(__HAIKU__) // workaround + if (my_charset == NULL) { + my_charset = g_strdup ("UTF-8"); + is_utf8 = 1; + } + if (charset != NULL) + *charset = my_charset; #else if (my_charset == NULL){ my_charset = g_strdup (nl_langinfo (CODESET)); Index: eglib/src/Makefile.am =================================================================== --- eglib/src/Makefile.am (revision 101922) +++ eglib/src/Makefile.am (working copy) @@ -37,7 +37,7 @@ if PLATFORM_WIN32 libeglib_la_LIBADD = -lm -liconv -lpsapi else -libeglib_la_LIBADD = -lm +#libeglib_la_LIBADD = -lm endif MAINTAINERCLEANFILES = Makefile.in Index: configure.in =================================================================== --- configure.in (revision 101922) +++ configure.in (working copy) @@ -237,6 +237,10 @@ has_broken_apple_cpp=yes fi ;; + *-*-haiku*) + platform_win32=no + libdl= + ;; *) AC_MSG_WARN([*** Please add $host to configure.in checks!]) platform_win32=no @@ -1307,7 +1311,12 @@ dnl ********************************* dnl *** Checks for math functions *** dnl ********************************* + case $host_os in + haiku*) + ;; + *) LIBS="$LIBS -lm"; + esac if test "x$has_broken_apple_cpp" != "xyes"; then AC_CHECK_FUNCS(finite, , AC_MSG_CHECKING(for finite in math.h) AC_TRY_LINK([#include ], @@ -1703,7 +1712,10 @@ # foo.c:6: warning: visibility attribute not supported in this configuration; ignored # ld: fatal: relocation error: R_386_GOTOFF: file /var/tmp//ccxYR96k.o: symbol astruct: relocation must bind locally have_visibility_hidden=no - + ;; + haiku*) + have_visibility_hidden=no + ;; esac ;; x86_64-*-* | amd64-*-*)