What worries me is that a lot of effort is being made to make this plugin work on MacOSX, when it is as yet not clear whether rpmbuild works properly on MacOSX at all.
I looked last night to see whether rpm was available for MacOSX, and I've found a lot of people complaining that while they can get rpm installed, they cannot get rpmbuild to work for them. While it is true that in the Java world we want the Java code to work everywhere, rpm doesn't seem to practically work everywhere, and so we should focus our efforts on getting the plugin working where rpm works, and that means on Redhat derivatives.
We also want to be careful of the RPM version in use. Newer versions of RPM found on Redhat derivatives have subtle difference in behaviour to the probably-older versions of RPM available for less mainstream RPM platforms. We don't want to force the plugin to only support older behaviour, and so break the plugin when used with up to date versions of RPM.
For example, newer versions of RPM seem to lowercase the architecture string, while this test insists on using mixed case. Therefore, newer versions of RPM break. We should fix the test in this case to remove the mixed case.