aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorPiotr Krysik <ptrkrysik@gmail.com>2017-09-13 09:31:52 +0200
committerPiotr Krysik <ptrkrysik@gmail.com>2017-09-13 09:31:52 +0200
commit3148ff80cefb2023857a97a283dad8878a88d00c (patch)
tree0bacebfdf2c7feb2f1f657ff303a9eb744750aca /lib
parente6e787959f51f280a78a2dc7bd7d1c16b11f8fa9 (diff)
parent0945cc5512e52f9a18770f1eea0dfb0bb1dfb2a4 (diff)
Merge branch 'development' into ptrkrysik/trx
# Conflicts: # lib/CMakeLists.txt
Diffstat (limited to 'lib')
-rw-r--r--lib/CMakeLists.txt92
-rw-r--r--lib/decoding/CMakeLists.txt28
-rw-r--r--lib/decoding/openbts/CMakeLists.txt28
-rw-r--r--lib/decoding/osmocom/coding/CMakeLists.txt28
-rw-r--r--lib/decryption/CMakeLists.txt22
-rw-r--r--lib/demapping/CMakeLists.txt24
-rw-r--r--lib/flow_control/CMakeLists.txt29
-rw-r--r--lib/misc_utils/CMakeLists.txt36
-rw-r--r--lib/qa_utils/CMakeLists.txt25
-rw-r--r--lib/receiver/CMakeLists.txt26
10 files changed, 281 insertions, 57 deletions
diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
index 7804e07..c6bba6e 100644
--- a/lib/CMakeLists.txt
+++ b/lib/CMakeLists.txt
@@ -17,13 +17,30 @@
# the Free Software Foundation, Inc., 51 Franklin Street,
# Boston, MA 02110-1301, USA.
-########################################################################
-# Setup library
-########################################################################
include(GrPlatform) #define LIB_SUFFIX
include(GrMiscUtils)
########################################################################
+# Add sources macro
+########################################################################
+set(grgsm_sources "")
+
+macro (add_sources)
+ file (RELATIVE_PATH _relPath "${PROJECT_SOURCE_DIR}/lib" "${CMAKE_CURRENT_SOURCE_DIR}")
+ foreach (_src ${ARGN})
+ if (_relPath)
+ list (APPEND grgsm_sources "${_relPath}/${_src}")
+ else()
+ list (APPEND grgsm_sources "${_src}")
+ endif()
+ endforeach()
+ if (_relPath)
+ # propagate grgsm_sources to parent directory
+ set (grgsm_sources ${grgsm_sources} PARENT_SCOPE)
+ endif()
+endmacro()
+
+########################################################################
# Handle the generated constants
########################################################################
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c
@@ -42,64 +59,25 @@ configure_file(
ESCAPE_QUOTES
@ONLY)
-list(APPEND grgsm_sources ${CMAKE_CURRENT_BINARY_DIR}/constants.cc)
+add_sources(constants.cc)
#########################################################################
+# Subdirecories
+#########################################################################
+add_subdirectory(decoding)
+add_subdirectory(decryption)
+add_subdirectory(demapping)
+add_subdirectory(flow_control)
+add_subdirectory(misc_utils)
+add_subdirectory(qa_utils)
+add_subdirectory(receiver)
+add_subdirectory(transmitter)
+add_subdirectory(trx_interface)
+########################################################################
+# Setup library
+########################################################################
include_directories(${Boost_INCLUDE_DIR} receiver)
link_directories(${Boost_LIBRARY_DIRS})
-list(APPEND grgsm_sources
- receiver/receiver_impl.cc
- receiver/receiver_config.cc
- receiver/viterbi_detector.cc
- decoding/sch.c
- receiver/clock_offset_control_impl.cc
- receiver/cx_channel_hopper_impl.cc
- demapping/universal_ctrl_chans_demapper_impl.cc
- demapping/tch_f_chans_demapper_impl.cc
- decoding/control_channels_decoder_impl.cc
- decoding/tch_f_decoder_impl.cc
- decoding/openbts/AmrCoder.cpp
- decoding/openbts/BitVector.cpp
- decoding/openbts/GSM610Tables.cpp
- decoding/openbts/GSM660Tables.cpp
- decoding/openbts/GSM503Tables.cpp
- decoding/openbts/ViterbiR204.cpp
- decoding/osmocom/coding/gsm0503_conv.c
- decoding/osmocom/coding/gsm0503_coding.c
- decoding/osmocom/coding/gsm0503_interleaving.c
- decoding/osmocom/coding/gsm0503_mapping.c
- decoding/osmocom/coding/gsm0503_parity.c
- decoding/osmocom/coding/gsm0503_tables.c
- flow_control/burst_timeslot_splitter_impl.cc
- flow_control/burst_sdcch_subslot_splitter_impl.cc
- flow_control/burst_timeslot_filter_impl.cc
- flow_control/burst_sdcch_subslot_filter_impl.cc
- flow_control/burst_fnr_filter_impl.cc
- flow_control/dummy_burst_filter_impl.cc
- flow_control/uplink_downlink_splitter_impl.cc
- misc_utils/collect_system_info_impl.cc
- misc_utils/controlled_rotator_cc_impl.cc
- misc_utils/controlled_fractional_resampler_cc_impl.cc
- misc_utils/msg_to_tag_impl.cc
- misc_utils/message_printer_impl.cc
- misc_utils/tmsi_dumper_impl.cc
- misc_utils/burst_file_sink_impl.cc
- misc_utils/burst_file_source_impl.cc
- misc_utils/message_file_sink_impl.cc
- misc_utils/message_file_source_impl.cc
- misc_utils/bursts_printer_impl.cc
- misc_utils/extract_system_info_impl.cc
- misc_utils/extract_immediate_assignment_impl.cc
- misc_utils/extract_cmc_impl.cc
- qa_utils/burst_sink_impl.cc
- qa_utils/burst_source_impl.cc
- qa_utils/message_source_impl.cc
- qa_utils/message_sink_impl.cc
- decryption/decryption_impl.cc
- trx_interface/udp_socket.cc
- trx_interface/trx_impl.cc
-)
-
add_library(grgsm SHARED ${grgsm_sources})
target_link_libraries(grgsm ${Boost_LIBRARIES} ${GNURADIO_ALL_LIBRARIES} ${VOLK_LIBRARIES} ${LIBOSMOCODEC_LIBRARIES} ${LIBOSMOCORE_LIBRARIES}
diff --git a/lib/decoding/CMakeLists.txt b/lib/decoding/CMakeLists.txt
new file mode 100644
index 0000000..0305a07
--- /dev/null
+++ b/lib/decoding/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Copyright 2011,2012 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.
+
+
+add_sources(
+ control_channels_decoder_impl.cc
+ tch_f_decoder_impl.cc
+ sch.c
+)
+
+add_subdirectory(osmocom/coding)
+add_subdirectory(openbts)
diff --git a/lib/decoding/openbts/CMakeLists.txt b/lib/decoding/openbts/CMakeLists.txt
new file mode 100644
index 0000000..eb857bf
--- /dev/null
+++ b/lib/decoding/openbts/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ AmrCoder.cpp
+ BitVector.cpp
+ GSM610Tables.cpp
+ GSM660Tables.cpp
+ GSM503Tables.cpp
+ ViterbiR204.cpp
+)
+
diff --git a/lib/decoding/osmocom/coding/CMakeLists.txt b/lib/decoding/osmocom/coding/CMakeLists.txt
new file mode 100644
index 0000000..615a2f6
--- /dev/null
+++ b/lib/decoding/osmocom/coding/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Copyright 2011,2012 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.
+
+add_sources(APPEND grgsm_sources
+ gsm0503_conv.c
+ gsm0503_coding.c
+ gsm0503_interleaving.c
+ gsm0503_mapping.c
+ gsm0503_parity.c
+ gsm0503_tables.c
+)
+
diff --git a/lib/decryption/CMakeLists.txt b/lib/decryption/CMakeLists.txt
new file mode 100644
index 0000000..7ccd99a
--- /dev/null
+++ b/lib/decryption/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ decryption_impl.cc
+)
diff --git a/lib/demapping/CMakeLists.txt b/lib/demapping/CMakeLists.txt
new file mode 100644
index 0000000..57d2d1a
--- /dev/null
+++ b/lib/demapping/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ tch_f_chans_demapper_impl.cc
+ universal_ctrl_chans_demapper_impl.cc
+)
+
diff --git a/lib/flow_control/CMakeLists.txt b/lib/flow_control/CMakeLists.txt
new file mode 100644
index 0000000..30a5f50
--- /dev/null
+++ b/lib/flow_control/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ burst_fnr_filter_impl.cc
+ burst_sdcch_subslot_filter_impl.cc
+ burst_sdcch_subslot_splitter_impl.cc
+ burst_timeslot_filter_impl.cc
+ burst_timeslot_splitter_impl.cc
+ dummy_burst_filter_impl.cc
+ uplink_downlink_splitter_impl.cc
+)
+
diff --git a/lib/misc_utils/CMakeLists.txt b/lib/misc_utils/CMakeLists.txt
new file mode 100644
index 0000000..1c51fb6
--- /dev/null
+++ b/lib/misc_utils/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ burst_file_sink_impl.cc
+ burst_file_source_impl.cc
+ bursts_printer_impl.cc
+ collect_system_info_impl.cc
+ controlled_fractional_resampler_cc_impl.cc
+ controlled_rotator_cc_impl.cc
+ extract_cmc_impl.cc
+ extract_immediate_assignment_impl.cc
+ extract_system_info_impl.cc
+ message_file_sink_impl.cc
+ message_file_source_impl.cc
+ message_printer_impl.cc
+ msg_to_tag_impl.cc
+ tmsi_dumper_impl.cc
+)
+
diff --git a/lib/qa_utils/CMakeLists.txt b/lib/qa_utils/CMakeLists.txt
new file mode 100644
index 0000000..a70967b
--- /dev/null
+++ b/lib/qa_utils/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ burst_sink_impl.cc
+ burst_source_impl.cc
+ message_sink_impl.cc
+ message_source_impl.cc
+)
diff --git a/lib/receiver/CMakeLists.txt b/lib/receiver/CMakeLists.txt
new file mode 100644
index 0000000..343d2f8
--- /dev/null
+++ b/lib/receiver/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Copyright 2011,2012 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.
+
+add_sources(
+ clock_offset_control_impl.cc
+ cx_channel_hopper_impl.cc
+ receiver_config.cc
+ receiver_impl.cc
+ viterbi_detector.cc
+)