[petsc-users] dyld[19098]: Library not loaded: @rpath/libHYPRE-2.32.0.dylib

Matthew Knepley knepley at gmail.com
Thu May 8 08:57:29 CDT 2025


On Thu, May 8, 2025 at 9:15 AM David Andrs <andrsd at gmail.com> wrote:

> Hi Juan,
>
> I recently bumped into a similar issue (not with PETSc). It is a general
> issue with the newest macOS where a duplicate rpath prevents you from
> running the binary. The info is buried in the error message when you run
> the binary. I saw people "fixing" the issue by downgrading Xcode to 16.2 -
> if my memory serves well. Also you can inspect your binary via `otool -l`
> to check for the duplicate entries and remove them via install_name_tool
> (not a solution, but a diagnosing step). So, maybe check if this is the
> problem you are running into.
>

Thanks! I will have to remember this one. Apple keeps finding ways to make
us less productive.

  Matt


> Side note: conda environment has the same problem and users are advised to
> update to the latest ld64 (from conda-forge).
>
> With regards,
> --
> David
>
>
> On Wed, May 7, 2025 at 10:27 PM Juan Salazar via petsc-users <
> petsc-users at mcs.anl.gov> wrote:
>
>> Dear PETSc users,
>>
>> I am probably doing something dumb, but since I recently updated macOS, I
>> am getting the following errors when running `make check`: dyld[19098]:
>> Library not loaded: @rpath/libHYPRE-2.32.0.dylib . I am also not able to
>> compile codes that previously worked with petsc because of the same issues.
>> The dylib is not linked, even tough it is in the path that apparently is
>> searched.
>>
>> Below is my configure command
>>
>> ./configure --with-debugging=0 --download-cmake --download-hypre
>> --download-parmetis --download-metis --download-ptscotch --download-mumps
>> --download-scalapack --with-precision=double --with-shared-libraries=1
>> --with-scalar-type=real --with-fc=mpifort --with-cc=mpicc --with-cxx=mpicxx
>> CXX_LINKER_FLAGS=-Wl,-rpath,/opt/homebrew/lib CFLAGS="-g -O2 -fPIC"
>> CXXFLAGS="-g -O2 -fPIC" FCFLAGS="-g -O2" FFLAGS="-g -O2"
>> LDFLAGS="-Wl,-ld_classic -Wl,-commons,use_dylibs" MAKEFLAGS=w
>> --download-bison
>>
>> Attached are the configure.log and make.log and check.log files.
>>
>> √ petsc-3.23.1 % mpifort --version
>> GNU Fortran (Homebrew GCC 14.2.0_1) 14.2.0
>> Copyright (C) 2024 Free Software Foundation, Inc.
>> This is free software; see the source for copying conditions.  There is NO
>> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
>> PURPOSE.
>>
>> √ petsc-3.23.1 % mpicc --version
>> Apple clang version 17.0.0 (clang-1700.0.13.3)
>> Target: arm64-apple-darwin24.4.0
>> Thread model: posix
>> InstalledDir:
>> /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
>>
>> √ petsc-3.23.1 % mpicxx --version
>> Apple clang version 17.0.0 (clang-1700.0.13.3)
>> Target: arm64-apple-darwin24.4.0
>> Thread model: posix
>> InstalledDir:
>> /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
>>
>> macOS Sequoia 15.4.1 (24E263)
>>
>> Any help is much appreciated,
>> Juan S.
>>
>>
>>
>>
>>
>>

-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://urldefense.us/v3/__https://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!foYFpXpWd_2fpOCFImBaX5XJCne4IvL_yUutmn2DFXcM7OgZ5IwCQNDVbRbCQBgFuwkIs1sYAKeY7pD4vxvO$  <https://urldefense.us/v3/__http://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!foYFpXpWd_2fpOCFImBaX5XJCne4IvL_yUutmn2DFXcM7OgZ5IwCQNDVbRbCQBgFuwkIs1sYAKeY7hVvkDoD$ >
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20250508/af0c1847/attachment-0001.html>


More information about the petsc-users mailing list