Hi all,
I'm trying to build buildroot with flexbuild_lsdk1812_update_010719.
The sequence is :
source ./setup.env
flex-builder -i mkrfs -r buildroot:tiny -a arm64
Step 1 : The build fails at restool ( the very first package in the file post-build.sh ) with :
Build restool [Done]
make[2]: Leaving directory '/home/fil/flexbuild_lsdk1812_update_010719/packages/apps'
make[1]: Leaving directory '/home/fil/flexbuild_lsdk1812_update_010719'
cp: cannot stat '/home/fil/flexbuild_lsdk1812_update_010719/build/apps/components_arm64/usr/local/bin/restool': No such file or directory
cp: cannot stat '/home/fil/flexbuild_lsdk1812_update_010719/build/apps/components_arm64/usr/local/bin/ls-*': No such file or directory
Makefile:692: recipe for target 'target-finalize' failed
I can't find the build/apps/components_arm64/ directory but I find build/apps/components_LS_arm64.
The file post-build.sh tells : DESTDIR=$FBDIR/build/apps/components_$DESTARCH , and $DESTARCH is arm64.
I have modified this line with DESTDIR=$FBDIR/build/apps/components_LS_$DESTARCH, and restool compiles fine.
Step 2, qbman_userspace .
This is the log:
Building QBMAN_USERSPACE ...
make[3]: Entering directory '/home/fil/flexbuild_lsdk1812_update_010719/packages/apps/qbman_userspace'
mkdir -p lib_aarch64_static
ar rcs lib_aarch64_static/libqbman.a driver/qbman_debug.o driver/qbman_portal.o
make[3]: Leaving directory '/home/fil/flexbuild_lsdk1812_update_010719/packages/apps/qbman_userspace'
cp: cannot create regular file '/home/fil/flexbuild_lsdk1812_update_010719/build/apps/components_LS_arm64/usr/local/lib/': Not a directory
apps/components_LS_arm64/usr/local/lib doesn't exists, only bin and include.
Looking at post-build.sh I see an interesting thing:
# setip qbman
if [ ! -f $DESTDIR/usr/local/bin/qbman_test ]; then
flex-builder -c qbman_userspace
fi
cp $DESTDIR/usr/local/bin/qbman_test ${TARGET_DIR}/usr/bin
cp $DESTDIR/usr/local/lib/libqbman.a ${TARGET_DIR}/lib
So, if qbman_test doesn't exists please build qbman_userspace... but I have no qbman_test package anywhere in packages/apps ... ok, build qbman_userspace each time I call it, it's quick enough ...
I have patched again commenting out the line that tells cp $DESTDIR/usr/local/bin/qbman_test ${TARGET_DIR}/usr/bin and creating build/apps/components_LS_arm64/usr/local/lib and now qbman_userspace compiles fine.
I've not yet tested the build on my ( custom ) system, but the question remains : can I safely build buildroot with flex-builder? Or it's better to use ubuntu or something else ?
Regards
Filippo
LSDK1812 is supposed to support buildroot fs, but it has bug. They've created patches (attached) and I've tried them, buildroot can be successfully built.
Copy these files to /flexbuild_lsdk1812 folder and use the following commands to apply these patches:
Have a great day,
Pavel Chubakov
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------