[Clfs-support] Binutils and Gcc Tests Fail--and the dreaded "no more PTY's"

Dan McGhee beesnees at grm.net
Tue Sep 22 18:44:32 PDT 2009


Please bear with me.  This takes a while to weave.  Using 
SVN-20090921-x86_64-Multilib.  Host system is Ubuntu-9.04 with kernel 
2.6.28.15-generic.

Things developed smoothly in Ch 10 with all test suites passing until I 
got to binutils.  Yes, I got the dreaded pty message when I ran <expect 
-c "spawn ls"> [BTW this is the first time in any of my LFS builds that 
I received this message. Lucky?].  So the first thing I did was go to 
the LFS FAQ's and used the one on how to recover.  Grepping through the 
kernel config file I discovered that UNIX98-PTYS was configured, but 
that there was no entry, I mean NO ENTRY for DEVPTS--configured or not.  
Hmm, I says.  But I thought that I remembered that DEVPTS was deprecated 
and UDEV was going to take its place and that DEVPTS was included in the 
kernels--two years ago--for compatibility.  and I ran <mount> with no 
options.  One of the results was

> devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620)

So I went forward in the FAQ.

Both /dev/ptmx and /dev/pts existed and had the permissions noted in the 
FAQ.  I changed ${CLFS}/etc/group so that the tty group had gid=5--to 
match Ubuntu.

Still got the dreaded message.  Next step was <man mount>.  Interesting 
info:

>  Note  that  the filesystem mount options will remain the same as
>  those on the original mount point,  and  cannot  be  changed  by
>   passing the -o option along with --bind/--rbind.
Since the command in Ch. 8.3, "Mounting the Virtual Kernel File Systems 
is <mount -v -o bind /dev ${CLFS/dev}> and devpts was mounted with 
"noexec, nosuid" in the host system, I wondered if this was "leaking 
through" to chroot environment and screwing up my ability to test.  
Leaving out the gorey details, the only way I could manage to eliminate 
the dreaded message  was to use the LFS commands to mount the filesystems:

> mount -vt devpts devpts $CLFS/dev/pts
> mount -vt tmpfs shm $CLFS/dev/shm
> mount -vt proc proc $CLFS/proc
> mount -vt sysfs sysfs $CLFS/sys
after mounting /dev.  BUT my binutils--didn't try gcc--tests still 
showed the same results.

So, if the Ubuntu devpts mount options--for a file system that's not 
even , nor can be, configured--are "leaking through" then simply change 
the entry in /etc/fstab--only there isn't one.  I still haven't found 
where the Ubuntu puts default mount points and options nor how to change 
them.  So I decided to add an entry to fstab.  Didn't work.  Running 
<mount> still gave the noexec and no suid options for devpts.  BTW I 
added the line

devpts /dev/pts devpts rw,gid=5, mode=620 00

Devpts was still mounted with the original options.  I'm trying to find 
out how to change this, but that's a question for a different venue. 
[Rant]It's things like this that lead me to LFS in the first place and 
now I'm spoiled.[/Rant]

Barring any other options, I think that the only way to proceed is to 
use the "boot" method for CLFS.  Then I'm assured that my host system 
won't get through.

Am I missing anything?  Does anyone have any other options that I might 
try?  I'm really interested in how DEVPTS gets into Ubuntu since you 
can't configure and how to change fstab.  I'll go to the ubuntu forums 
for that--hopefully on a "not to delay my CLFS build.  But I sure would 
appreciate any suggestions on tests that I can run to focus down to the 
problem of not being able to proceed or any other way of trying to 
figure out what the problem is.

Actually, the way I see it is that binutils and gcc were fine.  It's 
just that I can't test them, and I don't want to proceed unless I'm sure 
about them.  All other test suites came through with shining colors.


Thanks,
Dan



More information about the Clfs-support mailing list