Commit f371fda3 authored by Bruce Momjian's avatar Bruce Momjian

Fix BSD find_typedef logic.

parent 6c4b3f5f
#!/bin/sh #!/bin/sh
# $PostgreSQL: pgsql/src/tools/find_typedef,v 1.11 2008/03/18 23:23:08 momjian Exp $ # $PostgreSQL: pgsql/src/tools/find_typedef,v 1.12 2009/06/10 03:38:32 momjian Exp $
# This script attempts to find all typedef's in the postgres binaries # This script attempts to find all typedef's in the postgres binaries
# by using 'nm' to report all typedef debugging symbols. # by using 'nm' to report all typedef debugging symbols.
...@@ -49,7 +49,7 @@ do # if objdump -W is recognized, only one line of error should appear ...@@ -49,7 +49,7 @@ do # if objdump -W is recognized, only one line of error should appear
awk ' $2 == "DW_AT_name" {print $NF}' awk ' $2 == "DW_AT_name" {print $NF}'
else # BSD/OS else # BSD/OS
objdump --stabs "$DIR"/* | objdump --stabs "$DIR"/* |
awk ' $2 == "LSYM" && $7 ~ /:[tT]/ {sub(":.*", "", $7); print $7}' awk ' $2 == "LSYM" && $7 ~ /:t/ {sub(":.*", "", $7); print $7}'
fi fi
done | done |
grep -v ' ' | # some typedefs have spaces, remove them grep -v ' ' | # some typedefs have spaces, remove them
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment