'How to use libiconv in NDK now?

I found 2014 article, do these in Android Studio project:

cpp add this:

extern "C"{

include <iconv.h> }

android.mk add this:

LOCAL_WHOLE_STATIC_LIBRARIES += android_support

include $(BUILD_STATIC_LIBRARY)

$(call import-module, android/support)

then you can use libiconv function, but now android.mk has replaced by CMakeLists.txt, how to do with CMakeLists.txt to do the same thing?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source