The bindir definition can be shortened by replacing %{_datadir}/%{name} with %{homedir} Might want to replace "tomcat" with %{name} in the add user and group block: # add the tomcat user and group %{_sbindir}/groupadd -g %{tcuid} -r tomcat 2>/dev/null || : %{_sbindir}/useradd -c "Apache Tomcat" -u %{tcuid} -g tomcat \ -s /bin/nologin -r -d %{homedir} tomcat 2>/dev/null || : In the line: %{_javadir}/%{name}/%{name}-el-%{elspec}-api.jar %{_javadir}/%{name} can be replaced with: %{libdir}?
Created attachment 502313 [details] Patch with review modifications
The original spec defined in: https://bugzilla.redhat.com/show_bug.cgi?id=700199
Wrong component - this should have been filed against tomcat itself. Also providing a git formatted patch that the maintainer can just git am your_patch would be helpful.
Looks like Ivan applied it in http://pkgs.fedoraproject.org/gitweb/?p=tomcat.git;a=commitdiff;h=ca271e5d851bea547f2020de374e685531303f18 Closing.
I'm not sure that setting username to variable is a good idea tomcat6 and tomcat5 are using tomcat username httpd is using apache username...