Variable for version/release?
Ignacio Valdes
ivaldes at hal-pc.org
Sat Oct 17 16:16:40 UTC 2009
Thanks! Say I get the following message: /var/tmp/rpm-tmp.42695: line
6: [: %{arch_switch}: integer expression expected
with the following code but I do not know why this does not work?
%ifarch x86_64
$define arch_switch 1
%endif
if [ %{arch_switch} -eq 1 ]; then
actual_gtm_path="/opt/lsb-gtm/V5.3-004A_x86_64"
else
actual_gtm_path="/opt/lsb-gtm/V5.3-004A_i686"
fi
-- IV
On Sat, Oct 17, 2009 at 10:35 AM, Jos Vos <jos at xos.nl> wrote:
> On Sat, Oct 17, 2009 at 10:32:52AM -0500, Ignacio Valdes wrote:
>
>> I would like to get the version/release number for use in %post bash.
>> How does one obtain that and other introspection information in %post?
>
> %{version} and %{release}
>
> --
> -- Jos Vos <jos at xos.nl>
> -- X/OS Experts in Open Systems BV | Phone: +31 20 6938364
> -- Amsterdam, The Netherlands | Fax: +31 20 6948204
> _______________________________________________
> Rpm-list mailing list
> Rpm-list at lists.rpm.org
> http://lists.rpm.org/mailman/listinfo/rpm-list
>
More information about the Rpm-list
mailing list