aboutsummaryrefslogtreecommitdiff
path: root/scripts/odp_version.sh
blob: 2487b7f46187abcabc0bcfa12f17a165e83ac46f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash

VFILE="include/odp/api/version.h"

GEN=`grep "define ODP_VERSION_API_GENERATION"	${VFILE} | cut -d ' ' -f 3`
MAJ=`grep "define ODP_VERSION_API_MAJOR"	${VFILE} | cut -d ' ' -f 3`
MIN=`grep "define ODP_VERSION_API_MINOR"	${VFILE} | cut -d ' ' -f 3`

IMPL_FILE="platform/linux-generic/odp_impl.c"
IMPL=`grep "define ODP_VERSION_IMPL "		${IMPL_FILE} | cut -d ' ' -f 3`

echo -n $GEN.$MAJ.$MIN.$IMPL