2017년 1월 25일 수요일

, ,

libncursesw.so.5: cannnot open... error solution [PetaLinux]

When I try to open petalinux-config the terminal get this error

namsh@namsh-VirtualBox:~/test_project/images/linux$ petalinux-config
INFO: Checking component...
INFO: Config linux
[INFO ] config linux
mconf: error while loading shared libraries: libncursesw.so.5: cannot open shared object file: No such file or directory
make: *** [config] Error 255
ERROR: Failed to config linux!
ERROR: Failed to config component linux
This is 32bit software on a 64bit install, I need the lib32 version
Solution is installing libncursesw5:i386 package

namsh@namsh-VirtualBox:~/test_project/images/linux$ sudo aptitude install libncursesw5:i386
The following NEW packages will be installed:
  libgpm2:i386{a} libncursesw5:i386 libtinfo5:i386{a} 

After the install package rerun petalinux-config

namsh@namsh-VirtualBox:~/test_project/images/linux$ petalinux-config
INFO: Checking component...
INFO: Config linux
[INFO ] config linux

Continue reading libncursesw.so.5: cannnot open... error solution [PetaLinux]

2017년 1월 23일 월요일

, , ,

petalinux build error solution [PetaLinux]

 When ruuning a standard petalinux build process on ubuntu. Sometimes fails to build with error messages
namsh@namsh-VirtualBox:~/test_project$ petalinux-build
INFO: Checking component...
INFO: Generating make files and build linux
INFO: Generating make files for the subcomponents of linux
INFO: Building linux
[INFO ] pre-build linux/rootfs/fwupgrade
[INFO ] pre-build linux/rootfs/peekpoke
[INFO ] pre-build linux/rootfs/uWeb
[INFO ] build linux/kernel
[INFO ] update linux/u-boot source
[INFO ] generate linux/u-boot configuration files
[INFO ] build linux/u-boot
[INFO ] build zynq_fsbl
[INFO ] Expanding stagefs
[ERROR] E: Sub-process /opt/petalinux-v2014.4-final/tools/packagemanager/bin/dpkg returned an error code (127)
[ERROR] make[2]: *** [.pkg_stagefs] Error 255
[ERROR] make[1]: *** [sub_build_component_/none/packages-repo/single/plnx-repo] Error 2
ERROR: Failed to build linux

The follow is the soltution of this error

1. Enable 32bit library
namsh@namsh-VirtualBox:/opt/petalinux-v2014.4-final$ sudo dpkg --add-architecture i386
[sudo] password for namsh: 

2. update the package
namsh@namsh-VirtualBox:/opt/petalinux-v2014.4-final$ sudo apt-get -y update
Ign http://extras.ubuntu.com trusty InRelease                                
Get:1 http://security.ubuntu.com trusty-security InRelease [65.9 kB]        
...  
Hit http://security.ubuntu.com trusty-security/restricted Translation-en    
Hit http://security.ubuntu.com trusty-security/universe Translation-en      
Fetched 1,685 kB in 10s (158 kB/s)                                          
Reading package lists... Done

3. install the 32bit sellinux package
namsh@namsh-VirtualBox:/opt/petalinux-v2014.4-final$ sudo aptitude install libselinux1:i386
The following NEW packages will be installed:
  gcc-4.9-base:i386{a} libc6:i386{a} libgcc1:i386{a} libpcre3:i386{a}
  libselinux1:i386
0 packages upgraded, 5 newly installed, 0 to remove and 0 not upgraded.
Need to get 4,249 kB of archives. After unpacking 10.5 MB will be used.
Do you want to continue? [Y/n/?] y
Get: 1 http://kr.archive.ubuntu.com/ubuntu/ trusty-updates/main gcc-4.9-base i386 4.9.3-0ubuntu4 [15.1 kB]
...
4. rerun the petalinux-build
namsh@namsh-VirtualBox:~/test_project$ petalinux-build
INFO: Checking component...
INFO: Generating make files and build linux
INFO: Generating make files for the subcomponents of linux
INFO: Building linux
[INFO ] pre-build linux/rootfs/fwupgrade
[INFO ] pre-build linux/rootfs/peekpoke
[INFO ] pre-build linux/rootfs/uWeb
[INFO ] build linux/kernel
[INFO ] update linux/u-boot source
[INFO ] generate linux/u-boot configuration files
[INFO ] build linux/u-boot
[INFO ] build zynq_fsbl
[INFO ] Expanding stagefs
[INFO ] build linux/rootfs/fwupgrade
[INFO ] build linux/rootfs/peekpoke
[INFO ] build linux/rootfs/uWeb
[INFO ] build kernel in-tree modules
[INFO ] modules linux/kernel
[INFO ] post-build linux/rootfs/fwupgrade
[INFO ] post-build linux/rootfs/peekpoke
[INFO ] post-build linux/rootfs/uWeb
[INFO ] pre-install linux/rootfs/fwupgrade
[INFO ] pre-install linux/rootfs/peekpoke
[INFO ] pre-install linux/rootfs/uWeb
[INFO ] install system.dtb
[INFO ] install linux/kernel
[INFO ] update linux/u-boot source
[INFO ] generate linux/u-boot configuration files
[INFO ] build linux/u-boot
[INFO ] install linux/u-boot
[INFO ] Expanding rootfs
[INFO ] install sys_init
[INFO ] install linux/rootfs/fwupgrade
[INFO ] install linux/rootfs/peekpoke
[INFO ] install linux/rootfs/uWeb
[INFO ] install kernel in-tree modules
[INFO ] modules_install linux/kernel
[INFO ] post-install linux/rootfs/fwupgrade
[INFO ] post-install linux/rootfs/peekpoke
[INFO ] post-install linux/rootfs/uWeb
[INFO ] package rootfs.cpio to /home/namsh/test_project/images/linux
[INFO ] Update and install vmlinux image
[INFO ] vmlinux linux/kernel
[INFO ] install linux/kernel
[INFO ] package zImage
[INFO ] zImage linux/kernel
[INFO ] install linux/kernel

Continue reading petalinux build error solution [PetaLinux]