Updating OSX was unable to locate /usr/lib/libnetsnmp.25.dylib

Upgrading to the latest public Beta for OS X 10.10.5 will break the php and while I was trying to execute the snippet code from the php terminal I encountered the following messages:

$ arc diff
dyld: Library not loaded: /usr/lib/libnetsnmp.25.dylib
Referenced from: /usr/bin/php
Reason: image not found
Trace/BPT trap: 5

I checked the contents of the Library folder and discovered some changes to the Net-SNMP libraries:

ls -la /usr/lib/libnetsnmp.*
-rwxr-xr-x 1 root wheel 1106528 10 Sep 2014 /usr/lib/libnetsnmp.15.1.2.dylib
lrwxr-xr-x 1 root wheel 23 15 Feb 11:41 /usr/lib/libnetsnmp.15.dylib -> libnetsnmp.15.1.2.dylib
lrwxr-xr-x 1 root wheel 25 30 Jul 09:49 /usr/lib/libnetsnmp.25.dylib -> /usr/lib/libnetsnmp.dylib
lrwxr-xr-x 1 root wheel 25 30 Jul 09:46 /usr/lib/libnetsnmp.25dylib -> /usr/lib/libnetsnmp.dylib
-rwxr-xr-x 1 root wheel 1241136 9 Jul 08:38 /usr/lib/libnetsnmp.30.dylib
-rwxr-xr-x 1 root wheel 476848 10 Sep 2014 /usr/lib/libnetsnmp.5.2.1.dylib
lrwxr-xr-x 1 root wheel 22 15 Feb 11:41 /usr/lib/libnetsnmp.5.dylib -> libnetsnmp.5.2.1.dylib
lrwxr-xr-x 1 root wheel 19 17 Jul 02:23 /usr/lib/libnetsnmp.dylib -> libnetsnmp.30.dylib

What solved the issue
Symlinking libnetsnmp.25.dylib to the latest version of libnetsnmp.dylibfixes the issue:

$ sudo ln -s /usr/lib/libnetsnmp.dylib /usr/lib/libnetsnmp.25.dylib

Still not sure why the php was not updated to match the system changes. The php version now says

$ php -v
PHP 5.5.24 (cli) (built: May 19 2015 10:10:05)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2015 Zend Technologies

Send a Message