- Package:
- src:binutils
- Source:
- binutils
- Submitter:
- Witold Baryluk
- Date:
- 2025-08-29 05:33:11 UTC
- Severity:
- normal
Was trying to compile libhugetlbfs-2.12 on my 32-bit intel.
(same behaviour with gcc 4.5 and 4.6).
$ make
.....
CC32 obj32/zero_filesize_segment.o
LD32 (preload test) obj32/zero_filesize_segment
/usr/bin/ld: error: zero_filesize_segment.ld: SECTIONS seen after other input
files; try -T/--script
/usr/bin/ld: internal error in input_sections_begin, at ../../gold/merge.h:269
collect2: ld returned 1 exit status
....
Thanks.
tag 624208 + moreinfo help thanks - verbose build log please - please attach the object files and libraries used for the link
Sorry for not providing it at first place, but this is really small project, you can download it from http://sourceforge.net/projects/libhugetlbfs/files/libhugetlbfs/2.12/libhugetlbfs-2.12.tar.gz unpack, and just run make. It is just few files. I attach object files and script which should reproduce error under i386. Regards, Witek
please attach any library (.so files and compiler object files), best in one tarball. In it's current form, the internal error is not reproducible for me.
There is no .so files used. I copied all files I attached in previous message
into separate directory, removed all references to dynamic libraries,
as well all paths, and it still gives me same error.
You mean -lgcc -lc -lgcc_s ld-linux.so.2 crt1.o crtbegin.o crtn.o and dependencies?
Can you say what error you get?
Can you try the same files but with this simplified command:
gold --build-id --no-add-needed --eh-frame-hdr -m elf_i386 --hash-style=both -dynamic-linker \
/lib/ld-linux.so.2 -o zero_filesize_segment \
/usr/lib/crti.o \
zero_filesize_segment.ld ./zero_filesize_segment.o ./testutils.o \
./hugetlbfs_privutils.a
Regards,
Witek
PS. My ld-linux.so.2 and crti.o is from libc6{-dev} 2.11.2-11