After completing stage1 (bootstrap) and doing "emerge system", compilation of x11-base/xorg-x11-6.8.2-r2 fails with error: ld: cannot find -lfl Flex is to be recompiled later during "emerge --newuse system", but after xorg-x11. This can be fixed recompiling flex and then re-running emerge system: # emerge flex # emerge --newuse world There is fix in the forums (see URL) Reproducible: Always Steps to Reproduce: 1. do clean stage1 install 2. bootstrap system (process to stage2) 3. choose +X USE flag and emerge --newuse system Actual Results: Compilation of xorg-x11 fails with linker error Expected Results: Compilation should suceed This is not exactly what I saw, I lost scroll buffer, but it was same as in the forums, so I paste it here i686-pc-linux-gnu-gcc -o pswrap -march=pentium3 -pipe -fomit-frame-pointer -fno-strict-aliasing -ansi -pedantic -Wno-return-type -w -L../../exports/lib main.o pswparser.o lexer.o pswdict.o pswfile.o systemnames.o psw.o pswstring.o pswsemantics.o -lfl -Wl,-rpath-link,../../exports/lib /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.5/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lfl collect2: ld returned 1 exit status make[4]: *** [pswrap] Error 1 make[4]: Leaving directory `/var/tmp/portage/xorg-x11-6.8.2/work/xc/config/pswrap' make[3]: *** [../../config/pswrap/pswrap] Error 2 make[3]: Leaving directory `/var/tmp/portage/xorg-x11-6.8.2/work/xc/lib/dps' make[2]: *** [includes] Error 2 make[2]: Leaving directory `/var/tmp/portage/xorg-x11-6.8.2/work/xc/lib' make[1]: *** [includes] Error 2 make[1]: Leaving directory `/var/tmp/portage/xorg-x11-6.8.2/work/xc' make: *** [World] Error 2 !!! ERROR: x11-base/xorg-x11-6.8.2 failed. !!! Function build, Line 959, Exitcode 2 !!! make World failed !!! If you need support, post the topmost build error, NOT this status message. My make.conf (I use different flags than in code above): CFLAGS="-march=i686 -msse -mmmx -mfpmath=sse -Os -pipe -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" CXXFLAGS="${CFLAGS}" MAKEOPTS="-j2" USE="-gnome -kde alsa dvd nptl tcltk -spell bzip2 mmx sse -ipv6 -fortran chroot"
`emerge flex` should do it
*** This bug has been marked as a duplicate of 87613 ***