summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gr-digital/swig/Makefile.am6
-rw-r--r--gr-digital/swig/digital_swig.i38
-rw-r--r--gr-digital/swig/gnuradio/.gitignore2
-rw-r--r--gr-digital/swig/gnuradio/digital.scm28
4 files changed, 71 insertions, 3 deletions
diff --git a/gr-digital/swig/Makefile.am b/gr-digital/swig/Makefile.am
index 3b30ba789d..277c66f335 100644
--- a/gr-digital/swig/Makefile.am
+++ b/gr-digital/swig/Makefile.am
@@ -42,7 +42,7 @@ noinst_GUILE = digital.test
##############################
# SWIG interface and library
TOP_SWIG_IFILES = \
- gr_costas_loop_cc.i
+ digital_swig.i
# Install so that they end up available as:
# import gnuradio.digital
@@ -56,8 +56,8 @@ digital_swig_la_swig_libadd = \
$(abs_top_builddir)/gr-digital/lib/libgnuradio-digital.la
# additional SWIG files to be installed
-digital_swig_swiginclude_headers =
-
+digital_swig_swiginclude_headers = \
+ gr_costas_loop_cc.i
if GUILE
TESTS += run_guile_tests
endif \ No newline at end of file
diff --git a/gr-digital/swig/digital_swig.i b/gr-digital/swig/digital_swig.i
new file mode 100644
index 0000000000..1134ed7e0a
--- /dev/null
+++ b/gr-digital/swig/digital_swig.i
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2011 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 GNU Radio; see the file COPYING. If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ */
+
+%include "gnuradio.i"
+
+%{
+#include "gr_costas_loop_cc.h"
+%}
+
+%include "gr_costas_loop_cc.i"
+
+#if SWIGGUILE
+%scheme %{
+(load-extension-global "libguile-gnuradio-digital_swig" "scm_init_gnuradio_digital_swig_module")
+%}
+
+%goops %{
+(use-modules (gnuradio gnuradio_core_runtime))
+%}
+#endif
diff --git a/gr-digital/swig/gnuradio/.gitignore b/gr-digital/swig/gnuradio/.gitignore
new file mode 100644
index 0000000000..c264c571a4
--- /dev/null
+++ b/gr-digital/swig/gnuradio/.gitignore
@@ -0,0 +1,2 @@
+digital_swig-primitive.scm
+digital_swig.scm
diff --git a/gr-digital/swig/gnuradio/digital.scm b/gr-digital/swig/gnuradio/digital.scm
new file mode 100644
index 0000000000..834bc8d6de
--- /dev/null
+++ b/gr-digital/swig/gnuradio/digital.scm
@@ -0,0 +1,28 @@
+;;;
+;;; Copyright 2011 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 digital_swig module
+
+(define-module (gnuradio digital)
+ #:use-module (gnuradio export-safely)
+ #:use-module (gnuradio digital_swig)
+ #:duplicates (merge-generics replace check))
+
+(re-export-all '(gnuradio digital_swig))
+