If the headers are GPL, then his code will be GPL'd.
If he's linking against librpm, then his code will be GPL'd.
Wez, call me brain damaged here, is package metadata covered by the same license as the code in the package and, more importantly, is the metadata in an RPM always covered by a GPL license? i.e. RPM package of a BSD licensed program/library.
Even then, is reading that data enough to transmit the GPL virus?
What I'm coming around to cicumspectly is: Are you talking about headers as in:
<?php
$fp = fopen("somefile.rpm", "r");
$headers = fread($fp, 2048);
Or headers as in:
#include <librpm.h>
In the latter case the GPL issue is a serious one and a bar against entry into PECL, but in the former case I can't imagine how there's a problem (since not everything in any given .rpm is necessarily GPL licensed which means that the purpose of the linking ext is not explicitly as a derivative work of the GPL licensed IP).
-Sara