File: debian-source-package

package info (click to toggle)
codec2 1.2.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 76,376 kB
  • sloc: ansic: 436,819; cpp: 2,091; objc: 1,736; sh: 1,510; python: 1,405; asm: 683; makefile: 605
file content (55 lines) | stat: -rw-r--r-- 1,797 bytes parent folder | download | duplicates (2)
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
46
47
48
49
50
51
52
53
54
55
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
@@ -85,7 +85,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}")
@@ -164,6 +164,9 @@
     set(LPCNET_C_PROC_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)
@@ -195,6 +198,7 @@
         FetchContent_Populate(lpcnet)
     endif()
 endif()
+endif()
 
 add_subdirectory(src)
 
--- a/LPCNet/src/CMakeLists.txt
+++ b/LPCNet/src/CMakeLists.txt
@@ -40,7 +40,7 @@
 endforeach()
 endif(LPCNET_C_PROC_FLAGS)
 
-add_library(lpcnetfreedv SHARED ${lpcnet_freedv_srcs} ${codec2_import_srcs})
+add_library(lpcnetfreedv STATIC ${lpcnet_freedv_srcs} ${codec2_import_srcs})
 
 set_target_properties(lpcnetfreedv PROPERTIES
     PUBLIC_HEADER lpcnet_freedv.h
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -249,6 +249,7 @@
 endif(UNIX)
 if(LPCNET AND lpcnetfreedv_FOUND)
     target_link_libraries(codec2 PRIVATE lpcnetfreedv)
+    list(APPEND CODEC2_PUBLIC_HEADERS ${CMAKE_SOURCE_DIR}/LPCNet/src/lpcnet_freedv.h)
 endif()
 include_directories(${CMAKE_CURRENT_SOURCE_DIR})
 set_target_properties(codec2 PROPERTIES