File tree Expand file tree Collapse file tree 6 files changed +8
-13
lines changed Expand file tree Collapse file tree 6 files changed +8
-13
lines changed Original file line number Diff line number Diff line change @@ -27,10 +27,10 @@ find_package(Threads REQUIRED)
27
27
include (system )
28
28
include (simd )
29
29
30
- ###################### Configurations ############################
30
+ ################################ Configurations ########### ############################
31
31
option (WITH_GPU "Compile PaddlePaddle with NVIDIA GPU" ${CUDA_FOUND} )
32
32
option (WITH_AVX "Compile PaddlePaddle with AVX intrinsics" ${AVX_FOUND} )
33
- option (WITH_DSO "Compile PaddlePaddle with dynamic linked CUDA" ON )
33
+ option (WITH_DSO "Compile PaddlePaddle with dynamic linked CUDA" OFF )
34
34
option (WITH_TESTING "Compile PaddlePaddle with unit testing" ON )
35
35
option (WITH_SWIG_PY "Compile PaddlePaddle with inference api" ON )
36
36
option (WITH_STYLE_CHECK "Compile PaddlePaddle with style check" ON )
@@ -43,6 +43,7 @@ option(WITH_DOC "Compile PaddlePaddle with documentation" OFF)
43
43
option (ON_COVERALLS "Compile PaddlePaddle with code coverage" OFF )
44
44
option (COVERALLS_UPLOAD "Package code coverage data to coveralls" OFF )
45
45
option (ON_TRAVIS "Exclude special unit test on Travis CI" OFF )
46
+ ########################################################################################
46
47
47
48
include (external/zlib ) # download, build, install zlib
48
49
include (external/gflags ) # download, build, install gflags
Original file line number Diff line number Diff line change 15
15
INCLUDE (cblas )
16
16
17
17
IF (NOT ${CBLAS_FOUND} )
18
+ MESSAGE (FATAL_ERROR "Please install OpenBlas, MKL or ATLAS." )
18
19
INCLUDE (ExternalProject )
19
20
20
21
SET (CBLAS_SOURCES_DIR ${CMAKE_CURRENT_SOURCE_DIR} /third_party/openblas )
Original file line number Diff line number Diff line change @@ -53,6 +53,8 @@ ExternalProject_Add(
53
53
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${WARPCTC_INSTALL_DIR}
54
54
CMAKE_ARGS -DWITH_GPU=${WITH_GPU}
55
55
CMAKE_ARGS -DWITH_OMP=${USE_OMP}
56
+ CMAKE_ARGS -DWITH_TORCH=OFF
57
+ CMAKE_ARGS -DBUILD_SHARED=ON
56
58
)
57
59
58
60
LIST (APPEND external_project_dependencies warpctc )
Original file line number Diff line number Diff line change @@ -120,6 +120,7 @@ function(link_paddle_exe TARGET_NAME)
120
120
target_link_libraries (${TARGET_NAME} rt )
121
121
endif ()
122
122
endif ()
123
+
123
124
add_dependencies (${TARGET_NAME} ${external_project_dependencies} )
124
125
endfunction ()
125
126
Original file line number Diff line number Diff line change @@ -29,7 +29,6 @@ void* warpctc_dso_handle = nullptr;
29
29
* false, you need to add the path of libwarp-ctc.so to
30
30
* the linked-libs of paddle or to LD_PRELOAD.
31
31
*/
32
- #ifdef PADDLE_USE_DSO
33
32
#define DYNAMIC_LOAD_WARPCTC_WRAP (__name ) \
34
33
struct DynLoad__ ##__name { \
35
34
template <typename ... Args> \
@@ -41,15 +40,6 @@ void* warpctc_dso_handle = nullptr;
41
40
return reinterpret_cast <warpctcFunc>(p_##_name)(args...); \
42
41
} \
43
42
} __name; // struct DynLoad__##__name
44
- #else
45
- #define DYNAMIC_LOAD_WARPCTC_WRAP (__name ) \
46
- struct DynLoad__ ##__name { \
47
- template <typename ... Args> \
48
- auto operator ()(Args... args) -> decltype(__name(args...)) { \
49
- return __name (args...); \
50
- } \
51
- } __name; // struct DynLoad__##__name
52
- #endif
53
43
54
44
// include all needed warp-ctc functions
55
45
DYNAMIC_LOAD_WARPCTC_WRAP (get_warpctc_version)
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
13
13
sudo make install
14
14
elif [[ " $TRAVIS_OS_NAME " == " osx" ]]; then
15
15
export PYTHONPATH=/usr/local/lib/python2.7/site-packages
16
- cmake .. -DON_TRAVIS=ON -DON_COVERALLS=ON -DCOVERALLS_UPLOAD=ON -DWITH_SWIG_PY=ON
16
+ cmake .. -DON_TRAVIS=ON -DON_COVERALLS=ON -DCOVERALLS_UPLOAD=ON
17
17
NPROC=` sysctl -n hw.ncpu`
18
18
make -j $NPROC
19
19
fi
You can’t perform that action at this time.
0 commit comments