Re: [lfs-support] Non-working programs during LFS due to libraries in /tools
On 02/12/2018 08:04 PM, Bruce Dubbs wrote: Tim Tassonis wrote: Hi all I noticed that during LFS build, some programs will not work after they are installed, because their libraries are in /tools/lib and /tools/lib is not in the search path of the dynamic linker. An example is e2fsprogs, ldd on /bin/chattr results in: linux-vdso.so.1 (0x7ffd8a1e8000) libe2p.so.2 => /lib/libe2p.so.2 (0x7f827f8e) libcom_err.so.2 => /lib/libcom_err.so.2 (0x7f827f6dc000) libblkid.so.1 => not found libc.so.6 => /lib/libc.so.6 (0x7f827f322000) libpthread.so.0 => /lib/libpthread.so.0 (0x7f827f104000) /lib64/ld-linux-x86-64.so.2 (0x7f827faea000) So, I thought it would be an idea to create a tools.conf in /etc/ld.so.conf.d after installation of glibc and run /sbin/ldconfig, so programs find the missing libraries. As I assume that those entries come last, the programs will link to the proper libraries as soon as they become available. Or is there anything problematic with this solution? Why? In Chapter 6 you don't need anything that would require that. The partial chroot environment is not meant to be completely functional until the end of Chapter 6 at which point you can remove /mnt/lfs/tools and the /tools symlink that points to it. Well, it was just an idea, so one can test freshly installed stuff right away. I got unsure if I made a mistake during chapter 6 when I executed "clear" in my shell and it gave me an error about missing libncurses. After some thinking and checking, I realized that this due to libncurses still in /tools. I can well live with the current situation, I just thought it would be a bit nicer if everything worked right away. Just a thought. Cheers Tim -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Non-working programs during LFS due to libraries in /tools
Tim Tassonis wrote: Hi all I noticed that during LFS build, some programs will not work after they are installed, because their libraries are in /tools/lib and /tools/lib is not in the search path of the dynamic linker. An example is e2fsprogs, ldd on /bin/chattr results in: linux-vdso.so.1 (0x7ffd8a1e8000) libe2p.so.2 => /lib/libe2p.so.2 (0x7f827f8e) libcom_err.so.2 => /lib/libcom_err.so.2 (0x7f827f6dc000) libblkid.so.1 => not found libc.so.6 => /lib/libc.so.6 (0x7f827f322000) libpthread.so.0 => /lib/libpthread.so.0 (0x7f827f104000) /lib64/ld-linux-x86-64.so.2 (0x7f827faea000) So, I thought it would be an idea to create a tools.conf in /etc/ld.so.conf.d after installation of glibc and run /sbin/ldconfig, so programs find the missing libraries. As I assume that those entries come last, the programs will link to the proper libraries as soon as they become available. Or is there anything problematic with this solution? Why? In Chapter 6 you don't need anything that would require that. The partial chroot environment is not meant to be completely functional until the end of Chapter 6 at which point you can remove /mnt/lfs/tools and the /tools symlink that points to it. -- Bruce -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Problems with su when building LFS
On 02/12/2018 07:31 PM, Pierre Labastie wrote: On 12/02/2018 18:54, Pierre Labastie wrote: On 11/02/2018 23:01, Tim Tassonis wrote: On 02/11/2018 10:37 PM, Bruce Dubbs wrote: Tim Tassonis wrote: I have found a workaround for my problem: If I replace mount -vt devpts devpts $LFS/dev/pts -o gid=5,mode=620 with mount -v --bind /dev/pts $LFS/dev/pts I get the needed /dev/pts/0 and sudo and su with password asking now works. As it seems that this is really only a chroot issue and su and sudo now work fine, I'll continue with that. I'm not yet sure of the exact security implications, but as this is a dedicated vm only for building the system, it should be ok. I have the same issue, whether or not I use -o gid=... After entering chroot, I am root, and if I run "su - pierre", I become pierre. But if I try to become back root using su (that is running "su -" while being pierre), I get the "su: must be run from a terminal" message. Note that if I run (as pierre) "sudo su -", it works (user pierre can sudo without a password)... I tried an old LFS (SVN-20160929), and I have exactly the same results... Hmm, maybe a problem with host (I'm using Debian sid ATM). I've made a few trials. With kernels older than 4.9, same issue. With 4.7.4, no issue. That may explain why it was working for older LFS. s/With kernels older than 4.9/With kernels newer than 4.9/ sorry Might well be, as I am building under 4.14.16, the last lfs 8.0 build was under 4.9.21. -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
[lfs-support] Non-working programs during LFS due to libraries in /tools
Hi all I noticed that during LFS build, some programs will not work after they are installed, because their libraries are in /tools/lib and /tools/lib is not in the search path of the dynamic linker. An example is e2fsprogs, ldd on /bin/chattr results in: linux-vdso.so.1 (0x7ffd8a1e8000) libe2p.so.2 => /lib/libe2p.so.2 (0x7f827f8e) libcom_err.so.2 => /lib/libcom_err.so.2 (0x7f827f6dc000) libblkid.so.1 => not found libc.so.6 => /lib/libc.so.6 (0x7f827f322000) libpthread.so.0 => /lib/libpthread.so.0 (0x7f827f104000) /lib64/ld-linux-x86-64.so.2 (0x7f827faea000) So, I thought it would be an idea to create a tools.conf in /etc/ld.so.conf.d after installation of glibc and run /sbin/ldconfig, so programs find the missing libraries. As I assume that those entries come last, the programs will link to the proper libraries as soon as they become available. Or is there anything problematic with this solution? Of course, it would also have to be mentioned at the end of chapter six to remove that file again, and maybe re-run /sbin/ldconfig. Cheers Tim -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Problems with su when building LFS
On 12/02/2018 18:54, Pierre Labastie wrote: > On 11/02/2018 23:01, Tim Tassonis wrote: >> On 02/11/2018 10:37 PM, Bruce Dubbs wrote: >>> Tim Tassonis wrote: >>> I have found a workaround for my problem: If I replace mount -vt devpts devpts $LFS/dev/pts -o gid=5,mode=620 with mount -v --bind /dev/pts $LFS/dev/pts I get the needed /dev/pts/0 and sudo and su with password asking now works. As it seems that this is really only a chroot issue and su and sudo now work fine, I'll continue with that. I'm not yet sure of the exact security implications, but as this is a dedicated vm only for building the system, it should be ok. > > I have the same issue, whether or not I use -o gid=... > > After entering chroot, I am root, and if I run "su - pierre", I become pierre. > But if I try to become back root using su (that is running "su -" while being > pierre), I get the "su: must be run from a terminal" message. > > Note that if I run (as pierre) "sudo su -", it works (user pierre can sudo > without a password)... > > I tried an old LFS (SVN-20160929), and I have exactly the same results... > > Hmm, maybe a problem with host (I'm using Debian sid ATM). > > I've made a few trials. With kernels older than 4.9, same issue. With 4.7.4, > no issue. That may explain why it was working for older LFS. > s/With kernels older than 4.9/With kernels newer than 4.9/ sorry -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Problems with su when building LFS
On 11/02/2018 23:01, Tim Tassonis wrote: > On 02/11/2018 10:37 PM, Bruce Dubbs wrote: >> Tim Tassonis wrote: >> >>> I have found a workaround for my problem: >>> >>> If I replace >>> >>> mount -vt devpts devpts $LFS/dev/pts -o gid=5,mode=620 >>> >>> with >>> >>> mount -v --bind /dev/pts $LFS/dev/pts >>> >>> >>> I get the needed /dev/pts/0 and sudo and su with password asking now works. >>> As it seems that this is really only a chroot issue and su and sudo now >>> work fine, I'll continue with that. I'm not yet sure of the exact security >>> implications, but as this is a dedicated vm only for building the system, >>> it should be ok. I have the same issue, whether or not I use -o gid=... After entering chroot, I am root, and if I run "su - pierre", I become pierre. But if I try to become back root using su (that is running "su -" while being pierre), I get the "su: must be run from a terminal" message. Note that if I run (as pierre) "sudo su -", it works (user pierre can sudo without a password)... I tried an old LFS (SVN-20160929), and I have exactly the same results... Hmm, maybe a problem with host (I'm using Debian sid ATM). I've made a few trials. With kernels older than 4.9, same issue. With 4.7.4, no issue. That may explain why it was working for older LFS. Pierre -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Step 6.9: error: missing __attribute__ ((constructor)) support
On 12/02/2018 13:45, René Nyffenegger wrote: > I am following the "current stable" version according to "Read Online" > (http://www.linuxfromscratch.org/lfs/read.html) > > I am trying to build LFS on Ubuntu 17.10, 64 Bit Intel. > > > On 12.02.2018 12:28, Pierre Labastie wrote: >> On 12/02/2018 11:34, René Nyffenegger wrote: >>> In Step 6.9 >>> (http://www.linuxfromscratch.org/lfs/view/stable/chapter06/glibc.html) I get >>> the following error when I run the ../configure script: >>> >>>checking whether to use .ctors/.dtors header and trailer... configure: >>> error: missing __attribute__ ((constructor)) support?? >>> >>> This was already discussed on the mailing list: >>> >>> http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064937.html >>> >>> Apparently, adding >>>libc_cv_ctors_header=yes >>> to the invocation of the configure script helped. >>> >>> http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064955.html >>> >>> I am not sure in which step I should add this configre-setting: step 6.9, >>> step 5.7 or another step? >>> >>> Also, I am wondering if this bug(?) has not been fixed in the meantime. >>> >> >> Which version of the book, on which system, and which distro? With recent >> versions of glibc, adding libc_cv_ctors_header=yes should not be needed, at >> least on x86. But when it used to be needed, it was in chapter 5 glibc. >> Please do not top post. According to what you say, there should be no need to add libc_cv_ctors_header=yes. Looking at my logs, I have, during the configure stage: -- checking whether to use .ctors/.dtors header and trailer... no -- in both chapter 5 and chapter 6 glibc, and my build went smoothly. There was a thread in last September about the same issue, and the OP had the following in configure: -- checking for .set assembler directive... no checking linker support for protected data symbol... no -- while I have 'yes' to these 2 items. What do you have (it's just a few lines before configure stops)? Can you also check in chapter 5? If there is a no, I guess you'll have to start again chapter 5. Or maybe you just missed some symlink (section 6.6)... Pierre -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Step 6.9: error: missing __attribute__ ((constructor)) support
I am following the "current stable" version according to "Read Online" (http://www.linuxfromscratch.org/lfs/read.html) I am trying to build LFS on Ubuntu 17.10, 64 Bit Intel. On 12.02.2018 12:28, Pierre Labastie wrote: > On 12/02/2018 11:34, René Nyffenegger wrote: >> In Step 6.9 >> (http://www.linuxfromscratch.org/lfs/view/stable/chapter06/glibc.html) I get >> the following error when I run the ../configure script: >> >>checking whether to use .ctors/.dtors header and trailer... configure: >> error: missing __attribute__ ((constructor)) support?? >> >> This was already discussed on the mailing list: >> >> http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064937.html >> >> Apparently, adding >>libc_cv_ctors_header=yes >> to the invocation of the configure script helped. >> >> http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064955.html >> >> I am not sure in which step I should add this configre-setting: step 6.9, >> step 5.7 or another step? >> >> Also, I am wondering if this bug(?) has not been fixed in the meantime. >> > > Which version of the book, on which system, and which distro? With recent > versions of glibc, adding libc_cv_ctors_header=yes should not be needed, at > least on x86. But when it used to be needed, it was in chapter 5 glibc. > > Pierre -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Step 6.9: error: missing __attribute__ ((constructor)) support
On 12/02/2018 11:34, René Nyffenegger wrote: In Step 6.9 (http://www.linuxfromscratch.org/lfs/view/stable/chapter06/glibc.html) I get the following error when I run the ../configure script: checking whether to use .ctors/.dtors header and trailer... configure: error: missing __attribute__ ((constructor)) support?? This was already discussed on the mailing list: http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064937.html Apparently, adding libc_cv_ctors_header=yes to the invocation of the configure script helped. http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064955.html I am not sure in which step I should add this configre-setting: step 6.9, step 5.7 or another step? Also, I am wondering if this bug(?) has not been fixed in the meantime. Which version of the book, on which system, and which distro? With recent versions of glibc, adding libc_cv_ctors_header=yes should not be needed, at least on x86. But when it used to be needed, it was in chapter 5 glibc. Pierre -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
[lfs-support] Step 6.9: error: missing __attribute__ ((constructor)) support
In Step 6.9 (http://www.linuxfromscratch.org/lfs/view/stable/chapter06/glibc.html) I get the following error when I run the ../configure script: checking whether to use .ctors/.dtors header and trailer... configure: error: missing __attribute__ ((constructor)) support?? This was already discussed on the mailing list: http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064937.html Apparently, adding libc_cv_ctors_header=yes to the invocation of the configure script helped. http://archive.linuxfromscratch.org/mail-archives/lfs-dev/2011-August/064955.html I am not sure in which step I should add this configre-setting: step 6.9, step 5.7 or another step? Also, I am wondering if this bug(?) has not been fixed in the meantime. -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
Re: [lfs-support] Problems with su when building LFS
Hallo, > su: must be run from a terminal what are the defaults in your sudo.conf? Have you switched on requiretty? You could selectively (or globally) switch it off. Defaults:timtas !requiretty Tschau...Thomas -- "Do you wanna be a legend or a passing footprint on the sands of time?" signature.asc Description: OpenPGP digital signature -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style