GNOME Bugzilla – Bug 136500
"head -number" is evil (and deprecated/unportable)
Last modified: 2004-12-22 21:47:04 UTC
as i saw several warnings at gst-ffmpeg autogen, i did the following grep : grep -r "head -[0-9]" /usr/portage/distfiles/cvs-src/gst* and found : gst-ffmpeg/gst-libs/ext/ffmpeg/patch/autotools.diff:+ actual_version=`$checkprog --version | head -1 | \ and gst-editor/common/m4/ax_create_stdint_h.m4:ac_cv_stdint_message="using gnu compiler "`$CC --version | head -1` /gst-ffmpeg/common/m4/ax_create_stdint_h.m4:ac_cv_stdint_message="using gnu compiler "`$CC --version | head -1` gst-player/common/m4/ax_create_stdint_h.m4:ac_cv_stdint_message="using gnu compiler "`$CC --version | head -1` gst-plugins/common/m4/ax_create_stdint_h.m4:ac_cv_stdint_message="using gnu compiler "`$CC --version | head -1` gstreamer/common/m4/ax_create_stdint_h.m4:ac_cv_stdint_message="using gnu compiler "`$CC --version | head -1` head -number (or any number) as well as tail -number is deprecated and non-portable. (and would be removed in later head/tail versions) the following should be used : head -n number or tail -n number as there is a 'common' CVS repository, i suppose it contains this directory for every gstreamer part, so only one change required. the only part which a second bad use of head -1 is gst-ffmpeg here are the warnings i have : configure: slurping FFmpeg CVS source configure: checking out ffmpeg cvs code from 2004-02-29 20:00 GMT into gst-libs/ext/ffmpeg cvs checkout: warning: failed to open /usr/portage/tmp/portage/homedir/.cvspass for reading: No such file or directory configure: setting up ffmpeg build system and applying patches checking for libtool >= 1.5... testing libtoolize... head: `-1' option is obsolete; use `-n 1' since this will be removed in the future found. checking for autoconf >= 2.53... testing autoconf... head: `-1' option is obsolete; use `-n 1' since this will be removed in the future found. checking for automake >= 1.6... testing automake... head: `-1' option is obsolete; use `-n 1' since this will be removed in the future too old (found version 1.5) testing automake-1.7... head: `-1' option is obsolete; use `-n 1' since this will be removed in the future found. aclocal: configure.ac: 547: macro `AM_PATH_IMLIB' not found in library checking whether byte ordering is bigendian... no
Created attachment 25304 [details] [review] common patch
Created attachment 25305 [details] [review] gst-ffmpeg specific patch
Ronald apparently already fixed it in ffmpeg - please verify if I'm right. commited to HEAD, closing.