Bug 9302

Summary: Failed to start qemu with toolchain sysroot
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Valentin Hangan <valentinx.hangan>
Component: devtools / tool chainAssignee: Tim Orling <tim.orling>
Status: RESOLVED NOTABUG QA Contact: Valentin Hangan <valentinx.hangan>
Severity: normal    
Priority: Medium CC: alexandru.c.georgescu, brian.avery, meta.mr.watcher, meta.watcher, sgw, tim.orling
Version: 2.1   
Target Milestone: 2.2   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Don't know
Attachments:
Description Flags
error-message
none
profile-configuration
none
command to start qemu none

Description Valentin Hangan 2016-03-18 07:56:26 UTC
Created attachment 3040 [details]
error-message

Steps:

1. Download and install toolchain from AB (yocto-2.1_M3.rc1)
http://autobuilder.yoctoproject.org/pub/releases/yocto-2.1_M3.rc1/toolchain/x86_64/poky-glibc-x86_64-core-image-minimal-i586-toolchain-ext-2.0+snapshot.sh

2.Configure in Eclipse a Yocto Project ADT profile with:
   - Cross Compiler Options: Standalone pre-built
   - Toolchain Root Location: /home/valentin/eclipse-run/run-release-yocto-2.1_M3.rc1-2016-03-14/installed/toolchain (pointing where i installed toolchain)
   - Sysroot Location: /home/valentin/eclipse-run/run-release-yocto-2.1_M3.rc1-2016-03-14/installed/toolchain/sysroots/i586-poky-linux
   - Target Options: QEMU
   - Kernel: /home/valentin/eclipse-run/run-release-yocto-2.1_M3.rc1-2016-03-14/download/bzImage-qemux86.bin (download from http://autobuilder.yoctoproject.org/pub/releases/yocto-2.1_M3.rc1/machines/qemu/qemux86/bzImage-qemux86.bin)

3. Apply settings for Profile
4. Try to start qemu from Run-->External Tools --> 1 qemu_i586-poky-linux with Arguments:
-e "source /home/valentin/eclipse-run/run-releases-yocto-2.1_M3.rc1-2016-03-14/installed/toolchain/environment-setup-i586-poky-linux;runqemu qemux86 /home/valentin/eclipse-run/run-releases-yocto-2.1_M3.rc1-2016-03-14/download/bzImage-qemux86.bin /home/valentin/eclipse-run/run-releases-yocto-2.1_M3.rc1-2016-03-14/installed/toolchain/sysroots/i586-poky-linux ;bash"

Expected results: Start qemu successfully

Results: Error message:

Error:/home/valentin/eclipse-run/run-release-yocto-2.1_M3.rc1-2016-03-14/installed/toolchain/sysroots/i586-poky-linux/../i586-poky-linux.pseudo_state does not exists.
Did you create the export directory using runqemu-extract-sdk?
Comment 1 Valentin Hangan 2016-03-18 07:57:58 UTC
Created attachment 3041 [details]
profile-configuration
Comment 2 Valentin Hangan 2016-03-18 07:58:47 UTC
Created attachment 3042 [details]
command to start qemu
Comment 3 brian avery 2016-08-18 16:22:16 UTC
Moving to notabug as this is about errors in the steps.  In order to run the QEMU you need the following pieces:
1) an image like http://downloads.yoctoproject.org/releases/yocto/yocto-2.1.1/machines/qemu/qemux86-64/core-image-sato-sdk-qemux86-64.tar.bz2
note, it needs to be one of the sdk images and you cannot point to the sysroot in the toolchain.
2) you need to extract that image with runqemu-extract-sdk  http://www.yoctoproject.org/docs/2.1/sdk-manual/sdk-manual.html#sdk-extracting-the-root-filesystem
3) the toolchain needs to be a non extensible sdk toolchain.
4) It's easier to use the kernel in the downloaded image.