QGIS does not work correctly.

@greenvy, when you decide that you already spent too much time in the dark looking for packages that maybe solve your issue, why not build from source and get yourself an opportunity to learn what QGIS really needs and at the same time get a working instance that is fine tuned to your system? :slight_smile:

It only takes 16 minutes for me in a 8 core machine, not counting the time needed to get all dependencies installed.

Basic instructions (that I regularly maintain in this site):

  • go to https://github.com/qgis/QGIS and get the latest master code or the latest release, as you wish
  • open a terminal
  • log in as root
  • cd to “/usr/local/src”
  • copy the downloaded QGIS-master.zip to your /usr/local/src
  • unzip
  • cd to the new QGIS-master folder
  • make a directory build: mkdir build
  • change to the directory: cd build
  • run “ccmake …”
  • press “c” (configure [c] )
  • review your options (* see below)
  • after you are ready generate build script [g]
  • make -j N (N = your number of cores)
  • after it finishes “make install”
  • run “ldconfig”
  • in a terminal run “qgis”

(*) things that are useful to me:

  • read the options carefully
  • I normally find useful to disable “pedantic” and “tests”
  • disable postgresql if you not have it
  • If you have more than one version of Python in your system, check which one is being used, for example which one links to python3
  • pay attention to the many requirements (with all devel files): libwebkit, python-qt, qwt, libspatialindex, scintilla, qtwebkit, qjson, etc. Also several python modules, as psycopg2, GDAL, etc.
  • check that sip4 is NOT installed
  • I had sometimes difficulties with ccmake not finding libraries like qwt and qca. These libraries were sometimes found in directories not included in the standard library path and had to be given explicitly. It is always a good exercise to check with find, where these are. For example, in openSUSE these two are often found in:
    QCA_INCLUDE_DIR = /usr/include/qt5/Qca-qt5/QtCrypto
    QWT_INCLUDE_DIR = /usr/include/qt5/qwt6/ (for qwt6)

I use QGIS almost everyday. I believe it is already over 12 or 13 years that I have installed QGIS this way. Seldom had problems. But whenever there is a problem I either go back one version or wait, most of the times problems are soon fixed in the next merge.

Also use the QGIS mailing list and look for potential problems in the GitHub issues.

Good luck

Thanks VariableStar - inspired by your straightforward instructions, several hours later I’m deep in the world of cmake config and, weirdly, keep feeling like I’m very nearly there, but… what I don’t understand is: how come cmake can’t find libraries that are exactly in the locations described in the Find*.cmake files?

QGIS version: 3.22.14 Biaowiea (32214)
Could NOT find OpenCL (missing: OpenCL_LIBRARY)
Couldn’t find OpenCL: support DISABLED

YAST: /usr/lib64/libOpenCL.so.1

Found QScintilla2: /usr/lib64/libqscintilla2_qt5.so (2.13.1)

Found PyQt5 version: 5.9.2

Traceback (most recent call last):
File “/usr/local/src/qgis-3.22.14/cmake/FindQsci.py”, line 45, in
from PyQt5.Qsci import QSCINTILLA_VERSION_STR
ModuleNotFoundError: No module named ‘PyQt5.Qsci’

@jack_sprat are you on Tumbleweed? Anyway, have a look at the spec file here: Show Application:Geo / qgis - openSUSE Build Service for all the build requires. It was updated a few days ago, might be better to install the repository version?

Likely your missing python3-qscintilla-qt5 if not on Tumbleweed.

I got round the cmake issues (it was picking up python 3.9 from my anaconda environment, because OpenSUSE Leap 15.4 only supports 3.6 and QGIS needs > 3.7, so I installed Qscintilla in anaconda)

I just gave up on OpenCL - it was too much of a ball-ache figuring out why cmake refused to acknowledge presence of library when it was finding everything else in /usr/lib64.

And then make failed:

[ 47%] Linking CXX shared library …/…/output/lib/libqgis_core.so
/usr/lib64/gcc/x86_64-suse-linux/7/…/…/…/…/x86_64-suse-linux/bin/ld: /usr/bin/xmlwf: stdout: invalid version 2 (max 0)
/usr/lib64/gcc/x86_64-suse-linux/7/…/…/…/…/x86_64-suse-linux/bin/ld: /usr/bin/xmlwf: error adding symbols: bad value
collect2: error: ld returned 1 exit status
make[2]: *** [src/core/CMakeFiles/qgis_core.dir/build.make:14046: output/lib/libqgis_core.so.3.22.14] Error 1
make[1]: *** [CMakeFiles/Makefile2:4290: src/core/CMakeFiles/qgis_core.dir/all] Error 2
make: *** [Makefile:166: all] Error 2

I know hardcore enthusiasts enjoy building executables (and it’s meant to be good for my education’n’all), and I’m prepared to put in the effort, but I’ve now tried 4 separate times to build QGIS (probably 30 hours of faffing around) and each time hit a wall (when I really need to just hit the pillow - here I am again at 4:30am :frowning: ), and I’m just after a version of QGIS that works on Leap 15.4 - I don’t want to be on Tumbleweed, as Leap is supposed to be more stable, and the ‘current’ Leap version of QGIS (3.18) doesn’t work (and is waaay beyond support, so QGIS forum response is move to a newer version). If only Leap could catch up with python by a few versions…

Yup - seems that I’m grumpy now.

image

@jack_sprat I’ve found Tumbleweed to be stable, just lots of releases… There is always flatpak to install the latest or lts versions…

Hi! Glad to hear that you are trying. I do not have OpenCL either and can compile without problems. See the result of “generate”:

QGIS version: 3.29.0 Master (32900)
 Could NOT find OpenCL (missing: OpenCL_LIBRARY OpenCL_INCLUDE_DIR)
 Couldn't find OpenCL: support DISABLED
 Found GRASS 8: /usr/local/grass83 (8.3.dev, off_t size = )
 Found Proj: /usr/local/lib64/libproj.so version 9 (9.1.1)
 Found GEOS: /usr/local/lib64/libgeos_c.so ()
 Found GDAL: /usr/local/lib64/libgdal.so (3.6.2)
 Found Expat: /lib64/libexpat.so
 Found Spatialindex: /usr/lib64/libspatialindex.so
 Found libzip: /usr/lib64/libzip.so
 Found Sqlite3: /lib64/libsqlite3.so
 Found Protobuf: /usr/lib64/libprotobuf.so
 Found zlib: /usr/lib64/libz.so
 Found exiv2: /usr/lib64/libexiv2.so
 Found SpatiaLite: /usr/local/lib64/libspatialite.so
 Qt WebKit support DISABLED.
 Using embedded laz-perf
 Found ZSTD: /usr/lib64/libzstd.so
 Found Qt version: 5.15.7
 Found QScintilla2: /usr/lib64/libqscintilla2_qt5.so (2.13.3)
 Found Qwt: /usr/lib64/libqwt.so (6.2.0)
 Found QtKeychain: /usr/lib64/libqt5keychain.so
 Found QCA: /usr/lib64/libqca-qt5.so (2.3.5)
 Found QCA OpenSSL plugin
 Found GSL: -L/usr/local/lib64 -lgsl -lgslcblas -lm
 -- Found Python executable: /bin/python3.10 (version 3.10.9)
 -- Python library: /usr/lib64/libpython3.10.so
 -- Python site-packages: /usr/lib64/python3.10/site-packages
 Found SIP version: 6.7.3
 Found PyQt5 version: 5.15.7
 Found QScintilla2 PyQt module: 2.13.3
 Using PROJ >= 6 srs database.
 Configuring done

@jack_sprat as @malcolmlewis says, Tumbleweed is pretty stable, but you choose what you prefer of course.