Greetings,
I am trying to build imx28 FSL gnome package for imx28 EVK board. I have downloaded the following:
L2.6.35_10.12.01_SDK_source.tar.gz
I am running Ubuntu 10.04, 64 bit:
$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=10.04
DISTRIB_CODENAME=lucid
DISTRIB_DESCRIPTION="Ubuntu 10.04.4 LTS"
I have extracted the source package, and ran the install. I configured ltib for FSL gnome package, and changed the target hostname. After exiting, the build run run for a while, but then fail. If I do the following, it will fail the same way:
$ ./ltib -p fontconfig
Processing platform: Freescale iMX28 Based Boards
===================================================
using config/platform/imx/.config
Processing: fontconfig
========================
Build path taken because: no prebuilt rpm,
rpmbuild --dbpath /opt/freescale_imx28/ltib/rootfs//var/lib/rpm --target arm --define '_unpackaged_files_terminate_build 0' --define '_target_cpu arm' --define '__strip strip' --define '_topdir /opt/freescale_imx28/ltib/rpm' --define '_prefix /usr' --define '_tmppath /opt/freescale_imx28/ltib/tmp' --define '_rpmdir /opt/freescale_imx28/ltib/rpm/RPMS' --define '_mandir /usr/share/man' --define '_sysconfdir /etc' --define '_localstatedir /var' -bb --clean --rmsource /opt/freescale_imx28/ltib/dist/lfs-5.1/fontconfig/fontconfig.spec
Building target platforms: arm
Building for target arm
Executing(%prep): /bin/sh -e /opt/freescale_imx28/ltib/tmp/rpm-tmp.94447
+ umask 022
+ cd /opt/freescale_imx28/ltib/rpm/BUILD
+ cd /opt/freescale_imx28/ltib/rpm/BUILD
+ rm -rf fontconfig-2.4.2
+ /bin/gzip -dc /opt/freescale_imx28/ltib/rpm/SOURCES/fontconfig-2.4.2.tar.gz
+ tar -xvvf -
drwxrwxrwx 1488/100 0 2006-12-02 17:32 fontconfig-2.4.2/
drwxrwxrwx 1488/100 0 2006-12-02 17:32 fontconfig-2.4.2/doc/
.... [removing file list from rpm]
-rw-rw-r-- 1488/100 1640 2006-09-03 17:37 fontconfig-2.4.2/test/run-test.sh
-rw-rw-r-- 1488/100 70952 2006-08-27 16:36 fontconfig-2.4.2/test/4x6.pcf
-rw-rw-r-- 1488/100 21320 2006-08-27 16:36 fontconfig-2.4.2/test/8x16.pcf
-rw-rw-r-- 1488/100 115 2006-08-27 16:36 fontconfig-2.4.2/test/out.expected
-rw-rw-r-- 1488/100 80 2006-09-03 17:37 fontconfig-2.4.2/test/fonts.conf.in
+ STATUS=0
+ [ 0 -ne 0 ]
+ cd fontconfig-2.4.2
+ exit 0
Executing(%build): /bin/sh -e /opt/freescale_imx28/ltib/tmp/rpm-tmp.94447
+ umask 022
+ cd /opt/freescale_imx28/ltib/rpm/BUILD
+ cd fontconfig-2.4.2
+ ac_cv_prog_HASDOCBOOK=no ac_cv_prog_CC_FOR_BUILD=ccache /usr/bin/gcc -B/usr/bin/ ./configure --prefix=/usr --host=arm-linux --build=x86_64-unknown-linux-gnu --with-arch=arm --sysconfdir=/etc
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for arm-linux-strip... arm-linux-strip
checking whether to enable maintainer-specific portions of Makefiles... no
checking for arm-linux-gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... yes
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln -s works... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... arm-unknown-linux-gnu
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ld used by gcc... ld
checking if the linker (ld) is GNU ld... yes
checking for ld option to reload object files... -r
checking for BSD-compatible nm... /opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin/arm-linux-nm -B
checking how to recognise dependent libraries... pass_all
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for arm-linux-g77... no
checking for arm-linux-f77... no
checking for arm-linux-xlf... no
checking for arm-linux-frt... no
checking for arm-linux-pgf77... no
checking for arm-linux-cf77... no
checking for arm-linux-fort77... no
checking for arm-linux-fl32... no
checking for arm-linux-af77... no
checking for arm-linux-f90... no
checking for arm-linux-xlf90... no
checking for arm-linux-pgf90... no
checking for arm-linux-pghpf... no
checking for arm-linux-epcf90... no
checking for arm-linux-gfortran... no
checking for arm-linux-g95... no
checking for arm-linux-f95... no
checking for arm-linux-fort... no
checking for arm-linux-xlf95... no
checking for arm-linux-ifort... no
checking for arm-linux-ifc... no
checking for arm-linux-efc... no
checking for arm-linux-pgf95... no
checking for arm-linux-lf95... no
checking for arm-linux-ftn... no
checking for g77... no
checking for f77... no
checking for xlf... no
checking for frt... no
checking for pgf77... no
checking for cf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for f90... no
checking for xlf90... no
checking for pgf90... no
checking for pghpf... no
checking for epcf90... no
checking for gfortran... no
checking for g95... no
checking for f95... no
checking for fort... no
checking for xlf95... no
checking for ifort... no
checking for ifc... no
checking for efc... no
checking for pgf95... no
checking for lf95... no
checking for ftn... no
checking whether we are using the GNU Fortran 77 compiler... no
checking whether accepts -g... no
checking the maximum length of command line arguments... 32768
checking command to parse /opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin/arm-linux-nm -B output from gcc object... ok
checking for objdir... .libs
checking for arm-linux-ar... ar
checking for arm-linux-ranlib... arm-linux-ranlib
checking for arm-linux-strip... (cached) arm-linux-strip
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... rmdir: failed to remove `conftest': Directory not empty
rm: cannot remove `conftest': Is a directory
yes
checking whether the gcc linker (ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... rm: cannot remove `conftest': Is a directory
rm: cannot remove `conftest': Is a directory
no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
configure: creating libtool
appending configuration tag "CXX" to libtool
rm: cannot remove `conftest': Is a directory
rm: cannot remove `conftest': Is a directory
checking for ld used by g++... ld
checking if the linker (ld) is GNU ld... yes
checking whether the g++ linker (ld) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... rm: cannot remove `conftest': Is a directory
yes
checking if g++ static flag -static works... rm: cannot remove `conftest': Is a directory
no
checking if g++ supports -c -o file.o... rmdir: failed to remove `conftest': Directory not empty
rm: cannot remove `conftest': Is a directory
yes
checking whether the g++ linker (ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
appending configuration tag "F77" to libtool
checking whether make sets $(MAKE)... (cached) yes
checking for a C compiler for build tools... checking for gcc... (cached) ccache /usr/bin/gcc -B/usr/bin/
ccache /usr/bin/gcc -B/usr/bin/
checking for suffix of executable build tools... rm: cannot remove `conftest': Is a directory
configure: error: Cannot determine suffix of executable build tools
error: Bad exit status from /opt/freescale_imx28/ltib/tmp/rpm-tmp.94447 (%build)
RPM build errors:
Bad exit status from /opt/freescale_imx28/ltib/tmp/rpm-tmp.94447 (%build)
Build time for fontconfig: 6 seconds
Failed building fontconfig
f_buildrpms() returned an error, exiting
traceback:
main:560
Started: Mon Feb 4 15:28:56 2013
Ended: Mon Feb 4 15:29:02 2013
Elapsed: 6 seconds
These packages failed to build:
fontconfig
Build Failed
Exiting on error or interrupt
I am a bit concerned over the "--build=x86_64-unknown-linux-gnu" option in the fontconfig configuration option, although I am not sure what it should be set to, or even how to change it.
Daryl
已解决! 转到解答。
This has been resolved. The particular shell I was using had an Android build environment setup in it, which seemingly does work well with ltib environment. If having build problems, check the shell environment.
Sorry for your trouble.
Daryl
This has been resolved. The particular shell I was using had an Android build environment setup in it, which seemingly does work well with ltib environment. If having build problems, check the shell environment.
Sorry for your trouble.
Daryl
Hello Daryl,
I have also encountered the same problem while building.
I have checked my environment and it is bash.
Still it is not working.
I am not able to get the reason of it.
Regards
Gagan
Hi Gagan,
I am not exactly sure what the problem was, paths to incorrect compiler and components were likely. However, I do use the following environment setup script from a base login shell:
----------------------------------------
if [ -z "$ZSH_NAME" ] && [ "x$0" = "x./environment-setup" ]; then
echo "Error: This needs sourced. Please run as \". ./environment-setup\""
exit 1
else
if [ -n "$BASH_SOURCE" ]; then
SDK_PATH="`dirname $BASH_SOURCE`"
else
SDK_PATH="`pwd`"
fi
SDK_PATH=`readlink -f "$SDK_PATH"`
export SDK_PATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi
fi
export TOOLCHAIN_PATH=$SDK_PATH
export TARGET_SYS=arm-fsl-linux-gnueabi
export PATH=$SDK_PATH/bin:$TOOLCHAIN_PATH/bin:$PATH
export CPATH=$SDK_PATH/$TARGET_SYS/usr/include:$CPATH
export LIBTOOL_SYSROOT_PATH=$SDK_PATH/$TARGET_SYS
export PKG_CONFIG_SYSROOT_DIR=$SDK_PATH/$TARGET_SYS
export CC=arm-fsl-linux-gnueabi-gcc
export CPP="arm-fsl-linux-gnueabi-gcc -E"
export NM=arm-fsl-linux-gnueabi-nm
export RANLIB=arm-fsl-linux-gnueabi-ranlib
export OBJCOPY=arm-fsl-linux-gnueabi-objcopy
export STRIP=arm-fsl-linux-gnueabi-strip
export AS=arm-fsl-linux-gnueabi-as
export AR=arm-fsl-linux-gnueabi-ar
export OBJDUMP=arm-fsl-linux-gnueabi-objdump
export CROSS_COMPILE=arm-fsl-linux-gnueabi-
export ARCH=arm
-----------------------------------------------------------------------------------------------
Notice my placement of the arm-fsl cross compiler. As far as ltib itself goes, I think Freescale only tests two of the available build profiles, the base one and the full Gnome profile. I am not sure what will work outside of those two.
For completeness, I'll include my full environment so you might be able to match and compare what the problem might well be:
------------------------------------------------------------------
$ printenv
AS=arm-fsl-linux-gnueabi-as
AR=arm-fsl-linux-gnueabi-ar
SSH_AGENT_PID=1448
TERM=xterm
SHELL=/bin/bash
NM=arm-fsl-linux-gnueabi-nm
WINDOWID=73421175
OLDPWD=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0
GTK_MODULES=canberra-gtk-module
USER=daryl
PKG_CONFIG_SYSROOT_DIR=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/arm-fsl-linux-gnueabi
TOOLCHAIN_PATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi
CPATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/arm-fsl-linux-gnueabi/usr/include:
DEFAULTS_PATH=/usr/share/gconf/gnome.default.path
USERNAME=daryl
CPP=arm-fsl-linux-gnueabi-gcc -E
XDG_CONFIG_DIRS=/etc/xdg/xdg-gnome:/etc/xdg
TARGET_SYS=arm-fsl-linux-gnueabi
DESKTOP_SESSION=gnome
PATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin:/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin:/home/daryl/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/daryl/bin
PWD=/opt/freescale
STRIP=arm-fsl-linux-gnueabi-strip
GDM_KEYBOARD_LAYOUT=us
LANG=en_US.UTF-8
MANDATORY_PATH=/usr/share/gconf/gnome.mandatory.path
GDM_LANG=en_US.UTF-8
GDMSESSION=gnome
OBJCOPY=arm-fsl-linux-gnueabi-objcopy
SPEECHD_PORT=7560
SHLVL=1
HOME=/home/daryl
SDK_PATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
LOGNAME=daryl
XDG_DATA_DIRS=/usr/share/gnome:/usr/local/share/:/usr/share/
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-UFruqpg5uP,guid=3e70a9c87dfb0f118ebd7d17515036f4
LESSOPEN=| /usr/bin/lesspipe %s
USE_CCACHE=1
ARCH=arm
RANLIB=arm-fsl-linux-gnueabi-ranlib
LIBTOOL_SYSROOT_PATH=/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/arm-fsl-linux-gnueabi
CROSS_COMPILE=arm-fsl-linux-gnueabi-
CC=arm-fsl-linux-gnueabi-gcc
DISPLAY=:0.0
OBJDUMP=arm-fsl-linux-gnueabi-objdump
LESSCLOSE=/usr/bin/lesspipe %s %s
COLORTERM=gnome-terminal
_=/usr/bin/printenv
--------------------------------------------------------------------------------
I hope this helps, and good luck.
Daryl