From 7ee280eb7f6b125ba9587f6259b14eac7fc714cc Mon Sep 17 00:00:00 2001 From: Helin Wang Date: Wed, 17 May 2017 15:00:53 -0400 Subject: [PATCH] change folder structure --- paddle/go/{pserver/lib/client => cclient}/.gitignore | 0 paddle/go/{pserver/lib => cclient}/CMakeLists.txt | 5 +++-- paddle/go/{pserver/lib/client/main.go => cclient/cclient.go} | 0 .../lib => cclient}/cmake/CMakeDetermineGoCompiler.cmake | 0 .../{pserver/lib => cclient}/cmake/CMakeGoCompiler.cmake.in | 0 .../{pserver/lib => cclient}/cmake/CMakeGoInformation.cmake | 0 .../{pserver/lib => cclient}/cmake/CMakeTestGoCompiler.cmake | 0 paddle/go/{pserver/lib => cclient}/cmake/flags.cmake | 0 paddle/go/{pserver/lib => cclient}/cmake/golang.cmake | 0 .../go/{pserver/lib/client => cclient}/test/CMakeLists.txt | 4 ++-- paddle/go/{pserver/lib/client => cclient}/test/main.c | 0 paddle/go/pserver/lib/client/CMakeLists.txt | 5 ----- 12 files changed, 5 insertions(+), 9 deletions(-) rename paddle/go/{pserver/lib/client => cclient}/.gitignore (100%) rename paddle/go/{pserver/lib => cclient}/CMakeLists.txt (86%) rename paddle/go/{pserver/lib/client/main.go => cclient/cclient.go} (100%) rename paddle/go/{pserver/lib => cclient}/cmake/CMakeDetermineGoCompiler.cmake (100%) rename paddle/go/{pserver/lib => cclient}/cmake/CMakeGoCompiler.cmake.in (100%) rename paddle/go/{pserver/lib => cclient}/cmake/CMakeGoInformation.cmake (100%) rename paddle/go/{pserver/lib => cclient}/cmake/CMakeTestGoCompiler.cmake (100%) rename paddle/go/{pserver/lib => cclient}/cmake/flags.cmake (100%) rename paddle/go/{pserver/lib => cclient}/cmake/golang.cmake (100%) rename paddle/go/{pserver/lib/client => cclient}/test/CMakeLists.txt (68%) rename paddle/go/{pserver/lib/client => cclient}/test/main.c (100%) delete mode 100644 paddle/go/pserver/lib/client/CMakeLists.txt diff --git a/paddle/go/pserver/lib/client/.gitignore b/paddle/go/cclient/.gitignore similarity index 100% rename from paddle/go/pserver/lib/client/.gitignore rename to paddle/go/cclient/.gitignore diff --git a/paddle/go/pserver/lib/CMakeLists.txt b/paddle/go/cclient/CMakeLists.txt similarity index 86% rename from paddle/go/pserver/lib/CMakeLists.txt rename to paddle/go/cclient/CMakeLists.txt index eb98f4b0b6..29a2089fb1 100644 --- a/paddle/go/pserver/lib/CMakeLists.txt +++ b/paddle/go/cclient/CMakeLists.txt @@ -10,7 +10,6 @@ else() # find cmake directory modules get_filename_component(PARENT_DIR ${PARENT_DIR} DIRECTORY) get_filename_component(PARENT_DIR ${PARENT_DIR} DIRECTORY) - get_filename_component(PARENT_DIR ${PARENT_DIR} DIRECTORY) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PARENT_DIR}/cmake") @@ -30,4 +29,6 @@ project(cxx_go CXX C Go) include(cmake/golang.cmake) include(cmake/flags.cmake) -add_subdirectory(client) +ExternalGoProject_Add(pserver github.com/PaddlePaddle/Paddle/paddle/go/pserver) +add_go_library(client STATIC pserver) +add_subdirectory(test) diff --git a/paddle/go/pserver/lib/client/main.go b/paddle/go/cclient/cclient.go similarity index 100% rename from paddle/go/pserver/lib/client/main.go rename to paddle/go/cclient/cclient.go diff --git a/paddle/go/pserver/lib/cmake/CMakeDetermineGoCompiler.cmake b/paddle/go/cclient/cmake/CMakeDetermineGoCompiler.cmake similarity index 100% rename from paddle/go/pserver/lib/cmake/CMakeDetermineGoCompiler.cmake rename to paddle/go/cclient/cmake/CMakeDetermineGoCompiler.cmake diff --git a/paddle/go/pserver/lib/cmake/CMakeGoCompiler.cmake.in b/paddle/go/cclient/cmake/CMakeGoCompiler.cmake.in similarity index 100% rename from paddle/go/pserver/lib/cmake/CMakeGoCompiler.cmake.in rename to paddle/go/cclient/cmake/CMakeGoCompiler.cmake.in diff --git a/paddle/go/pserver/lib/cmake/CMakeGoInformation.cmake b/paddle/go/cclient/cmake/CMakeGoInformation.cmake similarity index 100% rename from paddle/go/pserver/lib/cmake/CMakeGoInformation.cmake rename to paddle/go/cclient/cmake/CMakeGoInformation.cmake diff --git a/paddle/go/pserver/lib/cmake/CMakeTestGoCompiler.cmake b/paddle/go/cclient/cmake/CMakeTestGoCompiler.cmake similarity index 100% rename from paddle/go/pserver/lib/cmake/CMakeTestGoCompiler.cmake rename to paddle/go/cclient/cmake/CMakeTestGoCompiler.cmake diff --git a/paddle/go/pserver/lib/cmake/flags.cmake b/paddle/go/cclient/cmake/flags.cmake similarity index 100% rename from paddle/go/pserver/lib/cmake/flags.cmake rename to paddle/go/cclient/cmake/flags.cmake diff --git a/paddle/go/pserver/lib/cmake/golang.cmake b/paddle/go/cclient/cmake/golang.cmake similarity index 100% rename from paddle/go/pserver/lib/cmake/golang.cmake rename to paddle/go/cclient/cmake/golang.cmake diff --git a/paddle/go/pserver/lib/client/test/CMakeLists.txt b/paddle/go/cclient/test/CMakeLists.txt similarity index 68% rename from paddle/go/pserver/lib/client/test/CMakeLists.txt rename to paddle/go/cclient/test/CMakeLists.txt index 895f0f66c9..c899bd275d 100644 --- a/paddle/go/pserver/lib/client/test/CMakeLists.txt +++ b/paddle/go/cclient/test/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.0) -include_directories(/env/gopath/src/github.com/PaddlePaddle/Paddle/paddle/go/pserver/lib/build/client) +include_directories(/env/gopath/src/github.com/PaddlePaddle/Paddle/paddle/go/cclient/build/) add_executable(main main.c) add_dependencies(main client) set (CMAKE_EXE_LINKER_FLAGS "-pthread") -target_link_libraries(main /env/gopath/src/github.com/PaddlePaddle/Paddle/paddle/go/pserver/lib/build/client/libclient.a) # ${GTEST_LIBRARIES}) +target_link_libraries(main /env/gopath/src/github.com/PaddlePaddle/Paddle/paddle/go/cclient/build/libclient.a) # ${GTEST_LIBRARIES}) diff --git a/paddle/go/pserver/lib/client/test/main.c b/paddle/go/cclient/test/main.c similarity index 100% rename from paddle/go/pserver/lib/client/test/main.c rename to paddle/go/cclient/test/main.c diff --git a/paddle/go/pserver/lib/client/CMakeLists.txt b/paddle/go/pserver/lib/client/CMakeLists.txt deleted file mode 100644 index 0f6d47f27c..0000000000 --- a/paddle/go/pserver/lib/client/CMakeLists.txt +++ /dev/null @@ -1,5 +0,0 @@ -cmake_minimum_required(VERSION 3.0) - -ExternalGoProject_Add(pserver github.com/PaddlePaddle/Paddle/paddle/go/pserver) -add_go_library(client STATIC pserver) -add_subdirectory(test) -- GitLab