summaryrefslogtreecommitdiff
path: root/tools/gcname.c
blob: 74be553c977e779b403b6fafe590db3cd9d99161 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <stdio.h>
#include <gc.h>

#ifndef GC_ALPHA_VERSION
# define GC_ALPHA_VERSION GC_TMP_ALPHA_VERSION
#endif

int main(void)
{
    if (GC_ALPHA_VERSION == GC_NOT_ALPHA) {
        printf("gc%d.%d", GC_VERSION_MAJOR, GC_VERSION_MINOR);
    } else {
        printf("gc%d.%dalpha%d", GC_VERSION_MAJOR,
                                 GC_VERSION_MINOR, GC_ALPHA_VERSION);
    }
    return 0;
}