Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 72098f3

Browse files
committed
Try to find cpp failure and report it.
1 parent b542fa1 commit 72098f3

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/backend/catalog/genbki.sh

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#
1111
#
1212
# IDENTIFICATION
13-
# $Header: /cvsroot/pgsql/src/backend/catalog/Attic/genbki.sh,v 1.10 1998/04/06 00:22:16 momjian Exp $
13+
# $Header: /cvsroot/pgsql/src/backend/catalog/Attic/genbki.sh,v 1.11 1998/04/20 18:11:42 momjian Exp $
1414
#
1515
# NOTES
1616
# non-essential whitespace is removed from the generated file.
@@ -24,6 +24,12 @@ trap "rm -f /tmp/genbki.tmp" 0 1 2 3 15
2424
>/tmp/genbki.tmp
2525

2626
PATH=$PATH:/lib:/usr/ccs/lib # to find cpp
27+
cpp /dev/null >/dev/null
28+
if [ "$?" -ne 0 ]
29+
then echo "Can't find cpp. Exiting." 1>&2
30+
exit 1
31+
fi
32+
2733
BKIOPTS=''
2834
if [ $? != 0 ]
2935
then
@@ -264,7 +270,7 @@ END {
264270
' | \
265271
cpp $BKIOPTS | \
266272
sed -e '/^[ ]*$/d' \
267-
-e 's/[ ][ ]*/ /g'
273+
-e 's/[ ][ ]*/ /g' || exit 1
268274

269275
# send pg_description file contents to standard error
270276
cat /tmp/genbki.tmp 1>&2

0 commit comments

Comments
 (0)