Package: omniorb-dfsg
Version: 4.1.5-2
Severity: important
Tags: patch
User: debian-h...@lists.debian.org
Usertags: hurd

Hi,

currently[1], omniorb-dfsg does not compile on GNU/Hurd.
The attached patch provides support for it:
- recognizes the Hurd OS in configure.ac
- sets the proper makefile bits for the omnithread library
- makes pthread the thread implementation

The patch should also apply for omniORB 4.1.6 too.

[1] 
https://buildd.debian.org/status/fetch.php?pkg=omniorb-dfsg&arch=hurd-i386&ver=4.1.5-2&stamp=1305465184

Thanks,
-- 
Pino
--- a/configure.ac
+++ b/configure.ac
@@ -204,6 +204,7 @@
   *-*-netbsd*)   plat_name="NetBSD";   plat_def="__netbsd__";   os_v="1";;
   *-*-openbsd*)  plat_name="OpenBSD";  plat_def="__openbsd__";  os_v="3";;
   *-*-sco*)      plat_name="OSR5";     plat_def="__osr5__";     os_v="5";;
+  *-*-gnu*)      plat_name="GNU";      plat_def="__hurd__" ;    os_v="0";;
 esac
 
 AC_SUBST(PLATFORM_NAME, $plat_name)
--- a/mk/beforeauto.mk.in
+++ b/mk/beforeauto.mk.in
@@ -775,6 +775,13 @@
 endif
 
 ###################
+ifdef GNU
+OMNITHREAD_POSIX_CPPFLAGS = -DPthreadDraftVersion=10
+OMNITHREAD_CPPFLAGS = -D_REENTRANT -pthread
+OMNITHREAD_LIB += -lpthread
+endif
+
+###################
 ifdef SunOS
 IMPORT_CPPFLAGS += -D__sunos__
 OMNITHREAD_POSIX_CPPFLAGS = -DPthreadDraftVersion=10 \
--- a/include/omnithread.h
+++ b/include/omnithread.h
@@ -184,6 +184,9 @@
 #elif defined(__Lynx__)
 #include <omnithread/posix.h>
 
+#elif defined(__GNU__)
+#include <omnithread/posix.h>
+
 #else
 #error "No implementation header file"
 #endif

Reply via email to