%define module core %define prefix %(%{SOURCE1} --prefix %{module}_uni) %define conf %{_sysconfdir}/ld.so.conf.d/20-amdgpu.conf Summary: Core meta package Name: amdgpu-core Version: 20.10 Release: 1048554.el8 Epoch: 0 BuildArch: noarch License: MIT Group: User Interface/X Hardware Support URL: http://www.amd.com/ Source1: rbh.sh Source2: rbh.conf %description Core meta package for unified amdgpu driver. %install %{SOURCE1} --install %{module}_uni %{?_licensedir:mkdir -p %{buildroot}$(sed "s|/usr|%{prefix}|"<<<%{_licensedir})} %pre %if 0%{?rhel} if [ $(rpm --eval 0%%{?rhel}) != "0%{rhel}" ] ; then >&2 echo "ERROR: This package can only be installed on EL%{?rhel}." exit 1 fi %endif %post prefix=%{prefix} conf=%{conf} echo "${prefix}/$(rpm --eval %%{_lib})" >$conf if [ "$(rpm --eval %%{_arch})" = "x86_64" ]; then echo "${prefix}/lib" >>$conf fi %postun if [ $1 -eq 0 ]; then rm -f %{conf} /sbin/ldconfig fi %files %{prefix} %changelog * Wed Apr 08 2020 AMD automated build system 20.10-1048554.el8 - build - gerritgit/releases/amd-20.10 - 2fdf5d32cc288f77af4f21149b16e5cafca7b723 - build ID: 1048554