We are trying to build Sun packages and Linux RPMs from the same specs. The single major hurdle is the naming. We are using our own prefix to distinguish packages build in-house from those supplied by 3rd parties and our existing set of Linux-tested specs uses the names like: example_foo.
On Sun, however, these are "illegal" -- after successful build, pkgbuild invokes pkgmk to wrap-up the package and gets:
pkgmk: ERROR: invalid package abbreviation <example_foo>
There is got to be some way to automatically change those into EXAMPLEfoo -- without inserting an %if into each spec...