3 print "#ifndef NOPROTO\n";
5 grep(s/^asn1pars$/asn1parse/,@ARGV);
8 { printf "extern int %s_main(int argc,char *argv[]);\n",$_; }
11 { printf "extern int %s_main();\n",$_; }
19 #define FUNC_TYPE_GENERAL 1
20 #define FUNC_TYPE_MD 2
21 #define FUNC_TYPE_CIPHER 3
29 FUNCTION functions[] = {
35 $str="\t{FUNC_TYPE_GENERAL,\"$_\",${_}_main},\n";
36 if (($_ =~ /^s_/) || ($_ =~ /^ciphers$/))
37 { print "#if !defined(NO_SOCK) && !(defined(NO_SSL2) && defined(O_SSL3))\n${str}#endif\n"; }
38 elsif ( ($_ =~ /^rsa$/) || ($_ =~ /^genrsa$/) )
39 { print "#ifndef NO_RSA\n${str}#endif\n"; }
40 elsif ( ($_ =~ /^dsa$/) || ($_ =~ /^gendsa$/) || ($_ =~ /^dsaparam$/))
41 { print "#ifndef NO_DSA\n${str}#endif\n"; }
42 elsif ( ($_ =~ /^dh$/) || ($_ =~ /^gendh$/))
43 { print "#ifndef NO_DH\n${str}#endif\n"; }
48 foreach ("md2","md5","sha","sha1","mdc2","rmd160")
51 printf "\t{FUNC_TYPE_MD,\"%s\",dgst_main},\n",$_;
56 "des", "des3", "desx", "idea", "rc4", "rc2","bf","cast","rc5",
57 "des-ecb", "des-ede", "des-ede3",
58 "des-cbc", "des-ede-cbc","des-ede3-cbc",
59 "des-cfb", "des-ede-cfb","des-ede3-cfb",
60 "des-ofb", "des-ede-ofb","des-ede3-ofb",
61 "idea-cbc","idea-ecb", "idea-cfb", "idea-ofb",
62 "rc2-cbc", "rc2-ecb", "rc2-cfb", "rc2-ofb",
63 "bf-cbc", "bf-ecb", "bf-cfb", "bf-ofb",
64 "cast5-cbc","cast5-ecb", "cast5-cfb","cast5-ofb",
65 "cast-cbc", "rc5-cbc", "rc5-ecb", "rc5-cfb", "rc5-ofb")
69 $t=sprintf("\t{FUNC_TYPE_CIPHER,\"%s\",enc_main},\n",$_);
70 if ($_ =~ /des/) { $t="#ifndef NO_DES\n${t}#endif\n"; }
71 elsif ($_ =~ /idea/) { $t="#ifndef NO_IDEA\n${t}#endif\n"; }
72 elsif ($_ =~ /rc4/) { $t="#ifndef NO_RC4\n${t}#endif\n"; }
73 elsif ($_ =~ /rc2/) { $t="#ifndef NO_RC2\n${t}#endif\n"; }
74 elsif ($_ =~ /bf/) { $t="#ifndef NO_BLOWFISH\n${t}#endif\n"; }
75 elsif ($_ =~ /cast/) { $t="#ifndef NO_CAST\n${t}#endif\n"; }
76 elsif ($_ =~ /rc5/) { $t="#ifndef NO_RC5\n${t}#endif\n"; }
80 print "\t{0,NULL,NULL}\n\t};\n";