summaryrefslogtreecommitdiff
path: root/gr-pager
diff options
context:
space:
mode:
Diffstat (limited to 'gr-pager')
-rw-r--r--gr-pager/CMakeLists.txt105
-rw-r--r--gr-pager/apps/CMakeLists.txt22
-rw-r--r--gr-pager/grc/CMakeLists.txt26
-rw-r--r--gr-pager/lib/CMakeLists.txt75
-rw-r--r--gr-pager/python/CMakeLists.txt49
-rw-r--r--gr-pager/swig/CMakeLists.txt51
6 files changed, 328 insertions, 0 deletions
diff --git a/gr-pager/CMakeLists.txt b/gr-pager/CMakeLists.txt
new file mode 100644
index 000000000..e5c3a3396
--- /dev/null
+++ b/gr-pager/CMakeLists.txt
@@ -0,0 +1,105 @@
+# 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.
+
+########################################################################
+# Setup dependencies
+########################################################################
+INCLUDE(GrBoost)
+
+########################################################################
+# Register component
+########################################################################
+INCLUDE(GrComponent)
+GR_REGISTER_COMPONENT("gr-pager" ENABLE_GR_PAGER
+ UNIX #FIXME until we get MSVC working
+ Boost_FOUND
+ ENABLE_GR_CORE_
+)
+
+REMOVE_DEFINITIONS(-fvisibility=hidden) #FIXME until we do symbol visibility
+
+GR_SET_GLOBAL(GR_PAGER_INCLUDE_DIRS
+ ${CMAKE_CURRENT_SOURCE_DIR}/lib
+)
+
+########################################################################
+# Begin conditional configuration
+########################################################################
+IF(ENABLE_GR_PAGER)
+
+########################################################################
+# Setup CPack components
+########################################################################
+INCLUDE(GrPackage)
+CPACK_SET(CPACK_COMPONENT_GROUP_PAGER_DESCRIPTION "The GNU Radio Pager Blocks")
+
+CPACK_COMPONENT("pager_runtime"
+ GROUP "Pager"
+ DISPLAY_NAME "Runtime"
+ DESCRIPTION "Runtime"
+ DEPENDS "core_runtime"
+)
+
+CPACK_COMPONENT("pager_devel"
+ GROUP "Pager"
+ DISPLAY_NAME "Development"
+ DESCRIPTION "C++ headers, package config, import libraries"
+ DEPENDS "core_devel"
+)
+
+CPACK_COMPONENT("pager_python"
+ GROUP "Pager"
+ DISPLAY_NAME "Python"
+ DESCRIPTION "Python modules for runtime; GRC xml files"
+ DEPENDS "core_python;pager_runtime"
+)
+
+CPACK_COMPONENT("pager_swig"
+ GROUP "Pager"
+ DISPLAY_NAME "SWIG"
+ DESCRIPTION "SWIG development .i files"
+ DEPENDS "core_swig;pager_python;pager_devel"
+)
+
+########################################################################
+# Add subdirectories
+########################################################################
+ADD_SUBDIRECTORY(lib)
+IF(ENABLE_PYTHON)
+ ADD_SUBDIRECTORY(python)
+ ADD_SUBDIRECTORY(swig)
+ ADD_SUBDIRECTORY(grc)
+ ADD_SUBDIRECTORY(apps)
+ENDIF(ENABLE_PYTHON)
+
+########################################################################
+# Create Pkg Config File
+########################################################################
+CONFIGURE_FILE(
+ ${CMAKE_CURRENT_SOURCE_DIR}/gnuradio-pager.pc.in
+ ${CMAKE_CURRENT_BINARY_DIR}/gnuradio-pager.pc
+@ONLY)
+
+INSTALL(
+ FILES ${CMAKE_CURRENT_BINARY_DIR}/gnuradio-pager.pc
+ DESTINATION ${GR_LIBRARY_DIR}/pkgconfig
+ COMPONENT "pager_devel"
+)
+
+ENDIF(ENABLE_GR_PAGER)
diff --git a/gr-pager/apps/CMakeLists.txt b/gr-pager/apps/CMakeLists.txt
new file mode 100644
index 000000000..4b7cd54fa
--- /dev/null
+++ b/gr-pager/apps/CMakeLists.txt
@@ -0,0 +1,22 @@
+# 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.
+
+#FIXME
+#not bothering to install because the apps require gr-usrp
+#which we are choosing not to support in the cmake build system
diff --git a/gr-pager/grc/CMakeLists.txt b/gr-pager/grc/CMakeLists.txt
new file mode 100644
index 000000000..a9c39c4c4
--- /dev/null
+++ b/gr-pager/grc/CMakeLists.txt
@@ -0,0 +1,26 @@
+# 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.
+
+INSTALL(FILES
+ pager_slicer_fb.xml
+ pager_flex_sync.xml
+ pager_flex_deinterleave.xml
+ DESTINATION ${GRC_BLOCKS_DIR}
+ COMPONENT "pager_python"
+)
diff --git a/gr-pager/lib/CMakeLists.txt b/gr-pager/lib/CMakeLists.txt
new file mode 100644
index 000000000..40aec57c8
--- /dev/null
+++ b/gr-pager/lib/CMakeLists.txt
@@ -0,0 +1,75 @@
+# 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.
+
+########################################################################
+# Setup the include and linker paths
+########################################################################
+INCLUDE_DIRECTORIES(
+ ${GNURADIO_CORE_INCLUDE_DIRS}
+ ${GR_PAGER_INCLUDE_DIRS}
+)
+
+INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIRS})
+LINK_DIRECTORIES(${Boost_LIBRARY_DIRS})
+
+########################################################################
+# Setup library
+########################################################################
+LIST(APPEND gr_pager_sources
+ pager_flex_frame.cc
+ pager_slicer_fb.cc
+ pager_flex_sync.cc
+ pager_flex_deinterleave.cc
+ pager_flex_parse.cc
+ pageri_bch3221.cc
+ pageri_flex_modes.cc
+ pageri_util.cc
+)
+
+LIST(APPEND pager_libs
+ gnuradio-core
+ ${Boost_LIBRARIES}
+)
+
+ADD_LIBRARY(gnuradio-pager SHARED ${gr_pager_sources})
+TARGET_LINK_LIBRARIES(gnuradio-pager ${pager_libs})
+SET_TARGET_PROPERTIES(gnuradio-pager PROPERTIES DEFINE_SYMBOL "gnuradio_pager_EXPORTS")
+SET_TARGET_PROPERTIES(gnuradio-pager PROPERTIES SOVERSION ${LIBVER})
+
+INSTALL(TARGETS gnuradio-pager
+ LIBRARY DESTINATION ${GR_LIBRARY_DIR} COMPONENT "pager_runtime" # .so/.dylib file
+ ARCHIVE DESTINATION ${GR_LIBRARY_DIR} COMPONENT "pager_devel" # .lib file
+ RUNTIME DESTINATION ${GR_RUNTIME_DIR} COMPONENT "pager_runtime" # .dll file
+)
+
+########################################################################
+# Install header files
+########################################################################
+INSTALL(FILES
+ pager_slicer_fb.h
+ pager_flex_sync.h
+ pager_flex_deinterleave.h
+ pager_flex_parse.h
+ pager_flex_frame.h
+ pageri_bch3221.h
+ pageri_flex_modes.h
+ pageri_util.h
+ DESTINATION ${GR_INCLUDE_DIR}/gnuradio
+ COMPONENT "pager_devel"
+)
diff --git a/gr-pager/python/CMakeLists.txt b/gr-pager/python/CMakeLists.txt
new file mode 100644
index 000000000..26fbf6f09
--- /dev/null
+++ b/gr-pager/python/CMakeLists.txt
@@ -0,0 +1,49 @@
+# 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(GrPython)
+
+GR_PYTHON_INSTALL(
+ FILES
+ __init__.py
+ pager_utils.py
+ flex_demod.py
+ DESTINATION ${GR_PYTHON_DIR}/gnuradio/pager
+ COMPONENT "pager_python"
+)
+
+########################################################################
+# Handle the unit tests
+########################################################################
+IF(ENABLE_TESTING)
+INCLUDE(GrTest)
+FILE(GLOB py_qa_test_files "qa_*.py")
+FOREACH(py_qa_test_file ${py_qa_test_files})
+ GET_FILENAME_COMPONENT(py_qa_test_name ${py_qa_test_file} NAME_WE)
+ SET(GR_TEST_PYTHON_DIRS
+ ${CMAKE_BINARY_DIR}/gnuradio-core/src/python
+ ${CMAKE_BINARY_DIR}/gnuradio-core/src/lib/swig
+ ${CMAKE_BINARY_DIR}/gr-pager/python
+ ${CMAKE_BINARY_DIR}/gr-pager/swig
+ )
+ SET(GR_TEST_TARGET_DEPS gruel gnuradio-core gnuradio-pager)
+ GR_ADD_TEST(${py_qa_test_name} ${PYTHON_EXECUTABLE} ${py_qa_test_file})
+ENDFOREACH(py_qa_test_file)
+ENDIF(ENABLE_TESTING)
diff --git a/gr-pager/swig/CMakeLists.txt b/gr-pager/swig/CMakeLists.txt
new file mode 100644
index 000000000..24cab0c9a
--- /dev/null
+++ b/gr-pager/swig/CMakeLists.txt
@@ -0,0 +1,51 @@
+# 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.
+
+########################################################################
+# Setup swig generation
+########################################################################
+INCLUDE(GrPython)
+INCLUDE(GrSwig)
+
+SET(GR_SWIG_INCLUDE_DIRS
+ ${GR_PAGER_INCLUDE_DIRS}
+ ${GNURADIO_CORE_SWIG_INCLUDE_DIRS}
+)
+
+SET(GR_SWIG_LIBRARIES gnuradio-pager)
+
+GR_SWIG_MAKE(pager_swig pager_swig.i)
+
+GR_SWIG_INSTALL(
+ TARGETS pager_swig
+ DESTINATION ${GR_PYTHON_DIR}/gnuradio/pager
+ COMPONENT "pager_python"
+)
+
+INSTALL(
+ FILES
+ pager_swig.i
+ pager_flex_deinterleave.i
+ pager_flex_frame.i
+ pager_flex_parse.i
+ pager_flex_sync.i
+ pager_slicer_fb.i
+ DESTINATION ${GR_INCLUDE_DIR}/gnuradio/swig
+ COMPONENT "pager_swig"
+)