Include guiddef.h in widltypes.h.
[wine/multimedia.git] / tools / make_authors
blobe2c1c9d9d4a0facfdefcc30716705443d4aa962e
1 #! /usr/bin/perl
3 # Generate AUTHORS and dlls/shell32/authors.h
5 # Copyright 1998 Alexandre Julliard
7 # This library is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License, or (at your option) any later version.
12 # This library is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 # Lesser General Public License for more details.
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with this library; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 open(AUTHORS,"<AUTHORS") or die "Can't open AUTHORS";
23 open(NEWAUTHORS,">AUTHORS.new");
24 while(<AUTHORS>)
26 print NEWAUTHORS;
27 last if /^Wine is/;
29 while(<AUTHORS>)
31 chop;
32 s/^and //;
33 s/[,.]$//;
34 push @authors, $_;
37 # Sort them
38 sub cmpnames
40 @anames = split(" ",$a);
41 @bnames = split(" ",$b);
42 $ret = $anames[-1] cmp $bnames[-1];
43 $ret = $anames[0] cmp $bnames[0] unless $ret;
44 return $ret;
46 @authors = sort cmpnames @authors;
48 # Print authors
49 for ($i = 0; $i < $#authors; $i++)
51 print NEWAUTHORS "$authors[$i],\n";
53 print NEWAUTHORS "and $authors[$#authors].\n";
54 print "Created AUTHORS.new\n";
56 # Build authors.h file
57 open(NEWAUTHORS_H,">dlls/shell32/authors.h");
59 print NEWAUTHORS_H <<EOF;
60 #ifndef __WINE_AUTHORS_H
61 #define __WINE_AUTHORS_H
63 static const char * const SHELL_People[] =
65 EOF
67 # Print authors
68 for ($i = 0; $i <= $#authors; $i++)
70 print NEWAUTHORS_H " \"$authors[$i]\",\n";
72 print NEWAUTHORS_H " 0\n};\n";
73 print NEWAUTHORS_H "\n#endif /* __WINE_AUTHORS_H */\n";
75 print "Created dlls/shell32/authors.h\n";