2
votes

Due to the Internet connect is poor on customer side, I copied the tar file of my Yocto Project to customer.

However, customer met an issue while untar the Yocto Project and run the bitbake command to build project on their PC.

Customer got the following build code error:

s32v@s32v-vm:~/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release$ bitbake fsl-image-s32v2xx
ERROR:  OE-core's config sanity checker detected a potential misconfiguration.
  Either fix the cause of this error or at your own risk disable the checker (see sanity.conf).
  Following is the list of potential problems / advisories:

  Error, TMPDIR has changed location. You need to either move it back to /media/2T_HDD_for_SDK/Amingo/S32V/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp or rebuild

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

I edited /build_s32v234evb_release/tmp/saved_tmpdir file to re-position the tmp directory, this error has pass.

However, I got another error while building Kernel, it seems the directory parameter is still wrong... (There is no error while building U-Boot only.)

s32v@s32v-vm:~/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release$ bitbake fsl-image-s32v2xx
Loading cache: 100% |########################################################################################################################################################################| ETA:  00:00:00
Loaded 2462 entries from dependency cache.
NOTE: Resolving any missing task queue dependencies

Build Configuration:
BB_VERSION        = "1.26.0"
BUILD_SYS         = "x86_64-linux"
NATIVELSBSTRING   = "Ubuntu-14.04"
TARGET_SYS        = "aarch64-fsl-linux"
MACHINE           = "s32v234evb"
DISTRO            = "fsl-networking"
DISTRO_VERSION    = "1.8"
TUNE_FEATURES     = "aarch64"
TARGET_FPU        = ""
meta              
meta-yocto        
meta-yocto-bsp    = "(nobranch):03b0fbcf6b3b5cd16ae16738fbaabd1c6bf98536"
meta-fsl-arm      = "(nobranch):c9f259a4bf8472dfa3ff75f1c3fcbe5e0ded7aaf"
meta-fsl-networking = "(nobranch):b8ff02a8d508464a16c84e1d13c155f45aa98cbe"
meta-fsl-toolchain = "(nobranch):0a235c4bcd4057608ee60b8c898eec9509632b95"
meta-virtualization = "(nobranch):0277cbcb47db4239d0a4aa3b37c5c6a705070951"
meta-fsl-s32v     = "<unknown>:<unknown>"
meta-oe           
meta-networking   
meta-python       
meta-webserver    
meta-filesystems  = "(nobranch):c841231b9f327d2d06d19d2ba1324dd86b83617c"
meta-linaro       
meta-aarch64      
meta-linaro-toolchain = "(nobranch):5075a82bd510d19617803fb16da2375605225cbb"

NOTE: Preparing RunQueue
WARNING: /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/meta-fsl-s32v/recipes-kernel/linux/linux-s32v2xx_4.1.26.bb.do_compile is tainted from a forced run
WARNING: /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/meta-fsl-s32v/recipes-bsp/u-boot/u-boot-s32v2xx_2016.01.bb.do_compile is tainted from a forced run
WARNING: /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/meta-fsl-s32v/recipes-bsp/u-boot/u-boot-s32v2xx_2016.01.bb.do_deploy is tainted from a forced run
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
ERROR: Function failed: do_compile (log file is located at /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/s32v234evb-fsl-linux/linux-s32v2xx/4.1.26-r0/temp/log.do_compile.17853)
ERROR: Logfile of failure stored in: /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/s32v234evb-fsl-linux/linux-s32v2xx/4.1.26-r0/temp/log.do_compile.17853
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 4 Image CC=aarch64-fsl-linux-gcc    --sysroot=/home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/sysroots/s32v234evb LD=aarch64-fsl-linux-ld.bfd    --sysroot=/home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/sysroots/s32v234evb
| make: *** /media/2T_HDD_for_SDK/Amingo/S32V/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work-shared/s32v234evb/kernel-source: No such file or directory.  Stop.
| make: *** [__sub-make] Error 2
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/s32v234evb-fsl-linux/linux-s32v2xx/4.1.26-r0/temp/log.do_compile.17853)
ERROR: Task 76 (/home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/meta-fsl-s32v/recipes-kernel/linux/linux-s32v2xx_4.1.26.bb, do_compile) failed with exit code '1'
ERROR: Function failed: do_compile (log file is located at /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/x86_64-linux/qemu-native/2.2.0-r1/temp/log.do_compile.17854)
ERROR: Logfile of failure stored in: /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/x86_64-linux/qemu-native/2.2.0-r1/temp/log.do_compile.17854
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 4
|   LINK  tests/qemu-iotests/socket_scm_helper
|   GEN   qemu-doc.html
|   GEN   qemu.1
|   CC    qga/commands.o
| cc1: warning: /media/2T_HDD_for_SDK/Amingo/S32V/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/sysroots/x86_64-linux/usr/include/pixman-1: No such file or directory [enabled by default]
| cc1: warning: /media/2T_HDD_for_SDK/Amingo/S32V/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/sysroots/x86_64-linux/usr/include/glib-2.0: No such file or directory [enabled by default]
| cc1: warning: /media/2T_HDD_for_SDK/Amingo/S32V/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/sysroots/x86_64-linux/usr/lib/glib-2.0/include: No such file or directory [enabled by default]
| /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/x86_64-linux/qemu-native/2.2.0-r1/qemu-2.2.0/qga/commands.c:13:18: fatal error: glib.h: No such file or directory
|  #include <glib.h>
|                   ^
| compilation terminated.
| make: *** [qga/commands.o] Error 1
| make: *** Waiting for unfinished jobs....
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/build_s32v234evb_release/tmp/work/x86_64-linux/qemu-native/2.2.0-r1/temp/log.do_compile.17854)
ERROR: Task 2849 (virtual:native:/home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/poky/meta/recipes-devtools/qemu/qemu_2.2.0.bb, do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 1504 tasks of which 1502 didn't need to be rerun and 2 failed.
Waiting for 0 running tasks to finish:

Summary: 2 tasks failed:
  /home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/meta-fsl-s32v/recipes-kernel/linux/linux-s32v2xx_4.1.26.bb, do_compile
  virtual:native:/home/s32v/s32v_15.0/yocto_auto_linux_bsp15.0/poky/meta/recipes-devtools/qemu/qemu_2.2.0.bb, do_compile
Summary: There were 3 WARNING messages shown.
Summary: There were 2 ERROR messages shown, returning a non-zero exit code.

My question is:

  1. Is it possible to copy the Yocot Project to another PC by tar file?
  2. What configuration / initial files I need to edit except saved_tmpdir file?
  3. Which file does Yocto Project define the "kernel-source" directory?

Best Regards, Wayne Kuo

3
If you want to copy the entire yocto repo to a new pc(even though it is not recomented), build yocto in a folder somewhere in /opt or something. Do not build it in your home directory. it will always contain /home/{user} path. And i wonder why your customer want to build the repo again? you can share the final build binaries and the configuration files to them. Just a suggestionzappy

3 Answers

4
votes

when you copy tar project to another PC, two files will be modified:

  1. build/conf/bblayers.conf
  2. build/tmp/saved_tmpdir
0
votes

If it's only a matter of internet connection, I suggest you create a download folder mirror.

On your side, you add BB_GENERATE_MIRROR_TARBALLS and build. Then copy entire DL_DIR folder at customer side, and use BB_NO_NETWORK there.

You can look here and here for usage example.

You can then make a new build at customer side without internet connection. to speed up process, you can also copy your sstate-cache folder to customer side and add a sstate mirror with SSTATE_MIRRORS.

  1. No, you will need a fresh build folder
  2. You need to create a new Yocto environment at customer side
  3. It's bitbake variable STAGING_KERNEL_DIR
0
votes

Error, TMPDIR has changed location. You need to either move it back to...

I built all yocto stuff with the user jamie. Due to disk space running out, I copied the whole $HOME directory of jamie to another disk /dev/sdb1, which had a larger storage. When I tried to run bitbake command to make a test, I got the same error. Here is a simple solution which worked for me:

mount  /dev/sdb1  /mnt/sdb1/
mount  --bind  /mnt/sdb1/home_jamie/  /home/jamie/

What I want was to restore the exact original filesystem layout which the bitbake commands were once run with.

To make the above changes permanent, write above mounting as entries of /etc/fstab.