Building an Empty RPM
When searching for information on creating an empty, or null rpm file, I was unable to locate the spec file details needed. In another post, I will describe my need for this empty rpm, but for now here is the minimal spec file needed to build an empty rpm:
Place the following in a file called, php.spec
Summary: Empty PHP
Name: php
Version: 0
Release: 0
License: Public
Group: Applications/System
%description
Empty PHP RPM
%files
Now, build your new php rpm using the following command:
# rpmbuild -bb php.spec
Processing files: php-0-0
Checking for unpackaged file(s): /usr/lib/rpm/check-files %{buildroot}
Wrote: /usr/src/redhat/RPMS/i386/php-0-0.i386.rpm
And that’s it, you now have an empty rpm!

Just curious why you need an empty RPM file?
This was in response to an issue with Plesk requiring the ‘php’ rpm package for the “Run as Apache module” setting.
One system we encountered was upgraded to php52 using the IUS repository. Since the IUS repo uses ‘php52′ as the base rpm package name (for php 5.2), not having a package named ‘php’ appeared to have caused the web hosting settings of PHP support: “Run as Apache module”, to be disabled/unavailable.
Adding in an empty ‘php’ rpm re-enabled the “Run as Apache module” option quickly while we determined a better long term solution.
I will be needing this in the future so I saved this lnk!!
Thanks!
Paul F.
Thanks, it helped me to create empty package with dependencies :)
That worked! Thanks!
haha, thanks. worked a treat to fool yum into installing cacti with the altertnative php53 packages.
lol, it can be done even blanker :P
Name: blank
Version: 0
Release: 0
Summary: blank
License: blank
%description
%files