@@ -21,6 +21,7 @@ MACRO(RTLSDR_APPEND_SRCS)
21
21
LIST (APPEND rtlsdr_srcs ${ARGV} )
22
22
ENDMACRO (RTLSDR_APPEND_SRCS )
23
23
24
+ if (NOT WIN32 )
24
25
RTLSDR_APPEND_SRCS (
25
26
librtlsdr.c
26
27
tuner_e4k.c
@@ -31,6 +32,16 @@ RTLSDR_APPEND_SRCS(
31
32
rtlsdr_rpc.c
32
33
rtlsdr_rpc_msg.c
33
34
)
35
+ else ()
36
+ RTLSDR_APPEND_SRCS (
37
+ librtlsdr.c
38
+ tuner_e4k.c
39
+ tuner_fc0012.c
40
+ tuner_fc0013.c
41
+ tuner_fc2580.c
42
+ tuner_r82xx.c
43
+ )
44
+ endif ()
34
45
35
46
########################################################################
36
47
# Set up Windows DLL resource files
@@ -94,8 +105,12 @@ add_executable(rtl_ir rtl_ir.c)
94
105
add_executable (rtl_eeprom rtl_eeprom.c )
95
106
add_executable (rtl_adsb rtl_adsb.c )
96
107
add_executable (rtl_power rtl_power.c )
97
- add_executable (rtl_rpcd rtl_rpcd.c rtlsdr_rpc_msg.c )
98
- set (INSTALL_TARGETS rtlsdr_shared rtlsdr_static rtl_sdr rtl_tcp rtl_test rtl_fm rtl_ir rtl_eeprom rtl_adsb rtl_power rtl_rpcd )
108
+ if (NOT WIN32 )
109
+ add_executable (rtl_rpcd rtl_rpcd.c rtlsdr_rpc_msg.c )
110
+ set (INSTALL_TARGETS rtlsdr_shared rtlsdr_static rtl_sdr rtl_tcp rtl_test rtl_fm rtl_ir rtl_eeprom rtl_adsb rtl_power rtl_rpcd )
111
+ else ()
112
+ set (INSTALL_TARGETS rtlsdr_shared rtlsdr_static rtl_sdr rtl_tcp rtl_test rtl_fm rtl_ir rtl_eeprom rtl_adsb rtl_power )
113
+ endif ()
99
114
100
115
target_link_libraries (rtl_sdr rtlsdr_shared convenience_static
101
116
${LIBUSB_LIBRARIES}
@@ -129,10 +144,13 @@ target_link_libraries(rtl_power rtlsdr_shared convenience_static
129
144
${LIBUSB_LIBRARIES}
130
145
${CMAKE_THREAD_LIBS_INIT}
131
146
)
147
+ if (NOT WIN32 )
132
148
target_link_libraries (rtl_rpcd rtlsdr_shared convenience_static
133
149
${LIBUSB_LIBRARIES}
134
150
${CMAKE_THREAD_LIBS_INIT}
135
151
)
152
+ endif ()
153
+
136
154
if (UNIX )
137
155
target_link_libraries (rtl_fm m )
138
156
target_link_libraries (rtl_ir m )
@@ -154,7 +172,7 @@ target_link_libraries(rtl_ir libgetopt_static)
154
172
target_link_libraries (rtl_eeprom libgetopt_static )
155
173
target_link_libraries (rtl_adsb libgetopt_static )
156
174
target_link_libraries (rtl_power libgetopt_static )
157
- target_link_libraries (rtl_rpcd ws2_32 libgetopt_static )
175
+ # target_link_libraries(rtl_rpcd ws2_32 libgetopt_static)
158
176
set_property (TARGET rtl_sdr APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
159
177
set_property (TARGET rtl_tcp APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
160
178
set_property (TARGET rtl_test APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
@@ -163,7 +181,7 @@ set_property(TARGET rtl_ir APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
163
181
set_property (TARGET rtl_eeprom APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
164
182
set_property (TARGET rtl_adsb APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
165
183
set_property (TARGET rtl_power APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
166
- set_property (TARGET rtl_rpcd APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
184
+ # set_property(TARGET rtl_rpcd APPEND PROPERTY COMPILE_DEFINITIONS "rtlsdr_STATIC" )
167
185
endif ()
168
186
########################################################################
169
187
# Install built library files & utilities
0 commit comments