Historical bug tracker for the Pacman package manager.
The pacman bug tracker has moved to gitlab:
https://gitlab.archlinux.org/pacman/pacman/-/issues
This tracker remains open for interaction with historical bugs during the transition period. Any new bugs reports will be closed without further action.
The pacman bug tracker has moved to gitlab:
https://gitlab.archlinux.org/pacman/pacman/-/issues
This tracker remains open for interaction with historical bugs during the transition period. Any new bugs reports will be closed without further action.
FS#42848 - [pacman] 'makepkg' should be more cross-compiler friendly
Attached to Project:
Pacman
Opened by Anatol Pomozov (anatolik) - Wednesday, 19 November 2014, 15:49 GMT
Last edited by Doug Newgard (Scimmia) - Wednesday, 19 November 2014, 16:10 GMT
Opened by Anatol Pomozov (anatolik) - Wednesday, 19 November 2014, 15:49 GMT
Last edited by Doug Newgard (Scimmia) - Wednesday, 19 November 2014, 16:10 GMT
|
DetailsThere are issues when using standard Arch toolset for cross-compiled projects.
makepkg strips libraries. It uses "strip" native binary that works only for current architecture binaries. This is the problem for cross-compiled packages. Although these packages are created for user's architectures (x86) they contain binaries for some other arch (arm/arm64/avr/...). And proper toolchain should be used - e.g. arm-none-eabi-strip should be used for arm embedded libs. Currently makepkg does not strip such cross-compiled binaries correctly. The package maintainers have to use '!strip' option and call *-strip manually. The code that does stripping comes from makepkg.in https://projects.archlinux.org/pacman.git/tree/scripts/makepkg.sh.in#n1750 function strip_file() It is not clear for me how this function should find exact toolchain. Here are several ideas: 1) Use information from 'file' to find what toolchain to use. It is example of output for 'arm-none-eabi' arch $ file /usr/arm-none-eabi/lib/crt0.o /usr/arm-none-eabi/lib/crt0.o: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), not stripped 2) It seems all (??) cross-compile libraries are kept in /usr/arm-none-eabi/lib/. Thus we can check if a package contains /usr/XXX/lib then assume XXX is architecture. 3) Check if make dependencies contains XXX-binutils. e.g. arm-none-eabi-binutils. If it presents assume user builds corss-compiled package. An example of such cross-compile project is https://aur.archlinux.org/packages/libopencm3-git that uses arm-none-eabi toolchain. |
This task depends upon