opensslv.h revision 279265
1204076Spjd#ifndef HEADER_OPENSSLV_H
2204076Spjd#define HEADER_OPENSSLV_H
3204076Spjd
4204076Spjd/* Numeric release version identifier:
5204076Spjd * MNNFFPPS: major minor fix patch status
6204076Spjd * The status nibble has one of the values 0 for development, 1 to e for betas
7204076Spjd * 1 to 14, and f for release.  The patch level is exactly that.
8204076Spjd * For example:
9204076Spjd * 0.9.3-dev	  0x00903000
10204076Spjd * 0.9.3-beta1	  0x00903001
11204076Spjd * 0.9.3-beta2-dev 0x00903002
12204076Spjd * 0.9.3-beta2    0x00903002 (same as ...beta2-dev)
13204076Spjd * 0.9.3	  0x0090300f
14204076Spjd * 0.9.3a	  0x0090301f
15204076Spjd * 0.9.4	  0x0090400f
16204076Spjd * 1.2.3z	  0x102031af
17204076Spjd *
18204076Spjd * For continuity reasons (because 0.9.5 is already out, and is coded
19204076Spjd * 0x00905100), between 0.9.5 and 0.9.6 the coding of the patch level
20204076Spjd * part is slightly different, by setting the highest bit.  This means
21204076Spjd * that 0.9.5a looks like this: 0x0090581f.  At 0.9.6, we can start
22204076Spjd * with 0x0090600S...
23204076Spjd *
24204076Spjd * (Prior to 0.9.3-dev a different scheme was used: 0.9.2b is 0x0922.)
25204076Spjd * (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
26204076Spjd *  major minor fix final patch/beta)
27204076Spjd */
28204076Spjd#define OPENSSL_VERSION_NUMBER	0x009081dfL
29204076Spjd#ifdef OPENSSL_FIPS
30204076Spjd#define OPENSSL_VERSION_TEXT	"OpenSSL 0.9.8zd-fips 8 Jan 2015"
31204076Spjd#else
32204076Spjd#define OPENSSL_VERSION_TEXT	"OpenSSL 0.9.8zd-freebsd 8 Jan 2015"
33204076Spjd#endif
34204076Spjd#define OPENSSL_VERSION_PTEXT	" part of " OPENSSL_VERSION_TEXT
35204076Spjd
36204076Spjd
37204076Spjd/* The macros below are to be used for shared library (.so, .dll, ...)
38204076Spjd * versioning.  That kind of versioning works a bit differently between
39204076Spjd * operating systems.  The most usual scheme is to set a major and a minor
40207070Spjd * number, and have the runtime loader check that the major number is equal
41204076Spjd * to what it was at application link time, while the minor number has to
42207070Spjd * be greater or equal to what it was at application link time.  With this
43204076Spjd * scheme, the version number is usually part of the file name, like this:
44204076Spjd *
45204076Spjd *	libcrypto.so.0.9
46204076Spjd *
47204076Spjd * Some unixen also make a softlink with the major verson number only:
48204076Spjd *
49204076Spjd *	libcrypto.so.0
50204076Spjd *
51204076Spjd * On Tru64 and IRIX 6.x it works a little bit differently.  There, the
52204076Spjd * shared library version is stored in the file, and is actually a series
53204076Spjd * of versions, separated by colons.  The rightmost version present in the
54204076Spjd * library when linking an application is stored in the application to be
55204076Spjd * matched at run time.  When the application is run, a check is done to
56204076Spjd * see if the library version stored in the application matches any of the
57204076Spjd * versions in the version string of the library itself.
58204076Spjd * This version string can be constructed in any way, depending on what
59212033Spjd * kind of matching is desired.  However, to implement the same scheme as
60212033Spjd * the one used in the other unixen, all compatible versions, from lowest
61212033Spjd * to highest, should be part of the string.  Consecutive builds would
62212033Spjd * give the following versions strings:
63204076Spjd *
64204076Spjd *	3.0
65204076Spjd *	3.0:3.1
66204076Spjd *	3.0:3.1:3.2
67204076Spjd *	4.0
68204076Spjd *	4.0:4.1
69204076Spjd *
70212033Spjd * Notice how version 4 is completely incompatible with version, and
71204076Spjd * therefore give the breach you can see.
72212033Spjd *
73204076Spjd * There may be other schemes as well that I haven't yet discovered.
74207070Spjd *
75212033Spjd * So, here's the way it works here: first of all, the library version
76204076Spjd * number doesn't need at all to match the overall OpenSSL version.
77212033Spjd * However, it's nice and more understandable if it actually does.
78204076Spjd * The current library version is stored in the macro SHLIB_VERSION_NUMBER,
79207070Spjd * which is just a piece of text in the format "M.m.e" (Major, minor, edit).
80204076Spjd * For the sake of Tru64, IRIX, and any other OS that behaves in similar ways,
81204076Spjd * we need to keep a history of version numbers, which is done in the
82204076Spjd * macro SHLIB_VERSION_HISTORY.  The numbers are separated by colons and
83207070Spjd * should only keep the versions that are binary compatible with the current.
84204076Spjd */
85207070Spjd#define SHLIB_VERSION_HISTORY ""
86204076Spjd#define SHLIB_VERSION_NUMBER "6"
87204076Spjd
88204076Spjd
89212033Spjd#endif /* HEADER_OPENSSLV_H */
90204076Spjd