diff options
author | Eric Blossom <eb@comsec.com> | 2010-11-24 00:20:02 -0800 |
---|---|---|
committer | Eric Blossom <eb@comsec.com> | 2010-11-24 00:20:02 -0800 |
commit | cec8dfd8d0331566c93abb69ca02913011ad2a91 (patch) | |
tree | 5ca43b968c834c0739a120fab877462cf4db43e3 /gr-pager | |
parent | 4f578fca338f749c075c46f1a5f16ea5218c9f31 (diff) |
Confirm we can load guile pager module
Diffstat (limited to 'gr-pager')
-rw-r--r-- | gr-pager/swig/Makefile.am | 11 | ||||
-rw-r--r-- | gr-pager/swig/gnuradio/pager.scm | 28 | ||||
-rw-r--r-- | gr-pager/swig/pager.test | 36 | ||||
-rw-r--r-- | gr-pager/swig/run_guile_tests.in | 14 |
4 files changed, 88 insertions, 1 deletions
diff --git a/gr-pager/swig/Makefile.am b/gr-pager/swig/Makefile.am index c59bdb0f2c..fe22753e33 100644 --- a/gr-pager/swig/Makefile.am +++ b/gr-pager/swig/Makefile.am @@ -20,6 +20,9 @@ # include $(top_srcdir)/Makefile.common +include $(top_srcdir)/Makefile.swig + +TESTS = AM_CPPFLAGS = \ -I$(top_srcdir)/gr-pager/lib \ @@ -27,6 +30,9 @@ AM_CPPFLAGS = \ $(PYTHON_CPPFLAGS) \ $(WITH_INCLUDES) +nobase_guile_DATA = \ + gnuradio/pager.scm + ############################## # SWIG interface and library TOP_SWIG_IFILES = \ @@ -51,10 +57,13 @@ pager_swig_swiginclude_headers = \ pager_flex_sync.i \ pager_slicer_fb.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
\ No newline at end of file diff --git a/gr-pager/swig/gnuradio/pager.scm b/gr-pager/swig/gnuradio/pager.scm new file mode 100644 index 0000000000..99331b09c5 --- /dev/null +++ b/gr-pager/swig/gnuradio/pager.scm @@ -0,0 +1,28 @@ +;;; +;;; 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 pager_swig module + +(define-module (gnuradio pager) + #:use-module (gnuradio export-safely) + #:use-module (gnuradio pager_swig) + #:duplicates (merge-generics replace check)) + +(re-export-all '(gnuradio pager_swig)) + diff --git a/gr-pager/swig/pager.test b/gr-pager/swig/pager.test new file mode 100644 index 0000000000..a5deb58107 --- /dev/null +++ b/gr-pager/swig/pager.test @@ -0,0 +1,36 @@ +;;; -*- Scheme -*- +;;; +;;; 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/>. +;;; + +;;; If you're using Emacs's Scheme mode: +;;; (put 'with-test-prefix 'scheme-indent-function 1) + +;;; See the comments in gnuradio/test-suite/lib.scm for info on writing tests. +;;; See also the very end of the file, where the test-equal, test-eqv +;;; and test-eq macros are defined. + +(define-module (test-module) + #:use-module (oop goops) + #:use-module (gnuradio core) + #:use-module (gnuradio test-suite lib) + #:duplicates (merge-generics replace check)) + +;;; Confirm we can import the module... +(use-modules (gnuradio pager)) + diff --git a/gr-pager/swig/run_guile_tests.in b/gr-pager/swig/run_guile_tests.in new file mode 100644 index 0000000000..5d08b0dd53 --- /dev/null +++ b/gr-pager/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@ |