Coreutils impossible to compile and bash pipes

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
User avatar
AlfaOmega08
Member
Member
Posts: 226
Joined: Wed Nov 07, 2007 12:15 pm
Location: Italy

Coreutils impossible to compile and bash pipes

Post by AlfaOmega08 »

My kernel is finally able to execute bash. Now I want to port coreutils using my cross-compiler.

When configuring the script exit with this error:

Code: Select all

checking for listmntent... no
checking for getmntinfo... no
checking for sys/ucred.h... no
checking for sys/mount.h... (cached) yes
checking mntent.h usability... no
checking mntent.h presence... no
checking for mntent.h... no
checking for sys/fs_types.h... (cached) no
checking for struct fsstat.f_fstypename... no
checking for library containing getmntent... no
checking for getmntent... no
checking for listmntent of Cray/Unicos-9... no
checking for mntctl function and struct vmount... no
checking for getfsstat function... no
checking for FIXME existence of three headers... no
checking for getmntinfo function... no
checking for getmnt function... no
checking for next_dev... no
checking for fs_stat_dev... no
checking fs_info.h usability... no
checking fs_info.h presence... no
checking for fs_info.h... no
checking for BEOS mounted file system support functions... no
checking whether it is possible to resort to fread on /etc/mnttab... no
configure: error: could not determine how to read list of mounted file systems
Someone knows how to make it work?

The only problem I got with bash are pipes. If I execute e.g. "ls | grep ..", I receive a page fault.
Do I need some special syscall to handle pipes?
Please, correct my English...
Motherboard: ASUS Rampage II Extreme
CPU: Core i7 950 @ 3.06 GHz OC at 3.6 GHz
RAM: 4 GB 1600 MHz DDR3
Video: nVidia GeForce 210 GTS... it sucks...
jal
Member
Member
Posts: 1385
Joined: Wed Oct 31, 2007 9:09 am

Re: Coreutils impossible to compile and bash pipes

Post by jal »

AlfaOmega08 wrote:configure: error: could not determine how to read list of mounted file systems[/code]

Well, assuming you are running this on your OS, it probably needs some syscalls you haven't implemented?
The only problem I got with bash are pipes. If I execute e.g. "ls | grep ..", I receive a page fault.
Do I need some special syscall to handle pipes?
exec, and, what's it dup or something?, to get stdin/out to be linked. But really, it should be rather straigtforward to debug, right? Or have you just compiled bash without a clue what's in it?


JAL
User avatar
JamesM
Member
Member
Posts: 2935
Joined: Tue Jul 10, 2007 5:27 am
Location: York, United Kingdom
Contact:

Re: Coreutils impossible to compile and bash pipes

Post by JamesM »

jal wrote:
AlfaOmega08 wrote:configure: error: could not determine how to read list of mounted file systems[/code]

Well, assuming you are running this on your OS, it probably needs some syscalls you haven't implemented?
The only problem I got with bash are pipes. If I execute e.g. "ls | grep ..", I receive a page fault.
Do I need some special syscall to handle pipes?
exec, and, what's it dup or something?, to get stdin/out to be linked. But really, it should be rather straigtforward to debug, right? Or have you just compiled bash without a clue what's in it?


JAL
"pipe" and "dup2" are what's required.
jal
Member
Member
Posts: 1385
Joined: Wed Oct 31, 2007 9:09 am

Re: Coreutils impossible to compile and bash pipes

Post by jal »

JamesM wrote:"pipe" and "dup2" are what's required.
Ah, yes, I haven't got a copy of POSIX in my head :). Anyway, it seems to me the OP could do much more research himself.


JAL
dosfan
Member
Member
Posts: 65
Joined: Tue Oct 14, 2008 1:18 pm
Location: Scotland

Re: Coreutils impossible to compile and bash pipes

Post by dosfan »

I ran into the exact same problem while trying to cross compile GNU coreutils packages with newlib. I poked around the configure script a bit to no avail.

(Congrats on getting bash running, nice feeling isn't it?)
All your base are belong to us.
Post Reply