On Darwin, the -r argument to sed is not valid. It has to be -E.

(issue #9399, reported by jcovert)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@60012 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.2
Russell Bryant 19 years ago
parent e237711157
commit 683a345699

@ -7,6 +7,13 @@ if [ "x$ASTERISKVERSIONNUM" = "x" ]; then
exit
fi
if uname -a | grep -q Darwin
then
SEDARG=-E
else
SEDARG=-r
fi
## Create a pkgconfig spec file for 3rd party modules (pkg-config asterisk --cflags)
if [ ! -d $PPATH ]; then
@ -16,10 +23,10 @@ fi
## 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 $SEDARG -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'`
sed $SEDARG -e 's/-DASTERISK_VERSION=\S* //g' | \
sed $SEDARG -e 's/-DAST(ETCDIR|LIBDIR|VARLIBDIR|VARRUNDIR|SPOOLDIR|LOGDIR|CONFPATH|MODDIR|AGIDIR)=\S* //g'`
cat <<EOF > $PPATH/asterisk.pc

Loading…
Cancel
Save