annotate lib-src/process-gnu-depends.sh @ 54:05472e90ae02 r19-16-pre2

Import from CVS: tag r19-16-pre2
author cvs
date Mon, 13 Aug 2007 08:57:55 +0200
parents 376386a54a3c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 #!/bin/sh
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 perl -e '
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4 while (<>)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6 chop;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 $foo .= $_;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 if (!/\\$/)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9 {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 @foo = split (/[ \\:\n]+/, $foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11 $filename = $foo[0];
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 if (($filename =~ /^unex/) ||
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 ($filename =~ /^sgiplay/) ||
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14 ($filename =~ /^Extern/) ||
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 ($filename =~ /^extw/))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16 {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 $foo = "";
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 next;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 @foo = grep (!/\.c$/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21 @foo = grep ((s/\/.*lwlib\//\$(LWLIBSRCDIR)\//, 1), @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 @foo = grep (!/lisp\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23 @foo = grep (!/lisp\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24 @foo = grep (!/lisp-union\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 @foo = grep (!/lisp-disunion\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
26 @foo = grep (!/lrecord\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
27 @foo = grep (!/emacsfns\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28 @foo = grep (!/symeval\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 @foo = grep (!/symsinit\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 @foo = grep (!/syssignal\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 @foo = grep (!/intl\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32 @foo = grep (!/tt_c\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 @foo = grep (!/descrip\.h/, @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34 shift @foo;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 if (!$#foo)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36 {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 next;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39 foreach $i (0 .. $#foo)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41 $foo[$i] = $filename . ": " . $foo[$i];
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 print $filename . ": config.h\n";
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
44 print join ("\n", @foo);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45 print "\n";
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
46 $foo = "";
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 ' | sort | uniq