Need help statically building qt for Ubuntu
-
@hamer said in Need help statically building qt for Ubuntu:
if(QT_CONFIGURE_RUNNING)
function(check_for_ulimit) endfunction()
it works, thanks
-
Hi
I tried to manually edit the configure file but I failed. I got the error
./configure: 31: Syntax error: word unexpected (expecting ")")
I quite dont posses expertise regarding programming and I dont Know how to edit it, any help please.
what line should be edit and howsrcpath=
dirname $0
srcpath=(cd "$srcpath"; pwd)
configure=$srcpath/qtbase/configure
if [ ! -e "$configure" ]; then
echo "$configure not found. Did you forget to run "init-repository"?" >&2
exit 1
fiset -ex
mkdir -p qtbase
cd qtbaseexec "$configure" -top-level "$@"
Best regards
-
Sorry
I'm trying to install qt6 6.3.0, but I just modified the correct file, not the configuration file in the parent folder. Nevertheless I've installed version 6.2.4, having problems trying to finding correct installer. I'm using Ubuntu 22.04 -
@jhcuarta When iI try to configure I got the following error
jason@jason:/home/jason/Documents/qt-everywhere-src-6.3.0$ ./configure- mkdir -p qtbase
- cd qtbase
- exec /home/jason/Documents/qt-everywhere-src-6.3.0/qtbase/configure -top-level
CMake Warning (dev) at qtbase/cmake/QtBuildInformation.cmake:167 (set):
Cannot set "__qt_configure_reports": current scope has no parent.
Call Stack (most recent call first):
qtsensors/src/sensors/configure.cmake:45 (qt_configure_add_report)
qtbase/cmake/QtProcessConfigureArgs.cmake:240 (include)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Error at qtwebengine/configure.cmake:623 (if):
Flow control statements are not properly nested.
Call Stack (most recent call first):
qtbase/cmake/QtProcessConfigureArgs.cmake:240 (include) -
@SGaist said in Need help statically building qt for Ubuntu:
Hi and welcome to devnet,
QtWebEngine cannot be built statically because the chromium project that powers it does not allow that.
That said, you should only build the modules you need rather than the full of Qt.
But how to ? Particularly, this annoying QtWebEngine?
I mean: how to disable the module QtWebEngine while building Qt from source (say: qt-everywhere-src-6.5.1) ?Cheers
-
@jiapei100 either delete the folder from the sources or use the
--skip webengine
option of the configure script. If you want to save time and space, only build the modules that you are actually using. You can always add others at a later stage if needed. Also, don't build the tests and examples. -
First, make sure you have all the necessary dependencies installed on your system. You can use the apt package manager to install them. Check the Qt documentation for the specific dependencies required for your version of Qt. Once you have the dependencies in place, download the source code for Qt and extract it to a directory of your choice. Then, open a terminal and navigate to the extracted directory. Next, you'll need to configure Qt with the appropriate options for static building. The configure script provides several flags to enable static building, such as -static and -static-runtime. You may also need to specify the path to the static version of any external libraries you want to include. After configuring, run make to start the build process. This may take a while, depending on the speed of your system.
employee monitoring software