Geunsik Lim [Mon, 9 Mar 2020 11:36:01 +0000 (20:36 +0900)]
ARM: Improved CPU handling to build 32bit packages on 64bit Linux
This commit is to handle a different attribute of CPU architectures
between kernel-space and user-space. For example, the Tizen platform
6.0 consists the ARM64-based Linux kernel and ARM32-based Tizen
platform packages. When the developer want to compile the user-space
software packages to support a ARM32 bit CPU architecture, they meet
an unexpected issue because the 'linux-glibc-devel' package is installed
based on CPU architecture of the Linux kernel on the real target board.
Therefore, we need to improve the compatibility of the user-space software
packages based on 32bit CPU architecture. Let's replace the criteria from
"uname -m" command to "%_arch" macro.
Let's assume that the Tizen 6.0 platform is based on ARM32bit,
and the Tizen Linux kernel is based on ARM64 bit (arm64/aarch64).
**Changelog**
* Version 2:
- Use '_arch' instead of tizen-release package to avoid a build issue
(Note that this package does not use the Unified repository.)
- Fixed typos
- Added annotation for maintenance
* Version 1:
- Replaced "uname -m" with "/etc/tizen-release"
**Self assessment**
sh-3.2# cat /etc/tizen-release
Tizen6/Unified 6.0.0 (arm)
VERSION = 6.0.0
CODENAME = Next
* Before this commit: It's incorrect.
sh-3.2# ls -al /usr/include/asm
lrwxrwxrwx 1 root root 7 Mar 4 14:26 /usr/include/asm -> asm-arm64
* After this commit: It's correct.
sh-3.2# ls -al /usr/include/asm
lrwxrwxrwx 1 root root 7 Mar 9 19:38 /usr/include/asm -> asm-arm
This commit allows all projects depending on kdbus (glib,
libdbus, libdbuspolicy, systemd) to use one common interface
file. Currently all project needing this header have it
duplicated.
Additionally, it allows to remove file from Apache-2.0
project which cased license conflict.