Link the static library .a to the .so dynamic library in cmake

add_library(kaldi-native-fbank-core STATIC ${sources})

set_property(TARGET kaldi-native-fbank-core PROPERTY POSITION_INDEPENDENT_CODE ON) #The core is this sentence, the setting position has nothing to do, that is, add -fPIC

Guess you like

Origin blog.csdn.net/znsoft/article/details/131195528