LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   LFS m4-1.4.16 make check (https://www.linuxquestions.org/questions/linux-software-2/lfs-m4-1-4-16-make-check-4175455779/)

vitronix 03-27-2013 07:58 AM

LFS m4-1.4.16 make check
 
Hello,

I'm trying to build an LFS (Linux From Scratch) system.
All is going fine until I run:

lfs@lfs:/mnt/lfs/sources/m4-1.4.16$ make check
if test -d ./.git; then \
cd . && \
git submodule --quiet foreach test '$(git rev-parse $sha1)' \
= '$(git merge-base origin $sha1)' \
|| { echo 'maint.mk: found non-public submodule commit' >&2; \
exit 1; }; \
else \
: ; \
fi
make check-recursive
make[1]: Entering directory `/mnt/lfs/sources/m4-1.4.16'
Making check in .
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16'
make[2]: Nothing to be done for `check-am'.
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16'
Making check in examples
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16/examples'
make[2]: Nothing to be done for `check'.
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/examples'
Making check in lib
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16/lib'
make check-am
make[3]: Entering directory `/mnt/lfs/sources/m4-1.4.16/lib'
gcc -std=gnu99 -I. -g -O2 -MT clean-temp.o -MD -MP -MF .deps/clean-temp.Tpo -c -o clean-temp.o clean-temp.c
In file included from clean-temp.h:22:0,
from clean-temp.c:23:
./stdio.h:477:1: error: 'gets' undeclared here (not in a function)
make[3]: *** [clean-temp.o] Error 1
make[3]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/lib'
make[2]: *** [check] Error 2
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/lib'
make[1]: *** [check-recursive] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/m4-1.4.16'
make: *** [check] Error 2
lfs@lfs:/mnt/lfs/sources/m4-1.4.16$ make check
if test -d ./.git; then \
cd . && \
git submodule --quiet foreach test '$(git rev-parse $sha1)' \
= '$(git merge-base origin $sha1)' \
|| { echo 'maint.mk: found non-public submodule commit' >&2; \
exit 1; }; \
else \
: ; \
fi
make check-recursive
make[1]: Entering directory `/mnt/lfs/sources/m4-1.4.16'
Making check in .
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16'
make[2]: Nothing to be done for `check-am'.
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16'
Making check in examples
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16/examples'
make[2]: Nothing to be done for `check'.
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/examples'
Making check in lib
make[2]: Entering directory `/mnt/lfs/sources/m4-1.4.16/lib'
make check-am
make[3]: Entering directory `/mnt/lfs/sources/m4-1.4.16/lib'
gcc -std=gnu99 -I. -g -O2 -MT clean-temp.o -MD -MP -MF .deps/clean-temp.Tpo -c -o clean-temp.o clean-temp.c
In file included from clean-temp.h:22:0,
from clean-temp.c:23:
./stdio.h:477:1: error: 'gets' undeclared here (not in a function)
make[3]: *** [clean-temp.o] Error 1
make[3]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/lib'
make[2]: *** [check] Error 2
make[2]: Leaving directory `/mnt/lfs/sources/m4-1.4.16/lib'
make[1]: *** [check-recursive] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/m4-1.4.16'
make: *** [check] Error 2
lfs@lfs:/mnt/lfs/sources/m4-1.4.16$

Does anybody know why I get these errors?

Thanks in advance.

benb2013 04-17-2013 04:27 AM

Hi,

I quote:

"Since the 2.16 release of the glibc, 'gets' is not any more defined in the gnulib.
No m4 version synchronized with gnulib since [1] has been released yet."
...

[1] http://git.savannah.gnu.org/gitweb/?...5140fa0c807348

This causes gets compile errors on systems with glibc >= 2.16 with sources that still assume the previous definition.

The following link contains a patch for the M4 source, that is supposed to fix this:
http://git.buildroot.net/buildroot/p...-no-gets.patch

Above as the long version of 'Must brush up Google Fu',
See "man patch" for details on applying patches to source code

Regards

druuna 04-17-2013 04:42 AM

@vitronix: This seems to be from chapter 5. This from the book about running make check in chapter 5:
Quote:

Note

Experience has shown that there is little to be gained from running the test suites in Chapter 5. There can be no escaping the fact that the host system always exerts some influence on the tests in that chapter, often causing inexplicable failures. Because the tools built in Chapter 5 are temporary and eventually discarded, we do not recommend running the test suites in Chapter 5 for the average reader. The instructions for running those test suites are provided for the benefit of testers and developers, but they are strictly optional.
In other words: Don't run the test when working on chapter 5 (you _do_ need to run them in chapter 6).


All times are GMT -5. The time now is 11:03 AM.