nixpkgs/pkgs/development/libraries/science/math/amd-libflame/add-lapacke.diff

35 lines
1.5 KiB
Diff
Raw Normal View History

diff --git a/Makefile b/Makefile
index 5549ce30..ac2ee51e 100644
--- a/Makefile
+++ b/Makefile
@@ -583,14 +583,14 @@ endif
# --- Shared library linker rules ---
-$(LIBFLAME_SO_PATH): $(MK_ALL_FLAMEC_OBJS)
+$(LIBFLAME_SO_PATH): $(MK_ALL_FLAMEC_OBJS) $(LAPACKE_A_PATH)
ifeq ($(ENABLE_VERBOSE),yes)
ifeq ($(FLA_ENABLE_MAX_ARG_LIST_HACK),yes)
$(CAT) $(AR_OBJ_LIST_FILE) | xargs -n$(AR_CHUNK_SIZE) $(AR) $(ARFLAGS) $(LIBFLAME_A)
ifeq ($(OS_NAME),Darwin)
- $(LINKER) $(SOFLAGS) -o $@ -Wl,-force_load,$(LIBFLAME_A) $(LDFLAGS)
+ $(LINKER) $(SOFLAGS) -o $@ -Wl,-force_load,$(LIBFLAME_A),$(LAPACKE_A_PATH) $(LDFLAGS)
else
- $(LINKER) $(SOFLAGS) -o $@ -Wl,--whole-archive,$(LIBFLAME_A),--no-whole-archive $(LDFLAGS)
+ $(LINKER) $(SOFLAGS) -o $@ -Wl,--whole-archive,$(LIBFLAME_A),$(LAPACKE_A_PATH)--no-whole-archive $(LDFLAGS)
endif
else
# NOTE: Can't use $^ automatic variable as long as $(AR_OBJ_LIST_FILE) is in
@@ -602,9 +602,9 @@ else
ifeq ($(FLA_ENABLE_MAX_ARG_LIST_HACK),yes)
@$(CAT) $(AR_OBJ_LIST_FILE) | xargs -n$(AR_CHUNK_SIZE) $(AR) $(ARFLAGS) $(LIBFLAME_A)
ifeq ($(OS_NAME),Darwin)
- @$(LINKER) $(SOFLAGS) -o $@ -Wl,-force_load,$(LIBFLAME_A) $(LDFLAGS)
+ @$(LINKER) $(SOFLAGS) -o $@ -Wl,-force_load,$(LIBFLAME_A),$(LAPACKE_A_PATH) $(LDFLAGS)
else
- @$(LINKER) $(SOFLAGS) -o $@ -Wl,--whole-archive,$(LIBFLAME_A),--no-whole-archive $(LDFLAGS)
+ @$(LINKER) $(SOFLAGS) -o $@ -Wl,--whole-archive,$(LIBFLAME_A),$(LAPACKE_A_PATH),--no-whole-archive $(LDFLAGS)
endif
else
# NOTE: Can't use $^ automatic variable as long as $(AR_OBJ_LIST_FILE) is in