From e5334a83c4bdf13ddeae0037534b82918fe54c9e Mon Sep 17 00:00:00 2001 From: "Huang, Guangtai" Date: Wed, 25 Sep 2019 06:39:21 +0800 Subject: [PATCH] Fix lack of dylib support in Makefile when use lapack (#15813) * fix * add another if-else pair --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 19aab2885e68..b3b188a2cf3b 100644 --- a/Makefile +++ b/Makefile @@ -220,10 +220,12 @@ ifeq ($(USE_LAPACK), 1) ifeq ($(USE_BLAS),$(filter $(USE_BLAS),blas openblas atlas mkl)) ifeq (,$(wildcard $(USE_LAPACK_PATH)/liblapack.a)) ifeq (,$(wildcard $(USE_LAPACK_PATH)/liblapack.so)) +ifeq (,$(wildcard $(USE_LAPACK_PATH)/liblapack.dylib)) ifeq (,$(wildcard /lib/liblapack.a)) ifeq (,$(wildcard /lib/liblapack.so)) ifeq (,$(wildcard /usr/lib/liblapack.a)) ifeq (,$(wildcard /usr/lib/liblapack.so)) +ifeq (,$(wildcard /usr/lib/liblapack.dylib)) ifeq (,$(wildcard /usr/lib64/liblapack.a)) ifeq (,$(wildcard /usr/lib64/liblapack.so)) USE_LAPACK = 0 @@ -238,6 +240,8 @@ endif endif endif endif +endif +endif # lapack settings. ifeq ($(USE_LAPACK), 1) @@ -761,7 +765,7 @@ ratcheck: build/rat/apache-rat/target/apache-rat-0.13.jar ifneq ($(EXTRA_OPERATORS),) clean: rclean cyclean $(EXTRA_PACKAGES_CLEAN) - $(RM) -r build lib bin deps *~ */*~ */*/*~ */*/*/*~ + $(RM) -r build lib bin deps *~ */*~ */*/*~ */*/*/*~ (cd scala-package && mvn clean) || true cd $(DMLC_CORE); $(MAKE) clean; cd - cd $(PS_PATH); $(MAKE) clean; cd - @@ -772,7 +776,7 @@ clean: rclean cyclean $(EXTRA_PACKAGES_CLEAN) $(RM) -r $(patsubst %, %/*.o, $(EXTRA_OPERATORS)) $(patsubst %, %/*/*.o, $(EXTRA_OPERATORS)) else clean: rclean mkldnn_clean cyclean testclean $(EXTRA_PACKAGES_CLEAN) - $(RM) -r build lib bin *~ */*~ */*/*~ */*/*/*~ + $(RM) -r build lib bin *~ */*~ */*/*~ */*/*/*~ (cd scala-package && mvn clean) || true cd $(DMLC_CORE); $(MAKE) clean; cd - cd $(PS_PATH); $(MAKE) clean; cd -