diff --git a/_multibuild b/_multibuild new file mode 100644 index 0000000..0f6de97 --- /dev/null +++ b/_multibuild @@ -0,0 +1,4 @@ + + openSUSE + SLE + diff --git a/fwupd.changes b/fwupd.changes index 1f45d1f..15dc548 100644 --- a/fwupd.changes +++ b/fwupd.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Jul 24 06:52:18 UTC 2020 - Yifan Jiang + +- Build the package separately for openSUSE and SLE using + _multibuild (jsc#SLE-11744). + ------------------------------------------------------------------- Wed Jun 03 15:32:46 UTC 2020 - dimstar@opensuse.org diff --git a/fwupd.spec b/fwupd.spec index c3668a8..3ac0376 100644 --- a/fwupd.spec +++ b/fwupd.spec @@ -17,16 +17,35 @@ # needssslcertforbuild +%define flavor @BUILD_FLAVOR@%{nil} + +%if "%{flavor}" == "" +ExclusiveArch: %{nil} +%else +%define branding_name %{flavor} +%if "%{flavor}" == "SLE" +%define build_SLE 1 +%else +%define build_openSUSE 1 +%endif +%endif + +%if (0%{?build_SLE} && 0%{?is_opensuse}) || (0%{?build_openSUSE} && ! 0%{?is_opensuse}) +# Don't build SLE branding on openSUSE and vice-versa +ExclusiveArch: %{nil} +%endif + %ifarch %{ix86} x86_64 aarch64 %bcond_without efi_fw_update %else %bcond_with efi_fw_update %endif -%if 0%{?is_opensuse} +%if 0%{?build_openSUSE} %global efidir opensuse %else %global efidir sles %endif + Name: fwupd Version: 1.4.2 Release: 0