CMPLIB – Compare IBM i Libraries for differences
The CMPLIB (Compare Library Objects) tool compares objects in any two libraries to find differences in objects or embedded modules within those two libraries:
CMPLIB LIB1(SOURCE) LIB2(TARGET) DATABASE(*REBUILD)

This dives deeper into the program definitions to compare embedded modules in both *PGM and *SRVPGM
The Database (*DATABASE/*REBUILD) option allows the utility work with previously built data, or to refresh the data every execution. This uses the @GENXREF database which is rebuilt daily by default.
When this has loaded all object details, a delta is performed and all objects are displayed in a subfile. Any programs that are found to have different embedded module information are highlighted


