using profile: default/linux/amd64/23.0/musl/llvm build will failed: > readelf: error: unknown argument '-w' > cc -O2 -g -Wall -W -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -DXXH_INLINE_ALL=1 -DDWZ_VERSION='"0.15"' -DFSF_YEARS='"1992-2021"' -DRH_YEARS='"2001-2021"' -DSUSE_YEARS='"2019-2021"' -c -o args.o args.c -DNATIVE_ENDIAN_VAL=ELFDATA2LSB -DNATIVE_POINTER_SIZE= > args.c:665:54: error: expected expression > 665 | multifile_force_ptr_size = NATIVE_POINTER_SIZE; > | ^ > 1 error generated. > make: *** [Makefile:50: args.o] Error 1 the reason is NATIVE_POINTER_SIZE is determined by readelf, but llvm-readelf has different arguments w/ gnu readelf, it doesn't accept "-wi". > NATIVE_POINTER_SIZE=$(shell ${READELF} -wi native.o \ > | grep "Pointer Size:" \ > | sed 's/.*: *//') I don't find other argument of llvm-readelf to get Pointer size, another command llvm-dwarfdump can get addr_size, > # llvm-dwarfdump --debug-info /var/tmp/portage/sys-devel/dwz-0.15-r4/work/dwz/native.o > /var/tmp/portage/sys-devel/dwz-0.15-r4/work/dwz/native.o: file format elf64-x86-64 > > .debug_info contents: > 0x00000000: Compile Unit: length = 0x00000033, format = DWARF32, version = 0x0005, unit_type = DW_UT_compile, abbr_offset = 0x0000, addr_size = 0x08 (next unit at 0x00000037) maybe it's best to write a small program to get the native pointer size? Reproducible: Always
*** This bug has been marked as a duplicate of bug 945628 ***