Bug 366327

Summary: Cross-compiling QCA. Make errors
Product: [Frameworks and Libraries] qca Reporter: Mikita Zaleski <zaleski.mikita>
Component: generalAssignee: Ivan Romanov <drizt72>
Status: RESOLVED WORKSFORME    
Severity: normal CC: aacid, bradh, justin
Priority: NOR    
Version First Reported In: 2.1.1   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Mikita Zaleski 2016-08-01 15:23:46 UTC
I want to build QCA for ARM Linux and Qt 4.8
I have successfully compiled OpenSSL 1.1.0 and Qt 4.8.6 for ARM platform
Then I tried to build QCA with cmake. I set paths to qt, openssl and cross-compiler through the toolchain-file and interface of ccmake.

But when I tried to make (verbose=1) I got an error:
[ 94%] Linking CXX shared module ../../lib/qca/crypto/libqca-gnupg.so
cd /home/zaleski/dev/cpp/sources/qca-2.1.1/build/plugins/qca-gnupg && /usr/bin/cmake -E cmake_link_script CMakeFiles/qca-gnupg.dir/link.txt --verbose=1
/opt/codesourcery/bin/arm-none-linux-gnueabi-g++  -fPIC  -Wcast-align -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-check-new -fno-common -g2  -shared  -o ../../lib/qca/crypto/libqca-gnupg.so CMakeFiles/qca-gnupg.dir/qca-gnupg.cpp.o CMakeFiles/qca-gnupg.dir/gpgop.cpp.o CMakeFiles/qca-gnupg.dir/utils.cpp.o CMakeFiles/qca-gnupg.dir/gpgproc/sprocess.cpp.o CMakeFiles/qca-gnupg.dir/mypgpkeycontext.cpp.o CMakeFiles/qca-gnupg.dir/mykeystoreentry.cpp.o CMakeFiles/qca-gnupg.dir/myopenpgpcontext.cpp.o CMakeFiles/qca-gnupg.dir/mykeystorelist.cpp.o CMakeFiles/qca-gnupg.dir/mymessagecontext.cpp.o CMakeFiles/qca-gnupg.dir/ringwatch.cpp.o CMakeFiles/qca-gnupg.dir/lineconverter.cpp.o CMakeFiles/qca-gnupg.dir/gpgaction.cpp.o CMakeFiles/qca-gnupg.dir/gpgproc/gpgproc.cpp.o CMakeFiles/qca-gnupg.dir/moc_gpgop.cxx.o CMakeFiles/qca-gnupg.dir/moc_gpgop_p.cxx.o CMakeFiles/qca-gnupg.dir/gpgproc/moc_gpgproc.cxx.o CMakeFiles/qca-gnupg.dir/gpgproc/moc_gpgproc_p.cxx.o CMakeFiles/qca-gnupg.dir/gpgproc/moc_sprocess.cxx.o CMakeFiles/qca-gnupg.dir/moc_ringwatch.cxx.o CMakeFiles/qca-gnupg.dir/moc_mykeystorelist.cxx.o CMakeFiles/qca-gnupg.dir/moc_mymessagecontext.cxx.o CMakeFiles/qca-gnupg.dir/moc_gpgaction.cxx.o <my way to qt>/lib/libQtCore.so ../../lib/libqca.so.2.1.1 <my way to qt>/lib/libQtCore.so -Wl,-rpath,<path to qt>/lib:/home/zaleski/dev/cpp/sources/qca-2.1.1/build/lib: 
make[2]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
[ 94%] Built target qca-gnupg
make[1]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

After second attempt of make I got such error:
[ 98%] Linking CXX executable ../../bin/qcatool
cd /home/zaleski/dev/cpp/sources/qca-2.1.1/build/tools/qcatool && /usr/bin/cmake -E cmake_link_script CMakeFiles/qcatool.dir/link.txt --verbose=1
<path to crosscompiler>/bin/arm-none-linux-gnueabi-g++    -Wcast-align -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-check-new -fno-common -g2   CMakeFiles/qcatool.dir/main.cpp.o  -o ../../bin/qcatool -rdynamic <path to qt>/lib/libQtCore.so ../../lib/libqca.so.2.1.1 <path to qt>/lib/libQtCore.so -Wl,-rpath,<path to qt>/lib:/home/zaleski/dev/cpp/sources/qca-2.1.1/build/lib: 
<path to crosscompiler>/lib/gcc/arm-none-linux-gnueabi/4.8.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libts-1.0.so.0, needed by <path to qt>/lib/libQtCore.so, not found (try using -rpath or -rpath-link)
make[2]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
[ 98%] Built target qcatool
make[1]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

And after third and subsequent attempts of make I got such error:
plugins/qca-ossl/CMakeFiles/qca-ossl.dir/build.make:67: recipe for target 'plugins/qca-ossl/CMakeFiles/qca-ossl.dir/qca-ossl.cpp.o' failed
make[2]: *** [plugins/qca-ossl/CMakeFiles/qca-ossl.dir/qca-ossl.cpp.o] Error 1
make[2]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
CMakeFiles/Makefile2:428: recipe for target 'plugins/qca-ossl/CMakeFiles/qca-ossl.dir/all' failed
make[1]: *** [plugins/qca-ossl/CMakeFiles/qca-ossl.dir/all] Error 2
make[1]: Leaving directory '/home/zaleski/dev/cpp/sources/qca-2.1.1/build'
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

Why do I get different errors during make? What am I doing wrong? How to cross-build QCA correctly?
The build of Qt uses external library Tslib. Seems that QCA can't find the path to tslib.so (see output of 2nd attempt of make). How should I specify the path to this library?
Comment 1 Albert Astals Cid 2020-03-10 16:25:39 UTC
Could you please try again with qca 2.3?
Comment 2 Bug Janitor Service 2020-03-25 04:33:12 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 3 Bug Janitor Service 2020-04-09 04:33:12 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!