singa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wang...@apache.org
Subject incubator-singa git commit: SINGA-356 Error using travis tool to build SINGA on mac os
Date Mon, 14 May 2018 05:34:08 GMT
Repository: incubator-singa
Updated Branches:
  refs/heads/master fa0ed01e3 -> 1bee4d2a0


SINGA-356 Error using travis tool to build SINGA on mac os


Project: http://git-wip-us.apache.org/repos/asf/incubator-singa/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-singa/commit/1bee4d2a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-singa/tree/1bee4d2a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-singa/diff/1bee4d2a

Branch: refs/heads/master
Commit: 1bee4d2a065ec896d772169e1052a0413c5a6278
Parents: fa0ed01
Author: dbxinj <jixin@comp.nus.edu.sg>
Authored: Mon May 14 12:50:36 2018 +0800
Committer: dbxinj <jixin@comp.nus.edu.sg>
Committed: Mon May 14 12:50:36 2018 +0800

----------------------------------------------------------------------
 python/CMakeLists.txt | 17 ++++++++++++-----
 python/setup.py.in    |  2 +-
 2 files changed, 13 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/1bee4d2a/python/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
index 75e39f3..6399332 100644
--- a/python/CMakeLists.txt
+++ b/python/CMakeLists.txt
@@ -128,12 +128,19 @@ ADD_CUSTOM_COMMAND(
 ENDIF(USE_CUDA)
 
 ADD_LIBRARY(_singa_wrap SHARED $<TARGET_OBJECTS:singa_objects>  ${python_srcs} ${proto_pys}
${global_cuda_objs})
-TARGET_LINK_LIBRARIES(_singa_wrap ${SINGA_LINKER_LIBS} ${PYTHON_LIBRARIES})
+
+# For MacOS Python3.6 is already linked into python executable, hence no need to link python3.6
into Singa.
+IF(APPLE)
+    TARGET_LINK_LIBRARIES(_singa_wrap ${SINGA_LINKER_LIBS})    
+    SET_TARGET_PROPERTIES(_singa_wrap PROPERTIES PREFIX "" 
+                                                 LINK_FLAGS "-undefined dynamic_lookup" 
+                                      LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/python/singa)
+ELSE()
+    TARGET_LINK_LIBRARIES(_singa_wrap ${SINGA_LINKER_LIBS} ${PYTHON_LIBRARIES})    
+    SET_TARGET_PROPERTIES(_singa_wrap PROPERTIES PREFIX "" LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/python/singa)
+ENDIF()
+
 TARGET_INCLUDE_DIRECTORIES(_singa_wrap PRIVATE ${PYTHON_INCLUDE_DIRS} ${NUMPY_INCLUDE_DIR})
-SET_TARGET_PROPERTIES(_singa_wrap
-PROPERTIES PREFIX ""
-LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/python/singa
-)
 
 #SETUP
 SET(SETUP_PY_IN "setup.py.in")

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/1bee4d2a/python/setup.py.in
----------------------------------------------------------------------
diff --git a/python/setup.py.in b/python/setup.py.in
index 37a7ea6..f117413 100644
--- a/python/setup.py.in
+++ b/python/setup.py.in
@@ -69,7 +69,7 @@ setup(
         'future',
     #    'xmlrunner',
         'tqdm',
-        'ipywidgets',
+    #    'ipywidgets',
         ],
 
     #List additional groups of dependencies here (e.g. development


Mime
View raw message