LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   binutils make problem : error: `YACC' has changed since the previous run (https://www.linuxquestions.org/questions/linux-from-scratch-13/binutils-make-problem-error-%60yacc-has-changed-since-the-previous-run-4175422734/)

k84834 08-18-2012 04:28 AM

binutils make problem : error: `YACC' has changed since the previous run
 
Hi
in chapter 5 of LFS book, at "5.4. Binutils-2.22 - Pass 1" point, I run "configure" and "make" commands for binutils but don't run "make install", and understand some of host system requirements aren't in my system, I run version-check.sh file and fix problems with these guides, then I rerun configure and make commands for binutils package so I encounter with below errors by running make command:


checking whether basename is declared... (cached) yes
checking whether stpcpy is declared... (cached) yes
checking linker --as-needed support... (cached) yes
checking for cos in -lm... (cached) yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing default-1 commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
make[2]: Entering directory `/mnt/lfs/sources/binutils-build/opcodes'
make all-recursive
make[3]: Entering directory `/mnt/lfs/sources/binutils-build/opcodes'
Making all in .
make[4]: Entering directory `/mnt/lfs/sources/binutils-build/opcodes'
make[4]: Leaving directory `/mnt/lfs/sources/binutils-build/opcodes'
Making all in po
make[4]: Entering directory `/mnt/lfs/sources/binutils-build/opcodes/po'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/mnt/lfs/sources/binutils-build/opcodes/po'
make[3]: Leaving directory `/mnt/lfs/sources/binutils-build/opcodes'
make[2]: Leaving directory `/mnt/lfs/sources/binutils-build/opcodes'
Configuring in ./binutils
configure: loading cache ./config.cache
configure: error: `YACC' has changed since the previous run:
configure: former value: `/mnt/lfs/sources/binutils-2.22/missing bison -y'
configure: current value: `bison -y'
configure: error: in `/mnt/lfs/sources/binutils-build/binutils':
configure: error: changes in the environment can compromise the build
configure: error: run `make distclean' and/or `rm ./config.cache' and start over
make[1]: *** [configure-binutils] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/binutils-build'
make: *** [all] Error 2
lfs@UBUNTU-32bit:/mnt/lfs/sources/binutils-build$

what should I do for fixing these errors?

druuna 08-18-2012 04:34 AM

Did you remove the /mnt/lfs/sources/binutils-build and /mnt/lfs/sources/binutils-2.22 directories before you retried?

You should; Always remove the source directory and unpack again after something went wrong. This to ensure a clean source. In short:
Code:

cd $LFS/sources
rm -rf binutils-build binutils-2.22
tar xf binutils-2.22.tar.bz2
cd binutils-2.22
<follow steps in chapter>


k84834 08-18-2012 05:09 AM

thanks again druuna . has been solved

druuna 08-18-2012 05:51 AM

Can you put up the [SOLVED] tag (first post -> Thread Tools -> Mark this thread as solved).


All times are GMT -5. The time now is 10:36 AM.