Author Topic: cross compiling e2fsprogs  (Read 7910 times)

ced

  • Full Member
  • ***
  • Posts: 225
    • View Profile
    • http://
cross compiling e2fsprogs
« on: January 30, 2004, 06:33:53 am »
I\'ve tried to cross compiling e2fsprogs and it doesn\'t do it...

$ export PATH=/opt/cross/bin:$PATH

$ ./configure --target=arm-linux --with-cc=arm-linux-gcc --with-linker=arm-linux-ld --prefix=/opt/cross/arm-linux

Quote
loading cache ./config.cache
checking for non-GNU ld... (cached) /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... (cached) yes
Generating configuration file for e2fsprogs version 1.34
Release date is July, 2003
checking host system type... arm-unknown-linux-gnu
CC=arm-linux-gcc
checking for gcc... (cached) cc
checking whether the C compiler (cc  ) works... yes
checking whether the C compiler (cc  ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether cc accepts -g... (cached) yes
LD=arm-linux-ld
checking how to run the C preprocessor... (cached) cc -E

It compile the library and tools as x86 binaries...

what\'s wrong? :-(

I need the e2fsprogs library to cross-compile qtopia 1.7. I\'ll try to make a rom with it...
SL-5600, kernel 2.6.16 + GPE from .dev
Ethernet Socket LP-E
Viking 256M SD

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
cross compiling e2fsprogs
« Reply #1 on: January 30, 2004, 08:55:02 am »
Try:

$ export PATH=/opt/cross/bin:/opt/cross/arm-linux/bin:$PATH
$ export CC=arm-linux-gcc
$ export LINKER=arm-linux-g++
$ export COMPILER=arm-linux-gcc
$ ./configure --host=arm-linux --build=i686-linux
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

ced

  • Full Member
  • ***
  • Posts: 225
    • View Profile
    • http://
cross compiling e2fsprogs
« Reply #2 on: January 30, 2004, 10:22:41 am »
I get this...

Code: [Select]
loading cache ./config.cache

checking for non-GNU ld... (cached) /usr/bin/ld

checking if the linker (/usr/bin/ld) is GNU ld... (cached) yes

Generating configuration file for e2fsprogs version 1.34

Release date is July, 2003

checking host system type... arm-unknown-linux-gnu

CC defaults to arm-linux-gcc

checking for gcc... (cached) cc

checking whether the C compiler (cc  ) works... no

configure: error: installation or configuration problem: C compiler cannot create executables.
SL-5600, kernel 2.6.16 + GPE from .dev
Ethernet Socket LP-E
Viking 256M SD

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
cross compiling e2fsprogs
« Reply #3 on: January 30, 2004, 11:19:45 am »
Try running:

$ make distclean

before you try my commands.


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

ced

  • Full Member
  • ***
  • Posts: 225
    • View Profile
    • http://
cross compiling e2fsprogs
« Reply #4 on: January 30, 2004, 11:23:55 am »
success! :-)

$tar xzvf e2fsprogs-1.34.tar.gz

$mkdir e2fsprogs-build

$cd e2fsprogs

$ export PATH=/opt/cross/bin:$PATH

$ CC=arm-linux-gcc LD=arm-linux-ld RANLIB=arm-linux-ranlib CROSS_COMPILE=arm-linux- ../e2fsprogs-1.34/configure --host=arm-linux --build=i686-pc-linux-gnu --prefix=/opt/cross/arm-linux --enable-elf-shlibs
SL-5600, kernel 2.6.16 + GPE from .dev
Ethernet Socket LP-E
Viking 256M SD