Bug#341089: Supporting Debian/GNU kfreebsd
Floris Bruynooghe <[email protected]> Thu, 10 May 2007 21:49:21 +0100
| Newsgroups | gmane.linux.debian.devel.bugs.general,gmane.comp.corba.omniorb.devel |
|---|---|
| Message-ID | <[email protected]> |
--a8Wt8u1KmwUX3Y2C
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Hi
The Debian kfreebsd porters need the attached patch for omniORB to
work. It would be nice if this could be included upstream.
The patch doesn't apply cleanly anymore to 4.1, but the rejected hunks
(configure.ac (and configure, but since you're upstream you'll just
regenerate that from configure.ac)) are easily merged by hand (so
easily that I didn't bother re-creating the patch).
For the original bug report see http://bugs.debian.org/341089
Regards
Floris
PS: Please CC me as I am not subscribed to this list.
--
Debian GNU/Linux -- The Power of Freedom
www.debian.org | www.gnu.org | www.kernel.org
--a8Wt8u1KmwUX3Y2C
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment; filename="omniorb4.diff"
diff -u omniorb4-4.0.6/configure.ac omniorb4-4.0.6/configure.ac
--- omniorb4-4.0.6/configure.ac
+++ omniorb4-4.0.6/configure.ac
@@ -168,6 +168,9 @@
*-*-freebsd3*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="3";;
*-*-freebsd4*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="4";;
*-*-freebsd5*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="5";;
+ *-*-freebsd6*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="6";;
+ *-*-kfreebsd5*) plat_name="kFreeBSD"; plat_def="__FreeBSD_kernel__"; os_v="5";;
+ *-*-kfreebsd6*) plat_name="kFreeBSD"; plat_def="__FreeBSD_kernel__"; os_v="6";;
*-*-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";;
diff -u omniorb4-4.0.6/mk/beforeauto.mk.in omniorb4-4.0.6/mk/beforeauto.mk.in
--- omniorb4-4.0.6/mk/beforeauto.mk.in
+++ omniorb4-4.0.6/mk/beforeauto.mk.in
@@ -746,6 +746,13 @@
endif
###################
+ifdef kFreeBSD
+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 \
only in patch2:
unchanged:
--- omniorb4-4.0.6.orig/src/lib/omnithread/posix.cc
+++ omniorb4-4.0.6/src/lib/omnithread/posix.cc
@@ -876,7 +876,7 @@
#else
-#if defined(__linux__) || defined(__aix__) || defined(__SCO_VERSION__) || defined(__darwin__) || defined(__macos__)
+#if defined(__linux__) || defined(__GLIBC__) || defined(__aix__) || defined(__SCO_VERSION__) || defined(__darwin__) || defined(__macos__)
struct timeval tv;
gettimeofday(&tv, NULL);
only in patch2:
unchanged:
--- omniorb4-4.0.6.orig/include/omnithread.h
+++ omniorb4-4.0.6/include/omnithread.h
@@ -133,6 +133,9 @@
#elif defined(__linux__)
#include <omnithread/posix.h>
+#elif defined(__GLIBC__)
+#include <omnithread/posix.h>
+
#elif defined(__nextstep__)
#include <omnithread/mach.h>
diff -u omniorb4-4.0.6/configure omniorb4-4.0.6/configure
--- omniorb4-4.0.6/configure
+++ omniorb4-4.0.6/configure
@@ -11872,6 +11733,9 @@
*-*-freebsd3*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="3";;
*-*-freebsd4*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="4";;
*-*-freebsd5*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="5";;
+ *-*-freebsd6*) plat_name="FreeBSD"; plat_def="__freebsd__"; os_v="6";;
+ *-*-kfreebsd5*) plat_name="kFreeBSD"; plat_def="__FreeBSD_kernel__"; os_v="5";;
+ *-*-kfreebsd6*) plat_name="kFreeBSD"; plat_def="__FreeBSD_kernel__"; os_v="6";;
*-*-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";;
--a8Wt8u1KmwUX3Y2C--