blob: 3af55fb8b15ca206013735d6123a1c54029347a5 (
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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
#!/bin/sh
echo ""
echo "Module ABI/API fingerprint file generation"
echo ""
echo ""
if [ "${#}" != "2" ]
then
echo ""
echo "ERROR: "
echo " Usage: ${0} _module_ko_file_ _output_file_"
echo ""
exit 1
fi
kerne_abi_file="/boot/abi/current"
if [ ! -f "${kerne_abi_file}" ]
then
echo ""
echo "ERROR: Please check ${kerne_abi_file} file"
echo " Check if linux-kernel-uImage package is installed in development environment."
echo ""
exit 1
fi
if [ ! -f "${1}" ]
then
echo "ERROR: Please check input file ${1}"
echo ""
exit 1
fi
ABI_TOOL_LOCATION="/usr/local/bin"
ABI_TOOL_NAME="abi-checker"
ABI_TOOL="${ABI_TOOL_LOCATION}/${ABI_TOOL_NAME}"
if [ -x "${ABI_TOOL}" ]
then
CMD="${ABI_TOOL}"
elif [ -x "./${ABI_TOOL_NAME}" ]
then
CMD="./${ABI_TOOL_NAME}"
else
CMD="${ABI_TOOL_NAME}"
fi
"${CMD}" "dump-module" "${kerne_abi_file}" "${1}" "${2}"
exit ${?}
|