rpm build improvements

remove version from folder name to improve ccache utilization

Related-To: NEO-7310
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
This commit is contained in:
Artur Harasimiuk 2022-09-26 12:13:10 +00:00 committed by Compute-Runtime-Automation
parent ec04de61a7
commit 5c0789aed8
7 changed files with 13 additions and 13 deletions

View File

@ -27,7 +27,7 @@ components:
branch: master
dest_dir: infra
fetch_tags: true
revision: v4207
revision: v4211
type: git
internal:
branch: master

View File

@ -57,7 +57,7 @@ if [ "${BUILD_SRPM}" == "1" ]; then
#setup rpm build tree
rm -rf $BUILD_DIR
mkdir -p $BUILD_DIR/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
tar -c -I 'xz -6 -T0' -f $BUILD_DIR/SOURCES/compute-runtime-$VERSION.tar.xz -C $REPO_DIR --transform "s,${REPO_DIR:1},compute-runtime-$VERSION," --exclude=.git\* $REPO_DIR
tar -c -I 'xz -6 -T0' -f $BUILD_DIR/SOURCES/compute-runtime.tar.xz -C $REPO_DIR --transform "s,${REPO_DIR:1},compute-runtime," --exclude=.git\* $REPO_DIR
cp $COPYRIGHT $BUILD_DIR/SOURCES/
cp $SPEC_SRC $BUILD_DIR/SPECS/
@ -93,7 +93,7 @@ if [ "${BUILD_RPM}" == "1" ]; then
if [ "${LOG_CCACHE_STATS}" == "1" ]; then
ccache -z
fi
export CCACHE_BASEDIR=$(readlink -m $BUILD_DIR/BUILD/compute-runtime-${VERSION}/)
export CCACHE_BASEDIR=$(readlink -m $BUILD_DIR/BUILD/compute-runtime/)
rpmbuild --rebuild ${REPO_DIR}/../output/SRPMS/intel-level-zero-gpu-${VERSION}*.src.rpm "${build_args[@]}"
if [ "${LOG_CCACHE_STATS}" == "1" ]; then
ccache -s

View File

@ -15,7 +15,7 @@ Summary: Intel(R) GPU Driver for oneAPI Level Zero.
Group: System Environment/Libraries
License: MIT
URL: https://github.com/intel/compute-runtime
Source0: %{url}/archive/%{version}/compute-runtime-%{version}.tar.xz
Source0: %{url}/archive/%{version}/compute-runtime.tar.xz
Source1: copyright
BuildRequires: libva-devel gcc-c++ cmake ninja-build make
@ -36,7 +36,7 @@ exposing hardware capabilities to applications.
%define debug_package %{nil}
%prep
%autosetup -p1 -n compute-runtime-%{ver}
%autosetup -p1 -n compute-runtime
%build
mkdir build

View File

@ -24,7 +24,7 @@ Summary: Intel(R) GPU Driver for oneAPI Level Zero.
Group: System Environment/Libraries
License: MIT
URL: https://github.com/intel/compute-runtime
Source0: %{url}/archive/%{version}/compute-runtime-%{version}.tar.xz
Source0: %{url}/archive/%{version}/compute-runtime.tar.xz
Source1: copyright
ExclusiveArch: x86_64
@ -48,7 +48,7 @@ exposing hardware capabilities to applications.
%debug_package %{nil}
%prep
%autosetup -p1 -n compute-runtime-%{version}
%autosetup -p1 -n compute-runtime
%build
%cmake .. \

View File

@ -57,7 +57,7 @@ if [ "${BUILD_SRPM}" == "1" ]; then
#setup rpm build tree
rm -rf $BUILD_DIR
mkdir -p $BUILD_DIR/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
tar -c -I 'xz -6 -T0' -f $BUILD_DIR/SOURCES/compute-runtime-$VERSION.tar.xz -C $REPO_DIR --transform "s,${REPO_DIR:1},compute-runtime-$VERSION," --exclude=.git\* $REPO_DIR
tar -c -I 'xz -6 -T0' -f $BUILD_DIR/SOURCES/compute-runtime.tar.xz -C $REPO_DIR --transform "s,${REPO_DIR:1},compute-runtime," --exclude=.git\* $REPO_DIR
cp $COPYRIGHT $BUILD_DIR/SOURCES/
cp $SPEC_SRC $BUILD_DIR/SPECS/
@ -98,7 +98,7 @@ if [ "${BUILD_RPM}" == "1" ]; then
if [ "${LOG_CCACHE_STATS}" == "1" ]; then
ccache -z
fi
export CCACHE_BASEDIR=$(readlink -m $BUILD_DIR/BUILD/compute-runtime-${VERSION}/)
export CCACHE_BASEDIR=$(readlink -m $BUILD_DIR/BUILD/compute-runtime/)
rpmbuild --rebuild ${REPO_DIR}/../output/SRPMS/intel-opencl-${VERSION}*.src.rpm "${build_args[@]}"
if [ "${LOG_CCACHE_STATS}" == "1" ]; then
ccache -s

View File

@ -18,7 +18,7 @@ Summary: Intel(R) Graphics Compute Runtime for OpenCL(TM)
Group: System Environment/Libraries
License: MIT
URL: https://github.com/intel/compute-runtime
Source0: %{url}/archive/%{version}/compute-runtime-%{version}.tar.xz
Source0: %{url}/archive/%{version}/compute-runtime.tar.xz
Source1: copyright
Requires: intel-gmmlib
@ -40,7 +40,7 @@ Intel(R) Graphics Compute Runtime for OpenCL(TM) is a open source project to con
%define debug_package %{nil}
%prep
%autosetup -p1 -n compute-runtime-%{ver}
%autosetup -p1 -n compute-runtime
%build
mkdir build

View File

@ -26,7 +26,7 @@ Summary: Intel(R) Graphics Compute Runtime for OpenCL(TM)
License: MIT
Group: System Environment/Libraries
Url: https://github.com/intel/compute-runtime
Source0: %{url}/archive/%{version}/compute-runtime-%{version}.tar.xz
Source0: %{url}/archive/%{version}/compute-runtime.tar.xz
Source1: copyright
ExclusiveArch: x86_64
@ -50,7 +50,7 @@ Summary: ocloc package for opencl
%debug_package %{nil}
%prep
%autosetup -p1 -n compute-runtime-%{version}
%autosetup -p1 -n compute-runtime
%build
%cmake .. \