jq: Add SOVERSION guard

%ci:no-build
This commit is contained in:
Tee KOBAYASHI 2022-12-30 01:58:41 +09:00 committed by xtkoba
parent d5208d0eb2
commit 57a944bb73
1 changed files with 12 additions and 0 deletions

View File

@ -13,3 +13,15 @@ TERMUX_PKG_BREAKS="jq-dev"
TERMUX_PKG_REPLACES="jq-dev"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--with-oniguruma"
TERMUX_PKG_BUILD_IN_SRC=true
termux_step_post_get_source() {
# Do not forget to bump revision of reverse dependencies and rebuild them
# after SOVERSION is changed.
local _SOVERSION=1
local e=$(sed -En 's/^libjq_la_LDFLAGS\s*=.*\s+-version-info\s+([0-9]+):([0-9]+):([0-9]+).*/\1-\3/p' \
Makefile.am)
if [ ! "${e}" ] || [ "${_SOVERSION}" != "$(( "${e}" ))" ]; then
termux_error_exit "SOVERSION guard check failed."
fi
}