Skip to content

Commit 125079e

Browse files
committed
Reorganize developers files.
1 parent 23db70b commit 125079e

File tree

12 files changed

+56
-109
lines changed

12 files changed

+56
-109
lines changed

src/DEVELOPERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
All the developer tools are located in the /tools directory.

src/MAKE_CTAGS

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/MAKE_ETAGS

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/MAKE_MKID

Lines changed: 0 additions & 7 deletions
This file was deleted.

src/PGINDENT

Lines changed: 0 additions & 48 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.

src/tools/find_typedef

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/bin/sh
2+
# This script attempts to find all typedef's in the postgres binaries
3+
# by using 'nm' to report all typedef debugging symbols.
4+
#
5+
# For this program to work, you must have compiled all binaries with
6+
# debugging symbols.
7+
#
8+
# This is run on BSD/OS 3.0, so you may need to make changes for your
9+
# version of nm.
10+
#
11+
# Ignore the nm errors about a file not being a binary file.
12+
#
13+
# Remember, debugging symbols are your friends.
14+
#
15+
16+
if [ "$#" -ne 1 -o ! -d "$1" ]
17+
then echo "Usage: $0 postgres_binary_directory" 1>&2
18+
exit 1
19+
fi
20+
21+
nm -a "$1"/* |
22+
grep LSYM |
23+
grep ':t' |
24+
sed 's/^.*LSYM \([^:]*\):.*$/\1/' |
25+
grep -v ' ' | # some typedefs have spaces, revove them
26+
sort |
27+
uniq

src/DEV_TIPS renamed to src/tools/make_diff/README

Lines changed: 3 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,9 @@ Bruce Momjian <maillist@candle.pha.pa.us>
22

33
Here are some of the scripts I use to make development easier.
44

5-
First, I use 'cpdir' on every file I am about to change. This makes a
5+
First, I use 'cporig' on every file I am about to change. This makes a
66
copy with the extension .orig. If an .orig already exists, I am warned.
77

8-
:
9-
# cporig
10-
for FILE
11-
do
12-
if [ ! -f "$FILE.orig" ]
13-
then cp $FILE $FILE.orig
14-
else echo "$FILE.orig exists" 1>&2
15-
fi
16-
done
17-
188
I can get really fancy with this. I can do 'cporig *' and make a .orig
199
for every file in the current directory. I can:
2010

@@ -34,33 +24,12 @@ or even better (using mkid):
3424

3525
to edit all those files.
3626

37-
When I am ready to generate a patch, I run this command from the top of
27+
When I am ready to generate a patch, I run 'difforig' command from the top of
3828
the source tree:
3929

40-
:
41-
#difforig
42-
if [ "$#" -eq 0 ]
43-
then APATH="."
44-
else APATH="$1"
45-
fi
46-
find $APATH -name '*.orig' -print | sort | while read FILE
47-
do
48-
NEW="`dirname $FILE`/`basename $FILE .orig`"
49-
echo "$NEW" 1>&2
50-
diff -c $FILE $NEW
51-
done
52-
5330
I pipe the output of this to a file to hold my patch, and the file names
5431
it processes appear on my screen. It creates a nice patch for me of all
5532
the files I used with cporig.
5633

57-
Finally, I remove my old copies with:
58-
59-
:
60-
# rmorig
61-
if [ "$#" -eq 0 ]
62-
then APATH="."
63-
else APATH="$1"
64-
fi
65-
find $APATH -name '*.orig' -exec rm {} \;
34+
Finally, I remove my old copies with 'rmorig'.
6635

src/tools/make_diff/cporig

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
:
2+
for FILE
3+
do
4+
if [ ! -f "$FILE.orig" ]
5+
then cp $FILE $FILE.orig
6+
else echo "$FILE.orig exists" 1>&2
7+
fi
8+
done

src/tools/make_diff/difforig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
:
2+
if [ "$#" -eq 0 ]
3+
then APATH="."
4+
else APATH="$1"
5+
fi
6+
find $APATH -name '*.orig' -print | sort | while read FILE
7+
do
8+
NEW="`dirname $FILE`/`basename $FILE .orig`"
9+
echo "$NEW" 1>&2
10+
diff -c $FILE $NEW
11+
done

src/tools/make_diff/rmorig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
:
2+
if [ "$#" -eq 0 ]
3+
then APATH="."
4+
else APATH="$1"
5+
fi
6+
find $APATH -name '*.orig' -exec rm {} \;

0 commit comments

Comments
 (0)