开发者

Rpmbuild - setting name of created .rpm

开发者 https://www.devze.com 2022-12-23 04:26 出处:网络
I\'ve been trying to find out what\'s the easiest way to set a fixed filename during rpm creation. Can it be set somewhere in .spec file or as rpmbuild parameter? The default name depends on version a

I've been trying to find out what's the easiest way to set a fixed filename during rpm creation. Can it be set somewhere in .spec file or as rpmbuild parameter? The default name depends on version and relea开发者_JAVA技巧se number. Name of my rpm has to be always the same.

thanks

sync


Yes, override the %_rpmfilename macro. The default value according to my rpm --showrc is:

%%{ARCH}/%%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm

So, you could add the following (or similar) to the top of your .spec file:

%define _rpmfilename %%{NAME}.%%{OS}.%%{ARCH}.rpm
0

精彩评论

暂无评论...
验证码 换一张
取 消