Accepting request 60424 from Kernel:openSUSE-11.4
Accepted submit request 60424 from user michal-m OBS-URL: https://build.opensuse.org/request/show/60424 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/kernel-source?expand=0&rev=127
This commit is contained in:
committed by
Git OBS Bridge
parent
18e7be3f39
commit
9cc54beab0
@@ -5,14 +5,28 @@
|
||||
%define _buildshell /bin/bash
|
||||
|
||||
%define using_buildservice 0%{?opensuse_bs}
|
||||
|
||||
# source_rel is the package release string, without the rebuild counter
|
||||
# generated by the build service. In non-official builds, the upstream
|
||||
# EXTRAVERSION component is also part of the release string,
|
||||
# e.g. next.20110101.9.6 (hyphens are replaced by periods). Builds in the
|
||||
# official distribution projects replace the release string though.
|
||||
%define source_rel %release
|
||||
%if %using_buildservice
|
||||
# The last digit is a volatile rebuild counter, strip it
|
||||
%define source_rel %(release=%release; echo ${release%.*})
|
||||
%endif
|
||||
|
||||
%define release_major %(rel="%source_rel" ; echo "${rel##[^0-9]*.}")
|
||||
%define kernelrelease %patchversion-%release_major
|
||||
# release_num is the numeric source revision part of the release number,
|
||||
# i.e. source_rel without the upstream tags like -rcX. A hyphen is added
|
||||
# automatically for convenient use.
|
||||
# examples: rc3 -> "", rc3.1 -> -1, next.20110101.9 -> -9
|
||||
#
|
||||
# patchversion is inserted into the spec files by the mkspec script, it is the
|
||||
# upstream release string unchanged, e.g. 2.6.38-rc3
|
||||
%define release_num %(upstream=%patchversion; upstream=${upstream#%version}; upstream=${upstream#-}; upstream=${upstream//-/.}; rel="%source_rel" ; res="${rel#$upstream}"; res=${res#.}; echo ${res:+-}${res})
|
||||
|
||||
# how the kernel release string (uname -r) should look like
|
||||
%define kernelrelease %patchversion%release_num
|
||||
|
||||
%define my_builddir %_builddir/%{name}-%{version}
|
||||
|
||||
|
Reference in New Issue
Block a user