twogood / unshield

Tool and library to extract CAB files from InstallShield installers
MIT License
348 stars 75 forks source link

Always builds a static library #108

Closed r-a-sattarov closed 3 years ago

r-a-sattarov commented 3 years ago

Always builds a static library regardless of value of BUILD_STATIC option (Linking C static library liblibunshield.a). On version 1.4.3 (October 2018) this does not happen, a dynamic library is created by default.

Сmake version 3.15.4

twogood commented 3 years ago

Thanks for the issue report! PR is welcome :)

r-a-sattarov commented 3 years ago

This error appeared after this commit

This code in unshield\lib\CMakeLists.txt will fixit this error:

if(BUILD_STATIC) add_library(${PROJECT_NAME} STATIC ${LIBUNSHIELD_HEADES} ${LIBUNSHIELD_SOURCES}) else() add_library(${PROJECT_NAME} SHARED ${LIBUNSHIELD_HEADES} ${LIBUNSHIELD_SOURCES}) endif()

twogood commented 3 years ago

Great job, thank you @r-a-sattarov!