summaryrefslogtreecommitdiff
path: root/mkconfig.sh
blob: 1abfa94b9e43c447e9d90bb032758a6669d07f71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh

HVINFO_LINUX=False
HVINFO_FREEBSD=False

VERSION=$(cat VERSION)

OS=$(uname)
case $OS in
    Linux)
        HVINFO_LINUX=True
        ;;
    FreeBSD)
        HVINFO_FREEBSD=True
        ;;
    *)
        echo "Operating system $OS is not supported"
        exit 1
esac

gnatprep -D LINUX=$HVINFO_LINUX \
         -D FREEBSD=$HVINFO_FREEBSD \
         -D VERSION=\"$VERSION\" \
         src/config.ads.in src/config.ads