On Fri, 22 Mar 2019, Mark Wigzell via blfs-dev wrote:
Hey guys, I recently added some BLFS support and got "startx" running, at
which point I decided to run "firefox" so I can follow along with further
installation of packages. However "firefox" wouldn't build because it turns
out "python2" determined (during its configuration), that POSIX semaphores
were not supported. This occurred both when booted and also when "chrooted"
to LFS partition. Up until success with "startx" I was mostly running with
"chroot" since that is easier.The failure occurred when testing the result
of generating a code file to use "sem_open()". When I tried that code
myself, it built and ran perfectly.
So my temp. solution is to force the configure of Python2 so that it
believes that the test worked. After that I could build Python2 with
sempahores enabled, and thus firefox went without a hitch.
I came accross this very problem back in December 2017. At around that
point the Firefox build system was tweaked somewhat to check for that
"sem_open()" test. I was also running in a chroot environment when I
built Python 2 and Firefox.
After quite a bit of dissection I discovered that the issue (in my case
anyway -- but will probably apply to you as well) is that the
permissions on the the /run/shm directory were not set "properly" for
the semaphore test to complete successfully.
In LFS "6.2. Preparing Virtual Kernel File Systems" there is a line that
creates the /run/shm directory using the following:
if [ -h $LFS/dev/shm ]; then
mkdir -pv $LFS/$(readlink $LFS/dev/shm)
fi
At that point the permissions on /run/shm are 0755.
If a user does not reboot the system before building Python 2, the
permissions on /run/shm remain at 0755 (they change to 1777 upon
reboot). Without world execute permissions on /run/shm the Python test
does not seem to work.
How I "fixed" the issue was to set permissions on /run/shm to
1777/drwxrwxrwt in LFS section 6.2, thereby keeping the right
permissions on /run/shm throughout the remaining LFS sections, plus BLFS
in the chroot environment.
However, I read Ken's response to your query and he uses the chroot
environment too, so I'm curious if you've done anything differently in
your setup, Ken?
For what it's worth, I wrote about this issue here:
http://lists.linuxfromscratch.org/pipermail/blfs-dev/2017-December/033789.html
Cheers,
-- Ryan
--
http://lists.linuxfromscratch.org/listinfo/blfs-dev
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page