diff options
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | config/grc_gr_noaa.m4 | 5 | ||||
-rw-r--r-- | gr-noaa/swig/Makefile.am | 14 | ||||
-rw-r--r-- | gr-noaa/swig/gnuradio/noaa.scm | 27 | ||||
-rw-r--r-- | gr-noaa/swig/run_guile_tests.in | 14 |
5 files changed, 56 insertions, 5 deletions
diff --git a/.gitignore b/.gitignore index 41ea212b6..6ba52a651 100644 --- a/.gitignore +++ b/.gitignore @@ -76,7 +76,6 @@ gr-msdd6000/src/guile/ gr-msdd6000/src/msdd.scm gr-msdd6000/src/msdd_rs.scm gr-msdd6000/src/python/ -gr-noaa/swig/gnuradio/ gr-noaa/swig/guile/ gr-noaa/swig/noaa_swig.scm gr-noaa/swig/python/ diff --git a/config/grc_gr_noaa.m4 b/config/grc_gr_noaa.m4 index 69d0aad55..54df77503 100644 --- a/config/grc_gr_noaa.m4 +++ b/config/grc_gr_noaa.m4 @@ -33,10 +33,13 @@ AC_DEFUN([GRC_GR_NOAA],[ gr-noaa/oct/Makefile \ gr-noaa/python/Makefile \ gr-noaa/swig/Makefile \ + gr-noaa/swig/run_guile_tests \ ]) GRC_BUILD_CONDITIONAL(gr-noaa,[ dnl run_tests is created from run_tests.in. Make it executable. - #AC_CONFIG_COMMANDS([run_tests_noaa], [chmod +x gr-pager/lib/run_tests]) + AC_CONFIG_COMMANDS([run_tests_noaa], + [chmod +x gr-noaa/swig/run_guile_tests]) + ]) ]) diff --git a/gr-noaa/swig/Makefile.am b/gr-noaa/swig/Makefile.am index 410b23fe6..51a72ffb6 100644 --- a/gr-noaa/swig/Makefile.am +++ b/gr-noaa/swig/Makefile.am @@ -20,6 +20,14 @@ # include $(top_srcdir)/Makefile.common +include $(top_srcdir)/Makefile.swig + +TESTS = + +if GUILE +nobase_guile_DATA = gnuradio/noaa.scm +endif + AM_CPPFLAGS = \ -I$(top_srcdir)/gr-noaa/lib \ @@ -27,7 +35,6 @@ AM_CPPFLAGS = \ $(PYTHON_CPPFLAGS) \ $(WITH_INCLUDES) -if PYTHON # ---------------------------------------------------------------- # The SWIG library # TESTS = run_tests @@ -56,11 +63,12 @@ noaa_swig_swiginclude_headers = \ noaa_hrpt_deframer.i \ noaa_hrpt_pll_cf.i -include $(top_srcdir)/Makefile.swig - # add some of the variables generated inside the Makefile.swig.gen BUILT_SOURCES = $(swig_built_sources) # Do not distribute the output of SWIG no_dist_files = $(swig_built_sources) + +if GUILE +TESTS += run_guile_tests endif diff --git a/gr-noaa/swig/gnuradio/noaa.scm b/gr-noaa/swig/gnuradio/noaa.scm new file mode 100644 index 000000000..0bb4725ce --- /dev/null +++ b/gr-noaa/swig/gnuradio/noaa.scm @@ -0,0 +1,27 @@ +;;; +;;; Copyright 2010 Free Software Foundation, Inc. +;;; +;;; This file is part of GNU Radio +;;; +;;; GNU Radio is free software; you can redistribute it and/or modify +;;; it under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3, or (at your option) +;;; any later version. +;;; +;;; GNU Radio is distributed in the hope that it will be useful, +;;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with this program. If not, see <http://www.gnu.org/licenses/>. +;;; + +;;; Module that just re-exports the noaa_swig module + +(define-module (gnuradio noaa) + #:use-module (gnuradio export-safely) + #:use-module (gnuradio noaa_swig) + #:duplicates (merge-generics replace check)) + +(re-export-all '(gnuradio noaa_swig)) diff --git a/gr-noaa/swig/run_guile_tests.in b/gr-noaa/swig/run_guile_tests.in new file mode 100644 index 000000000..5d08b0dd5 --- /dev/null +++ b/gr-noaa/swig/run_guile_tests.in @@ -0,0 +1,14 @@ +#!/bin/sh + +. @top_builddir@/setup_guile_test_env + +# 1st argument is absolute path to hand coded guile source directory +# 2nd argument is absolute path to component C++ shared library build directory +# 3nd argument is absolute path to component SWIG build directory + +add_local_paths \ + @srcdir@ \ + @abs_builddir@ \ + @abs_builddir@ + +@GUILE@ -e main -c '(use-modules (gnuradio test-suite guile-test))' -t @srcdir@ |