[svn-commits] qwell: trunk r40964 - in /trunk: Makefile build_tools/mkpkgconfig

svn-commits at lists.digium.com svn-commits at lists.digium.com
Wed Aug 23 18:21:42 MST 2006


Author: qwell
Date: Wed Aug 23 20:21:41 2006
New Revision: 40964

URL: http://svn.digium.com/view/asterisk?rev=40964&view=rev
Log:
Okay, there are 3 reasons why I'm doing this.

1) Solaris sed doesn't have -r, which means things like \s and \S don't work.
2) GNU sed version 4.1.2 failed on a very simple test
     echo "Test   Test" | sed -r -e 's/\s/x/g'
     should have returned "TestxxxTest", but did not (however, 4.1.4 did?).
3) The CFLAGS were never set, so that entire line actually did nothing.  Now it's useful again.

Modified:
    trunk/Makefile
    trunk/build_tools/mkpkgconfig

Modified: trunk/Makefile
URL: http://svn.digium.com/view/asterisk/trunk/Makefile?rev=40964&r1=40963&r2=40964&view=diff
==============================================================================
--- trunk/Makefile (original)
+++ trunk/Makefile Wed Aug 23 20:21:41 2006
@@ -331,7 +331,7 @@
 	rm -f build_tools/menuselect-deps
 
 datafiles: all
-	if [ x`$(ID) -un` = xroot ]; then sh build_tools/mkpkgconfig $(DESTDIR)/usr/lib/pkgconfig; fi
+	if [ x`$(ID) -un` = xroot ]; then CFLAGS="$(ASTCFLAGS)" sh build_tools/mkpkgconfig $(DESTDIR)/usr/lib/pkgconfig; fi
 # Should static HTTP be installed during make samples or even with its own target ala
 # webvoicemail?  There are portions here that *could* be customized but might also be
 # improved a lot.  I'll put it here for now.

Modified: trunk/build_tools/mkpkgconfig
URL: http://svn.digium.com/view/asterisk/trunk/build_tools/mkpkgconfig?rev=40964&r1=40963&r2=40964&view=diff
==============================================================================
--- trunk/build_tools/mkpkgconfig (original)
+++ trunk/build_tools/mkpkgconfig Wed Aug 23 20:21:41 2006
@@ -15,11 +15,11 @@
 
 ## Clean out CFLAGS for the spec file.
 
-LOCAL_CFLAGS=`echo $CFLAGS | sed -e 's/\s*-pipe\s*//g' | sed -e 's/-[Wmp]\S*\s*//g' | \
-  sed -r -e 's/-I(include|\.\.\/include) //g' | \
-  sed -e 's/-DINSTALL_PREFIX=\S* //g' | \
-  sed -r -e 's/-DASTERISK_VERSION=\S* //g' | \
-  sed -r -e 's/-DAST(ETCDIR|LIBDIR|VARLIBDIR|VARRUNDIR|SPOOLDIR|LOGDIR|CONFPATH|MODDIR|AGIDIR)=\S* //g'`
+LOCAL_CFLAGS=`echo $CFLAGS | sed -e 's/[[:space:]]*-pipe[[:space:]]*//g' | sed -e 's/-[Wmp][^[:space:]]*[[:space:]]*//g' | \
+  sed -e 's/-I\(include|\.\.\/include\) //g' | \
+  sed -e 's/-DINSTALL_PREFIX=[^[:space:]]* //g' | \
+  sed -e 's/-DASTERISK_VERSION=[^[:space:]]* //g' | \
+  sed -e 's/-DAST\(ETCDIR|LIBDIR|VARLIBDIR|VARRUNDIR|SPOOLDIR|LOGDIR|CONFPATH|MODDIR|AGIDIR\)=[^[:space:]]* //g'`
 
 
 cat <<EOF > $PPATH/asterisk.pc



More information about the svn-commits mailing list