Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package linux-glibc-devel for 
openSUSE:Factory checked in at 2021-07-08 22:49:04
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/linux-glibc-devel (Old)
 and      /work/SRC/openSUSE:Factory/.linux-glibc-devel.new.2625 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "linux-glibc-devel"

Thu Jul  8 22:49:04 2021 rev:79 rq:902815 version:5.13

Changes:
--------
--- /work/SRC/openSUSE:Factory/linux-glibc-devel/linux-glibc-devel.changes      
2021-02-23 20:21:54.619735560 +0100
+++ 
/work/SRC/openSUSE:Factory/.linux-glibc-devel.new.2625/linux-glibc-devel.changes
    2021-07-08 22:49:05.668156273 +0200
@@ -1,0 +2,15 @@
+Mon Jun 28 12:19:57 UTC 2021 - Andreas Schwab <[email protected]>
+
+- Update to kernel headers 5.13
+
+-------------------------------------------------------------------
+Thu May 20 09:46:11 UTC 2021 - Andreas Schwab <[email protected]>
+
+- Add cross-*-linux-glibc-devel packages
+
+-------------------------------------------------------------------
+Tue Apr 27 09:22:59 UTC 2021 - Andreas Schwab <[email protected]>
+
+- Update to kernel headers 5.12
+
+-------------------------------------------------------------------

Old:
----
  linux-glibc-devel-5.11.tar.xz

New:
----
  linux-glibc-devel-5.13.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ linux-glibc-devel.spec ++++++
--- /var/tmp/diff_new_pack.CcW7Cz/_old  2021-07-08 22:49:06.128152724 +0200
+++ /var/tmp/diff_new_pack.CcW7Cz/_new  2021-07-08 22:49:06.132152693 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           linux-glibc-devel
-Version:        5.11
+Version:        5.13
 Release:        0
 Summary:        Linux headers for userspace development
 License:        GPL-2.0-only
@@ -25,7 +25,6 @@
 URL:            http://www.kernel.org/
 Source:         %{name}-%{version}.tar.xz
 Source1:        install_all.sh
-BuildRequires:  fdupes
 BuildRequires:  xz
 # rpm-build requires gettext-tools; ignore this, in order to shorten cycles 
(we have no translations)
 #!BuildIgnore:  gettext-tools
@@ -35,31 +34,42 @@
 Provides:       kernel-headers
 Provides:       linux-kernel-headers = %{version}
 Obsoletes:      linux-kernel-headers < %{version}
-%global kernel_arch %_target_cpu
-%ifarch x86_64 %ix86
-%global kernel_arch x86
-%endif
-%ifarch ppc ppc64 ppc64le
-%global kernel_arch powerpc
-%endif
-%ifarch %arm
-%global kernel_arch arm
-%endif
-%ifarch aarch64
-%global kernel_arch arm64
-%endif
-%ifarch riscv64
-%global kernel_arch riscv
-%endif
-%ifarch s390x
-%global kernel_arch s390
-%endif
-%ifarch hppa
-%global kernel_arch parisc
-%endif
-%ifarch sparc64
-%global kernel_arch sparc
-%endif
+
+%{lua:
+function cross_archs()
+  return "aarch64", "arm", "hppa", "i386", "m68k", "mips", "ppc64", "ppc64le", 
"riscv64", "s390x", "sparc", "sparc64", "x86_64"
+end
+
+function kernel_arch(arch)
+  local map = {
+     ["aarch64"] = "arm64",
+     ["armv6hl"] = "arm",
+     ["armv7hl"] = "arm",
+     ["hppa"] = "parisc",
+     ["i386"] = "x86",
+     ["i586"] = "x86",
+     ["i686"] = "x86",
+     ["ppc"] = "powerpc",
+     ["ppc64"] = "powerpc",
+     ["ppc64le"] = "powerpc",
+     ["riscv64"] = "riscv",
+     ["s390x"] = "s390",
+     ["sparc64"] = "sparc",
+     ["x86_64"] = "x86",
+  }
+  return map[arch] or arch
+end
+
+function gcc_target(arch)
+  local map = {
+    ["arm"] = "arm-suse-linux-gnueabi",
+    ["i386"] = "i586-suse-linux",
+    ["ppc64"] = "powerpc64-suse-linux",
+    ["ppc64le"] = "powerpc64le-suse-linux",
+  }
+  return map[arch] or arch.."-suse-linux"
+end
+}
 
 %description
 This package provides Linux kernel headers, the kernel API description
@@ -68,12 +78,28 @@
 kernel-(flavor)-devel, or kernel-syms to pull in all kernel-*-devel,
 packages, instead.
 
+%{lua:
+  for i,arch in ipairs({cross_archs()}) do
+    print(rpm.expand([[
+
+%package -n cross-]]..arch..[[-linux-glibc-devel
+Summary:        Linux headers for ]]..arch..[[ userspace cross development
+Group:          Development/Libraries/C and C++
+BuildArch:      noarch
+
+%description -n cross-]]..arch..[[-linux-glibc-devel
+This package provides Linux kernel headers for ]]..arch..[[, the kernel API 
description
+required for compilation of almost all programs.
+]]))
+  end}
+
 %prep
 %setup -q -n linux-glibc-devel-%{version}
 
 %build
-cd %{kernel_arch}
-cat > version.h <<\BOGUS
+for karch in *; do
+  cd $karch
+  cat > version.h <<\BOGUS
 #ifdef __KERNEL__
 #error "======================================================="
 #error "You should not include %{_includedir}/{linux,asm}/ header"
@@ -109,18 +135,31 @@
 #error "======================================================="
 #else
 BOGUS
-# Get LINUX_VERSION_CODE and KERNEL_VERSION directly from kernel
-cat usr/include/linux/version.h >> version.h
-cat >> version.h <<\BOGUS
+  # Get LINUX_VERSION_CODE and KERNEL_VERSION directly from kernel
+  cat usr/include/linux/version.h >> version.h
+  cat >> version.h <<\BOGUS
 #endif
 BOGUS
-cat version.h
+  cd ..
+done
 
 %install
-cd %{kernel_arch}
+cd %{lua:print(kernel_arch(rpm.expand("%_target_cpu")))}
 cp -a usr %{buildroot}/
 cp -a version.h %{buildroot}%{_includedir}/linux/
-%fdupes %{buildroot}%{_includedir}
+cd ..
+%{lua:
+  for i,arch in ipairs({cross_archs()}) do
+    print(rpm.expand([[
+sysroot=%{_prefix}/]]..gcc_target(arch)..[[/sys-root
+mkdir -p %{buildroot}${sysroot}/%{_includedir}/linux/
+cd ]]..kernel_arch(arch)..[[
+
+cp -a usr %{buildroot}${sysroot}
+cp -a version.h %{buildroot}${sysroot}/%{_includedir}/linux/
+cd ..
+]]))
+  end}
 
 %pre
 if test -L %{_includedir}/asm; then
@@ -128,7 +167,14 @@
 fi
 
 %files
-%defattr(-,root,root)
 %{_includedir}/*
 
+%{lua:
+  for i,arch in ipairs({cross_archs()}) do
+    print(rpm.expand([[
+
+%files -n cross-]]..arch..[[-linux-glibc-devel
+%{_prefix}/]]..gcc_target(arch).."\n"))
+  end}
+
 %changelog

++++++ linux-glibc-devel-5.11.tar.xz -> linux-glibc-devel-5.13.tar.xz ++++++
++++ 107906 lines of diff (skipped)

Reply via email to