# lib/rpmversion.h File Reference

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Defines

#define | RPMLIB_VERSION RPMLIB_VERSION_ENCODE(5,0,r,3,0,_)
#define | RPMLIB_TIMESTAMP RPMLIB_TIMESTAMP_ENCODE(2008,3,3,0,0)
#define | RPMLIB_VENDOR RPMLIB_VENDOR_ENCODE('R','P','M','5')
#define | RPMLIB_VERSION_ENCODE(major, minor, type, micro, revision, snap)
#define | RPMLIB_VERSION_ENCODE_T(type) RPMLIB_VERSION_ENCODE_T_##type
#define | RPMLIB_VERSION_ENCODE_T__ 0
#define | RPMLIB_VERSION_ENCODE_T_a 1
#define | RPMLIB_VERSION_ENCODE_T_b 2
#define | RPMLIB_VERSION_ENCODE_T_c 3
#define | RPMLIB_VERSION_ENCODE_T_r 4
#define | RPMLIB_VERSION_ENCODE_S(snap) RPMLIB_VERSION_ENCODE_S_##snap
#define | RPMLIB_VERSION_ENCODE_S__ 0
#define | RPMLIB_VERSION_ENCODE_S_s 1
#define | RPMLIB_TIMESTAMP_ENCODE(year, month, date, hour, minute)
#define | RPMLIB_VENDOR_ENCODE(c1, c2, c3, c4)
#define | RPMLIB_VERSION_LT(major, minor, type, micro, revision, snap) (RPMLIB_VERSION < RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))
#define | RPMLIB_VERSION_LE(major, minor, type, micro, revision, snap) (RPMLIB_VERSION <= RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))
#define | RPMLIB_VERSION_EQ(major, minor, type, micro, revision, snap) (RPMLIB_VERSION == RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))
#define | RPMLIB_VERSION_GE(major, minor, type, micro, revision, snap) (RPMLIB_VERSION >= RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))
#define | RPMLIB_VERSION_GT(major, minor, type, micro, revision, snap) (RPMLIB_VERSION > RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))
#define | RPMLIB_TIMESTAMP_LT(year, month, date, hour, minute) (RPMLIB_TIMESTAMP < RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))
#define | RPMLIB_TIMESTAMP_LE(major, minor, type, micro, revision) (RPMLIB_TIMESTAMP <= RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))
#define | RPMLIB_TIMESTAMP_EQ(major, minor, type, micro, revision) (RPMLIB_TIMESTAMP == RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))
#define | RPMLIB_TIMESTAMP_GE(major, minor, type, micro, revision) (RPMLIB_TIMESTAMP >= RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))
#define | RPMLIB_TIMESTAMP_GT(major, minor, type, micro, revision) (RPMLIB_TIMESTAMP > RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))
#define | RPMLIB_VENDOR_EQ(c1, c2, c3, c4) (RPMLIB_VENDOR == RPMLIB_VENDOR_ENCODE((c1),(c2),(c3),(c4)))
#define | RPMLIB_BITFIELD_SET(l, r, n) (((n) & ((1<<(((l)-(r))+1))-1) ) << (r))

## Functions

uint32_t | rpmlibVersion (void)
uint32_t | rpmlibTimestamp (void)
uint32_t | rpmlibVendor (void)

## Define Documentation

#define RPMLIB_BITFIELD_SET | ( | l,
|  | r,
|  | n |  | ) | (((n) & ((1<<(((l)-(r))+1))-1) ) << (r))

Definition at line 135 of file rpmversion.h.

#define RPMLIB_TIMESTAMP RPMLIB_TIMESTAMP_ENCODE(2008,3,3,0,0)

Definition at line 70 of file rpmversion.h.

Referenced by rpmlibTimestamp().

#define RPMLIB_TIMESTAMP_ENCODE | ( | year,
|  | month,
|  | date,
|  | hour,
|  | minute |  | ) |

Value:

    ( RPMLIB_BITFIELD_SET(31,20,(year)) \
        | RPMLIB_BITFIELD_SET(19,16,(month)) \
        | RPMLIB_BITFIELD_SET(15,11,(date)) \
        | RPMLIB_BITFIELD_SET(10,6,(hour)) \
        | RPMLIB_BITFIELD_SET(5,0,(minute)))

Definition at line 92 of file rpmversion.h.

#define RPMLIB_TIMESTAMP_EQ | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision |  | ) | (RPMLIB_TIMESTAMP == RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))

Definition at line 123 of file rpmversion.h.

#define RPMLIB_TIMESTAMP_GE | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision |  | ) | (RPMLIB_TIMESTAMP >= RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))

Definition at line 125 of file rpmversion.h.

#define RPMLIB_TIMESTAMP_GT | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision |  | ) | (RPMLIB_TIMESTAMP > RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))

Definition at line 127 of file rpmversion.h.

#define RPMLIB_TIMESTAMP_LE | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision |  | ) | (RPMLIB_TIMESTAMP <= RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))

Definition at line 121 of file rpmversion.h.

#define RPMLIB_TIMESTAMP_LT | ( | year,
|  | month,
|  | date,
|  | hour,
|  | minute |  | ) | (RPMLIB_TIMESTAMP < RPMLIB_TIMESTAMP_ENCODE((year),(month),(date),(hour),(minute)))

Definition at line 119 of file rpmversion.h.

#define RPMLIB_VENDOR RPMLIB_VENDOR_ENCODE('R','P','M','5')

Definition at line 71 of file rpmversion.h.

Referenced by rpmlibVendor().

#define RPMLIB_VENDOR_ENCODE | ( | c1,
|  | c2,
|  | c3,
|  | c4 |  | ) |

Value:

    ( RPMLIB_BITFIELD_SET(31,24,(c1)) \
        | RPMLIB_BITFIELD_SET(23,16,(c2)) \
        | RPMLIB_BITFIELD_SET(15,8,(c3)) \
        | RPMLIB_BITFIELD_SET(7,0,(c4)))

Definition at line 100 of file rpmversion.h.

#define RPMLIB_VENDOR_EQ | ( | c1,
|  | c2,
|  | c3,
|  | c4 |  | ) | (RPMLIB_VENDOR == RPMLIB_VENDOR_ENCODE((c1),(c2),(c3),(c4)))

Definition at line 131 of file rpmversion.h.

#define RPMLIB_VERSION RPMLIB_VERSION_ENCODE(5,0,r,3,0,_)

Definition at line 69 of file rpmversion.h.

Referenced by rpmlibVersion().

#define RPMLIB_VERSION_ENCODE | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) |

Value:

    ( RPMLIB_BITFIELD_SET(31,27,(major)) \
        | RPMLIB_BITFIELD_SET(26,21,(minor)) \
        | RPMLIB_BITFIELD_SET(20,18,RPMLIB_VERSION_ENCODE_T(type)) \
        | RPMLIB_BITFIELD_SET(17,10,(micro)) \
        | RPMLIB_BITFIELD_SET(9,1,(revision)) \
        | RPMLIB_BITFIELD_SET(0,0,RPMLIB_VERSION_ENCODE_S(snap)))

Definition at line 74 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_S | ( | snap |  | ) | RPMLIB_VERSION_ENCODE_S_##snap

Definition at line 87 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_S__ 0

Definition at line 88 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_S_s 1

Definition at line 89 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T | ( | type |  | ) | RPMLIB_VERSION_ENCODE_T_##type

Definition at line 81 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T__ 0

Definition at line 82 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T_a 1

Definition at line 83 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T_b 2

Definition at line 84 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T_c 3

Definition at line 85 of file rpmversion.h.

#define RPMLIB_VERSION_ENCODE_T_r 4

Definition at line 86 of file rpmversion.h.

#define RPMLIB_VERSION_EQ | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) | (RPMLIB_VERSION == RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))

Definition at line 111 of file rpmversion.h.

#define RPMLIB_VERSION_GE | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) | (RPMLIB_VERSION >= RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))

Definition at line 113 of file rpmversion.h.

#define RPMLIB_VERSION_GT | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) | (RPMLIB_VERSION > RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))

Definition at line 115 of file rpmversion.h.

#define RPMLIB_VERSION_LE | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) | (RPMLIB_VERSION <= RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))

Definition at line 109 of file rpmversion.h.

#define RPMLIB_VERSION_LT | ( | major,
|  | minor,
|  | type,
|  | micro,
|  | revision,
|  | snap |  | ) | (RPMLIB_VERSION < RPMLIB_VERSION_ENCODE((major),(minor),(type),(micro),(revision),(snap)))

Definition at line 107 of file rpmversion.h.

## Function Documentation

uint32_t rpmlibTimestamp | ( | void |  | ) |

Definition at line 15 of file rpmversion.c.

References RPMLIB_TIMESTAMP.

Referenced by printVersion(), and rpmlibMarkers().

uint32_t rpmlibVendor | ( | void |  | ) |

Definition at line 20 of file rpmversion.c.

References RPMLIB_VENDOR.

Referenced by printVersion(), and rpmlibMarkers().

uint32_t rpmlibVersion | ( | void |  | ) |

Definition at line 10 of file rpmversion.c.

References RPMLIB_VERSION.

Referenced by printVersion(), and rpmlibMarkers().