-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sorting out merge conflicts with main, bbfm_sc_internal fails occasio…
…nally so might need tweaking
- Loading branch information
Showing
33 changed files
with
65,628 additions
and
448 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
name: ctests | ||
on: [push] | ||
|
||
jobs: | ||
run_ctests: | ||
name: Running ctests | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-22.04] | ||
python-version: ["3.10"] | ||
|
||
steps: | ||
- name: Checkout radae code | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: drowe67/radae | ||
path: ${{github.workspace}}/radae | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install system packages | ||
shell: bash | ||
run: | | ||
sudo apt update | ||
sudo apt install octave octave-common octave-signal sox cmake git python3.10-dev | ||
- name: Install python packages | ||
shell: bash | ||
run: | | ||
pip3 install torch numpy matplotlib tqdm | ||
- name: Install codec2-dev | ||
shell: bash | ||
# we have to use a hard coded path as it seems "~" isn't support by Github Actions | ||
# using "/home/runner" we seem to link to "~" | ||
working-directory: /home/runner/ | ||
run: | | ||
git clone https://github.com/drowe67/codec2-dev.git | ||
cd codec2-dev | ||
mkdir build_linux | ||
cd build_linux | ||
cmake -DUNITTEST=1 .. | ||
make ch mksine tlininterp | ||
- name: build radae | ||
shell: bash | ||
working-directory: ${{github.workspace}}/radae | ||
run: | | ||
mkdir build | ||
cd build | ||
cmake .. | ||
make | ||
- name: run ctests | ||
shell: bash | ||
working-directory: ${{github.workspace}}/radae/build | ||
run: | | ||
ctest -V --output-on-failure |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,76 @@ | ||
message(STATUS "Will build opus with FARGAN") | ||
|
||
set(CONFIGURE_COMMAND ./autogen.sh && ./configure --enable-dred --disable-shared --disable-doc --disable-extra-programs) | ||
|
||
if (CMAKE_CROSSCOMPILING) | ||
set(CONFIGURE_COMMAND ${CONFIGURE_COMMAND} --host=${CMAKE_C_COMPILER_TARGET} --target=${CMAKE_C_COMPILER_TARGET}) | ||
endif (CMAKE_CROSSCOMPILING) | ||
|
||
set(OPUS_URL https://gitlab.xiph.org/xiph/opus/-/archive/main/opus-main.tar.gz) | ||
|
||
include(ExternalProject) | ||
if(APPLE AND BUILD_OSX_UNIVERSAL) | ||
# Opus ./configure doesn't behave properly when built as a universal binary; | ||
# build it twice and use lipo to create a universal libopus.a instead. | ||
ExternalProject_Add(build_opus_x86 | ||
DOWNLOAD_EXTRACT_TIMESTAMP NO | ||
BUILD_IN_SOURCE 1 | ||
CONFIGURE_COMMAND ${CONFIGURE_COMMAND} --host=x86_64-apple-darwin --target=x86_64-apple-darwin CFLAGS=-arch\ x86_64\ -O2\ -mmacosx-version-min=10.11 | ||
BUILD_COMMAND $(MAKE) | ||
INSTALL_COMMAND "" | ||
URL ${OPUS_URL} | ||
) | ||
ExternalProject_Add(build_opus_arm | ||
DOWNLOAD_EXTRACT_TIMESTAMP NO | ||
BUILD_IN_SOURCE 1 | ||
CONFIGURE_COMMAND ${CONFIGURE_COMMAND} --host=aarch64-apple-darwin --target=aarch64-apple-darwin CFLAGS=-arch\ arm64\ -O2\ -mmacosx-version-min=10.11 | ||
BUILD_COMMAND $(MAKE) | ||
INSTALL_COMMAND "" | ||
URL ${OPUS_URL} | ||
) | ||
|
||
ExternalProject_Get_Property(build_opus_arm BINARY_DIR) | ||
ExternalProject_Get_Property(build_opus_arm SOURCE_DIR) | ||
set(OPUS_ARM_BINARY_DIR ${BINARY_DIR}) | ||
ExternalProject_Get_Property(build_opus_x86 BINARY_DIR) | ||
set(OPUS_X86_BINARY_DIR ${BINARY_DIR}) | ||
|
||
add_custom_command( | ||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libopus${CMAKE_STATIC_LIBRARY_SUFFIX} | ||
COMMAND lipo ${OPUS_ARM_BINARY_DIR}/.libs/libopus${CMAKE_STATIC_LIBRARY_SUFFIX} ${OPUS_X86_BINARY_DIR}/.libs/libopus${CMAKE_STATIC_LIBRARY_SUFFIX} -output ${CMAKE_CURRENT_BINARY_DIR}/libopus${CMAKE_STATIC_LIBRARY_SUFFIX} -create | ||
DEPENDS build_opus_arm build_opus_x86) | ||
|
||
add_custom_target( | ||
libopus.a | ||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/libopus${CMAKE_STATIC_LIBRARY_SUFFIX}) | ||
|
||
include_directories(${SOURCE_DIR}/dnn ${SOURCE_DIR}/celt ${SOURCE_DIR}/include) | ||
|
||
add_library(opus STATIC IMPORTED) | ||
add_dependencies(opus libopus.a) | ||
set_target_properties(opus PROPERTIES | ||
IMPORTED_LOCATION "${CMAKE_CURRENT_BINARY_DIR}/libopus${CMAKE_STATIC_LIBRARY_SUFFIX}" | ||
) | ||
|
||
else(APPLE AND BUILD_OSX_UNIVERSAL) | ||
ExternalProject_Add(build_opus | ||
GIT_REPOSITORY https://gitlab.xiph.org/xiph/opus.git | ||
GIT_TAG main | ||
DOWNLOAD_EXTRACT_TIMESTAMP NO | ||
BUILD_IN_SOURCE 1 | ||
CONFIGURE_COMMAND ./autogen.sh && ./configure --enable-dred --disable-shared | ||
CONFIGURE_COMMAND ${CONFIGURE_COMMAND} | ||
BUILD_COMMAND $(MAKE) | ||
INSTALL_COMMAND "" | ||
URL ${OPUS_URL} | ||
) | ||
|
||
ExternalProject_Get_Property(build_opus BINARY_DIR) | ||
ExternalProject_Get_Property(build_opus SOURCE_DIR) | ||
add_library(opus SHARED IMPORTED) | ||
add_library(opus STATIC IMPORTED) | ||
add_dependencies(opus build_opus) | ||
|
||
set_target_properties(opus PROPERTIES | ||
IMPORTED_LOCATION "${BINARY_DIR}/.libs/libopus${CMAKE_STATIC_LIBRARY_SUFFIX}" | ||
IMPORTED_IMPLIB "${BINARY_DIR}/.libs/libopus${CMAKE_IMPORT_LIBRARY_SUFFIX}" | ||
IMPORTED_IMPLIB "${BINARY_DIR}/.libs/libopus${CMAKE_STATIC_LIBRARY_SUFFIX}" | ||
) | ||
|
||
include_directories(${SOURCE_DIR}/dnn ${SOURCE_DIR}/celt ${SOURCE_DIR}/include) | ||
endif(APPLE AND BUILD_OSX_UNIVERSAL) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
set(CMAKE_SYSTEM_PROCESSOR aarch64) | ||
|
||
set(triple ${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32) | ||
|
||
set(CMAKE_C_COMPILER ${triple}-clang) | ||
set(CMAKE_C_COMPILER_TARGET ${triple}) | ||
set(CMAKE_CXX_COMPILER ${triple}-clang++) | ||
set(CMAKE_CXX_COMPILER_TARGET ${triple}) | ||
set(CMAKE_AR ${triple}-ar) | ||
set(CMAKE_RANLIB ${triple}-ranlib) | ||
set(CMAKE_RC_COMPILER ${triple}-windres) | ||
|
||
set(CMAKE_C_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_CXX_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_EXE_LINKER_FLAGS -Wl,--pdb=) | ||
|
||
# For make package use. | ||
set(CMAKE_OBJDUMP ${triple}-objdump) | ||
set(FREEDV_USING_LLVM_MINGW 1) | ||
|
||
# adjust the default behaviour of the FIND_XXX() commands: | ||
# search headers and libraries in the target environment, search | ||
# programs in the host environment | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
set(CMAKE_SYSTEM_PROCESSOR i686) | ||
|
||
set(triple ${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32) | ||
|
||
set(CMAKE_C_COMPILER ${triple}-clang) | ||
set(CMAKE_C_COMPILER_TARGET ${triple}) | ||
set(CMAKE_CXX_COMPILER ${triple}-clang++) | ||
set(CMAKE_CXX_COMPILER_TARGET ${triple}) | ||
|
||
set(CMAKE_AR ${triple}-ar) | ||
set(CMAKE_RANLIB ${triple}-ranlib) | ||
set(CMAKE_RC_COMPILER ${triple}-windres) | ||
|
||
set(CMAKE_C_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_CXX_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_EXE_LINKER_FLAGS -Wl,--pdb=) | ||
|
||
# For make package use. | ||
set(CMAKE_OBJDUMP ${triple}-objdump) | ||
set(FREEDV_USING_LLVM_MINGW 1) | ||
|
||
# adjust the default behaviour of the FIND_XXX() commands: | ||
# search headers and libraries in the target environment, search | ||
# programs in the host environment | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
set(CMAKE_SYSTEM_PROCESSOR x86_64) | ||
|
||
set(triple ${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32) | ||
|
||
set(CMAKE_C_COMPILER ${triple}-clang) | ||
set(CMAKE_C_COMPILER_TARGET ${triple}) | ||
set(CMAKE_CXX_COMPILER ${triple}-clang++) | ||
set(CMAKE_CXX_COMPILER_TARGET ${triple}) | ||
|
||
set(CMAKE_AR ${triple}-ar) | ||
set(CMAKE_RANLIB ${triple}-ranlib) | ||
set(CMAKE_RC_COMPILER ${triple}-windres) | ||
|
||
set(CMAKE_C_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_CXX_FLAGS "-Wno-unused-command-line-argument -gcodeview") | ||
set(CMAKE_EXE_LINKER_FLAGS -Wl,--pdb=) | ||
|
||
# For make package use. | ||
set(CMAKE_OBJDUMP ${triple}-objdump) | ||
set(FREEDV_USING_LLVM_MINGW 1) | ||
|
||
# adjust the default behaviour of the FIND_XXX() commands: | ||
# search headers and libraries in the target environment, search | ||
# programs in the host environment | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
Oops, something went wrong.