File: debian-source-package

package info (click to toggle)
codec2 1.0.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 121,056 kB
  • sloc: ansic: 414,118; sh: 2,612; objc: 2,574; python: 2,105; cpp: 2,091; asm: 683; makefile: 598
file content (45 lines) | stat: -rw-r--r-- 1,458 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
Description: The Debian source contains the lpcnet tar source,
 So this patch uses that feature and avoids fetching content.
Author: A. Maitland Bottoms <bottoms@debian.org>
Forwarded: not-needed

--- a/lpcnet/CMakeLists.txt
+++ b/lpcnet/CMakeLists.txt
@@ -79,7 +79,7 @@
 endif()
 
 # Set default flags
-set(CMAKE_C_FLAGS "-Wall -W -Wextra -Wno-unused-function -O3 -g -I. -MD ${CMAKE_C_FLAGS} -DENABLE_ASSERTIONS")
+set(CMAKE_C_FLAGS "-Wall -W -Wextra -Wno-unused-function -fPIC -O3 -g -I. -MD ${CMAKE_C_FLAGS} -DENABLE_ASSERTIONS")
 
 # Arch specific stuff here
 message(STATUS "Host system arch is: ${CMAKE_SYSTEM_PROCESSOR}")
@@ -139,6 +139,9 @@
     set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mfpu=neon -march=armv8-a -mtune=cortex-a53")
 endif()
 
+if(LPCNET_191005_DIR)
+set(lpcnet_SOURCE_DIR ${LPCNET_191005_DIR})
+else()
 # grab latest NN model (or substitute your own)
 set(LPCNET_ROOT http://rowetel.com/downloads/deep/)
 set(LPCNET_FILE lpcnet_191005_v1.0.tgz)
@@ -170,6 +173,7 @@
         FetchContent_Populate(lpcnet)
     endif()
 endif()
+endif()
 
 # Find codec2
 if(CODEC2_BUILD_DIR)
--- a/lpcnet/src/CMakeLists.txt
+++ b/lpcnet/src/CMakeLists.txt
@@ -19,7 +19,7 @@
     ${lpcnet_SOURCE_DIR}/nnet_data.c
 )
 
-add_library(lpcnetfreedv SHARED ${lpcnet_freedv_srcs})
+add_library(lpcnetfreedv STATIC ${lpcnet_freedv_srcs})
 target_link_libraries(lpcnetfreedv codec2)
 set_target_properties(lpcnetfreedv PROPERTIES
     PUBLIC_HEADER lpcnet_freedv.h