If you plan to recompile or relink a program, you can use the ANALZYE/IMAGE command to list which shareable libraries the program was orignally linked with. For example:
$ anal/image/out=tmp.txt p2$lib:nav.exe %ANALYZE-I-ERRORS, VICSYS:[VICAR160.P2.LIB.AXP-VMS]NAV.EXE;3 0 errors $ search/window=(0,11) tmp.txt shareable Shareable Image List 0) "VRDI$SHARE" 1) "V2$SHARE" 2) "TAE$SHARE" 3) "MULTINET_SOCKET_LIBRARY" 4) "DECC$SHR" 5) "DEC$FORRTL" 6) "DPML$SHR" 7) "LIBOTS" 8) "SYS$PUBLIC_VECTORS"