--On Sunday, March 30, 2003 7:02 PM +0000 [EMAIL PROTECTED] wrote:

  Backport of the RPM build scripts to v2.0
  Obtained from: Joe Orton <[EMAIL PROTECTED]>

This generates failures on Solaris (which does not have cpp). It also looks like your grep usage is relying upon some extended grep semantics (-e).

rebuilding rpm spec file
./buildconf: cpp: not found
grep: illegal option -- e
Usage: grep -hblcnsviw pattern file . . .
./buildconf: cpp: not found
grep: illegal option -- e
Usage: grep -hblcnsviw pattern file . . .

Please be more considerate when you commit to stable without review.

+echo rebuilding rpm spec file
+( VMMN=`echo MODULE_MAGIC_NUMBER_MAJOR | cpp -include
\`pwd\`/include/ap_mmn.h | grep -e '^[0-9]'`
+ REVISION=`echo
AP_SERVER_MAJORVERSION.AP_SERVER_MINORVERSION.AP_SERVER_PATCHLEVEL | cpp -include \`pwd\`/include/ap_release.h | tr -d "\" " | grep -e '^[0-9.\-]'`
  +  VERSION=`echo $REVISION | cut -d- -s -f1`
  +  RELEASE=`echo $REVISION | cut -d- -s -f2`
  +  if [ "x$VERSION" = "x" ]; then
  +    VERSION=$REVISION
  +    RELEASE=1
  +  fi
  +  cat ./build/rpm/httpd.spec.in | \
  +  sed -e "s/APACHE_VERSION/$VERSION/" \
  +      -e "s/APACHE_RELEASE/$RELEASE/" \
  +      -e "s/APACHE_MMN/$VMMN/" \
  +  > httpd.spec )
  +

Looking at how other projects do it, they generate their spec files as output
from autoconf rather than generating them manually. This has the drawback as
the vendor must run configure to produce the spec files, but this seems to be
the common practice. So, I think it's acceptable. And, if you were to do this,
this would become much cleaner and portable (a few AC_SUBST's and autoconf
can find an egrep and cpp that work to expand/find the #define's for you).


Regardless, this commit needs to be fixed or reverted on stable. -- justin

Reply via email to