diff options
-rw-r--r-- | Makefile.common | 10 | ||||
-rw-r--r-- | config/grc_gnuradio_core.m4 | 13 | ||||
-rw-r--r-- | config/grc_mblock.m4 | 10 | ||||
-rw-r--r-- | config/grc_omnithread.m4 | 33 | ||||
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | gnuradio-core/gnuradio-core.pc.in | 2 | ||||
-rw-r--r-- | gnuradio-core/src/lib/Makefile.am | 6 | ||||
-rw-r--r-- | omnithread/Makefile.am (renamed from gnuradio-core/src/lib/omnithread/Makefile.am) | 11 | ||||
-rw-r--r-- | omnithread/dir.mk (renamed from gnuradio-core/src/lib/omnithread/dir.mk) | 0 | ||||
-rw-r--r-- | omnithread/mach.cc (renamed from gnuradio-core/src/lib/omnithread/mach.cc) | 0 | ||||
-rw-r--r-- | omnithread/nt.cc (renamed from gnuradio-core/src/lib/omnithread/nt.cc) | 0 | ||||
-rw-r--r-- | omnithread/omnithread.h (renamed from gnuradio-core/src/lib/omnithread/omnithread.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_VxThread.h (renamed from gnuradio-core/src/lib/omnithread/ot_VxThread.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_mach.h (renamed from gnuradio-core/src/lib/omnithread/ot_mach.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_nt.h (renamed from gnuradio-core/src/lib/omnithread/ot_nt.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_posix.h (renamed from gnuradio-core/src/lib/omnithread/ot_posix.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_pthread_nt.h (renamed from gnuradio-core/src/lib/omnithread/ot_pthread_nt.h) | 0 | ||||
-rw-r--r-- | omnithread/ot_solaris.h (renamed from gnuradio-core/src/lib/omnithread/ot_solaris.h) | 0 | ||||
-rw-r--r-- | omnithread/posix.cc (renamed from gnuradio-core/src/lib/omnithread/posix.cc) | 0 | ||||
-rw-r--r-- | omnithread/solaris.cc (renamed from gnuradio-core/src/lib/omnithread/solaris.cc) | 0 | ||||
-rw-r--r-- | omnithread/threaddata.cc (renamed from gnuradio-core/src/lib/omnithread/threaddata.cc) | 0 | ||||
-rw-r--r-- | omnithread/vxWorks.cc (renamed from gnuradio-core/src/lib/omnithread/vxWorks.cc) | 0 |
22 files changed, 71 insertions, 15 deletions
diff --git a/Makefile.common b/Makefile.common index e7d928682..56d7f5caa 100644 --- a/Makefile.common +++ b/Makefile.common @@ -50,7 +50,6 @@ GNURADIO_INCLUDES = -I$(top_srcdir)/gnuradio-core/src/lib/runtime \ -I$(top_srcdir)/gnuradio-core/src/lib/reed-solomon \ -I$(top_srcdir)/gnuradio-core/src/lib/io \ -I$(top_srcdir)/gnuradio-core/src/lib/g72x \ - -I$(top_srcdir)/gnuradio-core/src/lib/omnithread \ -I$(top_srcdir)/gnuradio-core/src/lib/swig \ -I$(top_builddir)/gnuradio-core/src/lib/swig \ $(FFTW3F_CFLAGS) @@ -58,6 +57,7 @@ GNURADIO_INCLUDES = -I$(top_srcdir)/gnuradio-core/src/lib/runtime \ # These used to be set in PKGCONFIG but now point to the current # build tree. +# FIXME shouldn't -lfftw3f -lm just be extracted from libgnuradio-core.la ??? GNURADIO_CORE_LIBS = -L$(top_builddir)/gnuradio-core/src/lib \ -lgnuradio-core -lfftw3f -lm @@ -69,15 +69,17 @@ GNURADIO_I = $(top_srcdir)/gnuradio-core/src/lib/swig/gnuradio.i USRP_INCLUDES = -I$(top_srcdir)/usrp/host/lib \ -I$(top_srcdir)/usrp/firmware/include -USRP_LIBS = -L$(top_builddir)/usrp/host/lib \ - -lusrp +USRP_LIBS = -L$(top_builddir)/usrp/host/lib -lusrp PMT_INCLUDES = -I$(top_srcdir)/pmt/src/lib PMT_LIBS = -L$(top_builddir)/pmt/src/lib -lpmt +OMNITHREAD_INCLUDES = -I$(top_srcdir)/omnithread +OMNITHREAD_LIBS = -L$(top_builddir)/omnithread -lgromnithread + # This used to be set in configure.ac but is now defined here for all # Makefiles when this fragment is included. -STD_DEFINES_AND_INCLUDES=$(DEFINES) $(GNURADIO_INCLUDES) $(BOOST_CFLAGS) +STD_DEFINES_AND_INCLUDES=$(DEFINES) $(OMNITHREAD_INCLUDES) $(GNURADIO_INCLUDES) $(BOOST_CFLAGS) # Fix for BSD make not defining $(RM). We define it now in configure.ac # using AM_PATH_PROG, but now here have to add a -f to be like GNU make diff --git a/config/grc_gnuradio_core.m4 b/config/grc_gnuradio_core.m4 index da91f61ee..6b9c8542e 100644 --- a/config/grc_gnuradio_core.m4 +++ b/config/grc_gnuradio_core.m4 @@ -1,4 +1,4 @@ -dnl Copyright 2001,2002,2003,2004,2005,2006 Free Software Foundation, Inc. +dnl Copyright 2001,2002,2003,2004,2005,2006,2007 Free Software Foundation, Inc. dnl dnl This file is part of GNU Radio dnl @@ -37,7 +37,6 @@ AC_DEFUN([GRC_GNURADIO_CORE],[ gnuradio-core/src/lib/gengen/Makefile \ gnuradio-core/src/lib/io/Makefile \ gnuradio-core/src/lib/missing/Makefile \ - gnuradio-core/src/lib/omnithread/Makefile \ gnuradio-core/src/lib/reed-solomon/Makefile \ gnuradio-core/src/lib/runtime/Makefile \ gnuradio-core/src/lib/swig/Makefile \ @@ -55,6 +54,16 @@ AC_DEFUN([GRC_GNURADIO_CORE],[ ]) passed=yes + # Don't do gnuradio-core if omnithread skipped + # There *has* to be a better way to check if a value is in a string + for dir in $skipped_dirs + do + if test x$dir = xomnithread; then + AC_MSG_RESULT([Component gnuradio-core requires omnithread, which is not being built.]) + passed=no + fi + done + GRC_BUILD_CONDITIONAL([gnuradio-core],[ dnl run_tests is created from run_tests.in. Make it executable. AC_CONFIG_COMMANDS([run_tests_core], [chmod +x gnuradio-core/src/python/gnuradio/gr/run_tests]) diff --git a/config/grc_mblock.m4 b/config/grc_mblock.m4 index a8fba4e03..6e4bc4afe 100644 --- a/config/grc_mblock.m4 +++ b/config/grc_mblock.m4 @@ -28,6 +28,16 @@ AC_DEFUN([GRC_MBLOCK],[ ]) passed=yes + # Don't do mblock if omnithread skipped + # There *has* to be a better way to check if a value is in a string + for dir in $skipped_dirs + do + if test x$dir = xomnithread; then + AC_MSG_RESULT([Component mblock requires omnithread, which is not being built.]) + passed=no + fi + done + # Don't do mblock if pmt skipped # There *has* to be a better way to check if a value is in a string for dir in $skipped_dirs diff --git a/config/grc_omnithread.m4 b/config/grc_omnithread.m4 new file mode 100644 index 000000000..627ccdc9d --- /dev/null +++ b/config/grc_omnithread.m4 @@ -0,0 +1,33 @@ +dnl Copyright 2001,2002,2003,2004,2005,2006,2007 Free Software Foundation, Inc. +dnl +dnl This file is part of GNU Radio +dnl +dnl GNU Radio is free software; you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 2, or (at your option) +dnl any later version. +dnl +dnl GNU Radio is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with GNU Radio; see the file COPYING. If not, write to +dnl the Free Software Foundation, Inc., 51 Franklin Street, +dnl Boston, MA 02110-1301, USA. + +AC_DEFUN([GRC_OMNITHREAD],[ + GRC_ENABLE([omnithread]) + + AC_CONFIG_FILES([ \ + omnithread/Makefile \ + ]) + + passed=yes + GRC_BUILD_CONDITIONAL([omnithread],[ + dnl run_tests is created from run_tests.in. Make it executable. + dnl AC_CONFIG_COMMANDS([run_tests_omnithread], [chmod +x omnithread/run_tests]) + + ]) +]) diff --git a/configure.ac b/configure.ac index 924ad88ae..7fc963c39 100644 --- a/configure.ac +++ b/configure.ac @@ -184,6 +184,7 @@ AC_ARG_ENABLE( ) build_dirs="config" +GRC_OMNITHREAD dnl must come before gnuradio-core and mblock GRC_GNURADIO_CORE GRC_USRP GRC_GR_USRP dnl this must come after GRC_USRP diff --git a/gnuradio-core/gnuradio-core.pc.in b/gnuradio-core/gnuradio-core.pc.in index cc6c03ac5..9a8f6736e 100644 --- a/gnuradio-core/gnuradio-core.pc.in +++ b/gnuradio-core/gnuradio-core.pc.in @@ -7,5 +7,5 @@ Name: gnuradio-core Description: GNU Software Radio toolkit Requires: Version: @VERSION@ -Libs: -L${libdir} -lgnuradio-core @FFTW3F_LIBS@ +Libs: -L${libdir} -lgnuradio-core @FFTW3F_LIBS@ @OMNITHREAD_LIBS@ Cflags: -I${includedir} @DEFINES@ @PTHREAD_CFLAGS@ diff --git a/gnuradio-core/src/lib/Makefile.am b/gnuradio-core/src/lib/Makefile.am index 96a891700..70a4de08e 100644 --- a/gnuradio-core/src/lib/Makefile.am +++ b/gnuradio-core/src/lib/Makefile.am @@ -24,7 +24,7 @@ include $(top_srcdir)/Makefile.common ## Process this file with automake to produce Makefile.in # We've got to build . before swig -SUBDIRS = missing runtime filter general gengen g72x reed-solomon omnithread io . swig +SUBDIRS = missing runtime filter general gengen g72x reed-solomon io . swig # generate libgnuradio-core.la from the convenience libraries in subdirs @@ -35,7 +35,7 @@ libgnuradio_core_la_LDFLAGS = $(NO_UNDEFINED) -version-info 0:0:0 libgnuradio_core_qa_la_SOURCES = bug_work_around_6.cc libgnuradio_core_qa_la_LDFLAGS = $(NO_UNDEFINED) -version-info 0:0:0 \ - $(LIBGNURADIO_CORE_EXTRA_LDFLAGS) + $(LIBGNURADIO_CORE_EXTRA_LDFLAGS) libgnuradio_core_la_LIBADD = \ filter/libfilter.la \ @@ -44,9 +44,9 @@ libgnuradio_core_la_LIBADD = \ gengen/libgengen.la \ io/libio.la \ missing/libmissing.la \ - omnithread/libomnithread.la \ reed-solomon/librs.la \ runtime/libruntime.la \ + $(OMNITHREAD_LIBS) \ $(FFTW3F_LIBS) libgnuradio_core_qa_la_LIBADD = \ diff --git a/gnuradio-core/src/lib/omnithread/Makefile.am b/omnithread/Makefile.am index de365c15c..2eac4c920 100644 --- a/gnuradio-core/src/lib/omnithread/Makefile.am +++ b/omnithread/Makefile.am @@ -27,23 +27,24 @@ include $(top_srcdir)/Makefile.common # we should do some configure hacking to determine these on the fly OMNITHREAD_DEFINES = -DPthreadDraftVersion=10 -INCLUDES = $(STD_DEFINES_AND_INCLUDES) $(OMNITHREAD_DEFINES) +INCLUDES = $(DEFINES) $(OMNITHREAD_DEFINES) $(OMNITHREAD_INCLUDES) -noinst_LTLIBRARIES = libomnithread.la +# we call it libgromnithread to avoid a collision with libomnithread on Debian +lib_LTLIBRARIES = libgromnithread.la # At this point we only support the posix and nt pthreads i/f... if OMNITHREAD_POSIX -libomnithread_la_SOURCES = \ +libgromnithread_la_SOURCES = \ posix.cc endif if OMNITHREAD_NT -libomnithread_la_SOURCES = \ +libgromnithread_la_SOURCES = \ nt.cc endif -libomnithread_la_LIBADD = \ +libgromnithread_la_LIBADD = \ $(PTHREAD_LIBS) # ... but this code also came with the package diff --git a/gnuradio-core/src/lib/omnithread/dir.mk b/omnithread/dir.mk index d53803417..d53803417 100644 --- a/gnuradio-core/src/lib/omnithread/dir.mk +++ b/omnithread/dir.mk diff --git a/gnuradio-core/src/lib/omnithread/mach.cc b/omnithread/mach.cc index 8759bb4ce..8759bb4ce 100644 --- a/gnuradio-core/src/lib/omnithread/mach.cc +++ b/omnithread/mach.cc diff --git a/gnuradio-core/src/lib/omnithread/nt.cc b/omnithread/nt.cc index 3853f0108..3853f0108 100644 --- a/gnuradio-core/src/lib/omnithread/nt.cc +++ b/omnithread/nt.cc diff --git a/gnuradio-core/src/lib/omnithread/omnithread.h b/omnithread/omnithread.h index b6df34d72..b6df34d72 100644 --- a/gnuradio-core/src/lib/omnithread/omnithread.h +++ b/omnithread/omnithread.h diff --git a/gnuradio-core/src/lib/omnithread/ot_VxThread.h b/omnithread/ot_VxThread.h index e96c036cc..e96c036cc 100644 --- a/gnuradio-core/src/lib/omnithread/ot_VxThread.h +++ b/omnithread/ot_VxThread.h diff --git a/gnuradio-core/src/lib/omnithread/ot_mach.h b/omnithread/ot_mach.h index 76361926c..76361926c 100644 --- a/gnuradio-core/src/lib/omnithread/ot_mach.h +++ b/omnithread/ot_mach.h diff --git a/gnuradio-core/src/lib/omnithread/ot_nt.h b/omnithread/ot_nt.h index 551ccf2f1..551ccf2f1 100644 --- a/gnuradio-core/src/lib/omnithread/ot_nt.h +++ b/omnithread/ot_nt.h diff --git a/gnuradio-core/src/lib/omnithread/ot_posix.h b/omnithread/ot_posix.h index 666ccc089..666ccc089 100644 --- a/gnuradio-core/src/lib/omnithread/ot_posix.h +++ b/omnithread/ot_posix.h diff --git a/gnuradio-core/src/lib/omnithread/ot_pthread_nt.h b/omnithread/ot_pthread_nt.h index dbf4356cf..dbf4356cf 100644 --- a/gnuradio-core/src/lib/omnithread/ot_pthread_nt.h +++ b/omnithread/ot_pthread_nt.h diff --git a/gnuradio-core/src/lib/omnithread/ot_solaris.h b/omnithread/ot_solaris.h index f4fea0b11..f4fea0b11 100644 --- a/gnuradio-core/src/lib/omnithread/ot_solaris.h +++ b/omnithread/ot_solaris.h diff --git a/gnuradio-core/src/lib/omnithread/posix.cc b/omnithread/posix.cc index b82e86df3..b82e86df3 100644 --- a/gnuradio-core/src/lib/omnithread/posix.cc +++ b/omnithread/posix.cc diff --git a/gnuradio-core/src/lib/omnithread/solaris.cc b/omnithread/solaris.cc index b0139d29d..b0139d29d 100644 --- a/gnuradio-core/src/lib/omnithread/solaris.cc +++ b/omnithread/solaris.cc diff --git a/gnuradio-core/src/lib/omnithread/threaddata.cc b/omnithread/threaddata.cc index d54c43914..d54c43914 100644 --- a/gnuradio-core/src/lib/omnithread/threaddata.cc +++ b/omnithread/threaddata.cc diff --git a/gnuradio-core/src/lib/omnithread/vxWorks.cc b/omnithread/vxWorks.cc index 25634ce93..25634ce93 100644 --- a/gnuradio-core/src/lib/omnithread/vxWorks.cc +++ b/omnithread/vxWorks.cc |