aboutsummaryrefslogtreecommitdiffstats
path: root/create_modinfo.pl
diff options
context:
space:
mode:
authorlloyd <[email protected]>2008-09-28 18:15:52 +0000
committerlloyd <[email protected]>2008-09-28 18:15:52 +0000
commit983a8ecb42e844f89466d0ae52bba591d4fc4275 (patch)
treede01378ee9be0ba8bec28bc08d3bde6e422ff898 /create_modinfo.pl
parentd59f6a2c9e797ee22c21b2d85c662e0fe8d1cf35 (diff)
Modularize cipher modes
Diffstat (limited to 'create_modinfo.pl')
-rwxr-xr-xcreate_modinfo.pl35
1 files changed, 35 insertions, 0 deletions
diff --git a/create_modinfo.pl b/create_modinfo.pl
new file mode 100755
index 000000000..b3bf8458e
--- /dev/null
+++ b/create_modinfo.pl
@@ -0,0 +1,35 @@
+#!/usr/bin/perl -w
+
+use File::Spec;
+
+for $dir (<*>) {
+ next if $dir eq "create_modinfo.pl";
+
+ my @files = glob("$dir/*");
+
+ my $modfile = "$dir/modinfo.txt";
+
+ open MOD, ">$modfile" or die "Couldn't write $modfile\n ($!)";
+
+ my $name = uc $dir;
+ my $macro = uc $dir;
+
+ print MOD "realname \"$name\"\n\n";
+
+ print MOD "define $macro\n\n";
+
+ print MOD "load_on auto\n\n";
+
+ print MOD "<add>\n";
+
+ for my $fsname (@files) {
+ my (undef, undef, $file) = File::Spec->splitpath($fsname);
+ print MOD "$file\n";
+ }
+
+ print MOD "</add>\n";
+
+ close MOD;
+
+ #print $dir, " - ", join(' ', glob("$dir/*")), "\n";
+}