I had a go at what you suggested but this had no effect, it came up with exactly the same error. From what i can see from the error, it is looking in the linux/ directory in the libmad/ source directory, not in /usr/src/linux. I tried doing what you suggested but making the link in the libmad directory rather than in /usr/src, so now i have a link
mad-0.13.0b/libmad/linux -> /usr/local/arm/gnu/release/arm-linux/include.
Now it finds errno.h ok but generates different errors
decoder.c: In function 'mad_decoder_finish': decoder.c:91 'EINTR' undeclared (first use in this function) decoder.c:91 (Each undeclared identifier is reported only once for each function it apears in.) decoder.c In function'send_io': decoder.c:120 'EINTR' undeclared (first use in this function) decoder.c In function'recieve_io': decoder.c:142 'EINTR' undeclared (first use in this function) decoder.c:145 'EAGAIN' undeclared (first use in this function) make: *** [decoder.lo] error 1
I am wondering are there some required files that are needed for cross compiling that i have not installed?
Thanks
On Tue, 5 Mar 2002 13:45:55 +0800 "davidlee" davidlee@gv.com.tw wrote:
Dear Gareth: Maybe do could do this 1. logon as root 2. cd /usr/src 3. rm linux 4. ln -s arm-linux(or any path that you installed Arm Linux enviroment) ./linux
Try again , Good lucky.
----- Original Message ----- From: "Gareth" g.c.bransby-99@student.lboro.ac.uk To: "Gad Hayisraeli" gad@syete.co.il Cc: "Mad Dev List" mad-dev@lists.mars.org Sent: Thursday, February 28, 2002 7:56 PM Subject: RE: [mad-dev] Cross compiling libmad for ARM
Thanks for the help!
I had a go at doing the CC=... and RANLIB=... on the same line as the ./configure as suggested. This seems to have the dedsired effect, the configure script reports that gcc is a cross compiler and when i look at the Makefile all the paths are pointing to the right place. i.e. the cross compiler i installed.
Now when i come to make, it runs for a bit but then reports the error :
/usr/local/arm/gnu/release/lib/gcc-lib/arm-linux/2.95.3/../../../../arm-linux/include/bits/errno.h:25: linux/errno.h: No such file or directory
Why is the file bits/errno.h looking for another file of the same name? Is this meant to be an ARM specific errno.h? I did a search for this file and came up with loads :
/usr/include/asm/errno.h /usr/include/linux/errno.h /usr/include/bits/errno.h /usr/include/errno.h /usr/include/sys/errno.h /usr/local/arm/gnu/release/arm-linux/include/bits/errno.h /usr/local/arm/gnu/release/arm-linux/include/errno.h /usr/local/arm/gnu/release/arm-linux/include/sys/errno.h /usr/src/linux-2.4.3/include/asm-i386/errno.h /usr/src/linux-2.4.3/include/linux/errno.h
Which one is it looking for and how do i tell it to use that specific one?
On 27 Feb 2002 21:24:37 +0200, Gad Hayisraeli wrote:
Try this Shell> rm -f config.cache Shell> CC=<path>/arm-linux-gcc ./configure <options> (CC + configure - all in one line)
Gad
-----Original Message----- From: mad-dev-admin@lists.mars.org
[mailto:mad-dev-admin@lists.mars.org] On Behalf Of Gareth
Sent: Wednesday, February 27, 2002 9:02 PM To: mad-dev@lists.mars.org Subject: [mad-dev] Cross compiling libmad for ARM
Hi, I am wanting to compile libmad for ARM. I have installed :
arm-linux-binutils-2.11-1 arm-linux-gcc-2.95-1 arm-linux-glibc-2.1.3-1
To cross compile i do :
export CC=/usr/local/arm/gnu/release/bin/arm-linux-gcc export RANLIB=/usr/local/arm/gnu/release/bin/arm-linux-ranlib export LD=/usr/local/arm/gnu/release/bin/arm-linux-ld export NM=/usr/local/arm/gnu/release/bin/arm-linux-nm
./configure --host=arm-linux --enable-speed --enable-fpm=arm
The configure script completes fine but in the messages it prints i
see
the lines :
checking weather the C compiler (gcc ) is a cross-compiler ... no . . cheching for ld used by GCC... (cached) /usr/bin/ld
so it is not using the cross compiler that i installed. I read in another mail that i may have to configure manually. Is this the case
or
is there somthing i am missing out?
Thanks in advance.
I fixed it!!! I think.
I just added "# include <errno.h>" to decoder.c and it compiled fine using "CC=<path>/arm-linux-gcc RANSLIB=<path>/arm-linux-ranlib ./configure <options>" and then "make".
I think the errno.h that it was looking for was the one in /usr/src/linux-2.4.3/include/asm-i386/errno.h This one had all the defines for 'EINTR' etc.
Now to compile minimad.c!
On Tue, 5 Mar 2002 10:19:13 +0000 Gareth Bransby G.C.Bransby-99@student.lboro.ac.uk wrote:
I had a go at what you suggested but this had no effect, it came up with exactly the same error. From what i can see from the error, it is looking in the linux/ directory in the libmad/ source directory, not in /usr/src/linux. I tried doing what you suggested but making the link in the libmad directory rather than in /usr/src, so now i have a link
mad-0.13.0b/libmad/linux -> /usr/local/arm/gnu/release/arm-linux/include.
Now it finds errno.h ok but generates different errors
decoder.c: In function 'mad_decoder_finish': decoder.c:91 'EINTR' undeclared (first use in this function) decoder.c:91 (Each undeclared identifier is reported only once for each function it apears in.) decoder.c In function'send_io': decoder.c:120 'EINTR' undeclared (first use in this function) decoder.c In function'recieve_io': decoder.c:142 'EINTR' undeclared (first use in this function)
decoder.c:145 'EAGAIN' undeclared (first use in this function) make: *** [decoder.lo] error 1
I am wondering are there some required files that are needed for cross compiling that i have not installed?
Thanks
On Tue, 5 Mar 2002 13:45:55 +0800 "davidlee" davidlee@gv.com.tw wrote:
Dear Gareth: Maybe do could do this 1. logon as root 2. cd /usr/src 3. rm linux 4. ln -s arm-linux(or any path that you installed Arm Linux enviroment) ./linux
Try again , Good lucky.
----- Original Message ----- From: "Gareth" g.c.bransby-99@student.lboro.ac.uk To: "Gad Hayisraeli" gad@syete.co.il Cc: "Mad Dev List" mad-dev@lists.mars.org Sent: Thursday, February 28, 2002 7:56 PM Subject: RE: [mad-dev] Cross compiling libmad for ARM
Thanks for the help!
I had a go at doing the CC=... and RANLIB=... on the same line as the ./configure as suggested. This seems to have the dedsired effect, the configure script reports that gcc is a cross compiler and when i look at the Makefile all the paths are pointing to the right place. i.e. the cross compiler i installed.
Now when i come to make, it runs for a bit but then reports the error :
/usr/local/arm/gnu/release/lib/gcc-lib/arm-linux/2.95.3/../../../../arm-linux/include/bits/errno.h:25: linux/errno.h: No such file or directory
Why is the file bits/errno.h looking for another file of the same name? Is this meant to be an ARM specific errno.h? I did a search for this file and came up with loads :
/usr/include/asm/errno.h /usr/include/linux/errno.h /usr/include/bits/errno.h /usr/include/errno.h /usr/include/sys/errno.h /usr/local/arm/gnu/release/arm-linux/include/bits/errno.h /usr/local/arm/gnu/release/arm-linux/include/errno.h /usr/local/arm/gnu/release/arm-linux/include/sys/errno.h /usr/src/linux-2.4.3/include/asm-i386/errno.h /usr/src/linux-2.4.3/include/linux/errno.h
Which one is it looking for and how do i tell it to use that specific one?
On 27 Feb 2002 21:24:37 +0200, Gad Hayisraeli wrote:
Try this Shell> rm -f config.cache Shell> CC=<path>/arm-linux-gcc ./configure <options> (CC + configure - all in one line)
Gad
-----Original Message----- From: mad-dev-admin@lists.mars.org
[mailto:mad-dev-admin@lists.mars.org] On Behalf Of Gareth
Sent: Wednesday, February 27, 2002 9:02 PM To: mad-dev@lists.mars.org Subject: [mad-dev] Cross compiling libmad for ARM
Hi, I am wanting to compile libmad for ARM. I have installed :
arm-linux-binutils-2.11-1 arm-linux-gcc-2.95-1 arm-linux-glibc-2.1.3-1
To cross compile i do :
export CC=/usr/local/arm/gnu/release/bin/arm-linux-gcc export RANLIB=/usr/local/arm/gnu/release/bin/arm-linux-ranlib export LD=/usr/local/arm/gnu/release/bin/arm-linux-ld export NM=/usr/local/arm/gnu/release/bin/arm-linux-nm
./configure --host=arm-linux --enable-speed --enable-fpm=arm
The configure script completes fine but in the messages it prints i
see
the lines :
checking weather the C compiler (gcc ) is a cross-compiler ... no . . cheching for ld used by GCC... (cached) /usr/bin/ld
so it is not using the cross compiler that i installed. I read in another mail that i may have to configure manually. Is this the case
or
is there somthing i am missing out?
Thanks in advance.
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
I fixed it!!! I think.
I think the errno.h that it was looking for was the one in /usr/src/linux-2.4.3/include/asm-i386/errno.h This one had all the defines for 'EINTR' etc.
In general error numbers are platform dependent, so including an x86 header file probably isn't the safest thing to do... :-)
It looks like your problems come from a messed up toolchain - you may be better off getting hold of a pre-built version that is know to work.
The gcc v2.95.3 from
ftp://ftp.arm.linux.org.uk/pub/armlinux/toolchain/
works for me.
mad-0.14.2b builds without problem after running configure with the following options:
CC="/usr/local/arm/2.95.3/bin/arm-linux-gcc" ./configure --enable-speed --disable-debugging --enable-fpm=arm --disable-nls --disable-mmap --host=arm-linux
(Note that other options probably work fine as well, but the above should produce something fairly optimal for ARM).
Andre --
__________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Thanks, i will give that a go!
On Wed, 6 Mar 2002 23:49:33 +0000 (GMT) Andre armccurdy@yahoo.co.uk wrote:
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
I fixed it!!! I think.
I think the errno.h that it was looking for was the one in /usr/src/linux-2.4.3/include/asm-i386/errno.h This one had all the defines for 'EINTR' etc.
In general error numbers are platform dependent, so including an x86 header file probably isn't the safest thing to do... :-)
It looks like your problems come from a messed up toolchain - you may be better off getting hold of a pre-built version that is know to work.
The gcc v2.95.3 from
ftp://ftp.arm.linux.org.uk/pub/armlinux/toolchain/
works for me.
mad-0.14.2b builds without problem after running configure with the following options:
CC="/usr/local/arm/2.95.3/bin/arm-linux-gcc" ./configure --enable-speed --disable-debugging --enable-fpm=arm --disable-nls --disable-mmap --host=arm-linux
(Note that other options probably work fine as well, but the above should produce something fairly optimal for ARM).
Andre
Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Thanks for the advice. I downloaded that compiler and followed the installation instructions. I tried running configure with your options but it complains that the C compiler cannot create executables. I is definitley looking for the new compiler and not the old one (which i have uninstalled).
I tried running the compiler manually form the command line and it does seem to work so what could the problem be?
On Wed, 6 Mar 2002 23:49:33 +0000 (GMT) Andre armccurdy@yahoo.co.uk wrote:
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
I fixed it!!! I think.
I think the errno.h that it was looking for was the one in /usr/src/linux-2.4.3/include/asm-i386/errno.h This one had all the defines for 'EINTR' etc.
In general error numbers are platform dependent, so including an x86 header file probably isn't the safest thing to do... :-)
It looks like your problems come from a messed up toolchain - you may be better off getting hold of a pre-built version that is know to work.
The gcc v2.95.3 from
ftp://ftp.arm.linux.org.uk/pub/armlinux/toolchain/
works for me.
mad-0.14.2b builds without problem after running configure with the following options:
CC="/usr/local/arm/2.95.3/bin/arm-linux-gcc" ./configure --enable-speed --disable-debugging --enable-fpm=arm --disable-nls --disable-mmap --host=arm-linux
(Note that other options probably work fine as well, but the above should produce something fairly optimal for ARM).
Andre
Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
I tried running configure with your options but it complains that the C compiler cannot create executables. I is definitley looking for the new compiler and not the old one (which i have uninstalled).
Try running "make distclean" before configure (or untar yourself a fresh copy of mad in a new directory and try configuring that).
Double check that CC="..." really does point to the compiler and doesn't have a typo. (If you have added /usr/local/arm/2.95.3/bin to your path, you can simply use CC="arm-linux-gcc").
Have a look at the 'config.log' file which will give more details of what actually went wrong.
__________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Try running "make distclean" before configure (or untar yourself a
Yeah, i had that problem at first. It was looking for the wrong complier even though i had specified the path to the new one. Once i had done make distclean it looked for the correct compiler.
I have made a hello world program just to test it. I did ./arm-linux-gcc main.c and it gave :
/usr/local/arm/2.95.3/arm-linux/lib/libc.so.6: file not recognised: File truncated collect2: ld returned 1 exit status
Could file truncated be a bad download? Also, where arm-linux-gcc is about 181k, arm-linux-ld is zero size. What's going on here?
fresh copy of mad in a new directory and try configuring that).
Double check that CC="..." really does point to the compiler and doesn't have a typo. (If you have added /usr/local/arm/2.95.3/bin to your path, you can simply use CC="arm-linux-gcc").
Have a look at the 'config.log' file which will give more details of what actually went wrong.
Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
Could file truncated be a bad download? Also, where arm-linux-gcc is about 181k, arm-linux-ld is zero size. What's going on here?
My copy of arm-linux-ld is approx 1.3 MB.
ftp://ftp.arm.linux.org.uk/pub/armlinux/toolchain/
doesn't seem to give checksums for the toolchain archives, but the copy of cross-2.95.3.tar.bz2 that I have is 36273634 bytes long, with an md5 hash of
c40277b25adb1bd2bcef0dbaabb65283 cross-2.95.3.tar.bz2
__________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
I have downloade the toolchain agian and extracted it. 2.95.3/bin/arm-linux-ld is still zero size. But, 2.95.3/arm-linux/bin/ld is about 1.3M ad you said yours was. Are these the binaries i am supposed to be using, the ones in 2.953/arm-linux/bin rather than 2.95.3/bin?
----- Original Message ----- From: Andre armccurdy@yahoo.co.uk To: Gareth Bransby G.C.Bransby-99@student.lboro.ac.uk Cc: mad-dev@lists.mars.org Sent: Thursday, March 07, 2002 2:18 PM Subject: Re: [mad-dev] Cross compiling libmad for ARM
Gareth Bransby g.c.bransby-99@student.lboro.ac.uk wrote:
Could file truncated be a bad download? Also, where arm-linux-gcc is about 181k, arm-linux-ld is zero size. What's going on here?
My copy of arm-linux-ld is approx 1.3 MB.
ftp://ftp.arm.linux.org.uk/pub/armlinux/toolchain/
doesn't seem to give checksums for the toolchain archives, but the copy of cross-2.95.3.tar.bz2 that I have is 36273634 bytes long, with an md5 hash of
c40277b25adb1bd2bcef0dbaabb65283 cross-2.95.3.tar.bz2
Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com