File: addcmake.patch

package info (click to toggle)
edflib 1.27-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 680 kB
  • sloc: ansic: 9,078; makefile: 68; sh: 12
file content (60 lines) | stat: -rw-r--r-- 1,478 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
56
57
58
59
60
Description: add a build system
 Note upstream preferred not to include it.
Forwarded: https://lists.debian.org/debian-med/2021/01/msg00106.html
Author: Mathieu Malaterre <malat@debian.org>

--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,52 @@
+cmake_minimum_required(VERSION 2.8)
+# Author: Mathieu Malaterre / BSD (as upstream)
+project(edflib C)
+
+add_definitions(
+-D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE
+)
+add_library(edf SHARED edflib.c)
+
+set(VERSION_MAJOR 1)
+set(VERSION_MINOR 23)
+set(VERSION_FULL "${VERSION_MAJOR}.${VERSION_MINOR}")
+
+set(API_VERSION "${VERSION_MAJOR}")
+set(LIBRARY_PROPERTIES
+  VERSION "${VERSION_FULL}"
+  SOVERSION "${API_VERSION}"
+  )
+set_target_properties(edf
+  PROPERTIES
+  ${LIBRARY_PROPERTIES}
+  )
+
+install(FILES edflib.h
+  DESTINATION include
+  )
+
+if(NOT DEFINED EDFLIB_INSTALL_PATH)
+  set(EDFLIB_INSTALL_PATH lib)
+endif()
+install(TARGETS edf
+  LIBRARY DESTINATION ${EDFLIB_INSTALL_PATH}
+  )
+
+#
+add_executable(test_edflib test_edflib.c)
+target_link_libraries(test_edflib edf)
+
+add_executable(sine_generator sine_generator.c)
+target_link_libraries(sine_generator edf)
+
+add_executable(test_generator test_generator.c)
+target_link_libraries(test_generator edf)
+
+add_executable(sweep_generator sweep_generator.c)
+target_link_libraries(sweep_generator edf)
+
+if(UNIX)
+  target_link_libraries(sine_generator m)
+  target_link_libraries(test_generator m)
+  target_link_libraries(sweep_generator m)
+endif()