https://bugs.kde.org/show_bug.cgi?id=366327

            Bug ID: 366327
           Summary: Cross-compiling QCA. Make errors
           Product: qca
           Version: 2.1.1
          Platform: Other
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: dr...@land.ru
          Reporter: zaleski.mik...@gmail.com
                CC: br...@frogmouth.net, jus...@affinix.com

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?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to