Expand PMF_FN_* macros.
[netbsd-mini2440.git] / external / bsd / libdwarf / prepare-import.sh
blobb0bd19e90eedcbc60bf060a77f1904e19689c689
1 #!/bin/sh
2 # $NetBSD: prepare-import.sh,v 1.1 2009/12/19 05:45:28 thorpej Exp $
4 # Copy the FreeBSD src/lib/libdwarf directory contents to dist. Run
5 # this script and you're done.
7 # lib/ is built as SUBDIR from external/lib/Makefile.
9 # Use the following template to import
10 # cvs import src/external/bsd/libdwarf/dist FreeBSD FreeBSD-X-Y-Z
12 # don't forget to bump the lib/shlib_version if necessary
15 set -e
17 echo "Adding RCS tags .."
18 for f in $(grep -RL '\$NetBSD.*\$' dist | grep -v CVS); do
19 case $f in
20 *.[ch] | *.m4)
21 cat - > ${f}_tmp <<- EOF
22 /* \$NetBSD\$ */
24 EOF
25 sed -e 's,^__FBSDID.*,\/\* & \*\/\
26 __RCSID\(\"\$NetBSD\$\"\)\;,g' ${f} >> ${f}_tmp
27 mv ${f}_tmp ${f}
29 *.[0-9])
30 cat - ${f} > ${f}_tmp <<- EOF
31 .\" \$NetBSD\$
32 .\"
33 EOF
34 mv ${f}_tmp ${f}
37 echo "No RCS tag added to ${f}"
39 esac
40 done
42 echo "prepare-import done"