Просмотр исходного кода

BProcess, BInputProcess: move to system

ambrop7 14 лет назад
Родитель
Сommit
3e46c3f42e

+ 0 - 2
CMakeLists.txt

@@ -154,8 +154,6 @@ add_subdirectory(threadwork)
 add_subdirectory(stringmap)
 add_subdirectory(udpgw_client)
 if (NOT WIN32)
-    add_subdirectory(process)
-    add_subdirectory(inputprocess)
     add_subdirectory(udevmonitor)
 endif ()
 

+ 1 - 1
examples/CMakeLists.txt

@@ -29,7 +29,7 @@ target_link_libraries(ncd_parser_test ncdconfig)
 
 if (NOT WIN32)
     add_executable(bprocess_example bprocess_example.c)
-    target_link_libraries(bprocess_example system process)
+    target_link_libraries(bprocess_example system)
 
     add_executable(ncdudevmonitor_test ncdudevmonitor_test.c)
     target_link_libraries(ncdudevmonitor_test udevmonitor)

+ 1 - 1
examples/bprocess_example.c

@@ -29,7 +29,7 @@
 #include <system/BReactor.h>
 #include <system/BSignal.h>
 #include <system/BTime.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 
 BReactor reactor;
 BProcessManager manager;

+ 1 - 1
examples/ncdudevmanager_test.c

@@ -27,7 +27,7 @@
 #include <base/BLog.h>
 #include <system/BReactor.h>
 #include <system/BUnixSignal.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 #include <udevmonitor/NCDUdevManager.h>
 
 BReactor reactor;

+ 1 - 1
examples/ncdudevmonitor_test.c

@@ -26,7 +26,7 @@
 #include <base/BLog.h>
 #include <system/BReactor.h>
 #include <system/BSignal.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 #include <udevmonitor/NCDUdevMonitor.h>
 
 BReactor reactor;

+ 0 - 4
inputprocess/CMakeLists.txt

@@ -1,4 +0,0 @@
-add_library(inputprocess
-    BInputProcess.c
-)
-target_link_libraries(inputprocess system flow flowextra process)

+ 1 - 1
ncd/CMakeLists.txt

@@ -61,7 +61,7 @@ add_executable(badvpn-ncd
     modules/net_watch_interfaces.c
     ${NCD_ADDITIONAL_SOURCES}
 )
-target_link_libraries(badvpn-ncd system flow flowextra dhcpclient ncdconfig process inputprocess udevmonitor)
+target_link_libraries(badvpn-ncd system flow flowextra dhcpclient ncdconfig udevmonitor)
 
 if (BADVPN_USE_LINUX_INPUT)
     string(REPLACE " " ";" FLAGS_LIST "${CMAKE_C_FLAGS}")

+ 1 - 1
ncd/NCDModule.h

@@ -27,7 +27,7 @@
 #include <system/BReactor.h>
 #include <base/BPending.h>
 #include <base/BLog.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 #include <udevmonitor/NCDUdevManager.h>
 #include <ncd/NCDValue.h>
 

+ 1 - 1
ncd/modules/net_backend_wpa_supplicant.c

@@ -36,7 +36,7 @@
 #include <misc/cmdline.h>
 #include <misc/string_begins_with.h>
 #include <flow/LineBuffer.h>
-#include <inputprocess/BInputProcess.h>
+#include <system/BInputProcess.h>
 #include <ncd/NCDModule.h>
 
 #include <generated/blog_channel_ncd_net_backend_wpa_supplicant.h>

+ 1 - 1
ncd/ncd.c

@@ -39,7 +39,7 @@
 #include <system/BReactor.h>
 #include <system/BSignal.h>
 #include <system/BConnection.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 #include <udevmonitor/NCDUdevManager.h>
 #include <ncdconfig/NCDConfigParser.h>
 #include <ncd/NCDModule.h>

+ 0 - 2
process/CMakeLists.txt

@@ -1,2 +0,0 @@
-add_library(process BProcess.c)
-target_link_libraries(process system)

+ 1 - 1
inputprocess/BInputProcess.c → system/BInputProcess.c

@@ -24,7 +24,7 @@
 
 #include <base/BLog.h>
 
-#include <inputprocess/BInputProcess.h>
+#include "BInputProcess.h"
 
 #include <generated/blog_channel_BInputProcess.h>
 

+ 3 - 3
inputprocess/BInputProcess.h → system/BInputProcess.h

@@ -20,13 +20,13 @@
  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-#ifndef BADVPN_INPUTPROCESS_BINPUTPROCESS_H
-#define BADVPN_INPUTPROCESS_BINPUTPROCESS_H
+#ifndef BADVPN_BINPUTPROCESS_H
+#define BADVPN_BINPUTPROCESS_H
 
 #include <misc/debug.h>
 #include <base/DebugObject.h>
 #include <system/BConnection.h>
-#include <process/BProcess.h>
+#include <system/BProcess.h>
 
 typedef void (*BInputProcess_handler_terminated) (void *user, int normally, uint8_t normally_exit_status);
 typedef void (*BInputProcess_handler_closed) (void *user, int is_error);

+ 1 - 1
process/BProcess.c → system/BProcess.c

@@ -35,7 +35,7 @@
 #include <misc/offset.h>
 #include <base/BLog.h>
 
-#include <process/BProcess.h>
+#include "BProcess.h"
 
 #include <generated/blog_channel_BProcess.h>
 

+ 2 - 2
process/BProcess.h → system/BProcess.h

@@ -20,8 +20,8 @@
  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-#ifndef BADVPN_PROCESS_BPROCESS_H
-#define BADVPN_PROCESS_BPROCESS_H
+#ifndef BADVPN_BPROCESS_H
+#define BADVPN_BPROCESS_H
 
 #include <stdint.h>
 #include <unistd.h>

+ 2 - 0
system/CMakeLists.txt

@@ -14,6 +14,8 @@ if (NOT WIN32)
         BUnixSignal.c
         BConnection_unix.c
         BDatagram_unix.c
+        BProcess.c
+        BInputProcess.c
     )
 endif ()
 

+ 1 - 1
udevmonitor/CMakeLists.txt

@@ -4,4 +4,4 @@ add_library(udevmonitor
     NCDUdevCache.c
     NCDUdevManager.c
 )
-target_link_libraries(udevmonitor system flow inputprocess stringmap)
+target_link_libraries(udevmonitor system flow stringmap)

+ 1 - 1
udevmonitor/NCDUdevMonitor.h

@@ -26,7 +26,7 @@
 #include <misc/debug.h>
 #include <misc/debugerror.h>
 #include <flow/StreamRecvConnector.h>
-#include <inputprocess/BInputProcess.h>
+#include <system/BInputProcess.h>
 #include <udevmonitor/NCDUdevMonitorParser.h>
 
 typedef void (*NCDUdevMonitor_handler_event) (void *user);