38
44
} elsif($arg eq "-write") {
47
} elsif($arg eq "-help" || $arg eq "-h" || $arg eq "-?" || $arg eq "--help") {
49
mkerr.pl [options] ...
53
-conf F Use the config file F instead of the default one:
56
-hprefix P Prepend the filenames in generated #include <header>
57
statements with prefix P. Default: 'openssl/' (without
58
the quotes, naturally)
60
-debug Turn on debugging verbose output on stderr.
62
-rebuild Rebuild all header and C source files, irrespective of the
63
fact if any error or function codes have been added/removed.
64
Default: only update files for libraries which saw change
65
(of course, this requires '-write' as well, or no
66
files will be touched!)
68
-recurse scan a preconfigured set of directories / files for error and
70
(<crypto/*.c>, <crypto/*/*.c>, <ssl/*.c>, <apps/*.c>)
71
When this option is NOT specified, the filelist is taken from
72
the commandline instead. Here, wildcards may be embedded. (Be
73
sure to escape those to prevent the shell from expanding them
74
for you when you wish mkerr.pl to do so instead.)
75
Default: take file list to scan from the command line.
77
-reindex Discard the numeric values previously assigned to the error
78
and function codes as extracted from the scanned header files;
79
instead renumber all of them starting from 100. (Note that
80
the numbers assigned through 'R' records in the config file
82
Default: keep previously assigned numbers. (You are warned
83
when collisions are detected.)
85
-nostatic Generates a different source code, where these additional
86
functions are generated for each library specified in the
88
void ERR_load_<LIB>_strings(void);
89
void ERR_unload_<LIB>_strings(void);
90
void ERR_<LIB>_error(int f, int r, char *fn, int ln);
91
#define <LIB>err(f,r) ERR_<LIB>_error(f,r,__FILE__,__LINE__)
92
while the code facilitates the use of these in an environment
93
where the error support routines are dynamically loaded at
95
Default: 'static' code generation.
97
-staticloader Prefix generated functions with the 'static' scope modifier.
98
Default: don't write any scope modifier prefix.
100
-write Actually (over)write the generated code to the header and C
101
source files as assigned to each library through the config
103
Default: don't write.
105
-help / -h / -? / --help Show this help text.
107
... Additional arguments are added to the file list to scan,
108
assuming '-recurse' was NOT specified on the command line.
47
@source = ( <crypto/*.c>, <crypto/*/*.c>, <ssl/*.c>,
48
<fips/*.c>, <fips/*/*.c>);
118
@source = (<crypto/*.c>, <crypto/*/*.c>, <ssl/*.c>);
315
393
"/* ====================================================================\n",
316
" * Copyright (c) 2001-2010 The OpenSSL Project. All rights reserved.\n",
394
" * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved.\n",
318
396
" * Redistribution and use in source and binary forms, with or without\n",
319
397
" * modification, are permitted provided that the following conditions\n",