Programing

에뮬레이터에서 AVD를 시작할 수 없음 : QT 라이브러리를 찾을 수 없음

lottogame 2020. 7. 20. 21:09
반응형

에뮬레이터에서 AVD를 시작할 수 없음 : QT 라이브러리를 찾을 수 없음


Android Studio를 처음 사용하고 에뮬레이터를 사용하는 동안 문제가 있습니다. 내가 실행하려고하면 충돌이 계속 발생합니다.

"에뮬레이터에서 AVD를 시작할 수 없음"[6816] : ERROR : ./ android / qt / qt_setup.cpp : 28 : Qt 라이브러리가 C : \ Users \ Jay \ AppData \ Local \ Android \ Sdk \ emulator \ lib64 \ qt에 없습니다. \ lib

'C : \ Users \ Jay \ AppData \ Local \ Android \ Sdk \ emulator / qemu / windows-x86_64 / qemu-system-i386.exe'를 시작할 수 없습니다 : 해당 파일 또는 디렉토리가 없습니다

BIOS 설정에서 VT-x를 활성화했지만 문제가 있습니다. 많이 검색했는데 답을 찾을 수 없습니다. 도움을 주시면 감사하겠습니다. 누구든지 나에게 해결책을 줄 수 있습니까?

오류 스크린 샷 로그 스냅 샷


이것은 최근 업데이트와 관련된 문제인 것 같습니다. 임시 해결책은 /path/to/android-sdk/tools명령 줄 디렉토리 내에서 에뮬레이터를 시작 하는 것입니다.

문제를 해결하려면 https://code.google.com/p/android/issues/detail?id=235461참조 하십시오 .


"Android Emulator"가 표준 Android Studio 설치와 함께 설치되지 않았기 때문에 다른 답변은 모두 작동하지 않았습니다. 설치했는지 확인한 다음 필요한 경우 다른 답변을 시도하십시오.여기에 이미지 설명을 입력하십시오


Linux 또는 Mac 시스템의 경우 다음에 ~/.profile(또는 ~/.bashrc) 을 추가 할 수 있습니다 .

function emulator { cd "$(dirname "$(which emulator)")" && ./emulator "$@"; }

그런 다음 실행하여 변경 사항을로드하십시오.

source ~/.profile

(또는 source ~/.bashrc물론)

emulator문제가 해결 될 때까지 실행할 수 있습니다.

( https://code.google.com/p/android/issues/detail?id=235461의#10 yanokwa 의견을 바탕으로 함 )


이 문제를 해결 한 최신 Android Emulator 26.1.2를 설치했습니다.

PATH에 다음 두 가지가 모두있는 경우 Btw :

  • C:\AndroidSDK\tools

  • C:\AndroidSDK\emulator

emulator명령이 작동하지 않는 도구 폴더 안에 emulator.exe를 사용하려고합니다.

PATH 에서이 문제를 해결하려면 C:\AndroidSDK\emulatortools 디렉토리 앞의 줄로 이동해야합니다 .이 방법으로 에뮬레이터 실행 파일이 에뮬레이터 폴더 내에서 먼저 검색되고 tools 폴더에있는 것보다 우선합니다


간단한 해결책은이 별명을 귀하의 .bashrc .profile동등한 것으로 추가 하는 것입니다

alias emu="$ANDROID_HOME/tools/emulator"

다음 source .bashrc이나 .profile아니면 그냥 단순히 새로운 터미널을 엽니 다

마지막으로 에뮬레이터를 실행하는 것은 간단합니다. emu -avd name


Zsh 사용자는 다음을 추가 할 수 있습니다.

function emulator { ( cd "$(dirname "$(whence -p emulator)")" && ./emulator "$@"; ) }

.zshrc(또는 .zshenv).

변경된 파일을 소싱하여 현재 쉘에 변경 사항을로드합니다.

source ~/.zshrc

이제 emulatorzsh에서 명령을 사용할 수 있습니다 .

에 대한 답변을 주신 J. Costa에게 감사합니다 bash.


어제 Macbook에 설치된 최신 Android Studio와 동일한 문제가있었습니다.

에뮬레이터 바이너리는 sdk / tools 폴더에서 사용할 수 있지만 Android 에뮬레이터 패키지는 설치되지 않았습니다. Android Studio-> 환경 설정-> 시스템 설정-> Android SDK에서 Android Emulator를 선택하고 에뮬레이터 패키지를 다운로드하여 설치했습니다.

에뮬레이터 설치 후 에뮬레이터를 시작할 수 있습니다.


.../Sdk/tools디렉토리 에서 명령을 수행 할 때에도 여전히 문제가 발생하는 경우 -use-system-libs인수를 추가하십시오 .

따라서 다음 형식이어야합니다.

path/to/Sdk/emulator -use-system-libs -avd [AVD-NAME]

나를 위해 여기에 예가 있습니다.

/home/cillian/Android/Sdk/emulator -use-system-libs -avd Nexus5


나는 같은 문제가 있었고 에뮬레이터를 설치하여 어떻게 든 업데이트가 삭제 된 것처럼 보입니다. Android Studio 도구-> SDK 관리자에서 수행하십시오. 도움이 되었기를 바랍니다


우선, Google 이슈 트래커 이슈 스레드 가 이미 해결되었습니다. LD_LIBRARY_PATH더 이상 해결 방법으로 환경 변수를 설정할 필요가 없습니다 . 그러나 Android SDK를 업그레이드하고 최신 emulator 패키지 (바이너리)를 사용해야합니다 . 그것을 갖지 않으면 여전히 성가신 QT오류가 표시됩니다.

그런 다음 에뮬레이터를 시작하기 위해 필요한 SDK 패키지가 설치되어 있는지 확인해야합니다. 로 특정 에뮬레이터 이미지 sdkmanager를 설치할 때 필요한 종속성을 설치하거나 확인하지 않습니다. 당신이 볼 때마다 오류에 대한 불평 ANDROID_SDK_ROOT같은, PANIC: Cannot find AVD system path. Please define ANDROID_SDK_ROOT또는 PANIC: Broken AVD system path. Check your ANDROID_SDK_ROOT value정확히 그 때문에입니다.

따라서 에뮬레이터 이미지를 제외한 3 가지 다른 필수 종속성은 다음과 같습니다.

  • platform-tools
  • platforms;android-<api_level>
  • emulator

다음을 통해 설치할 수 있습니다.

sdkmanager "platform-tools" "platforms;android-<api_level>" "emulator"

api_level에뮬레이터 이미지는 동일한 API 레벨입니다.


Windows 10 x64에 Android Studio 2.3.3 (현재 2017-08-01)을 설치했습니다.

같은 문제입니다.

  • Android Studio-> 도구-> Android-> SDK 관리자-> SDK 도구-> Android 에뮬레이터 (버전 26.1.2)에서 에뮬레이터를 수동으로 설치했습니다.

  • 설치 후 ... 같은 문제

  • 도구 경로 앞에 에뮬레이터 폴더에서 환경 변수까지의 경로를 추가했지만 (위의 답변과 같은) 여전히 동일한 문제입니다.
  • 그런 다음 도구 폴더에서 emulator.exe 및 emulator-check.exe를 삭제 했으며 문제가 해결되었습니다.


이 문제는 Cordova 버전 7.0.X 에서 수정 된 것으로 보입니다.

Cordova 버전 6.5.0사용중인 경우 쉽게 수정할 수 있습니다.

The root of the problem is in the emulator.js file located from the root of your project directory at ./platforms/android/cordova/lib/emulator.js

Simply update the following line, (for me it was line 205):

.spawn('emulator', args, { stdio: 'inherit', detached: true})

to

.spawn('emulator', args, { stdio: 'inherit', detached: true, cwd: process.env['ANDROID_HOME'] + '/tools'})

This will fix the relative path issue your are experiencing.

Also, there is a second fix needed for the Cordova version 6.5.0 on line 56. Simply drop the letter "s" from the word "avds" plural, to make it "avd" singular.


I was facing this issue

  java.io.IOException: Cannot download 
 'https://dl.google.com/android/repository/emulator-windows-4266726.zip'

I updated to studio 3.0 in windows 10, my emulators stopped working.Things I did for fixing,

Deleted previous installation folders of android studio like 2.0 and 2.1 present under my username alongside .AndroidStudio3.0 folder(leaving it untouched).

Deleted previously installed emulators which any way stopped working.

Downloaded the emulator zip file manually from the link above. Pasted its contents in emulator folder of

       C:\Users\myusername\AppData\Local\Android\Sdk\emulator

Created a new emulator and started it, Bingo! it is working!!


For Mac

If have create emulators, try this shell code:

#!/bin/bash
cd /Users/***/Library/Android/sdk/tools/
avds=`emulator -list-avds`
echo "show All emulators"
i=0
for item in $avds
do
    echo [$i] $item
    let i+=1
done
read index
avds=($avds)
# echo ${avds[$index]}
emulator -avd ${avds[$index]}

*** is your user name


My android studio is in the windows operating system. but most of the answers in this page do not work for me.

but I figure it out with an easy way.

In your android studio IDE, open the [Sdk manager], check if you have downloaded the [Android Emulator] and [Android SDK tool]

How to check them?

[SDK Manager] -> [Appearance & behavior] -> [System Setting] -> [Android Sdk] -> There are tabs here and choose the second one [SDK tools]. then check [Android Emulator] and [Android SDK tool].

Hope that it can help you.

Good luck!


I see that you should only add below into the path to be able to launch emulator

C:\Users\Ram\AppData\Local\Android\Sdk\platform-tools
C:\Users\Ram\AppData\Local\Android\Sdk\emulator.

After installing Android Studio 3.0 and higher, I see that C:\Users\Ram\AppData\Local\Android\Sdk\emulator 에뮬레이터 _ 폴더 has same files as C:\Users\Ram\AppData\Local\Android\Sdk\tools tools_folder

The tools folder is missing some files, so remove the tools folder from path.

You can use below emulator commands to launch emulator from command prompt:

emulator -list-avds

emulator @Pixel_2_XL_API_26 - Based on the avd that you have setup

에뮬레이터 _ 명령


Follow these steps to resolve that problem (Windows 10):

  1. Check in Android studio if you installed Android emulator, if not, install it.

  2. Check in Android studio if you installed Intel x86 Emulator Accelerator (HAXM installer), if not, install it.

  3. In Environment variables => System variables edit "Path". You need to add this line for emulator: %ANDROID_HOME%\emulator before %ANDROID_HOME%\tools and %ANDROID_HOME%\platform-tools (The third step was a solution for me.)


Installing Android emulator will solve the issue as this setting is not by default enabled in android studio. In android studio 3+ onwards you cannot find it under Tools-->Android-->Sdk Manager -> SDK Tools -> Android Emulator  but it's under File-->Settings-->Appearance &Behavior-->System Settings-->Android SDK-->SDK Tools-->Android Emulator


My problem turned out to be that I was running VirtualBox at the same time as the emulator. For anybody else running into this problem, have a look here: Android emulator and virtualbox cannot run at same time. Hopefully one of the answers will give you a working solution.


You can also just open the Tools > AVD Manager from Android Studio and start the emulator manually.


There can be the bugs / updates happened in the underlying OS. So, instead of updating in .profile, /etc/environment, or .bashrc file to point adb, emulator etc, put (copy and paste) all the emulator folder inside /usr/bin directory. This /usr/bin is by default pointed by the system. Install adb tool from the terminal. This should solve everything.

And/Or, update your all environment variables in /etc/bash.bashrc file. Note that: /etc/bash.bashrc file is what gets executed everytime you open the bash terminal.


If you're using a Docker container which is running a Ubuntu x86 image, it may not be possible to run an x86-based emulator within the Docker image. You will either get the "Qt library not found" error or the "Please ensure KVM is properly installed and usable" error (more info here).

An alternative is to use an ARM-based emulator, which are easier to run, although they are slower:

# Download an ARM emulator image
android-sdk/tools/bin/sdkmanager "system-images;android-24;default;armeabi-v7a"

# Create an ARM-based emulator AVD with 250 MB SD card
avdmanager create avd -n Android_7.0_API_24 -k "system-images;android-24;default;armeabi-v7a" -c 250M --force

# Check the image is properly created and available to run
android-sdk/emulator/emulator -list-avds

# Run the emulator
android-sdk/emulator/emulator -avd Android_7.0_API_24

More info: https://medium.com/@AndreSand/android-emulator-on-docker-container-f20c49b129ef


A solution that worked for me that I've not seen here before is to link android-sdk/emulator/emulator to android-sdk/tools/emulator.

Dumb? Genius? worksforme.

참고 URL : https://stackoverflow.com/questions/42554337/cannot-launch-avd-in-emulatorqt-library-not-found

반응형