Re: What caused my executable file not to run on a Linux of old version 2.4.36.1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2023-10-10 at 10:28 +0000, Dingjun Chen wrote:
> 
> Hi, Ruoyao and Kai, 
> 
> The kernel is too old and Please see errors occurred below. You
> mentioned "because the executable may use symbols which don't exist in
> the old Glibc" and You are right.  How to fix it? 

I've told you:

   Build a cross compiler and use the root FS of the target board as the
   sysroot.

> By the way, the GNU ld command is 64-bit. However I want to build 32-
> bit executables. 

The 64-bit ld can link 32-bit executables (with -m elf_i386).

> dingjun@G02515:~/DAQ_XYZCross2_cmake/build$ objdump -f /usr/bin/ld
> /usr/bin/ld:     file format elf64-x86-64
> architecture: i386:x86-64, flags 0x00000150:
> HAS_SYMS, DYNAMIC, D_PAGED
> start address 0x0000000000048630
> 
> Can I fix such an error with 32-bit ld?

No.

> Which GNU C/C++ compiler version can offer us a 32-bit ld to link the
> objects? 

ld is not a part of GCC.

> I look forward to your help! 

But now this is just being annoying.  You are lacking some common
knowledge about how a program is linked and executed.  gcc-help is not
for teaching these common knowledge.

Try to find a textbook.

-- 
Xi Ruoyao <xry111@xxxxxxxxxxx>
School of Aerospace Science and Technology, Xidian University




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux