Previously some headers were getting installed twice, once as expected and again as part of the compat32 library stage. Makefile.libcompat sets -DLIBRARIES_ONLY for the install make invocation which causes bsd.lib.mk to skip headers. However some headers are handled via bsd.prog.mk, which does not use LIBRARIES_ONLY.
@jrtc27 pointed out in IRC that we'll have similar issues with CONFS and FILES but this should at least be a start.
Using tools/pkgbase/metalog_reader.lua we can find a bunch of duplicated headers:
warning: ./usr/include/infiniband/arch.h repeated with same meta: line 11478,38405 warning: ./usr/include/infiniband/byteorder.h repeated with same meta: line 11473,38400 warning: ./usr/include/infiniband/byteswap.h repeated with same meta: line 11474,38401 warning: ./usr/include/infiniband/cm.h repeated with same meta: line 11494,38421 warning: ./usr/include/infiniband/cm_abi.h repeated with same meta: line 11495,38422 ...