Skip to content

Commit

Permalink
OSX: specify the full path to the location of libblis.dylib (flame#390)
Browse files Browse the repository at this point in the history
* OSX: specify the full path to the location of libblis.dylib so that it can be found at runtime

Before this change:

Appication gives runtime error [when linked with blis]
dyld: Library not loaded: libblis.3.dylib

balay@kpro lib % otool -L libblis.dylib
libblis.dylib:
        libblis.3.dylib (compatibility version 0.0.0, current version 0.0.0)
        /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.0.0)

After this change:
balay@kpro lib % otool -L libblis.dylib
libblis.dylib:
	/Users/balay/petsc/arch-darwin-c-debug/lib/libblis.3.dylib (compatibility version 0.0.0, current version 0.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.0.0)

* INSTALL_LIBDIR -> libdir as INSTALL_LIBDIR has DESTDIR

Co-Authored-By: Jed Brown <jed@jedbrown.org>

* CREDITS file update.

Co-authored-by: Jed Brown <jed@jedbrown.org>
Co-authored-by: Field G. Van Zee <field@cs.utexas.edu>
  • Loading branch information
3 people authored and kiran-amd committed May 21, 2020
1 parent 3597284 commit d560d10
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 1 addition & 0 deletions CREDITS
Expand Up @@ -15,6 +15,7 @@ but many others have contributed code and feedback, including
Erling Andersen @erling-d-andersen
Alex Arslan @ararslan
Vernon Austel (IBM, T.J. Watson Research Center)
Satish Balay @balay (Argonne National Laboratory)
Matthew Brett @matthew-brett (University of Birmingham)
Jed Brown @jedbrown (Argonne National Laboratory)
Robin Christ @robinchrist
Expand Down
3 changes: 1 addition & 2 deletions common.mk
Expand Up @@ -540,7 +540,7 @@ endif
ifeq ($(OS_NAME),Darwin)
# OS X shared library link flags.
SOFLAGS := -dynamiclib
SOFLAGS += -Wl,-install_name,$(LIBBLIS_SONAME)
SOFLAGS += -Wl,-install_name,$(libdir)/$(LIBBLIS_SONAME)
else
SOFLAGS := -shared
ifeq ($(IS_WIN),yes)
Expand Down Expand Up @@ -1082,4 +1082,3 @@ BUILD_CPPFLAGS := -DBLIS_IS_BUILDING_LIBRARY
# end of ifndef COMMON_MK_INCLUDED conditional block
endif


0 comments on commit d560d10

Please sign in to comment.