{"id":242,"date":"2013-06-07T07:52:30","date_gmt":"2013-06-07T07:52:30","guid":{"rendered":"http:\/\/www.selinuxplus.com\/?p=242"},"modified":"2013-06-07T08:06:56","modified_gmt":"2013-06-07T08:06:56","slug":"fedroa-avd-%e6%a8%a1%e6%8b%9f%e5%99%a8%e5%90%af%e5%8a%a8","status":"publish","type":"post","link":"http:\/\/www.selinuxplus.com\/?p=242","title":{"rendered":"Fedroa AVD \u6a21\u62df\u5668\u542f\u52a8"},"content":{"rendered":"<p>1 \u5229\u7528\u6a21\u62df\u5668\u542f\u52a8android<br \/>\n\u521b\u5efa\u548c\u542f\u52a8\u6a21\u62df\u5668<br \/>\n\u542f\u52a8\u4e4b\u524d\uff0c\u9700\u8981\u521b\u5efaAVD\uff1a<br \/>\n\u8f6c\u8f7d\u8bf7\u6ce8\u660e\u51fa\u5904 <a href=\"http:\/\/www.selinuxplus.com\/?p=242\" title=\"selinuxplus.com\">[By SELinux+]<\/a><\/p>\n<pre class=\"lang:default decode:true \" >\r\n[root@fc16 bin]# .\/android list avd\r\nSWT folder '\/root\/android\/out\/host\/linux-x86\/framework\/x86_64' does not exist.\r\nPlease export ANDROID_SWT to point to the folder containing swt.jar for your platform.<\/pre>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a  <\/p>\n<pre class=\"lang:default decode:true \" >export ANDROID_SWT=\/root\/android\/out\/host\/linux-x86\/framework<\/pre>\n<p>\u6216\u8005\u5199\u5230.bash_profile\u6587\u4ef6<\/p>\n<pre class=\"lang:default decode:true \" >[root@fc16 bin]# source \/root\/.bash_profile<\/pre>\n<p>\u521b\u5efa\u8bbe\u5907<\/p>\n<pre class=\"lang:default decode:true \" >\r\n[root@fc16 bin]# .\/android list avd\r\nAvailable Android Virtual Devices:\r\n\u73b0\u5b9e\u6ca1\u6709avd\u8bbe\u5907\r\n\u521b\u5efaavd\u8bbe\u5907<\/pre>\n<pre class=\"lang:default decode:true \" >[root@fc16 android]# lunch sdk-eng\r\n\r\n============================================\r\nPLATFORM_VERSION_CODENAME=REL\r\nPLATFORM_VERSION=4.1.1\r\nTARGET_PRODUCT=sdk\r\nTARGET_BUILD_VARIANT=eng\r\nTARGET_BUILD_TYPE=release\r\nTARGET_BUILD_APPS=\r\nTARGET_ARCH=arm\r\nTARGET_ARCH_VARIANT=armv7-a\r\nHOST_ARCH=x86\r\nHOST_OS=linux\r\nHOST_OS_EXTRA=Linux-3.4.7-1.fc16.x86_64-x86_64-with-fedora-16-Verne\r\nHOST_BUILD_TYPE=release\r\nBUILD_ID=JRO03C\r\nOUT_DIR=out\r\n\r\nmake sdk\r\n\r\n[root@fc16 android]# cd out\/host\/linux-x86\/sdk\/android-sdk_eng.root_linux-x86\/\r\n[root@fc16 android-sdk_eng.root_linux-x86]# ls\r\nadd-ons extras RELEASE_NOTES.html tests\r\ndocs platforms samples tools\r\ndocumentation.html platform-tools system-images\r\n[root@fc16 android-sdk_eng.root_linux-x86]# cd tools\/\r\n[root@fc16 tools]# .\/android list avd\r\nAvailable Android Virtual Devices:\r\n[root@fc16 tools]# .\/android create avd -n and1 -t 1\r\nAuto-selecting single ABI armeabi-v7a\r\nAndroid 4.1.1 is a basic Android platform.\r\nDo you wish to create a custom hardware profile [no]\r\nCreated AVD 'and1' based on Android 4.1.1, ARM (armeabi-v7a) processor,\r\nwith the following hardware config:\r\nhw.lcd.density=240\r\nvm.heapSize=48\r\nhw.ramSize=512<\/pre>\n<p>\u67e5\u770bavd\u5217\u8868<\/p>\n<pre class=\"lang:default decode:true \" >\r\n[root@fc16 tools]# .\/android list avd\r\nAvailable Android Virtual Devices:\r\nName: and1\r\nPath: \/root\/.android\/avd\/and1.avd\r\nTarget: Android 4.1.1 (API level 16)\r\nABI: armeabi-v7a\r\nSkin: WVGA800<\/pre>\n<p>\u542f\u52a8\u6a21\u62df\u5668<\/p>\n<pre class=\"lang:default decode:true \" >\r\n[root@fc16 tools]# .\/emulator -avd and1\r\nSDL init failure, reason is: No available video device<\/pre>\n<p>Android\u6a21\u62df\u5668\u9519\u8bef:SDL init failure, reason is: No available video device\u539f\u56e0\u548c\u89e3\u51b3\u65b9\u6cd5<br \/>\nAndroid\u5e94\u7528\u5f00\u53d1\u8fc7\u7a0b\u4e2d,\u4f7f\u7528\u6a21\u62df\u5668\u6267\u884c\u7a0b\u5e8f\u662f\u8c03\u8bd5\u5fc5\u4e0d\u53ef\u5c11\u7684\u4e00\u6b65.<br \/>\n\u9519\u8bef:<br \/>\n\u5f88\u591a\u4eba\u4f1a\u9047\u5230\u9519\u8bef:SDL init failure, reason is: No available video device<br \/>\n\u7cfb\u7edf\u73af\u5883:Fedora 16 <\/p>\n<p>\u539f\u56e0:<br \/>\n\u8fd9\u4e2a\u51fa\u9519\u4e3b\u8981\u662f\u572864\u4f4d\u7684linux\u7cfb\u7edf\u4e2d,\u539f\u56e0\u662fandroid\u6a21\u62df\u5668\u662f\u4f7f\u7528\u4e86\u4e00\u4e9b32\u4f4d\u7684\u8f6f\u4ef6\u5305,\u901a\u5e3864\u4e3a\u7684\u7cfb\u7edf\u4e2d\u5b89\u88c5\u5305\u7684\u65f6\u5019\u4e0d\u4f1a\u628a32\u4f4d\u7684\u5305\u88c5\u4e0a.<br \/>\n\u89e3\u51b3\u65b9\u6cd5:<br \/>\n\u89e3\u51b3\u95ee\u9898\u7684\u65b9\u6cd5\u5c31\u662f\u5b89\u88c5\u6240\u9700\u768432\u4f4d\u8f6f\u4ef6\u5305.<\/p>\n<p>\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u5b89\u8f6c\u76f8\u5e9432\u4f4d\u7684\u5305\u5373\u53ef:<\/p>\n<pre class=\"lang:default decode:true \" >yum install libXrandr.i686 libX11.i686<\/pre>\n<p>\u5982\u679c\u6267\u884c\u6a21\u62df\u8fd8\u51fa\u73b0\u4e00\u4e9b\u8f6f\u4ef6\u5305\u627e\u4e0d\u5230\u7684\u9519\u8bef,\u53ef\u4ee5\u5b89\u88c5\u4ee5\u4e0b\u8f6f\u4ef6\u5305<\/p>\n<pre class=\"lang:default decode:true \" >yum install glibc.i686 ncurses-libs.i686 compat-libstdc++-33.i686 libstdc++.i686 libzip.i686<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>1 \u5229\u7528\u6a21\u62df\u5668\u542f\u52a8android \u521b\u5efa\u548c\u542f\u52a8\u6a21\u62df\u5668&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[40],"tags":[],"_links":{"self":[{"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/posts\/242"}],"collection":[{"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=242"}],"version-history":[{"count":4,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/posts\/242\/revisions"}],"predecessor-version":[{"id":252,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=\/wp\/v2\/posts\/242\/revisions\/252"}],"wp:attachment":[{"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=242"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=242"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.selinuxplus.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=242"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}