Androidã«ã¯NDKã¨ãããJavaã§ã¯ãªããã¤ãã£ãã®C/C++ã§éçºããããã®ãã¼ã«ãã§ã¤ã³ãç¨æããã¦ãã¦ãããã使ãã°ããã©ã¼ãã³ã¹ã¢ãããæããããC/C++ã§æ¸ãããè³ç£ãæµç¨åºæ¥ãããã¾ãã ãããã£ã使ãæ¹ãããå ´åã¯ããã¤ãã£ãã®ã³ã¼ããã³ã³ãã¤ã«ãã¦.soãã¤ããããããJavaããloadLibrary()ã§ãã¼ããããã¨ãã使ãæ¹ãããã®ã§ããã.soã§ã¯ãªããå®è¡ãã¡ã¤ã«å½¢å¼ãã¤ãããã¨ãåºæ¥ã¾ãã ããæ¹ã¯è³ã£ã¦ç°¡åã§ãAndroid.mkã«ä»¥ä¸ã追è¨ããã ãã§ã(â»NDK r4) include $(BUILD_EXECUTABLE) ãµã³ãã« hello-exe.c #include int main(int argc, char ** argv) { printf("Hello, world!\n"); return 0; } Android.mk L
{{#tags}}- {{label}}
{{/tags}}