I am installing Qt6 using this guide on my fresh raspberry pi 4 running the latest official 32bit OS
https://www.tal.org/tutorials/building-qt-62-raspberry-pi
and i am stuck in the Configure the Qt 6.2 build portion where it asks me to execute this line
/opt/cmake/bin/cmake -G Ninja \
-DCMAKE_INSTALL_PREFIX=/opt/Qt/6.2.3-armv7l \
-DQT_FEATURE_opengles2=ON \
-DQT_FEATURE_opengles3=ON \
-DCMAKE_TOOLCHAIN_FILE=tc.cmake \
-DQT_AVOID_CMAKE_ARCHIVING_API=ON ../qtbase-everywhere-src-6.2.3
but i am getting an error
bash: /opt/cmake/bin/cmake: No such file or directory
I followed every step behore hand and there were no problems, everthing went smoothly exempt this part. Can anybody help me with this problem ?
If you have installed Cmake through apt, the default path should be
/usr/bin/cmake
Try to see if is there. If yes, you might want to replace
/opt/cmake/bin/cmake
with
/usr/bin/cmake
Another way to find if you have cmake installed somewhere else would be to run the command:
whereis cmake
Related
I wanted to try learn things in DPDK in Debian 10 buster VM.
I have taken DPDK 20.08 as source.
I followed steps as mentioned in Compiling the DPDK Target from Source https://doc.dpdk.org/guides/linux_gsg/build_dpdk.html#uncompress-dpdk-and-browse-sources
I have tried to follow the below steps
tar xJf dpdk-<version>.tar.xz
cd dpdk-<version>
meson build
cd build
ninja
ninja install
ldconfig
On the above when I tried
ninja
it works. Then I went for next command
If I try with
sudo ninja install
from dpdk build directory
it says sudo: ninja: command not found
If I try
ninja install with out sudo
it gets terminated with error.
It asks for sudo password then shows
ModuleNotFoundError: No module named mesonbuild
Failed Meson-install
ninja:build stopped:subcommand failed
Would appreciate your help to resolve this step.
Edit
Repeated steps with root account. Problem didn't occur. Initially it was looking in /home/vijay/.local/bin folder. Then I used from /usr/local/bin/meson
The error information ninja: command not found could be 1 of the 2 things
either NINJA utility is not installed
or PATH for NINJA Binary is incorrect
As recommended in the comment, ensure 'ninja' is installed and you have the right path like /usr/bin/ for the same.
[EDIT] #Vijay has updated it is indeed the path related issue.
I'm using google cloud instance for host Odoo, somo reports print to pdf ok, but other with custom paperformat get the following error:
"The switch --header-spacing, is not support using unpatched qt, and will be ignored.The switch --header-html, is not support using unpatched qt, and will be ignored.The switch --footer-html, is not support using unpatched qt, and will be ignored.QXcbConnection: Could not connect to display"
I google it, and to solve I need to compile wkhtmltopdf like this:
http://www.grobak.net/id/blog/how-fix-wkhtmltopdf-failed-error-code-6 but this proccess need 3 hs and I'm building a script to install google instances on the run with odoo dependencies.
the .deb package have a dependency broken
Anyone know other solution?
My system configuration is Ubuntu 14.04 and 64 bit. So, i am downloading according to that.
First you have to check your system OS name by
lsb_release -a
Check to see if your Ubuntu Linux operating system architecture is 32-bit or 64-bit, open up a terminal and run the following command below.
file /sbin/init
Download wkhtmltopdf patched with qt using below command
sudo wget -P Downloads https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.1/wkhtmltox-0.12.1_linux-trusty-amd64.deb
Here, replace "trusty" with your OS name and if 64 bit only then keep "amd64" like that , otherwise change it to "i386" and down load the deb file.
After that execute the following commands,
cd ~/Downloads
sudo dpkg -i wkhtmltox-0.12.1_linux-trusty-amd64.deb
Now, check wkhtmltopdf version with below command,
wkhtmltopdf -V
Enjoy!!
After trying many ways I finally made it work.
First I removed all my previous installation by
sudo apt-get remove --purge wkhtmltopdf
sudo apt-get autoremove
Then I opened wkhtmltopdf.org and navigated into their Downloads > Archive. In Archive section I downloaded 0.12.1 .deb version by
wget <copy the link from website for the.deb file and paste it in terminal here>.
sudo dpkg -i <package name>
sudo cp /usr/local/bin/wkhtmltopdf /usr/bin
This is because odoo looks for wkhtmltopdf in /usr/bin directory otherwise gives IOError. I also set my webkit_path parameter in Odoo System Parameters to /usr/bin.
Thats it. Hope this helps
I was facing same issue with wkhtmltopdf 0.12.4
installed new version of wkhtmltopdf 0.12.6-1
follow below commands to install wkhtmltopdf 0.12.6-1
wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox-0.12.6-1.centos7.x86_64.rpm
yum localinstall wkhtmltox-0.12.6-1.centos7.x86_64.rpm #centos specific command
I am trying to build Qt 5 on a Nitrogen6x board powered by an *i.MX6Q`.
I've installed Debian/wheezy on the board and am using an Ubuntu 12.10 machine for cross-compiling.
Configuring Qt works like a charm but I am stuck in the make step.
This is the configure script I run:
./configure -v -opensource -confirm-license -reduce-relocations -no-pch -no-xcb -no-opengl -opengl es2 -qt-libpng -qt-zlib -qt-xkbcommon -qt-xcb -qt-pcre -qt-libjpeg -qt-sql-mysql -optimized-qmake\
-make libs -device imx6 \
-compile-examples \
-device-option CROSS_COMPILE=/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabi- \
-sysroot /media/finn/d72e3b65-b529-4e5c-9d30-872e1b0c9973 \
-prefix /opt/qt5
And this is the error I receive about 5 minutes into the make process:
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld:
/media/finn/d72e3b65-b529-4e5c-9d30-872e1b0c9973/usr/lib/libm.a(mpa.o): relocation R_ARM_THM_MOVW_ABS_NC against `a local symbol' can not be used when making a shared object; recompile with -fPIC
/media/finn/d72e3b65-b529-4e5c-9d30-872e1b0c9973/usr/lib/libm.a: could not read symbols: Bad value
collect2: error: ld returned 1 exit status
I've run into the same error before, when it was trying to access libz.a but adding the qt-zlib parameter to the configure command fixed that issue.
Many articles state that affected applications/libraries should be recompiled, however I don't think that's possible as libm is part of libc6.
I already tried reinstalling it using aptitude remove libc6-dev zlib1g-dev g++-4.6
and apt-get install gcc g++ make flex bison openssl libssl-dev perl perl-base perl-modules libperl-dev build-essential
Sadly this did not fix the problem.
Debian has been installed using the official network installer as well as a Kernel and an Overlay provided by Boundarydevices, the manufacturer of the board.
Does anyone has an idea how to fix this?
My next step would be to install a completely new Debian system but I would really like to avoid that.
Edit
Compiling qtbase with -static option works for me, however I am running into this error when trying to build qtdeclarative during the make step:
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld: cannot find crt1.o: No such file or directory
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld: cannot find crti.o: No such file or directory
/home/finn/qt/qtbase/lib/libQt5Core.a(qlibrary_unix.o): In function `QLibraryPrivate::load_sys()':
qlibrary_unix.cpp:(.text+0xaac): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lqxcb
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld: cannot find /lib/arm-linux-gnueabihf/libpthread.so.0
/home/finn/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.8.2/../../../../arm-linux-gnueabihf/bin/ld: cannot find /usr/lib/arm-linux-gnueabihf/libpthread_nonshared.a
collect2: error: ld returned 1 exit status
Edit 2 - Solution
I fixed the problem and successfully compiled Qt.
All I needed to do was reinstall Ubuntu. It sure isn't an elegant solution but it works for me.
A litte late, but I found the problem/solution:
The problem is the sysroot. Normally gcc links to shared libraries. But when it cant find it, gcc uses the static libraries (.a). When you look in [sysroot]/usr/lib/arm-linux-gnueabihf the shared libraries are not in this place. There are only symlinks to /lib/arm-linux-gnueabihf. So gcc looks for the shared libraries on you host-pc, where it can not find them.
Solution
Create just the right symlink. (Here's an example for libglib, the X is the version number)
ln -s [sysroot]/lib/arm-linux-gnueabihf/libglib.so.X \
[sysroot]/usr/lib/arm-linux-gnueabihf/libglib.so
(Dont forget to remove the old symlink and create it after compiling successfully; i just do the following before compiling:
mv file.so file.so.backup
another solution
Another solution is to change the absolut symlinks to relative ones.
For Example, if your library is /lib/arm-linux-gnueabihf/libglib.so.X and you need a link in /usr/lib/arm-linux-gnueabihf/, you just do:
ln -s ../../../lib/arm-linux-gnueabihf/libglib.so.X \
[sysroot]/usr/lib/arm-linux-gnueabihf/libglib.so
libm.a(mpa.o): relocation R_ARM_THM_MOVW_ABS_NC against `a local symbol' can not be used when making a shared object
Translation: you are trying to link non--fPIC compiled object file (mpa.o from libm.a) into a shared library. You can't do that.
You need to either find/install libm.so for your target, or configure qt5 to not build shared library (possibly with --disable-shared option).
Installed Qt Creator 2.8 in ArchLinux
Installed qt5-* (* as every related package) using pacman
examples were not available in the repositories so I used the one in the AUR, qt5-examples
examples are installed under /usr/share/doc/qt/examples
qmake-qt5 -query says:
QT_SYSROOT:
QT_INSTALL_PREFIX:/usr
QT_INSTALL_ARCHDATA:/usr/lib/qt
QT_INSTALL_DATA:/usr/share/qt
QT_INSTALL_DOCS:/usr/share/doc/qt
QT_INSTALL_HEADERS:/usr/include/qt
QT_INSTALL_LIBS:/usr/lib
QT_INSTALL_LIBEXECS:/usr/lib/qt/libexec
QT_INSTALL_BINS:/usr/lib/qt/bin
QT_INSTALL_TESTS:/usr/tests
QT_INSTALL_PLUGINS:/usr/lib/qt/plugins
QT_INSTALL_IMPORTS:/usr/lib/qt/imports
QT_INSTALL_QML:/usr/lib/qt/qml
QT_INSTALL_TRANSLATIONS:/usr/share/qt/translations
QT_INSTALL_CONFIGURATION:/etc/xdg
QT_INSTALL_EXAMPLES:/usr/share/doc/qt/examples
QT_INSTALL_DEMOS:/usr/share/doc/qt/examples
QT_HOST_PREFIX:/usr
QT_HOST_DATA:/usr/lib/qt
QT_HOST_BINS:/usr/lib/qt/bin
QT_HOST_LIBS:/usr/lib
QMAKE_SPEC:linux-g++
QMAKE_XSPEC:linux-g++
QMAKE_VERSION:3.0
QT_VERSION:5.1.0
which means examples are in the right place
But they are not shown in Qt Creator!
How can I bring them in qtcreator?
PS: I don't wanna forget about the solution and install SDK.
I know OP asked for archlinux but I faced the same issue with Ubuntu 20.04. To solve it I had to install the following two packages:
sudo apt-get install qtbase5-examples qtbase5-doc-html
This will show the basic widget examples.
Additional examples (e.g. qt quick) can be added by installing them explicitly:
sudo apt install qtquickcontrols2-5-examples
To actually get them displayed in qtcreator I had to install:
sudo apt install qt5-doc qt5-doc-html
Here is the output of echo $(apt-mark showmanual | grep -P '(libqt|qt)')
cmake-qt-gui qt5-default qt5-doc qt5-doc-html qtbase5-dev qtbase5-doc-html qtbase5-examples qtcreator qtquickcontrols2-5-examples
Edit:
Also make sure to install the qml modules you need, for example:
sudo apt install qml-module-qtquick-controls2
QtCreator Examples are added in Official Repository 'Extra'
https://www.archlinux.org/packages/extra/any/qt5-examples/
install it using :-
sudo pacman -S qt5-examples
Navigate to the installation location of the examples and open the .pro project file with qt-creator.
Alternatively if you just want to build and run the example. Navigate to the directory qmake and then make and then simple run the output
Additionally if you strictly require the examples to show in the IDE, try launching with admin privileges as the installation directory of the examples may require admin privileges.
My situation is that qt example folder has no permission to read and execute for non-root users, fixed it and everything OK. In your case:
sudo chmod +rx /usr/share/doc/qt/examples
I am also using archlinux and have had the same problem. Despite not having the examples & demo installed the qmake-qt5 -query is printing a non-existence path.
It seems Qt5 examples are now on AUR(Arch User Repository).
To get the them
Download https://aur.archlinux.org/packages/qt/qt5-examples/qt5-examples.tar.gz
Extract the package maybe with $ tar xzf qt5-examples.tar.gz
cd qt5-examples which contains the PKGBUILD . Then run makepkg .This will download 165MB qt-everywhere-opensource-src-5.2.0.tar.xz
Run pacman -U qt-everywhere-opensource-src-5.2.0.tar.xz
Qtcreator cannot detect the example without its html file.
So, in my case I've already installed qtbase5-examples, but could not able to see examples in qtcreator.
After,
sudo apt-get install qtbase5-doc-html
examples are visible in qtcreator. It was the same with qt5serialport-examples.
sudo apt-get install qt5serialport-examples qtserialport5-doc-html
Have a nice one.
make sure you run the qt-opensource-linux-x86-android-5.4.0.run like this:
$sudo ./qt-opensource-linux-x86-android-5.4.0.run
please do not forget the "sudo"
or you will find that the examples in the qtcreator is missing.
qmake: could not find a Qt installation of ''
This thread was not of any help to me. qmake: could not find a Qt installation of ''.
How can I get qmake to recognize where the Qt folder is?
Right now it is installed in /opt/Qt5.1.0.
Have you installed the qt5-default ? You need to do this in addition to running the Qt supplier .run file.
sudo apt-get install qt5-default
This message shown by qtchooser app.
To setup it properly, you should make conf files in /etc/xdg/qtchooser/
for example:
$ ls -1 /etc/xdg/qtchooser/
default.conf
qt-4.8.5.conf
qt-5.1.0.conf
each file has two lines: path to bin, path to lib:
$ cat /etc/xdg/qtchooser/default.conf
/opt/Qt/4.8.5/bin
/opt/Qt/4.8.5/lib
additional info: man qtchooser
The solution for me on this problem was to specify the QT version, as this message was being generated by /usr/bin/qtchooser
So in my case, it was QT4 I was trying to use, and running:
qmake
generated the error (could not find a Qt installation of '')
qmake -qt=qt4
fixed that error though. In my case, it was a Ruby Gem trying to compile with qmake, so I couldn't get it to pass in that extra command line argument, so I instead added this to my profile
export QT_SELECT=qt4
And now QT4 runs just fine on my Ubuntu system.
For me the symlink to default.conf was missing in /usr/share/qtchooser. It wasn't enough to put it into /etc/xdg/qtchooser.