Create symlink for base soname for libraries with release number in the name

as a separate target instead of POST_BUILD command. This prevents the
command from being executed multiple times and thus FTBFS.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/37/head
Slávek Banko 4 年前
父節點 48b1e42b64
當前提交 e22f5ace4a
沒有發現已知的金鑰在資料庫的簽署中
GPG 金鑰 ID: 608F5293A04BE668

@ -939,8 +939,22 @@ macro( tde_add_library _arg_target )
get_target_property( _soversion ${_target} SOVERSION )
set( _soname "${_soname}.${_soversion}" )
endif( )
add_custom_command( TARGET ${_target} POST_BUILD
COMMAND ln -s ${_soname} "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}" )
if( NOT _exclude_from_all )
add_custom_command(
OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}"
COMMAND ln -s ${_soname} "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}"
DEPENDS ${_target}
)
add_custom_target(
${_target}+base-so ALL
DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}"
)
else( )
add_custom_command(
TARGET ${_target} POST_BUILD
COMMAND ln -s ${_soname} "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}"
)
endif( )
install( FILES "${CMAKE_CURRENT_BINARY_DIR}/${_soname_base}" DESTINATION ${_destination} )
endif( )

載入中…
取消
儲存