Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:13981 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 99044 invoked by uid 1010); 2 Dec 2004 03:11:12 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 98942 invoked from network); 2 Dec 2004 03:11:10 -0000 Received: from unknown (HELO sccrmhc11.comcast.net) (204.127.202.55) by pb1.pair.com with SMTP; 2 Dec 2004 03:11:10 -0000 Received: from [24.218.93.90] (h00c0f040af87.ne.client2.attbi.com[24.218.93.90]) by comcast.net (sccrmhc11) with ESMTP id <2004120203111001100gq399e>; Thu, 2 Dec 2004 03:11:10 +0000 Received: from nome.praxis-sw.com (nome.praxis-sw.com [192.168.100.11]) by avocet.praxis-sw.com (Postfix) with SMTP id D7A7E6D00FB for ; Wed, 1 Dec 2004 22:11:09 -0500 (EST) Received: (nullmailer pid 6277 invoked by uid 500); Thu, 02 Dec 2004 03:11:09 -0000 Date: Wed, 1 Dec 2004 22:11:09 -0500 To: internals@lists.php.net Message-ID: <20041202031109.GA6176@praxis-sw.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="SUOF0GtieIMvvwua" Content-Disposition: inline User-Agent: Mutt/1.5.6i Subject: [PATCH] makerpm From: gyepi@praxis-sw.com (Gyepi SAM) --SUOF0GtieIMvvwua Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi -- The attached patch contains modifications to the makerpm script for php-4.3.9 for portability, security, and bug fixes. Without the patches, the generated spec file would not build on a Fedora Core 2 system. Here's a summary of the changes: - Invoke rpmbuild instead of rpm for building package. - Replace hard-coded rpm directories with rpm macros. - Drop buildconf invocation. - Replace hard-coded /usr with %{_prefix}. - Add README* to %docs, remove missing Changelog entry -Gyepi --SUOF0GtieIMvvwua Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="makerpm.patch" --- makerpm.orig 2004-12-01 19:00:56.646722375 -0500 +++ makerpm 2004-12-01 21:56:28.688613389 -0500 @@ -2,6 +2,10 @@ # Based slightly on an original by John H Terpstra but not much left of his. # S Liddicott 1999 sam@campbellsci.co.uk +# Modified my Gyepi Sam to: +# - Invoke rpmbuild instead of rpm for building package. +# - Replace hard-coded rpm directories with rpm macros. +# - Fixes to generated spec file. See changelog entry. PREFIX="php" TARDIR="`basename \`pwd\``" @@ -50,17 +54,17 @@ %prep %setup -q -n TARDIR #mkdir manual; cd manual && tar xzf $RPM_SOURCE_DIR/php3-manual.tar.gz -./buildconf +#./buildconf %build # first the standalone (why can't you build both at once?) # need to run this under sh or it breaks -sh ./configure --prefix=/usr \ - --with-config-file-path=/etc \ +sh ./configure --prefix=%{_prefix} \ + --with-config-file-path=%{_etcdir} \ --enable-force-cgi-redirect \ --enable-safe-mode \ - --with-exec-dir=/usr/bin \ + --with-exec-dir=%{_prefix}/bin \ --with-mysql \ --with-zlib \ --enable-xml \ @@ -71,13 +75,13 @@ # then the apache module test -f config.cache && rm -f config.cache -sh ./configure --prefix=/usr \ +sh ./configure --prefix=%{_prefix} \ --with-apxs=/usr/sbin/apxs \ --enable-versioning \ --enable-cli \ --with-config-file-path=/etc \ --enable-safe-mode \ - --with-exec-dir=/usr/bin \ + --with-exec-dir=%{_prefix}/bin \ --with-mysql \ --with-zlib \ --enable-xml \ @@ -104,6 +108,11 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Wed Dec 1 2004 Gyepi Sam +- Drop buildconf invocation. +- Replace hard-coded /usr with %{_prefix}. +- Add README* to %docs, remove missing Changelog entry + * Tue Jan 20 2004 Marcus Boerger - Fix script - Drop pdf @@ -153,9 +162,9 @@ %doc TODO CODING_STANDARDS CREDITS ChangeLog LICENSE NEWS EOF -RPMDIR=/usr/src/redhat/RPMS -SPECDIR=/usr/src/redhat/SPECS -SRCDIR=/usr/src/redhat/SOURCES +RPMDIR=$(rpm --eval '%{_topdir}') +SPECDIR=$(rpm --eval '%{_specdir}') +SRCDIR=$(rpm --eval '%{_sourcedir}') ( make clean @@ -163,8 +172,9 @@ cd .. tar czvf ${SRCDIR}/${TAR} $TARDIR ) -cp -a $SPEC $SPECDIR/${SPEC} +SPECFILE=$SPECDIR/${SPEC} +cp -a $SPEC $SPECFILE #cp -a *.patch $SRCDIR -cd $SRCDIR -cd $SPECDIR -rpm -ba -v ${SPEC} +#cd $SRCDIR +#cd $SPECDIR +rpmbuild -ba -v ${SPECFILE} --SUOF0GtieIMvvwua--