Fix static build issues caused by yangobj set_target_properties call.
@@ -272,10 +272,11 @@ else()
#link dl
target_link_libraries(yang ${CMAKE_DL_LIBS})
+
+ set_target_properties(yangobj PROPERTIES COMPILE_FLAGS "-fvisibility=hidden")
endif(ENABLE_STATIC)
set_target_properties(yang PROPERTIES VERSION ${LIBYANG_SOVERSION_FULL} SOVERSION ${LIBYANG_SOVERSION})
-set_target_properties(yangobj PROPERTIES COMPILE_FLAGS "-fvisibility=hidden")
# link math
target_link_libraries(yang m)
