I have a package I'm integrating into my LTIB tree, and the tarfile uses a
style of naming that is not conventional. This is probably not so
important, but I was wondering if it would be possible to add support for
something like the _rpmfilename macro in the ltib script when it comes
time to check for a pre-built rpm and for the creation of patch files.
The tarfile I'm working with is:
SeaMAC_0.98.1.tar.gz
It expands to a directory tree whose base is:
seamac/
I figured out that I needed to add
%Prep
%setup -n seamac
to my .spec file to have the build directory recognized. Beyond that, I
wanted to see if I could change the name of the output binary package file
name from the default
SeaMAC-0.98.1-1.ppc.rpm
to
SeaMAC_0.98.1-1.ppc.rpm
(with the underscore), just to match the format of the .tar.gz file name.
Using either the _rpmfilename or the _build_name_fmt macro in the %Files
section of my .spec file, I was able to accomplish this.
%Files
%define _rpmfilename %{ARCH}/%{NAME}_%{VERSION}-%{RELEASE}.%{ARCH}.rpm
I ran into a separate problem then however, since the ltib script was
searching for the .rpm file with the dash and not the underscore, and so
this package was being rebuilt every time I ran ltib, because it wasn't
finding the .rpm file created in the previous run. I noticed that there
could potentially be support for this if the ltib script searched for the
_rpmfilename macro in the .spec file. Also, it might be nice if the patch
files that are created could check for this as well, and instead of
SeaMAC-0.98.1-1254860786.patch
be
SeaMAC_0.98.1-1254860786.patch
depending on if _rpmfilename or _build_name_fmt or some other similar type
macro were defined in the .spec file. I don't know if added flexibility
would be useful here, or if it's just bad naming conventions to begin
with.
_______________________________________________
LTIB home page: http://ltib.org
Ltib mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/ltib