ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/ozone/mgar/gar/bin/find_unpackaged
Revision: 1
Committed: Sat Jun 20 14:58:51 2026 UTC (4 weeks, 3 days ago) by operz
File size: 1180 byte(s)
Log Message:
Initial import of OZSW mgar build tree

File Contents

# Content
1 #!/usr/bin/perl
2
3 # A quick hack of a script to find files that are not added to any
4 # package The idea is that we build a list of files from the main
5 # prototype file in build-global. Then, we look for each arch
6 # specific prototype and remove files that we see there from the
7 # global list. Any remaining file is not listed in a package
8 # prototype and therefore won't be delivered to client systems.
9
10 # We expect a path to build-global as an argument. No error checking
11 # is done on this.
12
13 chdir $ARGV[0];
14 $proc = `uname -p`;
15 @ptypes = glob("*prototype-$proc");
16 %ptype_whole = ();
17
18 open (MAINPTYPE, "prototype") or die "Couldn't open full prototype.\n";
19 while (<MAINPTYPE>) {
20 @parts = split(/\s+/, $_);
21 next if $parts[0] eq 'i';
22 # store references to each file. remove these while traversing
23 # sub-package prototypes
24 $ptype_whole{$parts[2]} = 1;
25 }
26 close(MAINPTYPE);
27
28 foreach $ptype (@ptypes) {
29 open(PTYPE, "$ptype") or die "Couldn't open prototype $ptype.\n";
30 while (<PTYPE>) {
31 @parts = split(/\s+/, $_);
32 next if $parts[0] eq 'i';
33 delete $ptype_whole{$parts[2]};
34 }
35 close(PTYPE);
36 }
37
38 foreach $k (keys %ptype_whole) {
39 print "$k\n";
40 }

Properties

Name Value
svn:executable *