mirror of
https://github.com/postgres/postgres.git
synced 2025-05-23 00:02:38 -04:00
Update include scripts
This commit is contained in:
parent
7fe8722295
commit
8e6697fcd9
10
src/tools/pginclude/README
Normal file
10
src/tools/pginclude/README
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
These utilities help clean up #include file usage:
|
||||||
|
|
||||||
|
pgfixinclude change #include's to <> or ""
|
||||||
|
pgrminclude remove extra #include's
|
||||||
|
pginclude [-v] report which #include files can not compile on their own
|
||||||
|
|
||||||
|
pgdefine create macro calls for all defines in the file (used by
|
||||||
|
the above routines)
|
||||||
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
|||||||
:
|
:
|
||||||
|
# create macro calls for all defines in the file
|
||||||
|
|
||||||
trap "rm -f /tmp/$$" 0 1 2 3 15
|
trap "rm -f /tmp/$$" 0 1 2 3 15
|
||||||
for FILE
|
for FILE
|
||||||
do
|
do
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
:
|
:
|
||||||
# mark includes as <> or ""
|
# change #include's to <> or ""
|
||||||
|
|
||||||
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a /tmp/$$b" 0 1 2 3 15
|
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a /tmp/$$b" 0 1 2 3 15
|
||||||
find . \( -name CVS -a -prune \) -o -type f -print |
|
find . \( -name CVS -a -prune \) -o -type f -print |
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
:
|
:
|
||||||
# report which include files can not compile on their own
|
# report which #include files can not compile on their own
|
||||||
|
# takes -v option to display compile failure message and line numbers
|
||||||
|
|
||||||
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a" 0 1 2 3 15
|
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a" 0 1 2 3 15
|
||||||
find . \( -name CVS -a -prune \) -o -name '*.[ch]' -type f -print | while read FILE
|
find . \( -name CVS -a -prune \) -o -name '*.[ch]' -type f -print | while read FILE
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
:
|
:
|
||||||
# report which files have extra includes
|
# remove extra #include's
|
||||||
|
|
||||||
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a /tmp/$$b" 0 1 2 3 15
|
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a /tmp/$$b" 0 1 2 3 15
|
||||||
find . \( -name CVS -a -prune \) -o -type f -print |
|
find . \( -name CVS -a -prune \) -o -type f -print |
|
Loading…
x
Reference in New Issue
Block a user