mirror of https://github.com/thesofproject/sof.git
scripts: use project root directory instead of relative path
Use the SOF project root directory in get_abi.sh to read the ABI macros instead of using the relative path. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
This commit is contained in:
parent
ad0ff1f2e5
commit
eac4a73232
|
@ -7,7 +7,7 @@ file(GLOB TPLG_DEPS
|
|||
)
|
||||
|
||||
add_custom_target(abi
|
||||
COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/get_abi.sh
|
||||
COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/get_abi.sh ${SOF_ROOT_SOURCE_DIRECTORY}
|
||||
DEPENDS ${TPLG_DEPS}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
||||
VERBATIM
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
MAJOR=`grep '#define SOF_ABI_MAJOR ' ../../../src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
MINOR=`grep '#define SOF_ABI_MINOR ' ../../../src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
PATCH=`grep '#define SOF_ABI_PATCH ' ../../../src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
MAJOR=`grep '#define SOF_ABI_MAJOR ' $1/src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
MINOR=`grep '#define SOF_ABI_MINOR ' $1/src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
PATCH=`grep '#define SOF_ABI_PATCH ' $1/src/include/uapi/abi.h | grep -E ".[[:digit:]]$" -o`
|
||||
printf "define(\`SOF_ABI_MAJOR', \`0x%02x')\n" $MAJOR > abi.h
|
||||
printf "define(\`SOF_ABI_MINOR', \`0x%02x')\n" $MINOR >> abi.h
|
||||
printf "define(\`SOF_ABI_PATCH', \`0x%02x')\n" $PATCH >> abi.h
|
||||
|
|
Loading…
Reference in New Issue