From dde1d34da1302fa9e63b58bcb9e9854a231270e4 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:27:25 -0800 Subject: [PATCH 01/25] Move dialogs and custom controls under gui folder. --- src/CMakeLists.txt | 30 ++-------------------- src/gui/CMakeLists.txt | 5 +++- src/{ => gui/controls}/plot.cpp | 0 src/{ => gui/controls}/plot.h | 0 src/{ => gui/controls}/plot_scalar.cpp | 4 +-- src/{ => gui/controls}/plot_scalar.h | 0 src/{ => gui/controls}/plot_scatter.cpp | 6 +++-- src/{ => gui/controls}/plot_scatter.h | 2 +- src/{ => gui/controls}/plot_spectrum.cpp | 4 +-- src/{ => gui/controls}/plot_spectrum.h | 2 +- src/{ => gui/controls}/plot_waterfall.cpp | 6 +++-- src/{ => gui/controls}/plot_waterfall.h | 2 +- src/{ => gui/dialogs}/dlg_audiooptions.cpp | 7 ++++- src/{ => gui/dialogs}/dlg_audiooptions.h | 13 +++++++--- src/{ => gui/dialogs}/dlg_easy_setup.cpp | 6 +++++ src/{ => gui/dialogs}/dlg_easy_setup.h | 0 src/{ => gui/dialogs}/dlg_filter.cpp | 0 src/{ => gui/dialogs}/dlg_filter.h | 0 src/{ => gui/dialogs}/dlg_options.cpp | 0 src/{ => gui/dialogs}/dlg_options.h | 0 src/{ => gui/dialogs}/dlg_ptt.cpp | 0 src/{ => gui/dialogs}/dlg_ptt.h | 0 src/main.cpp | 5 ++++ src/main.h | 16 ++++-------- src/ongui.cpp | 6 +++++ 25 files changed, 59 insertions(+), 55 deletions(-) rename src/{ => gui/controls}/plot.cpp (100%) rename src/{ => gui/controls}/plot.h (100%) rename src/{ => gui/controls}/plot_scalar.cpp (99%) rename src/{ => gui/controls}/plot_scalar.h (100%) rename src/{ => gui/controls}/plot_scatter.cpp (99%) rename src/{ => gui/controls}/plot_scatter.h (98%) rename src/{ => gui/controls}/plot_spectrum.cpp (99%) rename src/{ => gui/controls}/plot_spectrum.h (98%) rename src/{ => gui/controls}/plot_waterfall.cpp (99%) rename src/{ => gui/controls}/plot_waterfall.h (99%) rename src/{ => gui/dialogs}/dlg_audiooptions.cpp (99%) rename src/{ => gui/dialogs}/dlg_audiooptions.h (96%) rename src/{ => gui/dialogs}/dlg_easy_setup.cpp (99%) rename src/{ => gui/dialogs}/dlg_easy_setup.h (100%) rename src/{ => gui/dialogs}/dlg_filter.cpp (100%) rename src/{ => gui/dialogs}/dlg_filter.h (100%) rename src/{ => gui/dialogs}/dlg_options.cpp (100%) rename src/{ => gui/dialogs}/dlg_options.h (100%) rename src/{ => gui/dialogs}/dlg_ptt.cpp (100%) rename src/{ => gui/dialogs}/dlg_ptt.h (100%) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index d79842b60..e1a955f8e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,40 +1,14 @@ set(FREEDV_SOURCES - dlg_audiooptions.cpp - dlg_easy_setup.cpp - dlg_filter.cpp - dlg_options.cpp - dlg_ptt.cpp freedv_reporter.cpp main.cpp - plot.cpp - plot_scalar.cpp - plot_scatter.cpp - plot_spectrum.cpp - plot_waterfall.cpp topFrame.cpp sox_biquad.c - sox_biquad.h - comp.h - dlg_audiooptions.h - dlg_filter.h - dlg_options.h - dlg_ptt.h - defines.h - main.h - plot.h - plot_scalar.h - plot_scatter.h - plot_spectrum.h - plot_waterfall.h - topFrame.h - version.h util.cpp eq.cpp voicekeyer.cpp playrec.cpp ongui.cpp freedv_interface.cpp - freedv_interface.h ) set(FREEDV_LINK_LIBS_OSX @@ -75,9 +49,9 @@ endif(APPLE) # Link imported or build tree targets. if(APPLE) -target_link_libraries(FreeDV fdv_audio fdv_audio_pipeline fdv_config fdv_gui_util fdv_os_wrapper fdv_rig_control fdv_reporting fdv_sox fdv_util lpcnetfreedv codec2) +target_link_libraries(FreeDV fdv_audio fdv_audio_pipeline fdv_config fdv_gui_controls fdv_gui_dialogs fdv_gui_util fdv_os_wrapper fdv_rig_control fdv_reporting fdv_sox fdv_util lpcnetfreedv codec2) else(APPLE) -target_link_libraries(freedv fdv_audio fdv_audio_pipeline fdv_config fdv_gui_util fdv_os_wrapper fdv_rig_control fdv_reporting fdv_sox fdv_util lpcnetfreedv codec2) +target_link_libraries(freedv fdv_audio fdv_audio_pipeline fdv_config fdv_gui_controls fdv_gui_dialogs fdv_gui_util fdv_os_wrapper fdv_rig_control fdv_reporting fdv_sox fdv_util lpcnetfreedv codec2) endif(APPLE) # Add build dependencies for internally built external libraries. diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 23d1845e7..7f849c35d 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -1 +1,4 @@ -add_subdirectory(util) \ No newline at end of file +add_subdirectory(controls) +add_subdirectory(dialogs) +add_subdirectory(util) + diff --git a/src/plot.cpp b/src/gui/controls/plot.cpp similarity index 100% rename from src/plot.cpp rename to src/gui/controls/plot.cpp diff --git a/src/plot.h b/src/gui/controls/plot.h similarity index 100% rename from src/plot.h rename to src/gui/controls/plot.h diff --git a/src/plot_scalar.cpp b/src/gui/controls/plot_scalar.cpp similarity index 99% rename from src/plot_scalar.cpp rename to src/gui/controls/plot_scalar.cpp index b9af9bf56..353f00293 100644 --- a/src/plot_scalar.cpp +++ b/src/gui/controls/plot_scalar.cpp @@ -19,8 +19,8 @@ // //========================================================================== #include -#include "wx/wx.h" -#include "main.h" + +#include #include "plot_scalar.h" BEGIN_EVENT_TABLE(PlotScalar, PlotPanel) diff --git a/src/plot_scalar.h b/src/gui/controls/plot_scalar.h similarity index 100% rename from src/plot_scalar.h rename to src/gui/controls/plot_scalar.h diff --git a/src/plot_scatter.cpp b/src/gui/controls/plot_scatter.cpp similarity index 99% rename from src/plot_scatter.cpp rename to src/gui/controls/plot_scatter.cpp index 4474c9954..43df085f5 100644 --- a/src/plot_scatter.cpp +++ b/src/gui/controls/plot_scatter.cpp @@ -19,10 +19,12 @@ // //========================================================================== #include -#include "wx/wx.h" -#include "plot_scatter.h" + +#include #include +#include "plot_scatter.h" + BEGIN_EVENT_TABLE(PlotScatter, PlotPanel) EVT_PAINT (PlotScatter::OnPaint) EVT_MOTION (PlotScatter::OnMouseMove) diff --git a/src/plot_scatter.h b/src/gui/controls/plot_scatter.h similarity index 98% rename from src/plot_scatter.h rename to src/gui/controls/plot_scatter.h index d02e9e321..2f526e644 100644 --- a/src/plot_scatter.h +++ b/src/gui/controls/plot_scatter.h @@ -23,7 +23,7 @@ #include "comp.h" #include "plot.h" -#include "defines.h" +#include "../../defines.h" #define PLOT_SCATTER_MODE_SCATTER 0 #define PLOT_SCATTER_MODE_EYE 1 diff --git a/src/plot_spectrum.cpp b/src/gui/controls/plot_spectrum.cpp similarity index 99% rename from src/plot_spectrum.cpp rename to src/gui/controls/plot_spectrum.cpp index 4cac7d433..7a6e869a6 100644 --- a/src/plot_spectrum.cpp +++ b/src/gui/controls/plot_spectrum.cpp @@ -19,9 +19,9 @@ // //========================================================================== #include -#include "wx/wx.h" +#include -#include "main.h" +#include "plot_spectrum.h" void clickTune(float frequency); // callback to pass new click freq diff --git a/src/plot_spectrum.h b/src/gui/controls/plot_spectrum.h similarity index 98% rename from src/plot_spectrum.h rename to src/gui/controls/plot_spectrum.h index 09226f58a..5dece6f12 100644 --- a/src/plot_spectrum.h +++ b/src/gui/controls/plot_spectrum.h @@ -22,7 +22,7 @@ #define __FDMDV2_PLOT_SPECTRUM__ #include "plot.h" -#include "defines.h" +#include "../../defines.h" //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--=-=-=-= // Class Waterfall diff --git a/src/plot_waterfall.cpp b/src/gui/controls/plot_waterfall.cpp similarity index 99% rename from src/plot_waterfall.cpp rename to src/gui/controls/plot_waterfall.cpp index 8b58afd2d..b835626ee 100644 --- a/src/plot_waterfall.cpp +++ b/src/gui/controls/plot_waterfall.cpp @@ -20,10 +20,12 @@ //========================================================================== #include #include -#include "wx/wx.h" -#include "main.h" + +#include #include "os/os_interface.h" +#include "plot_waterfall.h" + // Tweak accordingly #define Y_PER_SECOND (30) diff --git a/src/plot_waterfall.h b/src/gui/controls/plot_waterfall.h similarity index 99% rename from src/plot_waterfall.h rename to src/gui/controls/plot_waterfall.h index 51f56b7db..f03edb00b 100644 --- a/src/plot_waterfall.h +++ b/src/gui/controls/plot_waterfall.h @@ -22,7 +22,7 @@ #define __FDMDV2_PLOT_WATERFALL__ #include "plot.h" -#include "defines.h" +#include "../../defines.h" //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--=-=-=-= // Class PlotWaterfall diff --git a/src/dlg_audiooptions.cpp b/src/gui/dialogs/dlg_audiooptions.cpp similarity index 99% rename from src/dlg_audiooptions.cpp rename to src/gui/dialogs/dlg_audiooptions.cpp index 4e89a7426..785ad0605 100644 --- a/src/dlg_audiooptions.cpp +++ b/src/gui/dialogs/dlg_audiooptions.cpp @@ -22,11 +22,16 @@ #include -#include "main.h" +#include +#include + #include "dlg_audiooptions.h" + #include "audio/AudioEngineFactory.h" #include "audio/IAudioDevice.h" +#include "main.h" + using namespace std::chrono_literals; // constants for test waveform plots diff --git a/src/dlg_audiooptions.h b/src/gui/dialogs/dlg_audiooptions.h similarity index 96% rename from src/dlg_audiooptions.h rename to src/gui/dialogs/dlg_audiooptions.h index e0520433f..475f1f516 100644 --- a/src/dlg_audiooptions.h +++ b/src/gui/dialogs/dlg_audiooptions.h @@ -22,14 +22,21 @@ #define __AudioOptsDialog__ #include -#include "main.h" +#include +#include +#include +#include +#include +#include +#include +#include + +#include "gui/controls/plot_scalar.h" #define ID_AUDIO_OPTIONS 1000 #define AUDIO_IN 0 #define AUDIO_OUT 1 -#include "codec2_fifo.h" - //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--=-=-=-= // AudioInfoDisplay //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--=-=-=-= diff --git a/src/dlg_easy_setup.cpp b/src/gui/dialogs/dlg_easy_setup.cpp similarity index 99% rename from src/dlg_easy_setup.cpp rename to src/gui/dialogs/dlg_easy_setup.cpp index 1873bc489..fc8270a05 100644 --- a/src/dlg_easy_setup.cpp +++ b/src/gui/dialogs/dlg_easy_setup.cpp @@ -24,8 +24,12 @@ #include #include +#include + #include "main.h" #include "dlg_easy_setup.h" +#include "dlg_audiooptions.h" +#include "dlg_ptt.h" #include "audio/AudioEngineFactory.h" #ifdef __WIN32__ @@ -35,7 +39,9 @@ #include #endif +#ifndef PI #define PI 3.14159 +#endif // PI #define RX_ONLY_STRING "None (receive only)" #define MULTIPLE_DEVICES_STRING "(multiple)" diff --git a/src/dlg_easy_setup.h b/src/gui/dialogs/dlg_easy_setup.h similarity index 100% rename from src/dlg_easy_setup.h rename to src/gui/dialogs/dlg_easy_setup.h diff --git a/src/dlg_filter.cpp b/src/gui/dialogs/dlg_filter.cpp similarity index 100% rename from src/dlg_filter.cpp rename to src/gui/dialogs/dlg_filter.cpp diff --git a/src/dlg_filter.h b/src/gui/dialogs/dlg_filter.h similarity index 100% rename from src/dlg_filter.h rename to src/gui/dialogs/dlg_filter.h diff --git a/src/dlg_options.cpp b/src/gui/dialogs/dlg_options.cpp similarity index 100% rename from src/dlg_options.cpp rename to src/gui/dialogs/dlg_options.cpp diff --git a/src/dlg_options.h b/src/gui/dialogs/dlg_options.h similarity index 100% rename from src/dlg_options.h rename to src/gui/dialogs/dlg_options.h diff --git a/src/dlg_ptt.cpp b/src/gui/dialogs/dlg_ptt.cpp similarity index 100% rename from src/dlg_ptt.cpp rename to src/gui/dialogs/dlg_ptt.cpp diff --git a/src/dlg_ptt.h b/src/gui/dialogs/dlg_ptt.h similarity index 100% rename from src/dlg_ptt.h rename to src/gui/dialogs/dlg_ptt.h diff --git a/src/main.cpp b/src/main.cpp index 243376183..d47283725 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -30,6 +30,7 @@ #include #include #include + #include "version.h" #include "main.h" #include "os/os_interface.h" @@ -40,6 +41,10 @@ #include "reporting/pskreporter.h" #include "reporting/FreeDVReporter.h" +#include "gui/dialogs/dlg_options.h" +#include "gui/dialogs/dlg_filter.h" +#include "gui/dialogs/dlg_easy_setup.h" + #define wxUSE_FILEDLG 1 #define wxUSE_LIBPNG 1 #define wxUSE_LIBJPEG 1 diff --git a/src/main.h b/src/main.h index 7bbeb371f..6a93b43f9 100644 --- a/src/main.h +++ b/src/main.h @@ -72,18 +72,12 @@ #include "modem_stats.h" #include "topFrame.h" -#include "dlg_easy_setup.h" -#include "dlg_ptt.h" -#include "dlg_options.h" -#include "plot.h" -#include "plot_scalar.h" -#include "plot_scatter.h" -#include "plot_waterfall.h" -#include "plot_spectrum.h" +#include "gui/controls/plot.h" +#include "gui/controls/plot_scalar.h" +#include "gui/controls/plot_scatter.h" +#include "gui/controls/plot_waterfall.h" +#include "gui/controls/plot_spectrum.h" #include "sndfile.h" -#include "dlg_audiooptions.h" -#include "dlg_filter.h" -#include "dlg_options.h" #include "freedv_reporter.h" #include "sox_biquad.h" #include "comp_prim.h" diff --git a/src/ongui.cpp b/src/ongui.cpp index 836e3d198..0271ca407 100644 --- a/src/ongui.cpp +++ b/src/ongui.cpp @@ -11,6 +11,12 @@ #include "main.h" #include "lpcnet_freedv.h" +#include "gui/dialogs/dlg_easy_setup.h" +#include "gui/dialogs/dlg_filter.h" +#include "gui/dialogs/dlg_audiooptions.h" +#include "gui/dialogs/dlg_options.h" +#include "gui/dialogs/dlg_ptt.h" + #if defined(WIN32) #include "rig_control/omnirig/OmniRigController.h" #endif // defined(WIN32) From 62343a8d09bc2751caa9ba54e332a8eec8eab712 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:37:18 -0800 Subject: [PATCH 02/25] Move SpeexDSP scripts to cmake scripts folder. --- cmake/BuildSpeex.cmake | 4 ++-- configure_speexdsp_osx.sh => cmake/configure_speexdsp_osx.sh | 0 .../configure_speexdsp_osx_universal.sh | 0 3 files changed, 2 insertions(+), 2 deletions(-) rename configure_speexdsp_osx.sh => cmake/configure_speexdsp_osx.sh (100%) rename configure_speexdsp_osx_universal.sh => cmake/configure_speexdsp_osx_universal.sh (100%) diff --git a/cmake/BuildSpeex.cmake b/cmake/BuildSpeex.cmake index 6fe3ffda8..4b8c95358 100644 --- a/cmake/BuildSpeex.cmake +++ b/cmake/BuildSpeex.cmake @@ -3,9 +3,9 @@ if(MINGW AND CMAKE_CROSSCOMPILING) set(CONFIGURE_COMMAND ./configure --host=${HOST} --prefix=${CMAKE_BINARY_DIR}/external/dist --disable-examples) elseif(APPLE) if(BUILD_OSX_UNIVERSAL) - set(CONFIGURE_COMMAND ${CMAKE_BINARY_DIR}/../configure_speexdsp_osx_universal.sh ${CMAKE_BINARY_DIR}/external/dist) + set(CONFIGURE_COMMAND ${CMAKE_BINARY_DIR}/../cmake/configure_speexdsp_osx_universal.sh ${CMAKE_BINARY_DIR}/external/dist) else() - set(CONFIGURE_COMMAND ${CMAKE_BINARY_DIR}/../configure_speexdsp_osx.sh ${CMAKE_BINARY_DIR}/external/dist) + set(CONFIGURE_COMMAND ${CMAKE_BINARY_DIR}/../cmake/configure_speexdsp_osx.sh ${CMAKE_BINARY_DIR}/external/dist) endif(BUILD_OSX_UNIVERSAL) else() set(CONFIGURE_COMMAND ./configure --prefix=${CMAKE_BINARY_DIR}/external/dist --disable-examples) diff --git a/configure_speexdsp_osx.sh b/cmake/configure_speexdsp_osx.sh similarity index 100% rename from configure_speexdsp_osx.sh rename to cmake/configure_speexdsp_osx.sh diff --git a/configure_speexdsp_osx_universal.sh b/cmake/configure_speexdsp_osx_universal.sh similarity index 100% rename from configure_speexdsp_osx_universal.sh rename to cmake/configure_speexdsp_osx_universal.sh From 9cf79ca147b0a9bfec8886cc37f6bc8ea3ac09a0 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:38:22 -0800 Subject: [PATCH 03/25] Move hamlib patch file to cmake folder. --- cmake/BuildHamlib.cmake | 4 ++-- hamlib-windows.patch => cmake/hamlib-windows.patch | 0 2 files changed, 2 insertions(+), 2 deletions(-) rename hamlib-windows.patch => cmake/hamlib-windows.patch (100%) diff --git a/cmake/BuildHamlib.cmake b/cmake/BuildHamlib.cmake index 026da630a..b9964a675 100644 --- a/cmake/BuildHamlib.cmake +++ b/cmake/BuildHamlib.cmake @@ -1,6 +1,6 @@ if(MINGW AND CMAKE_CROSSCOMPILING) set(CONFIGURE_COMMAND ./configure --host=${HOST} --target=${HOST} --without-cxx-binding --enable-shared --prefix=${CMAKE_BINARY_DIR}/external/dist --without-libusb CFLAGS=-g\ -O2\ -fstack-protector CXXFLAGS=-g\ -O2\ -fstack-protector) - set(HAMLIB_PATCH_CMD patch -p1 < ${CMAKE_SOURCE_DIR}/hamlib-windows.patch) + set(HAMLIB_PATCH_CMD patch -p1 < ${CMAKE_SOURCE_DIR}/cmake/hamlib-windows.patch) else(MINGW AND CMAKE_CROSSCOMPILING) set(HAMLIB_PATCH_CMD "") if(APPLE) @@ -44,4 +44,4 @@ list(APPEND FREEDV_STATIC_DEPS hamlib) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fstack-protector") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fstack-protector") -set(HAMLIB_ADD_DEPENDENCY TRUE) \ No newline at end of file +set(HAMLIB_ADD_DEPENDENCY TRUE) diff --git a/hamlib-windows.patch b/cmake/hamlib-windows.patch similarity index 100% rename from hamlib-windows.patch rename to cmake/hamlib-windows.patch From 103ef42d79a9fbebf38b7717f848dc658ec98ea9 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:39:15 -0800 Subject: [PATCH 04/25] Remove no longer used libsamplerate patch. --- patch-samplerate.diff | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 patch-samplerate.diff diff --git a/patch-samplerate.diff b/patch-samplerate.diff deleted file mode 100644 index ed5bcdd37..000000000 --- a/patch-samplerate.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- examples/Makefile.in.orig 2011-08-15 22:12:30.000000000 +1000 -+++ examples/Makefile.in 2012-03-25 15:31:07.000000000 +1100 -@@ -56,7 +56,7 @@ - CONFIG_CLEAN_FILES = - CONFIG_CLEAN_VPATH_FILES = - am__installdirs = "$(DESTDIR)$(bindir)" --PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS) -+PROGRAMS = $(bin_PROGRAMS) - am_sndfile_resample_OBJECTS = sndfile-resample.$(OBJEXT) - sndfile_resample_OBJECTS = $(am_sndfile_resample_OBJECTS) - am__DEPENDENCIES_1 = From 6e0355260656fff935507a1bbe1945e24f1bf6d5 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:43:29 -0800 Subject: [PATCH 05/25] Add forgotten CMakeLists.txt files. --- src/gui/controls/CMakeLists.txt | 14 ++++++++++++++ src/gui/dialogs/CMakeLists.txt | 14 ++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 src/gui/controls/CMakeLists.txt create mode 100644 src/gui/dialogs/CMakeLists.txt diff --git a/src/gui/controls/CMakeLists.txt b/src/gui/controls/CMakeLists.txt new file mode 100644 index 000000000..182da03bc --- /dev/null +++ b/src/gui/controls/CMakeLists.txt @@ -0,0 +1,14 @@ +add_library(fdv_gui_controls STATIC + plot.cpp + plot_scalar.cpp + plot_scatter.cpp + plot_spectrum.cpp + plot_waterfall.cpp) + +target_include_directories(fdv_gui_controls PRIVATE ${CODEC2_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR}/../.. ${CMAKE_CURRENT_BINARY_DIR}/../..) + +if(BOOTSTRAP_WXWIDGETS) + add_dependencies(fdv_gui_controls wx::core wx::base wx::aui wx::html wx::net wx::adv wx::propgrid wx::xrc) + target_compile_definitions(fdv_gui_controls PRIVATE ${WXBUILD_BUILD_DEFS}) + target_include_directories(fdv_gui_controls PRIVATE ${WXBUILD_INCLUDES}) +endif(BOOTSTRAP_WXWIDGETS) diff --git a/src/gui/dialogs/CMakeLists.txt b/src/gui/dialogs/CMakeLists.txt new file mode 100644 index 000000000..c79e18e2a --- /dev/null +++ b/src/gui/dialogs/CMakeLists.txt @@ -0,0 +1,14 @@ +add_library(fdv_gui_dialogs STATIC + dlg_audiooptions.cpp + dlg_easy_setup.cpp + dlg_filter.cpp + dlg_options.cpp + dlg_ptt.cpp) + +target_include_directories(fdv_gui_dialogs PRIVATE ${CODEC2_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR}/../.. ${CMAKE_CURRENT_BINARY_DIR}/../..) + +if(BOOTSTRAP_WXWIDGETS) + add_dependencies(fdv_gui_dialogs wx::core wx::base wx::aui wx::html wx::net wx::adv wx::propgrid wx::xrc) + target_compile_definitions(fdv_gui_dialogs PRIVATE ${WXBUILD_BUILD_DEFS}) + target_include_directories(fdv_gui_dialogs PRIVATE ${WXBUILD_INCLUDES}) +endif(BOOTSTRAP_WXWIDGETS) From 79fc67cc188e16a54837cafac27b5b54ed27e7f7 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:45:34 -0800 Subject: [PATCH 06/25] Add PR #654 to changelog. --- USER_MANUAL.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/USER_MANUAL.md b/USER_MANUAL.md index 3a9d76a80..df502b8f5 100644 --- a/USER_MANUAL.md +++ b/USER_MANUAL.md @@ -918,6 +918,10 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes * End support for 32 bit ARM on Windows. (PR #651) 4. Documentation: * Fix spelling, etc. mistakes in the documentation. (PR #640) +5. Code cleanup: + * Move GUI related files into their own folder. (PR #654) + * Move build scripts into cmake folder. (PR #654) + * Remove no longer used scripts and patch files. (PR #654) ## V1.9.6 December 2023 From 35c677b1d31ca60dc41474474130ddd71d67c288 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 12:46:06 -0800 Subject: [PATCH 07/25] Remove unused send_email_on_sync.py file. --- src/send_email_on_sync.py | 67 --------------------------------------- 1 file changed, 67 deletions(-) delete mode 100644 src/send_email_on_sync.py diff --git a/src/send_email_on_sync.py b/src/send_email_on_sync.py deleted file mode 100644 index b3e681f2c..000000000 --- a/src/send_email_on_sync.py +++ /dev/null @@ -1,67 +0,0 @@ -#!/usr/bin/env python -# -# FreeDV Sync Notification Script -# -from __future__ import print_function -import argparse -import smtplib -import socket -import sys -import time - - -# Clean way of printing to stderr... -def eprint(*args, **kwargs): - print(*args, file=sys.stderr, **kwargs) - - -if __name__ == "__main__": - - parser = argparse.ArgumentParser(description='FreeDV Sync to E-Mail Gateway') - parser.add_argument('email_addr', type=str, help="User e-mail address.") - parser.add_argument('email_pass', type=str, help="User e-mail SMTP password.") - parser.add_argument('--limit', type=int, default=5, help="Limit e-mails to once every X minutes. Default = 5") - parser.add_argument('--listen_port', type=int, default=3000, help="Listen on port X. Default: 3000") - parser.add_argument('--smtp_server', type=str, default="smtp.gmail.com", help="E-Mail SMTP Server. Default: gmail") - parser.add_argument('--smtp_port', type=int, default=587, help="SMTP Port. Default: 587 (SSL)") - args = parser.parse_args() - - - # Create a UDP/IP socket - sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) - - # Bind the socket to the port - server_address = ('localhost', args.listen_port) - eprint("Starting up on %s port %s" % (server_address[0], server_address[1])) - sock.bind(server_address) - - _last_email = 0 - - while True: - eprint('\nwaiting to receive message') - data, address = sock.recvfrom(4096) - - eprint('received %s bytes from %s' % (len(data), address)) - eprint(data) - - if data: - # Check if we are allowed to send. - _now = time.time() - if (_now - _last_email) > args.limit*60: - try: - # send gmail - server = smtplib.SMTP(args.smtp_server, args.smtp_port) - server.starttls() - server.login(args.email_addr, args.email_pass) - - msg = "FreeDV has sync" - server.sendmail(args.email_addr, args.email_addr, msg) - server.quit() - - except Exception as e: - # Lazy exception handling... - eprint("Error when sending e-mail - %s" % str(e)) - - _last_email = time.time() - else: - eprint("Error: Not long enough since last e-mail.") From 277c55fe2eee327e546c64d24dcc3f3ef57e1d60 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:02:35 -0800 Subject: [PATCH 08/25] Update README. --- README.md | 110 ++++++++++--------------------------------------- USER_MANUAL.md | 1 + 2 files changed, 22 insertions(+), 89 deletions(-) diff --git a/README.md b/README.md index 7aa00112d..4386202b9 100644 --- a/README.md +++ b/README.md @@ -8,16 +8,25 @@ This document describes how to build the FreeDV GUI program for various operatin * [FreeDV GUI User Manual](USER_MANUAL.md) * [Building for Windows using Docker](docker/README_docker.md) -## Building on Ubuntu Linux (16-20) with PortAudio +## Building on Ubuntu Linux + ``` $ sudo apt install libspeexdsp-dev libsamplerate0-dev sox git \ - libwxgtk3.0-gtk3-dev portaudio19-dev libhamlib-dev libasound2-dev libao-dev \ + libwxgtk3.0-gtk3-dev libhamlib-dev libasound2-dev libao-dev \ libgsm1-dev libsndfile1-dev cmake module-assistant build-essential $ git clone https://github.com/drowe67/freedv-gui.git $ cd freedv-gui + + (if using pipewire/PulseAudio -- recommended and the default) + $ sudo apt install libpulse-dev + $ ./build_linux.sh + + (if using PortAudio) + $ sudo apt install portaudio19-dev $ ./build_linux.sh portaudio ``` - (For Ubuntu 20.04 the wxWidgets package is named `libwxgtk3.0-gtk3-dev`.) + + (Depending on release you may need to use `libwxgtk3.0-gtk3-dev` instead of `libwxgtk3.2-dev`.) Then run with: ``` @@ -26,50 +35,26 @@ This document describes how to build the FreeDV GUI program for various operatin Note this builds all libraries locally, nothing is installed on your machine. ```make install``` is not required. -## Building on Fedora Linux with PortAudio +## Building on Fedora Linux ``` $ sudo dnf groupinstall "Development Tools" - $ sudo dnf install cmake wxGTK3-devel portaudio-devel libsamplerate-devel \ + $ sudo dnf install cmake wxGTK3-devel libsamplerate-devel \ libsndfile-devel speexdsp-devel hamlib-devel alsa-lib-devel libao-devel \ gsm-devel gcc-c++ sox $ git clone https://github.com/drowe67/freedv-gui.git $ cd freedv-gui + + (if using pipewire/PulseAudio -- default and recommended) + $ sudo dnf install pulseaudio-libs-devel + $ ./build_linux.sh + + (if using PortAudio) + $ sudo dnf install portaudio-devel $ ./build_linux.sh portaudio ``` - Then run with: - ``` - $ ./build_linux/src/freedv - ``` -## Building on Ubuntu Linux (16-20) with PulseAudio - ``` - $ sudo apt install libspeexdsp-dev libsamplerate0-dev sox git \ - libwxgtk3.0-gtk3-dev libhamlib-dev libasound2-dev libao-dev \ - libgsm1-dev libsndfile1-dev cmake module-assistant build-essential libpulse-dev - $ git clone https://github.com/drowe67/freedv-gui.git - $ cd freedv-gui - $ ./build_linux.sh pulseaudio - ``` - (For Ubuntu 20.04 the wxWidgets package is named `libwxgtk3.0-gtk3-dev`.) - Then run with: - ``` - $ ./build_linux/src/freedv - ``` - - Note this builds all libraries locally, nothing is installed on your machine. ```make install``` is not required. -## Building on Fedora Linux with PulseAudio - ``` - $ sudo dnf groupinstall "Development Tools" - $ sudo dnf install cmake wxGTK3-devel libsamplerate-devel \ - libsndfile-devel speexdsp-devel hamlib-devel alsa-lib-devel libao-devel \ - gsm-devel pulseaudio-libs-devel gcc-c++ sox - $ git clone https://github.com/drowe67/freedv-gui.git - $ cd freedv-gui - $ ./build_linux.sh pulseaudio - ``` - Then run with: ``` $ ./build_linux/src/freedv ``` @@ -87,10 +72,6 @@ You need to install the codec2 and lpcnetfreedv shared libraries, and freedv-gui $ sudo ldconfig ``` -## Generating Debian packages - -To generate a Debian/Ubuntu package, simply run the "cpack" command after running "make". The resulting .deb file can then be installed by running "dpkg -i" (once Codec2 and LPCNet packages are also installed). - ## Testing The ```wav``` directory contains test files of modulated audio that you can use to test FreeDV (see the [USER_MANUAL](USER_MANUAL.md)). @@ -99,49 +80,6 @@ The ```wav``` directory contains test files of modulated audio that you can use The Windows build process has been automated using a Docker container, see the freedv-gui Docker [README](docker/README_docker.md). -## Building for Windows on Fedora (Cross compiling) - -Install basic MinGW development packages: -``` - $ sudo dnf install mingw{32,64}-filesystem mingw{32,64}-binutils \ - mingw{32,64}-gcc mingw{32,64}-crt mingw{32,64}-headers mingw32-nsis -``` - -Install dependencies of FreeDV/Codec2: -``` - $ sudo dnf install mingw{32,64}-speex -``` - -Enable Freetel specific packages not currently in Fedora proper: -``` - $ sudo dnf install dnf-plugins-core - $ sudo dnf copr enable hobbes1069/mingw - $ sudo dnf install mingw{32,64}-wxWidgets3 mingw{32,64}-hamlib \ - mingw{32,64}-portaudio mingw{32,64}-libsndfile mingw{32,64}-libsamplerate.noarch -``` - -Clone freedv-gui: -``` - $ cd - $ git clone https://github.com/drowe67/freedv-gui.git -``` - -Building FreeDV for 64 Bit windows: -``` - $ cd ~/freedv-gui - $ ./build_windows.sh - $ cd build_win64 - $ make package -``` - -**OR** Building FreeDV for 32 Bit windows: -``` - $ cd ~/freedv-gui - $ CMAKE=mingw32-cmake ./build_windows.sh - $ cd build_win32 - $ make package -``` - ### Building FreeDV using LLVM MinGW (EXPERIMENTAL) It is now possible to use the LLVM version of MinGW to build FreeDV. This allows @@ -200,12 +138,6 @@ $ sudo port install subversion git libtool sox +universal cmake It should be fairly similar using HomeBrew, but you will need to replace all the /opt/ paths in the following instructions. -Note: If using an ARM Mac, you may need to build and install the Git version of MacPorts first. See https://guide.macports.org/#installing.macports.git for more details on how to do this. - Once the dependencies are installed, you can then run the `build_osx.sh` script inside the source tree to build FreeDV and associated libraries (codec2, LPCNet, hamlib). A FreeDV.app app bundle will be created inside the build_osx/src folder which can be copied to your system's Applications folder. - -## Building and installing on FreeBSD - -In ```build_linux.sh``` change the ```build_linux``` directory to build_freebsd. diff --git a/USER_MANUAL.md b/USER_MANUAL.md index df502b8f5..e05be37a3 100644 --- a/USER_MANUAL.md +++ b/USER_MANUAL.md @@ -918,6 +918,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes * End support for 32 bit ARM on Windows. (PR #651) 4. Documentation: * Fix spelling, etc. mistakes in the documentation. (PR #640) + * Update README to reflect latest state of codebase. (PR #654) 5. Code cleanup: * Move GUI related files into their own folder. (PR #654) * Move build scripts into cmake folder. (PR #654) From 1f77849a0248a5ccf1394ac4f11a4ce0a0e1ae63 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:04:17 -0800 Subject: [PATCH 09/25] Adjust README headings. --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 4386202b9..6b20cd62b 100644 --- a/README.md +++ b/README.md @@ -76,11 +76,13 @@ You need to install the codec2 and lpcnetfreedv shared libraries, and freedv-gui The ```wav``` directory contains test files of modulated audio that you can use to test FreeDV (see the [USER_MANUAL](USER_MANUAL.md)). -## Building for Windows using Docker +## Building for Windows + +### Building using Docker The Windows build process has been automated using a Docker container, see the freedv-gui Docker [README](docker/README_docker.md). -### Building FreeDV using LLVM MinGW (EXPERIMENTAL) +### Building LLVM MinGW (EXPERIMENTAL) It is now possible to use the LLVM version of MinGW to build FreeDV. This allows one to build FreeDV for ARM as well as for Intel Windows systems, including support From 3769d0cd884a00ae5f729ecd1897093ae8d34cbc Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:06:15 -0800 Subject: [PATCH 10/25] Attempt to fix GitHub CI errors. --- src/gui/controls/plot_scalar.cpp | 2 ++ src/gui/controls/plot_scalar.h | 2 ++ src/gui/controls/plot_scatter.h | 2 ++ src/gui/controls/plot_spectrum.h | 2 ++ src/gui/controls/plot_waterfall.h | 2 ++ 5 files changed, 10 insertions(+) diff --git a/src/gui/controls/plot_scalar.cpp b/src/gui/controls/plot_scalar.cpp index 353f00293..9442f643a 100644 --- a/src/gui/controls/plot_scalar.cpp +++ b/src/gui/controls/plot_scalar.cpp @@ -21,6 +21,8 @@ #include #include +#include + #include "plot_scalar.h" BEGIN_EVENT_TABLE(PlotScalar, PlotPanel) diff --git a/src/gui/controls/plot_scalar.h b/src/gui/controls/plot_scalar.h index 2de14fdd6..b4c4cd1b9 100644 --- a/src/gui/controls/plot_scalar.h +++ b/src/gui/controls/plot_scalar.h @@ -21,6 +21,8 @@ #ifndef __FDMDV2_PLOT_SCALAR__ #define __FDMDV2_PLOT_SCALAR__ +#include + #include "plot.h" #include "defines.h" diff --git a/src/gui/controls/plot_scatter.h b/src/gui/controls/plot_scatter.h index 2f526e644..bb494e979 100644 --- a/src/gui/controls/plot_scatter.h +++ b/src/gui/controls/plot_scatter.h @@ -21,6 +21,8 @@ #ifndef __FDMDV2_PLOT_SCATTER__ #define __FDMDV2_PLOT_SCATTER__ +#include + #include "comp.h" #include "plot.h" #include "../../defines.h" diff --git a/src/gui/controls/plot_spectrum.h b/src/gui/controls/plot_spectrum.h index 5dece6f12..f227b2ed1 100644 --- a/src/gui/controls/plot_spectrum.h +++ b/src/gui/controls/plot_spectrum.h @@ -21,6 +21,8 @@ #ifndef __FDMDV2_PLOT_SPECTRUM__ #define __FDMDV2_PLOT_SPECTRUM__ +#include + #include "plot.h" #include "../../defines.h" diff --git a/src/gui/controls/plot_waterfall.h b/src/gui/controls/plot_waterfall.h index f03edb00b..0d1fef521 100644 --- a/src/gui/controls/plot_waterfall.h +++ b/src/gui/controls/plot_waterfall.h @@ -21,6 +21,8 @@ #ifndef __FDMDV2_PLOT_WATERFALL__ #define __FDMDV2_PLOT_WATERFALL__ +#include + #include "plot.h" #include "../../defines.h" From 4f72766328e3b142941db9c74bfa99e7a8359749 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:16:37 -0800 Subject: [PATCH 11/25] Include experimental macOS GitHub Action. --- .github/workflows/cmake-macos.yml | 32 +++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/cmake-macos.yml diff --git a/.github/workflows/cmake-macos.yml b/.github/workflows/cmake-macos.yml new file mode 100644 index 000000000..7360a883e --- /dev/null +++ b/.github/workflows/cmake-macos.yml @@ -0,0 +1,32 @@ +name: Build FreeDV (macOS) + +on: + push: + branches-ignore: + - 'dr-render-manual' + +env: + # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) + BUILD_TYPE: Debug + +jobs: + build: + # The CMake configure and build commands are platform agnostic and should work equally + # well on Windows or Mac. You can convert this to a matrix build if you need + # cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + + - name: Build freedv-gui + shell: bash + working-directory: ${{github.workspace}} + run: UT_ENABLE=1 ./build_osx.sh + + - name: Execute unit tests + shell: bash + working-directory: ${{github.workspace}}/build_osx + run: make test + From 94274c1728b5683aba31c4d3101d27f8c86707e3 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:16:45 -0800 Subject: [PATCH 12/25] Additional README fixes. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 6b20cd62b..a58594a1b 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ This document describes how to build the FreeDV GUI program for various operatin ``` $ sudo apt install libspeexdsp-dev libsamplerate0-dev sox git \ - libwxgtk3.0-gtk3-dev libhamlib-dev libasound2-dev libao-dev \ + libwxgtk3.2-dev libhamlib-dev libasound2-dev libao-dev \ libgsm1-dev libsndfile1-dev cmake module-assistant build-essential $ git clone https://github.com/drowe67/freedv-gui.git $ cd freedv-gui @@ -102,7 +102,7 @@ for 2020 mode (on systems fast enough to acceptably decode it). 3. Add LLVM MinGW to your PATH: `export PATH=/path/to/llvm-mingw-20220906-ucrt-ubuntu-18.04-x86_64/bin:$PATH`. (The folder containing the LLVM tools is typically named the same as the file downloaded in step (2) minus the extension.) 4. Create a build folder inside freedv-gui: `mkdir build_windows` 5. Run CMake to configure the FreeDV build: `cd build_windows && cmake -DCMAKE_TOOLCHAIN_FILE=${PWD}/../cross-compile/freedv-mingw-llvm-[architecture].cmake ..` - * Valid architectures are: aarch64, armv7, i686, x86_64 + * Valid architectures are: aarch64 (64 bit ARM), i686 (32 bit Intel/AMD), x86_64 (64 bit Intel/AMD) 6. Build FreeDV as normal: `make` (You can also add `-j[num]` to the end of this command to use multiple cores and shorten the build time.) 7. Create FreeDV installer: `make package` From 912041ea6dfb5f5d33bd36e001eb2f683157ed00 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:22:17 -0800 Subject: [PATCH 13/25] GitHub environment needs a few more packages. --- .github/workflows/cmake-macos.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/cmake-macos.yml b/.github/workflows/cmake-macos.yml index 7360a883e..fcfc25c3c 100644 --- a/.github/workflows/cmake-macos.yml +++ b/.github/workflows/cmake-macos.yml @@ -20,6 +20,11 @@ jobs: steps: - uses: actions/checkout@v2 + - name: Install packages + shell: bash + working-directory: ${{github.workspace}} + run: sudo brew install automake libtool + - name: Build freedv-gui shell: bash working-directory: ${{github.workspace}} From 64a5fe4e030847a1facc12c0e4a247bab96640cd Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:22:41 -0800 Subject: [PATCH 14/25] Some more README cleanup for macOS. --- README.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a58594a1b..559d0bf1c 100644 --- a/README.md +++ b/README.md @@ -136,9 +136,15 @@ Testing FreeDV API: Using MacPorts, most of the appropriate dependencies can be installed by: -$ sudo port install subversion git libtool sox +universal cmake +``` +$ sudo port install automake git libtool sox +universal cmake +``` + +and on Homebrew: -It should be fairly similar using HomeBrew, but you will need to replace all the /opt/ paths in the following instructions. +``` +$ sudo brew install automake libtool git sox cmake +``` Once the dependencies are installed, you can then run the `build_osx.sh` script inside the source tree to build FreeDV and associated libraries (codec2, LPCNet, hamlib). A FreeDV.app app bundle will be created inside the build_osx/src From aada4b2b7503e0084ba5805e708c6251c06e1c2c Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:23:58 -0800 Subject: [PATCH 15/25] brew can't run as root. --- .github/workflows/cmake-macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake-macos.yml b/.github/workflows/cmake-macos.yml index fcfc25c3c..6af984e9f 100644 --- a/.github/workflows/cmake-macos.yml +++ b/.github/workflows/cmake-macos.yml @@ -23,7 +23,7 @@ jobs: - name: Install packages shell: bash working-directory: ${{github.workspace}} - run: sudo brew install automake libtool + run: brew install automake libtool - name: Build freedv-gui shell: bash From c6b7383dc2c121307f3f44fff148debf9e85614f Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 13:24:18 -0800 Subject: [PATCH 16/25] Update Homebrew instructions in README. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 559d0bf1c..61a7cdd9b 100644 --- a/README.md +++ b/README.md @@ -143,7 +143,7 @@ $ sudo port install automake git libtool sox +universal cmake and on Homebrew: ``` -$ sudo brew install automake libtool git sox cmake +$ brew install automake libtool git sox cmake ``` Once the dependencies are installed, you can then run the `build_osx.sh` script inside the source tree to build From 5f9e9a0a68a0dad80279ad50b2f261db7b40dc75 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 14:00:49 -0800 Subject: [PATCH 17/25] Fix Windows compiler error. --- src/gui/dialogs/dlg_easy_setup.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gui/dialogs/dlg_easy_setup.cpp b/src/gui/dialogs/dlg_easy_setup.cpp index fc8270a05..8a76a7d81 100644 --- a/src/gui/dialogs/dlg_easy_setup.cpp +++ b/src/gui/dialogs/dlg_easy_setup.cpp @@ -24,6 +24,7 @@ #include #include +#include #include #include "main.h" From 587306f6458d21dce633e1098f314cba697a7d6f Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 14:01:05 -0800 Subject: [PATCH 18/25] Use macOS 13 for GitHub action. --- .github/workflows/cmake-macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake-macos.yml b/.github/workflows/cmake-macos.yml index 6af984e9f..4fdbcd782 100644 --- a/.github/workflows/cmake-macos.yml +++ b/.github/workflows/cmake-macos.yml @@ -15,7 +15,7 @@ jobs: # well on Windows or Mac. You can convert this to a matrix build if you need # cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix - runs-on: macos-latest + runs-on: macos-13 steps: - uses: actions/checkout@v2 From c3e2464addebf7471476659a251e57269c907231 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 19:12:59 -0800 Subject: [PATCH 19/25] Don't include -ld_classic if not compiling on an old enough macOS. --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2999ac82f..50e946801 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,7 +33,9 @@ if(APPLE) # Workaround for Xcode 15 bug preventing FreeDV binaries from starting # on older versions of macOS. See https://developer.apple.com/documentation/xcode-release-notes/xcode-15-release-notes#Linking. - add_link_options("-Wl,-ld_classic") + if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 15.0.0.0) + add_link_options("-Wl,-ld_classic") + endif(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 15.0.0.0) else(APPLE) project( ${PROJECT_NAME} From 73df560eb7fac1c78185e1b9561804f6f21691ab Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 19:13:22 -0800 Subject: [PATCH 20/25] Go back to using macos-latest. --- .github/workflows/cmake-macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake-macos.yml b/.github/workflows/cmake-macos.yml index 4fdbcd782..6af984e9f 100644 --- a/.github/workflows/cmake-macos.yml +++ b/.github/workflows/cmake-macos.yml @@ -15,7 +15,7 @@ jobs: # well on Windows or Mac. You can convert this to a matrix build if you need # cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix - runs-on: macos-13 + runs-on: macos-latest steps: - uses: actions/checkout@v2 From e462cd4060d2d1f52b017be77b2237802d2cf706 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 22:08:26 -0800 Subject: [PATCH 21/25] Ignore libsamplerate UT. --- CMakeLists.txt | 3 +++ build_osx.sh | 2 +- cmake/BuildSamplerate.cmake | 2 ++ cmake/CTestCustom.cmake | 16 ++++++++++++++++ 4 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 cmake/CTestCustom.cmake diff --git a/CMakeLists.txt b/CMakeLists.txt index 50e946801..cf8ee20d3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -78,6 +78,9 @@ message(STATUS "Compilation date = XX${DATE_RESULT}XX") # configure_file(cmake/version.h.in src/version.h @ONLY) +# Generate custom CTest config +configure_file(cmake/CTestCustom.cmake ${CMAKE_BINARY_DIR}) + # Set default build type if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Debug") diff --git a/build_osx.sh b/build_osx.sh index c1f4be043..61357947d 100755 --- a/build_osx.sh +++ b/build_osx.sh @@ -62,5 +62,5 @@ if [ -d .git ]; then git pull fi mkdir -p build_osx && cd build_osx && rm -Rf * -cmake -DBUILD_OSX_UNIVERSAL=1 -DCMAKE_BUILD_TYPE=Debug -DBOOTSTRAP_WXWIDGETS=1 -DUSE_STATIC_SPEEXDSP=1 -DUSE_STATIC_PORTAUDIO=1 -DUSE_STATIC_SAMPLERATE=1 -DUSE_STATIC_SNDFILE=1 -DHAMLIB_INCLUDE_DIR=${HAMLIBDIR}/include -DHAMLIB_LIBRARY=${HAMLIBDIR}/lib/libhamlib.dylib -DCODEC2_BUILD_DIR=$CODEC2DIR/build_osx -DLPCNET_BUILD_DIR=$LPCNETDIR/build_osx .. +cmake -DBUILD_OSX_UNIVERSAL=1 -DUNITTEST=$UT_ENABLE -DCMAKE_BUILD_TYPE=Debug -DBOOTSTRAP_WXWIDGETS=1 -DUSE_STATIC_SPEEXDSP=1 -DUSE_STATIC_PORTAUDIO=1 -DUSE_STATIC_SAMPLERATE=1 -DUSE_STATIC_SNDFILE=1 -DHAMLIB_INCLUDE_DIR=${HAMLIBDIR}/include -DHAMLIB_LIBRARY=${HAMLIBDIR}/lib/libhamlib.dylib -DCODEC2_BUILD_DIR=$CODEC2DIR/build_osx -DLPCNET_BUILD_DIR=$LPCNETDIR/build_osx .. make VERBOSE=1 -j8 diff --git a/cmake/BuildSamplerate.cmake b/cmake/BuildSamplerate.cmake index 90cc58557..3af6d8828 100644 --- a/cmake/BuildSamplerate.cmake +++ b/cmake/BuildSamplerate.cmake @@ -1,5 +1,7 @@ set(SAMPLERATE_VERSION "0.2.2") +set(BUILD_TESTING OFF CACHE BOOL "Enable unit tests for libsamplerate") + include(FetchContent) FetchContent_Declare( samplerate diff --git a/cmake/CTestCustom.cmake b/cmake/CTestCustom.cmake new file mode 100644 index 000000000..40af941eb --- /dev/null +++ b/cmake/CTestCustom.cmake @@ -0,0 +1,16 @@ +# Set of tests to ignore. On some platforms, libsamplerate's tests somehow get included +# with our own, so it causes problems with e.g. CI builds to keep these. +set(CTEST_CUSTOM_TESTS_IGNORE + misc_test + termination_test + callback_hang_test + downsample_test + simple_test + callback_test + reset_test + clone_test + nullptr_test + multi_channel_test + varispeed_test + float_short_test + snr_bw_test) \ No newline at end of file From 2926c84a083512a8f122588fc7d22b9c886d2bbd Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 22:20:00 -0800 Subject: [PATCH 22/25] Move changelog to separate file. --- CHANGELOG_OLD.md | 355 +++++++++++++++++++++++++++++++++++++++++++++++ USER_MANUAL.md | 355 +---------------------------------------------- 2 files changed, 358 insertions(+), 352 deletions(-) create mode 100644 CHANGELOG_OLD.md diff --git a/CHANGELOG_OLD.md b/CHANGELOG_OLD.md new file mode 100644 index 000000000..224aab08b --- /dev/null +++ b/CHANGELOG_OLD.md @@ -0,0 +1,355 @@ +# Changes in older releases + +## V1.8.12 July 2023 + +1. Bugfixes: + * Clear audio plots when recording or playback starts. (PR #439) + * Clear button now clears the callsign list. (PR #436) + * Fix bug causing the PTT button to stay red after the voice keyer finishes TX. (PR #440) + * Fix FreeDV Reporter crash when sending RX record. (PR #443) + * Hamlib: set mode before frequency to avoid accidental offsetting. (PR #442, #452) + * Fix audio dialog plot display and lockup issues. (PR #450) + * Disable PTT and Voice Keyer buttons if only RX devices are configured. (PR #449) + * Fix Linux display bugs when switching between dark and light mode. (PR #454) +2. Enhancements: + * Add the ability to request that another FreeDV Reporter user QSY. + (PR #434, #453, #456, #458, #459, #467, #468) + * Display 'Digital' on button when Analog mode is active. (PR #447) + * Set minimum size for Mode box to 250px. (PR #446) + * Notify FreeDV Reporter if only capable of RX. (PR #449) + * Hamlib: allow frequency and mode changes during TX. (PR #455) + * Save and restore size and position of FreeDV Reporter window on startup. (PR #462) + * Auto-size columns in Audio Options to improve readability. (PR #461) + * Add support for modifying the drop down frequency list. (PR #460) + * Preserve size and position of Audio Configuration dialog. (PR #466) + * Add ability to suppress automatic frequency reporting on radio changes. (PR #469) +3. Build system: + * Bump Codec2 version to v1.1.1. (PR #437) + * Generate PDF/HTML docs only on PR merge. (PR #471) +4. Documentation + * Add RF bandwidth information to user manual. (PR #444) +5. Cleanup: + * Refactor configuration handling in the codebase. (PR #457, #474) + * Clean up compiler warnings on Windows builds. (PR #475) +6. Miscellaneous: + * Set default FreeDV Reporter hostname to qso.freedv.org. (PR #448) + +*Note for Windows users: you may receive a one-time error message on startup +after upgrading from v1.8.12-20230705 indicating that certain Registry keys +have incorrect types. This is expected as part of the bugfix merged in PR #474.* + +## V1.8.11 June 2023 + +1. Bugfixes: + * Add missed captures for pavucontrol related handlers. (PR #420) + * Fix issue causing intermittent failures to report the current frequency to FreeDV Reporter. (PR #421) + * Set initial audio device count on startup. (PR #422) + * Make sure focus isn't on the Report Frequency text box immediately after starting. (PR #430) +2. Enhancements: + * Add option to enable/disable Hamlib frequency/mode control. (PR #424, #427) + * Add option to enable/disable Space key for PTT. (PR #425) + * Turn PTT button red when transmitting. (PR #423) + +## V1.8.10.1 June 2023 + +1. Bugfixes: + * Fix bug with FreeDV Reporter going out of sync with radio. (PR #408) + * Allow frequency to be changed even if mode change fails. (PR #408) + * Only change mode, not frequency, when going in/out of Analog mode. (PR #414) + * Fix crash when repeatedly switching in and out of Analog mode. (PR #413) + +## V1.8.10 June 2023 + +1. Build system: + * Minimum required Codec2 version bumped up to 1.1.0. (PR #383) + * Disable libusb support for Hamlib on all platforms, not just Windows. (PR #387) + * Build Hamlib as a dynamic library on Windows and macOS. (PR #395) +2. Bugfixes: + * Fix incorrect assertion causing crash on certain systems without a microphone. (PR #384) + * Shrink sliders so that the Filter window can fit on a 720p display. (PR #386, #396) + * Hamlib: use RIG_VFO_CURR if explicit VFO doesn't work. (PR #385, #400) + * Fix various misspellings in codebase. (PR #392) + * Prevent Start/Stop button from being pressed twice in a row during shutdown. (PR #399) +3. Enhancements: + * Add last received SNR to callsign list. (PR #389, #391) + * Add support for FreeDV Reporter web-based tool. (PR #390, #402, #404) + * Defer sound device checking until Start is pushed. (PR #393) + * Add ability for Hamlib to use RTS/DTR instead of CAT for PTT. (PR #394) + * Automatically change radio frequency if the reporting frequency changes. (PR #405) + +## V1.8.9 April 2023 + +1. Enhancements: + * Add 20% buffer for systems that are marginally able to decode 2020. (PR #355) + * Enable RTS and DTR for PTT input to provide a voltage source for some footswitches. (PR #354) + * Show previously received callsigns in main window. (PR #362, #378) + * Add Record button to the main window to easily allow recording of the incoming signal. (PR #369) + * Open GitHub releases page if Check For Updates is selected. (PR #382) +2. Bugfixes: + * Fix typo preventing use of Easy Setup when not having a radio configured. (PR #359) + * Fix issue preventing Yaesu sound devices from appearing in Easy Setup. (PR #371) + * Fix crash on Windows after resizing the window to hide the waterfall. (PR #366, #375) + * Use /dev/cu.* instead of /dev/tty.* on macOS. (PR #377) + * Hamlib: avoid use of rig_get_vfo() for radios with only one VFO. (PR #376) + * Prevent status bar text from truncating unless required. (PR #379) + * Prevent devices from rearranging if one disappears. (PR #381) + * Remove record completion popups to align with file playback behavior. (PR #380) +3. Build system: + * GitHub action now uses LLVM MinGW for pull requests. (PR #360) + * Update Speex/Hamlib build code to avoid unnecessary rebuilds. (PR #361) + * Upgrade Hamlib to version 4.5.5. (PR #361) + * Fix typo preventing proper naming of installers for test builds. (PR #363) + * macOS builds should also not use Hamlib master. (PR #364) +4. Cleanup: + * Remove 'Split' button from UI. (PR #372) + * Remove dead code for RX/TX loopback buttons. (PR #372) + +## V1.8.8.1 March 2023 + +1. Bugfixes: + * Downgrade Hamlib for Windows and macOS due to PTT and CAT control bugs on various radios. (PR #357) + +## V1.8.8 March 2023 + +1. Bugfixes: + * Resolve compile failure in EasySetupDialog on openSUSE. (PR #344) + * Prevent Mode box from auto-resizing to avoid unexpected movement of other controls. (PR #347) +2. Build system: + * CPack: Properly handle the case where FREEDV_HASH doesn't exist. (PR #345) +3. Enhancements: + * Show friendlier error if serial ports can't be opened. (PR #348) + * Use same VFO retrieval mechanism for PTT as with frequency sync. (PR #350) + * Tweak PSK Reporter handling to report received callsigns more quickly. (PR #352) + +## V1.8.7 January 2023 + +1. Code Cleanup: + * Remove "force sync" option from Tools->Options (PR #332) +2. Enhancements: + * Add "Easy Setup" dialog to simplify first time setup. (PR #189) +3. Bugfixes: + * Add a bit of extra space for the sample rate drop-downs. (PR #336) + * Add units for SNR gauge to match squelch gauge. (PR #339) + * Fix compiler errors due to recent samplerate changes. (PR #338) + * Fix inability to change to certain FreeDV modes for transmit. (PR #340) + +## V1.8.6 December 2022 + +1. Build system: + * Suppress documentation generation when tagging releases. (PR #314) + * Simplify build to reduce need for build scripts. (PR #305, #329, #331) +2. Bugfixes: + * Filter out non-MME devices to match previous behavior. (PR #318) + * Use 64 bit int for frequency to enable reporting microwave frequencies. (PR #325, #331) + * Resolves issue with minimum button sizing in the Filter dialog. (PR #326, #331) + * Update labeling of clipping and BPF options to match actual behavior. (PR #319) + * Adjusts positioning and spacing of controls in the Options dialog to prevent truncation. (PR #328, #331) +3. Enhancements: + * Add 2020B to multi-RX feature to enable RX and TX without restarting session. (PR #312) + * Hide modes not on the SM1000 by default. (PR #313) + * Increase the default Record From Modulator time to 60 seconds. (PR #321) +4. Code Cleanup: + * Adjusted function prototypes to use bool instead of int. (PR #316) + +## V1.8.5 December 2022 + +1. Build system: + * Add checks for .git folder to prevent errors when building from official release tarballs. (PR #294) + * Simplify PortAudio static build to fix multi-core build issue on macOS. (PR #304, #308) + * Upgrade bootstrapped wxWidgets to v3.2.1. (PR #302) + * Upgrade Docker container to Fedora 37. (PR #306) +2. Enhancements: + * Update FreeDV configuration defaults to improve first-time usability. (PR #293) +3. Bugfixes: + * Fix issue preventing macOS binaries from running on releases older than 12.0. (PR #301) + * Fix issue with 2020B not being selected as default on next start (PR #299) +4. Documentation: + * Update manual to reflect Ubuntu renaming libsndfile-dev to libsnd1file-dev. (PR #297) + +## V1.8.4 October 2022 + +1. Build system: + * Updates to reflect LPCNet decoupling from Codec2 (PR #274) +2. Bugfixes: + * Add missed UI disable on startup for 2020B mode. (PR #279) + * Fixed TX audio dropouts when using different sample rates. (PR #287) + * Remove sample rates above 48K from audio configuration. (PR #288) +3. Enhancements: + * Add alternate method of determining 2020 support for non-x86 machines. (PR #280) + * Remove unnecessary BW and DPSK options from UI. (PR #283) + * Stats on left hand side of main window now auto-reset after user-configurable time period (default 10s). (PR #262, #286) + +## V1.8.3.1 August 2022 + +1. Build system: + * Fix issue preventing patch version from being passed to Windows installer. (PR #271) + +## V1.8.3 August 2022 + +1. Build system: + * Build Git version of Hamlib for Windows builds. (PR #261) + * Remove build date and time from libsox. (PR #267) + * Refactor CMakeList.txt using newer project format. (PR #268) +1. Enhancements: + * Update frequency and mode display every 5 sec. (PR #266) + +## V1.8.2 July 2022 + +1. Enhancements: + * Save rig names instead of IDs to prevent Hamlib off by one issues. (PR #256) +2. Bugfixes: + * Increase plot buffer size to resolve issues with "To Spkr/Headphones" tab (PR #258) +3. Build system: + * Depend on Codec2 1.0.5. (PR #259) + +## V1.8.1 July 2022 + +1. Bugfixes: + * Disable 2020B unless the installed Codec2 provides it. (PR #257) +2. Build system: + * Update build scripts to use specific Codec2 and LPCNet versions. (PR #257) + +## V1.8.0 July 2022 + +1. Enhancements: + * PSK Reporter: Encodes callsign regardless of whether the internet is working. (PR #214) + * PSK Reporter: Sends report upon pushing Stop (vs. simply clearing the report list). (PR #214) + * PSK Reporter: Performs reporting in background instead of hanging the caller of the PskReporter class. (PR #214) + * PSK Reporter: Suppress reporting if we're playing back a radio file (to avoid false reports). (PR #214) + * Filter dialog: Increase length of vertical sliders to simplify fine-tuning. (PR #224) + * Modem compression (Tools-Options-Modem Clipping checkbox) added to FreeDV 2020 for increased RMS power. (PR #211) + * Added experimental 2020B mode. (PR #211) + * Refactored audio handling to use pipeline design pattern. (PR #219) + * Eliminated requirement to use the same audio sample rate for both mic and speaker devices. (PR #219, #234) + * 60 meters shows as USB and not LSB for countries where FreeDV usage is legal on that band. (PR #243) + * Improved audio quality and reduced CPU usage for multi-RX. (PR #246) +2. Build system: + * Add spell checking of codebase on every Git push. (PR #216) + * Build Windows build on every Git push. (PR #220) + * Default branch and repo to the current branch and repo for Docker (or else reasonable defaults). (PR #233) +3. Documentation: + * Removed obsolete references to required sample rates for voice keyer files. (PR #219) + * Add troubleshooting instructions for serial port PTT on Windows. (PR #226) + * Add missing gcc-g++ package to Fedora build instructions. (PR #235) + * Add missing sox package to Fedora build instructions. (PR #241) +4. Bugfixes: + * Suppress refresh of the sync indicator if disabled/no change in sync. (PR #230) + * Clarify location from where to run Docker build script. (PR #231) + * Change shutdown ordering to prevent hangs on slower systems. (PR #236) + * Disable PulseAudio suspend failure due to interactions with pipewire. (PR #239) + +## V1.7.0 February 2022 + +1. Bugfixes: + * Resolves issue with waterfall appearing garbled on some systems. (PR #205) + * Resolves issue with Restore Defaults restoring previous settings on exit. (PR #207) + * Resolves issue with some sound valid sound devices causing PortAudio errors during startup checks. (PR #192) +2. Enhancements: + * Removes requirement to restart FreeDV after using Restore Defaults. (PR #207) + * Hides frequency display on main window unless PSK Reporter reporting is turned on. (PR #207) + * Scales per-mode squelch settings when in multi-RX mode to reduce unwanted noise. (PR #186) + * Single-thread mode is now the default when multi-RX is turned on. (PR #175) + * Makes multi-RX mode the default. (PR #175) + * Mic In/Speaker Out volume controls added to Filter window. (PR #208) + * Cleans up UI for filters and makes the dialog non-modal. (PR #208) + * Adds optional support for PulseAudio on Linux systems. (PR #194) +3. Documentation: + * Adds section on creating Windows shortcuts to handle multiple configurations. (PR #204) + * Resolves issue with PDF image placement. (PR #203) +4. Build System: + * Uses more portable way of referring to Bash in build scripts. (PR #200) + * User manual now installed along with executable. (PR #187) + * macOS app bundle generated by CMake instead of manually. (PR #184) + * Fail as soon as a step in the build script fails. (PR #183) + * Have Windows uninstaller clean up Registry. (PR #182) + * Windows installer now installs sample .wav files. (PR #182) + +## V1.6.1 September 2021 + +1. Bugfixes: + * Uses UTF-8 for device names from PortAudio to resolve display problems on non-English systems. (PR #153) + * Resolves crash when using click to tune feature on main window. (PR #157) + * Resolves issue where test plots inside Audio Options dialog hang during test. (PR #154) + * Disable multi-RX options in Tools->Options when a session is active. (PR #154) + * Resolves buffer overflow when using mono-only TX sound devices. (PR #169) +2. Enhancements: + * Updates mode indicator on transition between TX and RX instead of only on start. (PR #158) + * Updates PSK Reporter feature to use new Codec2 reliable\_text API. (PR #156, #162, #166, #168) + * Suppress unnecessary rig_init() calls to prevent FreeDV from changing the current VFO. (PR #173) + +_Note: The PSK Reporter feature beginning in this release is incompatible with versions older than 1.6.1 due to a change in how callsigns are encoded._ + +## V1.6.0 August 2021 + +1. Bugfixes: + * Suppressed clipping of TX speech when PTT is released. (PR #123) + * Added missing mode labels for 800XA and 2400B as a result of implementing multi-RX in 1.5.3. (PR #128) + * Fixed analog passthrough when using 2400B. (PR #130) + * Fixed non-responsive scroll controls on macOS. (PR #139) + * Auto EQ now working for 800XA. (PR #141) + * Reset scatter plot state when multi-RX switches modes. (PR #146) + * Use selected sound device sample rates for the equalizer controls. (PR #142) +2. Enhancements: + * Frequency ticks moved to the top of the waterfall. (PR #115) + * Optimized rendering code for the waterfall display to improve responsiveness on slower machines. (PR #127, #137) + * Fixed navigation issues encountered while using screen readers. (PR #121) + * Allow main window to expand horizontally for shorter displays. (PR #135, #121) + * Allow autoconversion of voice keyer file to selected TX mode's sample rate. (PR #145) + * Multi-RX: decode each supported mode on its own thread. (PR #129) +3. New features: + * Added support for alternative configuration files by specifying -f/--config options. (PR #119, #125) + * Added support for PTT input, e.g. for foot switches. (PR #136) +4. Build system: + * Use MacPorts/Homebrew PortAudio for macOS builds. (PR #134, #138) + * Bootstrapped wxWidgets now uses version 3.1.5. (PR #147) + * Added support for bootstrapped wxWidgets on Windows builds. (PR #124) + * Updated Docker container for Windows builds to Fedora 34. (PR #124) + * Created "make dist" target for easy tarball generation. (PR #152) + +## V1.5.3 April 2021 + +1. Simultaneous decode of 2020, 1600 and 700C/D/E (without needing to push Stop first, change the mode and push Start again). +2. Dynamic switching of the current Tx mode between the aforementioned modes, again without needing to restart the session. +3. A Tx level slider on the right hand side of the main screen to fine-tune transmit output (to more easily avoid clipping ALC and conflicting with other soundcard ham radio applications). + +## V1.5.2 January 2021 + +1. Updates storage for sound card configuration to use device names instead of IDs. +2. Detects changes to computer sound card configuration and notifies user when devices go away. + +## V1.5.1 January 2021 + +1. Experimental support for reporting to [PSK Reporter](https://pskreporter.info) added. +2. Bug fixes with audio configuration to allow mono devices to be used along with stereo ones. +3. Tweaks to user interface and record/playback functionality to improve usability. +4. Bug fixes and tweaks to improve voice keyer support. + +## V1.5.0 December 2020 + +1. FreeDV 700E, better performance than 700D on fast fading channels +1. FreeDV 700D/700E clipper to increase average transmit power by 6dB + +## V1.4.3 August 2020 + +1. Maintenance Release (no major new features) +1. Changes to support wxWidgets 3.1 (but Windows versions built against wxWidgets 3.0) +1. Under the hood - OFDM modem has been refactored, shouldn't affect freedv-gui operation + +## V1.4.2 July 2020 + +1. Maintenance Release (no major new features) +1. Improved squelch/audio pass through on 700D/2020/2400B +1. Under the hood - Codec2 library has been refactored, shouldn't affect freedv-gui operation +1. Removed Project Horus support (now being maintained outside of Codec2/FreeDV) + +## V1.4 June-October 2019 + +1. FreeDV 2020, Project Horus Binary Modes. +1. [Improved OFDM Modem Acquisition](http://www.rowetel.com/?p=6824), this will improve sync time on FreeDV 700D and 2020 on HF fading channels, and can also handle +/- 60 Hz frequency offsets when tuning. +1. Fixed FreeDV 700C frequency offset bug fix, was losing sync at certain frequency offsets. +1. Wide bandwidth phase estimation and DPSK for OFDM modes (700D/2020) for fast fading/QO-100 channels (Tools-Options) +1. Better speech quality on FreeDV 700C/700D with Auto equaliser (Tools-Filter) + +## V1.3 May 2018 + +* FreeDV 700D diff --git a/USER_MANUAL.md b/USER_MANUAL.md index e05be37a3..146ae37fb 100644 --- a/USER_MANUAL.md +++ b/USER_MANUAL.md @@ -919,6 +919,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes 4. Documentation: * Fix spelling, etc. mistakes in the documentation. (PR #640) * Update README to reflect latest state of codebase. (PR #654) + * Move older changelog from user manual to separate file. (PR #654) 5. Code cleanup: * Move GUI related files into their own folder. (PR #654) * Move build scripts into cmake folder. (PR #654) @@ -1075,359 +1076,9 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes *Note: Official Windows releases are now signed using Software Freedom Conservancy's code certificate. To validate that the installers and binary files are properly signed, right-click on the file, choose Properties and go to the 'Digital Signatures' tab.* -## V1.8.12 July 2023 +## Earlier than V1.9.0 -1. Bugfixes: - * Clear audio plots when recording or playback starts. (PR #439) - * Clear button now clears the callsign list. (PR #436) - * Fix bug causing the PTT button to stay red after the voice keyer finishes TX. (PR #440) - * Fix FreeDV Reporter crash when sending RX record. (PR #443) - * Hamlib: set mode before frequency to avoid accidental offsetting. (PR #442, #452) - * Fix audio dialog plot display and lockup issues. (PR #450) - * Disable PTT and Voice Keyer buttons if only RX devices are configured. (PR #449) - * Fix Linux display bugs when switching between dark and light mode. (PR #454) -2. Enhancements: - * Add the ability to request that another FreeDV Reporter user QSY. - (PR #434, #453, #456, #458, #459, #467, #468) - * Display 'Digital' on button when Analog mode is active. (PR #447) - * Set minimum size for Mode box to 250px. (PR #446) - * Notify FreeDV Reporter if only capable of RX. (PR #449) - * Hamlib: allow frequency and mode changes during TX. (PR #455) - * Save and restore size and position of FreeDV Reporter window on startup. (PR #462) - * Auto-size columns in Audio Options to improve readability. (PR #461) - * Add support for modifying the drop down frequency list. (PR #460) - * Preserve size and position of Audio Configuration dialog. (PR #466) - * Add ability to suppress automatic frequency reporting on radio changes. (PR #469) -3. Build system: - * Bump Codec2 version to v1.1.1. (PR #437) - * Generate PDF/HTML docs only on PR merge. (PR #471) -4. Documentation - * Add RF bandwidth information to user manual. (PR #444) -5. Cleanup: - * Refactor configuration handling in the codebase. (PR #457, #474) - * Clean up compiler warnings on Windows builds. (PR #475) -6. Miscellaneous: - * Set default FreeDV Reporter hostname to qso.freedv.org. (PR #448) - -*Note for Windows users: you may receive a one-time error message on startup -after upgrading from v1.8.12-20230705 indicating that certain Registry keys -have incorrect types. This is expected as part of the bugfix merged in PR #474.* - -## V1.8.11 June 2023 - -1. Bugfixes: - * Add missed captures for pavucontrol related handlers. (PR #420) - * Fix issue causing intermittent failures to report the current frequency to FreeDV Reporter. (PR #421) - * Set initial audio device count on startup. (PR #422) - * Make sure focus isn't on the Report Frequency text box immediately after starting. (PR #430) -2. Enhancements: - * Add option to enable/disable Hamlib frequency/mode control. (PR #424, #427) - * Add option to enable/disable Space key for PTT. (PR #425) - * Turn PTT button red when transmitting. (PR #423) - -## V1.8.10.1 June 2023 - -1. Bugfixes: - * Fix bug with FreeDV Reporter going out of sync with radio. (PR #408) - * Allow frequency to be changed even if mode change fails. (PR #408) - * Only change mode, not frequency, when going in/out of Analog mode. (PR #414) - * Fix crash when repeatedly switching in and out of Analog mode. (PR #413) - -## V1.8.10 June 2023 - -1. Build system: - * Minimum required Codec2 version bumped up to 1.1.0. (PR #383) - * Disable libusb support for Hamlib on all platforms, not just Windows. (PR #387) - * Build Hamlib as a dynamic library on Windows and macOS. (PR #395) -2. Bugfixes: - * Fix incorrect assertion causing crash on certain systems without a microphone. (PR #384) - * Shrink sliders so that the Filter window can fit on a 720p display. (PR #386, #396) - * Hamlib: use RIG_VFO_CURR if explicit VFO doesn't work. (PR #385, #400) - * Fix various misspellings in codebase. (PR #392) - * Prevent Start/Stop button from being pressed twice in a row during shutdown. (PR #399) -3. Enhancements: - * Add last received SNR to callsign list. (PR #389, #391) - * Add support for FreeDV Reporter web-based tool. (PR #390, #402, #404) - * Defer sound device checking until Start is pushed. (PR #393) - * Add ability for Hamlib to use RTS/DTR instead of CAT for PTT. (PR #394) - * Automatically change radio frequency if the reporting frequency changes. (PR #405) - -## V1.8.9 April 2023 - -1. Enhancements: - * Add 20% buffer for systems that are marginally able to decode 2020. (PR #355) - * Enable RTS and DTR for PTT input to provide a voltage source for some footswitches. (PR #354) - * Show previously received callsigns in main window. (PR #362, #378) - * Add Record button to the main window to easily allow recording of the incoming signal. (PR #369) - * Open GitHub releases page if Check For Updates is selected. (PR #382) -2. Bugfixes: - * Fix typo preventing use of Easy Setup when not having a radio configured. (PR #359) - * Fix issue preventing Yaesu sound devices from appearing in Easy Setup. (PR #371) - * Fix crash on Windows after resizing the window to hide the waterfall. (PR #366, #375) - * Use /dev/cu.* instead of /dev/tty.* on macOS. (PR #377) - * Hamlib: avoid use of rig_get_vfo() for radios with only one VFO. (PR #376) - * Prevent status bar text from truncating unless required. (PR #379) - * Prevent devices from rearranging if one disappears. (PR #381) - * Remove record completion popups to align with file playback behavior. (PR #380) -3. Build system: - * GitHub action now uses LLVM MinGW for pull requests. (PR #360) - * Update Speex/Hamlib build code to avoid unnecessary rebuilds. (PR #361) - * Upgrade Hamlib to version 4.5.5. (PR #361) - * Fix typo preventing proper naming of installers for test builds. (PR #363) - * macOS builds should also not use Hamlib master. (PR #364) -4. Cleanup: - * Remove 'Split' button from UI. (PR #372) - * Remove dead code for RX/TX loopback buttons. (PR #372) - -## V1.8.8.1 March 2023 - -1. Bugfixes: - * Downgrade Hamlib for Windows and macOS due to PTT and CAT control bugs on various radios. (PR #357) - -## V1.8.8 March 2023 - -1. Bugfixes: - * Resolve compile failure in EasySetupDialog on openSUSE. (PR #344) - * Prevent Mode box from auto-resizing to avoid unexpected movement of other controls. (PR #347) -2. Build system: - * CPack: Properly handle the case where FREEDV_HASH doesn't exist. (PR #345) -3. Enhancements: - * Show friendlier error if serial ports can't be opened. (PR #348) - * Use same VFO retrieval mechanism for PTT as with frequency sync. (PR #350) - * Tweak PSK Reporter handling to report received callsigns more quickly. (PR #352) - -## V1.8.7 January 2023 - -1. Code Cleanup: - * Remove "force sync" option from Tools->Options (PR #332) -2. Enhancements: - * Add "Easy Setup" dialog to simplify first time setup. (PR #189) -3. Bugfixes: - * Add a bit of extra space for the sample rate drop-downs. (PR #336) - * Add units for SNR gauge to match squelch gauge. (PR #339) - * Fix compiler errors due to recent samplerate changes. (PR #338) - * Fix inability to change to certain FreeDV modes for transmit. (PR #340) - -## V1.8.6 December 2022 - -1. Build system: - * Suppress documentation generation when tagging releases. (PR #314) - * Simplify build to reduce need for build scripts. (PR #305, #329, #331) -2. Bugfixes: - * Filter out non-MME devices to match previous behavior. (PR #318) - * Use 64 bit int for frequency to enable reporting microwave frequencies. (PR #325, #331) - * Resolves issue with minimum button sizing in the Filter dialog. (PR #326, #331) - * Update labeling of clipping and BPF options to match actual behavior. (PR #319) - * Adjusts positioning and spacing of controls in the Options dialog to prevent truncation. (PR #328, #331) -3. Enhancements: - * Add 2020B to multi-RX feature to enable RX and TX without restarting session. (PR #312) - * Hide modes not on the SM1000 by default. (PR #313) - * Increase the default Record From Modulator time to 60 seconds. (PR #321) -4. Code Cleanup: - * Adjusted function prototypes to use bool instead of int. (PR #316) - -## V1.8.5 December 2022 - -1. Build system: - * Add checks for .git folder to prevent errors when building from official release tarballs. (PR #294) - * Simplify PortAudio static build to fix multi-core build issue on macOS. (PR #304, #308) - * Upgrade bootstrapped wxWidgets to v3.2.1. (PR #302) - * Upgrade Docker container to Fedora 37. (PR #306) -2. Enhancements: - * Update FreeDV configuration defaults to improve first-time usability. (PR #293) -3. Bugfixes: - * Fix issue preventing macOS binaries from running on releases older than 12.0. (PR #301) - * Fix issue with 2020B not being selected as default on next start (PR #299) -4. Documentation: - * Update manual to reflect Ubuntu renaming libsndfile-dev to libsnd1file-dev. (PR #297) - -## V1.8.4 October 2022 - -1. Build system: - * Updates to reflect LPCNet decoupling from Codec2 (PR #274) -2. Bugfixes: - * Add missed UI disable on startup for 2020B mode. (PR #279) - * Fixed TX audio dropouts when using different sample rates. (PR #287) - * Remove sample rates above 48K from audio configuration. (PR #288) -3. Enhancements: - * Add alternate method of determining 2020 support for non-x86 machines. (PR #280) - * Remove unnecessary BW and DPSK options from UI. (PR #283) - * Stats on left hand side of main window now auto-reset after user-configurable time period (default 10s). (PR #262, #286) - -## V1.8.3.1 August 2022 - -1. Build system: - * Fix issue preventing patch version from being passed to Windows installer. (PR #271) - -## V1.8.3 August 2022 - -1. Build system: - * Build Git version of Hamlib for Windows builds. (PR #261) - * Remove build date and time from libsox. (PR #267) - * Refactor CMakeList.txt using newer project format. (PR #268) -1. Enhancements: - * Update frequency and mode display every 5 sec. (PR #266) - -## V1.8.2 July 2022 - -1. Enhancements: - * Save rig names instead of IDs to prevent Hamlib off by one issues. (PR #256) -2. Bugfixes: - * Increase plot buffer size to resolve issues with "To Spkr/Headphones" tab (PR #258) -3. Build system: - * Depend on Codec2 1.0.5. (PR #259) - -## V1.8.1 July 2022 - -1. Bugfixes: - * Disable 2020B unless the installed Codec2 provides it. (PR #257) -2. Build system: - * Update build scripts to use specific Codec2 and LPCNet versions. (PR #257) - -## V1.8.0 July 2022 - -1. Enhancements: - * PSK Reporter: Encodes callsign regardless of whether the internet is working. (PR #214) - * PSK Reporter: Sends report upon pushing Stop (vs. simply clearing the report list). (PR #214) - * PSK Reporter: Performs reporting in background instead of hanging the caller of the PskReporter class. (PR #214) - * PSK Reporter: Suppress reporting if we're playing back a radio file (to avoid false reports). (PR #214) - * Filter dialog: Increase length of vertical sliders to simplify fine-tuning. (PR #224) - * Modem compression (Tools-Options-Modem Clipping checkbox) added to FreeDV 2020 for increased RMS power. (PR #211) - * Added experimental 2020B mode. (PR #211) - * Refactored audio handling to use pipeline design pattern. (PR #219) - * Eliminated requirement to use the same audio sample rate for both mic and speaker devices. (PR #219, #234) - * 60 meters shows as USB and not LSB for countries where FreeDV usage is legal on that band. (PR #243) - * Improved audio quality and reduced CPU usage for multi-RX. (PR #246) -2. Build system: - * Add spell checking of codebase on every Git push. (PR #216) - * Build Windows build on every Git push. (PR #220) - * Default branch and repo to the current branch and repo for Docker (or else reasonable defaults). (PR #233) -3. Documentation: - * Removed obsolete references to required sample rates for voice keyer files. (PR #219) - * Add troubleshooting instructions for serial port PTT on Windows. (PR #226) - * Add missing gcc-g++ package to Fedora build instructions. (PR #235) - * Add missing sox package to Fedora build instructions. (PR #241) -4. Bugfixes: - * Suppress refresh of the sync indicator if disabled/no change in sync. (PR #230) - * Clarify location from where to run Docker build script. (PR #231) - * Change shutdown ordering to prevent hangs on slower systems. (PR #236) - * Disable PulseAudio suspend failure due to interactions with pipewire. (PR #239) - -## V1.7.0 February 2022 - -1. Bugfixes: - * Resolves issue with waterfall appearing garbled on some systems. (PR #205) - * Resolves issue with Restore Defaults restoring previous settings on exit. (PR #207) - * Resolves issue with some sound valid sound devices causing PortAudio errors during startup checks. (PR #192) -2. Enhancements: - * Removes requirement to restart FreeDV after using Restore Defaults. (PR #207) - * Hides frequency display on main window unless PSK Reporter reporting is turned on. (PR #207) - * Scales per-mode squelch settings when in multi-RX mode to reduce unwanted noise. (PR #186) - * Single-thread mode is now the default when multi-RX is turned on. (PR #175) - * Makes multi-RX mode the default. (PR #175) - * Mic In/Speaker Out volume controls added to Filter window. (PR #208) - * Cleans up UI for filters and makes the dialog non-modal. (PR #208) - * Adds optional support for PulseAudio on Linux systems. (PR #194) -3. Documentation: - * Adds section on creating Windows shortcuts to handle multiple configurations. (PR #204) - * Resolves issue with PDF image placement. (PR #203) -4. Build System: - * Uses more portable way of referring to Bash in build scripts. (PR #200) - * User manual now installed along with executable. (PR #187) - * macOS app bundle generated by CMake instead of manually. (PR #184) - * Fail as soon as a step in the build script fails. (PR #183) - * Have Windows uninstaller clean up Registry. (PR #182) - * Windows installer now installs sample .wav files. (PR #182) - -## V1.6.1 September 2021 - -1. Bugfixes: - * Uses UTF-8 for device names from PortAudio to resolve display problems on non-English systems. (PR #153) - * Resolves crash when using click to tune feature on main window. (PR #157) - * Resolves issue where test plots inside Audio Options dialog hang during test. (PR #154) - * Disable multi-RX options in Tools->Options when a session is active. (PR #154) - * Resolves buffer overflow when using mono-only TX sound devices. (PR #169) -2. Enhancements: - * Updates mode indicator on transition between TX and RX instead of only on start. (PR #158) - * Updates PSK Reporter feature to use new Codec2 reliable\_text API. (PR #156, #162, #166, #168) - * Suppress unnecessary rig_init() calls to prevent FreeDV from changing the current VFO. (PR #173) - -_Note: The PSK Reporter feature beginning in this release is incompatible with versions older than 1.6.1 due to a change in how callsigns are encoded._ - -## V1.6.0 August 2021 - -1. Bugfixes: - * Suppressed clipping of TX speech when PTT is released. (PR #123) - * Added missing mode labels for 800XA and 2400B as a result of implementing multi-RX in 1.5.3. (PR #128) - * Fixed analog passthrough when using 2400B. (PR #130) - * Fixed non-responsive scroll controls on macOS. (PR #139) - * Auto EQ now working for 800XA. (PR #141) - * Reset scatter plot state when multi-RX switches modes. (PR #146) - * Use selected sound device sample rates for the equalizer controls. (PR #142) -2. Enhancements: - * Frequency ticks moved to the top of the waterfall. (PR #115) - * Optimized rendering code for the waterfall display to improve responsiveness on slower machines. (PR #127, #137) - * Fixed navigation issues encountered while using screen readers. (PR #121) - * Allow main window to expand horizontally for shorter displays. (PR #135, #121) - * Allow autoconversion of voice keyer file to selected TX mode's sample rate. (PR #145) - * Multi-RX: decode each supported mode on its own thread. (PR #129) -3. New features: - * Added support for alternative configuration files by specifying -f/--config options. (PR #119, #125) - * Added support for PTT input, e.g. for foot switches. (PR #136) -4. Build system: - * Use MacPorts/Homebrew PortAudio for macOS builds. (PR #134, #138) - * Bootstrapped wxWidgets now uses version 3.1.5. (PR #147) - * Added support for bootstrapped wxWidgets on Windows builds. (PR #124) - * Updated Docker container for Windows builds to Fedora 34. (PR #124) - * Created "make dist" target for easy tarball generation. (PR #152) - -## V1.5.3 April 2021 - -1. Simultaneous decode of 2020, 1600 and 700C/D/E (without needing to push Stop first, change the mode and push Start again). -2. Dynamic switching of the current Tx mode between the aforementioned modes, again without needing to restart the session. -3. A Tx level slider on the right hand side of the main screen to fine-tune transmit output (to more easily avoid clipping ALC and conflicting with other soundcard ham radio applications). - -## V1.5.2 January 2021 - -1. Updates storage for sound card configuration to use device names instead of IDs. -2. Detects changes to computer sound card configuration and notifies user when devices go away. - -## V1.5.1 January 2021 - -1. Experimental support for reporting to [PSK Reporter](https://pskreporter.info) added. -2. Bug fixes with audio configuration to allow mono devices to be used along with stereo ones. -3. Tweaks to user interface and record/playback functionality to improve usability. -4. Bug fixes and tweaks to improve voice keyer support. - -## V1.5.0 December 2020 - -1. FreeDV 700E, better performance than 700D on fast fading channels -1. FreeDV 700D/700E clipper to increase average transmit power by 6dB - -## V1.4.3 August 2020 - -1. Maintenance Release (no major new features) -1. Changes to support wxWidgets 3.1 (but Windows versions built against wxWidgets 3.0) -1. Under the hood - OFDM modem has been refactored, shouldn't affect freedv-gui operation - -## V1.4.2 July 2020 - -1. Maintenance Release (no major new features) -1. Improved squelch/audio pass through on 700D/2020/2400B -1. Under the hood - Codec2 library has been refactored, shouldn't affect freedv-gui operation -1. Removed Project Horus support (now being maintained outside of Codec2/FreeDV) - -## V1.4 June-October 2019 - -1. FreeDV 2020, Project Horus Binary Modes. -1. [Improved OFDM Modem Acquisition](http://www.rowetel.com/?p=6824), this will improve sync time on FreeDV 700D and 2020 on HF fading channels, and can also handle +/- 60 Hz frequency offsets when tuning. -1. Fixed FreeDV 700C frequency offset bug fix, was losing sync at certain frequency offsets. -1. Wide bandwidth phase estimation and DPSK for OFDM modes (700D/2020) for fast fading/QO-100 channels (Tools-Options) -1. Better speech quality on FreeDV 700C/700D with Auto equaliser (Tools-Filter) - -## V1.3 May 2018 - -* FreeDV 700D +See [this](https://github.com/drowe67/codec2/blob/master/CHANGELOG_OLD.md) for more information about changes in versions prior to v1.9.0. # References From 81a36fd88a0d1f70367dfd49eaf5f697548afb71 Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 22:21:22 -0800 Subject: [PATCH 23/25] Add changelog entry for macOS CI builds. --- USER_MANUAL.md | 1 + 1 file changed, 1 insertion(+) diff --git a/USER_MANUAL.md b/USER_MANUAL.md index 146ae37fb..7cdb6b0cd 100644 --- a/USER_MANUAL.md +++ b/USER_MANUAL.md @@ -916,6 +916,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes 3. Build system: * Include PDB debugging file for FreeDV. (PR #633) * End support for 32 bit ARM on Windows. (PR #651) + * Begin performing CI builds for macOS. (PR #654) 4. Documentation: * Fix spelling, etc. mistakes in the documentation. (PR #640) * Update README to reflect latest state of codebase. (PR #654) From fc6f30b6da83fef3197b4b21a2c92ff73414f05b Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 22:24:37 -0800 Subject: [PATCH 24/25] Add Xcode bug fix to changelog. --- USER_MANUAL.md | 1 + 1 file changed, 1 insertion(+) diff --git a/USER_MANUAL.md b/USER_MANUAL.md index fabbc4a62..4e6db180e 100644 --- a/USER_MANUAL.md +++ b/USER_MANUAL.md @@ -908,6 +908,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes * Add guard code to prevent FreeDV Reporter window from being off screen on startup. (PR #650) * Fix issue preventing FreeDV startup on macOS <= 10.13. (PR #652) * On startup, only jiggle height and not width. (PR #653) + * Fix issue preventing FreeDV from being linked with older versions of Xcode. (PR #654) 2. Enhancements: * Allow user to refresh status message even if it hasn't been changed. (PR #632) * Increase priority of status message highlight. (PR #632) From 97ce4cce97a1faee14b97252e2c731f45a016ddf Mon Sep 17 00:00:00 2001 From: Mooneer Salem Date: Sun, 14 Jan 2024 22:31:04 -0800 Subject: [PATCH 25/25] Remove Docker container as it hasn't been used in quite a while. --- README.md | 37 ++-------- build_windows.sh | 60 ---------------- build_windows_old.sh | 32 --------- docker/README_docker.md | 37 ---------- docker/docker-compose-win.yml | 22 ------ docker/fdv_win_fedora/Dockerfile | 25 ------- docker/fdv_win_fedora/entrypoint.sh | 43 ------------ docker/freedv_build_windows.sh | 105 ---------------------------- 8 files changed, 5 insertions(+), 356 deletions(-) delete mode 100755 build_windows.sh delete mode 100755 build_windows_old.sh delete mode 100644 docker/README_docker.md delete mode 100644 docker/docker-compose-win.yml delete mode 100644 docker/fdv_win_fedora/Dockerfile delete mode 100755 docker/fdv_win_fedora/entrypoint.sh delete mode 100755 docker/freedv_build_windows.sh diff --git a/README.md b/README.md index 61a7cdd9b..e8353139a 100644 --- a/README.md +++ b/README.md @@ -78,26 +78,20 @@ The ```wav``` directory contains test files of modulated audio that you can use ## Building for Windows -### Building using Docker - -The Windows build process has been automated using a Docker container, see the freedv-gui Docker [README](docker/README_docker.md). - -### Building LLVM MinGW (EXPERIMENTAL) - -It is now possible to use the LLVM version of MinGW to build FreeDV. This allows +Windows releases are built using the LLVM version of MinGW. This allows one to build FreeDV for ARM as well as for Intel Windows systems, including support for 2020 mode (on systems fast enough to acceptably decode it). -#### Prerequisites +### Prerequisites * CMake >= 3.25.0 * Linux (tested on Ubuntu 22.04) * *NOTE: This does not currently work on macOS due to CMake using incorrect library suffixes.* * NSIS for generating the installer (for example, `sudo apt install nsis` on Ubuntu) -#### Instructions +### Instructions -1. Download LLVM MinGW at https://github.com/mstorsjo/llvm-mingw/releases/tag/20220906. +1. Download LLVM MinGW at https://github.com/mstorsjo/llvm-mingw/releases/. 2. Decompress into your preferred location. For example: `tar xvf llvm-mingw-20220906-ucrt-ubuntu-18.04-x86_64.tar.xz` (The exact filename here will depend on the file downloaded in step (1). Note that for best results, you should use a build containing "ucrt" in the file name corresponding to the platform which you're building the Windows binary from.) 3. Add LLVM MinGW to your PATH: `export PATH=/path/to/llvm-mingw-20220906-ucrt-ubuntu-18.04-x86_64/bin:$PATH`. (The folder containing the LLVM tools is typically named the same as the file downloaded in step (2) minus the extension.) 4. Create a build folder inside freedv-gui: `mkdir build_windows` @@ -106,32 +100,11 @@ for 2020 mode (on systems fast enough to acceptably decode it). 6. Build FreeDV as normal: `make` (You can also add `-j[num]` to the end of this command to use multiple cores and shorten the build time.) 7. Create FreeDV installer: `make package` -#### Known Issues +### Known Issues * NSIS-related issues: * ARM installers will not properly register in Windows despite installing properly. You can still run the application manually by navigating to C:\Program Files\FreeDV \[version\]\ using File Explorer and double-clicking on `freedv.exe`. -### Testing Windows Build - -Conveniently, it is possible to run Windows executables using Wine on Fedora: - -Testing LPCNet: -``` - $ cd ~/freedv-gui/LPCNet/build_win/src - $ WINEPATH=$HOME/freedv-gui/codec2/build_win/src';'$HOME/freedv-gui/build_win/_CPack_Packages/win64/NSIS/FreeDV-1.4.0-devel-win64/bin/ wine lpcnet_enc.exe --infile all.wav --outfile all.bit - $ WINEPATH=$HOME/freedv-gui/codec2/build_win/src';'$HOME/freedv-gui/build_win/_CPack_Packages/win64/NSIS/FreeDV-1.4.0-devel-win64/bin/ wine lpcnet_dec.exe --infile all.bin --outfile all_out.raw - $ cat all_out.raw | aplay -f S16_LE -r 16000 - -``` - -Testing FreeDV API: - -``` - $ cd freedv-gui/codec2/build_win/src - $ WINEPATH=$HOME/freedv-gui/LPCNet/build_win/src';'$HOME/freedv-gui/build_win/_CPack_Packages/win64/NSIS/FreeDV-1.4.0-devel-win64/bin/ wine freedv_rx 2020 ~/freedv-gui/wav/all_2020.wav out.raw - $ play -t .s16 -r 16000 -b 16 out.raw -``` - ## Building and installing on macOS Using MacPorts, most of the appropriate dependencies can be installed by: diff --git a/build_windows.sh b/build_windows.sh deleted file mode 100755 index 3209dd1b5..000000000 --- a/build_windows.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/usr/bin/env bash -# build_windows.sh -# -# Script that cross compiles freedv-gui for Windows on Fedora -# Linux. Git pulls codec2 and LPCNet repos so they are available for -# parallel development. - -# override this at the command line for a 32 bit build -# $ CMAKE=mingw32-cmake ./build_windows.sh -: ${CMAKE=mingw64-cmake} - -UT_ENABLE=${UT_ENABLE:-0} - -if [ $CMAKE = "mingw64-cmake" ]; then - BUILD_DIR=build_win64 - MINGW_TRIPLE=x86_64-w64-mingw32 -else - BUILD_DIR=build_win32 - MINGW_TRIPLE=i686-w64-mingw32 -fi -export FREEDVGUIDIR=${PWD} -export CODEC2DIR=$FREEDVGUIDIR/codec2 -export LPCNETDIR=$FREEDVGUIDIR/LPCNet - -CODEC2_BRANCH=1.2.0 -LPCNET_BRANCH=v0.5 - -# OK, build and test LPCNet -cd $FREEDVGUIDIR -git clone https://github.com/drowe67/LPCNet.git -cd $LPCNETDIR && git switch master && git pull && git checkout $LPCNET_BRANCH -mkdir -p $BUILD_DIR && cd $BUILD_DIR && rm -Rf * -$CMAKE .. -make - -# Build codec2 with LPCNet and test FreeDV 2020 support -# First build and install vanilla codec2 as we need -lcodec2 to build LPCNet -cd $FREEDVGUIDIR -if [ ! -d codec2 ]; then - git clone https://github.com/drowe67/codec2.git -fi -cd codec2 && git switch main && git pull && git checkout $CODEC2_BRANCH -mkdir -p $BUILD_DIR && cd $BUILD_DIR && rm -Rf * && $CMAKE -DLPCNET_BUILD_DIR=$LPCNETDIR/$BUILD_DIR .. && make VERBOSE=1 - -cd $FREEDVGUIDIR -if [ -d .git ]; then - git pull -fi -mkdir -p $BUILD_DIR && cd $BUILD_DIR -if [ $CLEAN -eq 1 ]; then rm -Rf *; fi - -if [ $BOOTSTRAP_WX -eq 1 ]; then - # build freedv-gui - $CMAKE -DBOOTSTRAP_WXWIDGETS=1 -DCMAKE_BUILD_TYPE=Debug -DCODEC2_BUILD_DIR=$CODEC2DIR/$BUILD_DIR -DLPCNET_BUILD_DIR=$LPCNETDIR/$BUILD_DIR .. - make VERBOSE=1 -j4 -else - # build freedv-gui - $CMAKE -DCMAKE_BUILD_TYPE=Debug -DUNITTEST=$UT_ENABLE -DCODEC2_BUILD_DIR=$CODEC2DIR/$BUILD_DIR -DLPCNET_BUILD_DIR=$LPCNETDIR/$BUILD_DIR .. - make VERBOSE=1 -j4 -fi diff --git a/build_windows_old.sh b/build_windows_old.sh deleted file mode 100755 index 741926362..000000000 --- a/build_windows_old.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/usr/bin/env bash -# build_windows_old.sh -# -# Script that cross compiles freedv-gui for Windows on Fedora -# Linux. Git pulls older versions of freedv-gui for test/debug purposes, -# then constructs a zip file for testing. Zips files are convenient -# when testing several versions, as everything is self contained. -# -# usage: ./build_old.sh githash - -export FREEDVGUIDIR=${PWD} -export CODEC2DIR=$FREEDVGUIDIR/codec2 -export LPCNETDIR=$FREEDVGUIDIR/LPCNet -#git checkout $1 -#mkdir -p build_win && cd build_win && rm -Rf * -#make VERBOSE=1 -git checkout dr-debug-vac-3 -#git checkout $1 -cd $FREEDVGUIDIR/build_win -rm -Rf * -# old cmake line -mingw64-cmake -DCMAKE_BUILD_TYPE=Debug -DCODEC2_BUILD_DIR=$CODEC2DIR/build_win -DLPCNET_BUILD_DIR=$LPCNETDIR/build_win .. -make -make package -cd $FREEDVGUIDIR -export zipdir=freedv-gui-$1 -mkdir -p $zipdir -cp -f `find build_win/_CPack_Packages -name *.dll` $zipdir -cp -f `find codec2/build_win/ -name *.dll` $zipdir -cp -f `find LPCNet/build_win/ -name *.dll` $zipdir -cp build_win/src/freedv.exe $zipdir -zip -r $zipdir'.zip' $zipdir diff --git a/docker/README_docker.md b/docker/README_docker.md deleted file mode 100644 index c3676e236..000000000 --- a/docker/README_docker.md +++ /dev/null @@ -1,37 +0,0 @@ -# Building freedv-gui for Windows using Docker on Ubuntu 18 - -## Docker installation -``` -sudo apt install docker docker-compose -sudo systemctl start docker -sudo systemctl enable docker -sudo systemctl status docker -sudo usermod -aG docker $USER - -groups - -docker info -docker container run hello-world -``` - -## Building the docker images -Building is only required once, or if you modify the docker scripts - -``` -cd $FREEDV_GUI/docker -docker-compose -f docker-compose-win.yml build -``` - -## Running the docker image to build Windows installers - -``` -cd $FREEDV_GUI/docker -./freedv_build_windows.sh 64 -./freedv_build_windows.sh 32 -``` - -See `build_log.txt` for a record of the build. More options are available with: - -``` -./freedv_build_windows.sh -h -``` diff --git a/docker/docker-compose-win.yml b/docker/docker-compose-win.yml deleted file mode 100644 index 9d1239d80..000000000 --- a/docker/docker-compose-win.yml +++ /dev/null @@ -1,22 +0,0 @@ -version: "3" - -services: - fdv_win_fed_37_s: - environment: - - FDV_GIT_REPO - - FDV_GIT_BRANCH - - FDV_CLEAN - - FDV_CMAKE - - FDV_BOOTSTRAP_WX - build: - context: fdv_win_fedora - args: - - FED_REL=37 - - image: fdv_win_fed37_i - container_name: 'fdv_win_fed37_c' - volumes: - - win_fed37_v:/home/build/ - -volumes: - win_fed37_v: diff --git a/docker/fdv_win_fedora/Dockerfile b/docker/fdv_win_fedora/Dockerfile deleted file mode 100644 index a90f4b267..000000000 --- a/docker/fdv_win_fedora/Dockerfile +++ /dev/null @@ -1,25 +0,0 @@ -ARG FED_REL=37 - -FROM fedora:${FED_REL} - -# Build & Test Linux: cmake build-essential git libspeexdsp-dev libsamplerate0-dev octave-common octave gnuplot sox ca-cacert octave-signal -# Build OpenOCD: automake libtool libusb-1.0-0-dev wget which? -# Build & Test STM32: libc6-i386 p7zip-full python3-numpy bc -# tar: bzip2 -# arm-none-eabi-gdb: ncurses-compat-libs - -RUN dnf -y install --setopt=install_weak_deps=False @development-tools cmake git speexdsp-devel libsamplerate-devel octave octave-signal gnuplot sox python3-numpy automake libtool libusb1-devel wget bc glibc.i686 which bzip2 gcc gcc-c++ diffutils && useradd -m build - -# specific for windows mingw build -RUN dnf install -y dnf-plugins-core -RUN dnf -y copr enable hobbes1069/mingw -RUN dnf install -y mingw{32,64}-filesystem mingw{32,64}-binutils mingw{32,64}-gcc mingw{32,64}-crt mingw{32,64}-headers mingw32-nsis mingw{32,64}-libusbx-static -RUN dnf install -y mingw{32,64}-speex mingw{32,64}-wxWidgets3 mingw{32,64}-portaudio mingw{32,64}-libsndfile mingw{32,64}-libsamplerate.noarch svn - - -# finally, this is the build script. -COPY entrypoint.sh / - -USER build - -ENTRYPOINT ["/entrypoint.sh"] diff --git a/docker/fdv_win_fedora/entrypoint.sh b/docker/fdv_win_fedora/entrypoint.sh deleted file mode 100755 index f077f52c4..000000000 --- a/docker/fdv_win_fedora/entrypoint.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/bash -x - -BUILDROOT=/home/build -mkdir -p $BUILDROOT -cd $BUILDROOT - -# variables are passed into this Docker process ------------------ - -# note the codec2 and LPCNet repos are hard coded in build_windows.sh -GIT_REPO=${FDV_GIT_REPO:-https://github.com/drowe67/freedv-gui.git} -GIT_BRANCH=${FDV_GIT_BRANCH:-master} - -# override with "mingw32-cmake" for a 32 bit build -CMAKE=${FDV_CMAKE:-mingw64-cmake} - -CLEAN=${FDV_CLEAN:-1} -BOOTSTRAP_WX=${FDV_BOOTSTRAP_WX:-0} - -echo "FDV_GIT_REPO=$GIT_REPO" -echo "FDV_GIT_BRANCH=$GIT_BRANCH" -echo "FDV_CLEAN=$CLEAN" -echo "FDV_CMAKE=$CMAKE" - -if [ $CLEAN -eq 1 ]; then - # start with a fresh clone - rm -Rf freedv-gui; - git clone $GIT_REPO - cd freedv-gui -else - cd freedv-gui - git pull -fi -git checkout $GIT_BRANCH - -echo "--------------------- starting build_windows.sh ---------------------" -CMAKE=$CMAKE BOOTSTRAP_WX=$BOOTSTRAP_WX ./build_windows.sh - -if [ $CMAKE = "mingw64-cmake" ]; then - cd build_win64 -else - cd build_win32 -fi -make package diff --git a/docker/freedv_build_windows.sh b/docker/freedv_build_windows.sh deleted file mode 100755 index 4937b346d..000000000 --- a/docker/freedv_build_windows.sh +++ /dev/null @@ -1,105 +0,0 @@ -#!/bin/bash - -FDV_CURRENT_BRANCH=`git rev-parse --abbrev-ref HEAD 2>/dev/null` -FDV_CURRENT_BRANCH=${FDV_CURRENT_BRANCH:=master} -FDV_CURRENT_REPO=`git remote get-url origin 2>/dev/null` -FDV_CURRENT_REPO=${FDV_CURRENT_REPO:=https://github.com/drowe67/freedv-gui.git} - -function print_help { - echo - echo "Build freedv-gui for Windows using Docker" - echo - echo " usage ./freedv_build_windows.sh [-d] [--noclean] [--build] [--repo GitRepo] [--branch GitBranch] 32|64" - echo - echo " -d debug mode; trace script execution" - echo " --noclean start from a previous build (git pull && make), which is faster for small changes." - echo " The default is a clean build from a fresh git clone (slow but safer)" - echo " --build Update docker image first (run if you have modified the docker scripts in fdv_win_fedora)" - echo " --rebuild Completely recreate docker image first (e.g. run if you have new rpm packages)" - echo " --repo GitRepo (default $FDV_CURRENT_REPO)" - echo " --branch GitBranch (default $FDV_CURRENT_BRANCH)" - echo " --bootstrap-wx Builds wxWidgets from source (may take significantly longer to complete)" - echo - exit -} - -# defaults - these variables are passed to the docker container -FDV_CLEAN=1 -FDV_BUILD=0 -FDV_REBUILD=0 -FDV_GIT_REPO=$FDV_CURRENT_REPO -FDV_GIT_BRANCH=$FDV_CURRENT_BRANCH -FDV_BOOTSTRAP_WX=0 - -POSITIONAL=() -while [[ $# -gt 0 ]]; do -key="$1" -case $key in - -d) - set -x - shift - ;; - --noclean) - FDV_CLEAN=0 - shift - ;; - --build) - FDV_BUILD=1 - shift - ;; - --rebuild) - FDV_REBUILD=1 - shift - ;; - --repo) - FDV_GIT_REPO="$2" - shift - shift - ;; - --branch) - FDV_GIT_BRANCH="$2" - shift - shift - ;; - --bootstrap-wx) - FDV_BOOTSTRAP_WX=1 - shift - ;; - -h|--help) - print_help - ;; - *) - POSITIONAL+=("$1") # save it in an array for later - shift - ;; -esac -done -set -- "${POSITIONAL[@]}" # restore positional parameters - -FDV_CMAKE=mingw64-cmake -if [ $# -eq 1 ]; then - if [ $1 -eq 32 ]; then - FDV_CMAKE=mingw32-cmake - fi -else - print_help -fi - -# create log file -log=build_log.txt -echo > $log - -if [ $FDV_BUILD -eq 1 ]; then - docker-compose -f docker-compose-win.yml build >> $log -fi - -if [ $FDV_REBUILD -eq 1 ]; then - docker-compose -f docker-compose-win.yml rm -f >> $log - docker-compose -f docker-compose-win.yml build --no-cache >> $log -fi - -FDV_CLEAN=$FDV_CLEAN FDV_BOOTSTRAP_WX=$FDV_BOOTSTRAP_WX FDV_CMAKE=$FDV_CMAKE FDV_GIT_REPO=$FDV_GIT_REPO FDV_GIT_BRANCH=$FDV_GIT_BRANCH \ -docker-compose -f docker-compose-win.yml up --remove-orphans >> $log -package_docker_path=$(cat $log | sed -n "s/.*package: \(.*exe\) .*/\1/p") -echo $package_docker_path -docker cp fdv_win_fed37_c:$package_docker_path .