Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Failed to load driver: swrast ?
Forum Updated to NodeBB v4.3 + New Features

Failed to load driver: swrast ?

Scheduled Pinned Locked Moved General and Desktop
27 Posts 6 Posters 47.0k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    deleted28
    wrote on last edited by
    #3

    SGaist, telling the truth, i read this 2nd line in error message and if i had any idea how to start my application with "LIBGL_DEBUG=verbose" i had posted the result in my question.

    The package manager yast finds a single package on search "swrast"
    Its "Mesa - System for rendering interactive 3-D graphics"
    I remeber in the past there have been problems when MESA stuff was installed.
    Maybe i should remove this (?)

    1 Reply Last reply
    0
    • M Offline
      M Offline
      MuldeR
      wrote on last edited by
      #4

      Try something like:
      @LIBGL_DEBUG=verbose ./myapp@

      Or alternatively:
      @export LIBGL_DEBUG=verbose
      ./myapp@

      My OpenSource software at: http://muldersoft.com/

      Qt v4.8.6 MSVC 2013, static/shared: http://goo.gl/BXqhrS

      Go visit the coop: http://youtu.be/Jay...

      1 Reply Last reply
      0
      • D Offline
        D Offline
        deleted28
        wrote on last edited by
        #5

        LIBGL_DEBUG=verbose ./SizeGrip_q001
        "Qt Warning - invalid keysym: dead_actute"

        that's all i get in Konsole.
        The "libGL error: failed to load driver: swrast" i get in creator - Application output.

        The application starts up and seems to work properly.
        Anyway, this message is annooying

        1 Reply Last reply
        0
        • D Offline
          D Offline
          deleted28
          wrote on last edited by
          #6

          MuldeR,

          if i use the second approach with export, i set an environment variable, right ?
          Do i need to remove this later or does it not survive a reboot ?
          If necessary to manually remove, please tell me how to ?

          [quote author="MuldeR" date="1398112562"]Try something like:
          @LIBGL_DEBUG=verbose ./myapp@

          Or alternatively:
          @export LIBGL_DEBUG=verbose
          ./myapp@[/quote]

          Any other ideas about this annoying swrast message ?
          i changed to qt veersion 5.2.1 now, but the problem persists.

          1 Reply Last reply
          0
          • M Offline
            M Offline
            MuldeR
            wrote on last edited by
            #7

            [quote author="wally123" date="1398180317"]if i use the second approach with export, i set an environment variable, right ?[/quote]

            Actually you set the environment variable in both cases. While the first method sets it only for the new process, the second method will set it for all processes you start subsequently (from the same bash instance). And nope, it doesn't survive a reboot, unless you add it to your .bashrc file.

            My OpenSource software at: http://muldersoft.com/

            Qt v4.8.6 MSVC 2013, static/shared: http://goo.gl/BXqhrS

            Go visit the coop: http://youtu.be/Jay...

            1 Reply Last reply
            0
            • D Offline
              D Offline
              deleted28
              wrote on last edited by
              #8

              thank you :)

              running both approaches with LIBGL_DEBUG=verbose i do not get any
              error message.
              This error message seems to appear only when i build and run the application in qt-creator.
              This happens even on fresh Qt GUI Application without any additional code.
              Any idea highly welcome

              this error is only emitted when i use Qt 5.2.1 , not with 4.8.

              1 Reply Last reply
              0
              • A Offline
                A Offline
                andreyc
                wrote on last edited by
                #9

                [quote author="wally123" date="1398113331"]> LIBGL_DEBUG=verbose ./SizeGrip_q001
                "Qt Warning - invalid keysym: dead_actute" [/quote]
                Tells that you have broken "locale file":https://bugs.freedesktop.org/show_bug.cgi?id=69476
                But it is not a problem here.

                [quote author="wally123" date="1398113331"]
                The "libGL error: failed to load driver: swrast" i get in creator - Application output.
                The application starts up and seems to work properly.
                Anyway, this message is annooying [/quote]
                LibGL tries to load software rendering library even if you have nvidia drivers.

                What does the following command says
                @
                LIBGL_DEBUG=verbose glxinfo >/dev/null
                @

                1 Reply Last reply
                0
                • D Offline
                  D Offline
                  deleted28
                  wrote on last edited by
                  #10

                  @> LIBGL_DEBUG=verbose glxinfo >/dev/null@
                  return nothing

                  @> LIBGL_DEBUG=verbose glxinfo
                  name of display: :0
                  display: :0 screen: 0
                  direct rendering: Yes
                  server glx vendor string: NVIDIA Corporation
                  server glx version string: 1.4
                  server glx extensions:
                  GLX_ARB_create_context, GLX_ARB_create_context_profile,
                  GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float,
                  GLX_ARB_multisample, GLX_EXT_create_context_es2_profile,
                  GLX_EXT_create_context_es_profile, GLX_EXT_swap_control,
                  GLX_EXT_swap_control_tear, GLX_EXT_texture_from_pixmap,
                  GLX_EXT_visual_info, GLX_EXT_visual_rating, GLX_NV_float_buffer,
                  GLX_SGIX_fbconfig, GLX_SGIX_pbuffer, GLX_SGI_swap_control,
                  GLX_SGI_video_sync
                  client glx vendor string: NVIDIA Corporation
                  client glx version string: 1.4
                  client glx extensions:
                  GLX_ARB_create_context, GLX_ARB_create_context_profile,
                  GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float,
                  GLX_ARB_get_proc_address, GLX_ARB_multisample,
                  GLX_EXT_create_context_es2_profile, GLX_EXT_fbconfig_packed_float,
                  GLX_EXT_framebuffer_sRGB, GLX_EXT_import_context, GLX_EXT_swap_control,
                  GLX_EXT_swap_control_tear, GLX_EXT_texture_from_pixmap,
                  GLX_EXT_visual_info, GLX_EXT_visual_rating, GLX_NV_copy_image,
                  GLX_NV_float_buffer, GLX_NV_multisample_coverage, GLX_NV_present_video,
                  GLX_NV_swap_group, GLX_NV_video_capture, GLX_NV_video_out,
                  GLX_SGIX_fbconfig, GLX_SGIX_pbuffer, GLX_SGI_swap_control,
                  GLX_SGI_video_sync
                  GLX version: 1.4
                  GLX extensions:
                  GLX_ARB_create_context, GLX_ARB_create_context_profile,
                  ........ @
                  and some more, do you need all the output ?

                  I also posted this question to opensuse forum:
                  Also several interesting explanations:
                  "openuse forum swrast ":https://forums.opensuse.org/showthread.php/497353-Remove-packages-dependency-question?p=2638720#post2638720

                  1 Reply Last reply
                  0
                  • A Offline
                    A Offline
                    andreyc
                    wrote on last edited by
                    #11

                    [quote author="wally123" date="1398277480"]@> LIBGL_DEBUG=verbose glxinfo >/dev/null@
                    return nothing[/quote]
                    This is interesting. Because in my case it returns the debug messages
                    @
                    $ LIBGL_DEBUG=verbose glxinfo >/dev/null
                    libGL: OpenDriver: trying /usr/lib64/dri/tls/i965_dri.so
                    libGL: OpenDriver: trying /usr/lib64/dri/i965_dri.so
                    @

                    [quote author="wally123" date="1398277480"]and some more, do you need all the output ? [/quote]
                    No. don't need it. :-)

                    If you have this warning only in QtCreator Application output window then I would suggest to compare the terminal environment and QtCreator Run environment. Run "env | sort" in a terminal and compare the output with QtCreator Projects/Run/Run Environment.
                    Unfortunately there is no easy way to grab it from QtCreator into a file and run diff on two files.

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      deleted28
                      wrote on last edited by
                      #12

                      ...

                      1 Reply Last reply
                      0
                      • D Offline
                        D Offline
                        deleted28
                        wrote on last edited by
                        #13

                        here the QT… part of “env” :

                        @QEMU_AUDIO_DRV=pa
                        QT_IM_MODULE=xim
                        QT_IM_SWITCHER=imsw-multi
                        QT_PLUGIN_PATH=/home/op/.kde4/lib/kde4/plugins/:/usr/lib/kde4/plugins/
                        QT_SYSTEM_DIR=/usr/share/desktop-data
                        SDL_AUDIODRIVER=pulse@
                        

                        QtCreator Projects/Run/Run Environment:
                        Yes, unfortunately not easy to grab :)
                        Also unable to paste a screenshot here.

                        What’s the relevvant lines, what to compare ?

                        1 Reply Last reply
                        0
                        • D Offline
                          D Offline
                          deleted28
                          wrote on last edited by
                          #14

                          maybe another hint to get behind what i setup wrong:

                          When i open examples from Qt 5.2.1 i get :
                          @.../Examples/basicdrawing/window.cpp:44: error: QtWidgets: No such file or directory
                          #include <QtWidgets>
                          ^@
                          on every single example i tested so far.
                          I fear i messed up some settings :(

                          1 Reply Last reply
                          0
                          • SGaistS Offline
                            SGaistS Offline
                            SGaist
                            Lifetime Qt Champion
                            wrote on last edited by
                            #15

                            Aren't you opening Qt 4's examples ?

                            Interested in AI ? www.idiap.ch
                            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                            1 Reply Last reply
                            0
                            • D Offline
                              D Offline
                              deleted28
                              wrote on last edited by
                              #16

                              in the QtCreator "Welcome" Tab - > Examples i can choose in the rightmost top corner between 4.8 and 5.2.
                              I selected qt5 example but i think the creator environment setting is wrong. In qt4 i think i used #include <QtGui>.

                              When i change #include <QtWidgets> to <QtGui> in a qt5 example i got no error message.

                              1 Reply Last reply
                              0
                              • A Offline
                                A Offline
                                andreyc
                                wrote on last edited by
                                #17

                                [quote author="wally123" date="1398324670"]
                                here the QT… part of “env” :

                                @QEMU_AUDIO_DRV=pa
                                QT_IM_MODULE=xim
                                QT_IM_SWITCHER=imsw-multi
                                QT_PLUGIN_PATH=/home/op/.kde4/lib/kde4/plugins/:/usr/lib/kde4/plugins/
                                QT_SYSTEM_DIR=/usr/share/desktop-data
                                SDL_AUDIODRIVER=pulse@
                                

                                What’s the relevant lines, what to compare ?
                                [/quote]

                                I don't exactly know what environment variables to compare. I hoped the difference would be obvious when you see it.

                                Try to change "Build Environment" to "Clean Environment" in "Run Environment" section of the Project settings.

                                1 Reply Last reply
                                0
                                • A Offline
                                  A Offline
                                  andreyc
                                  wrote on last edited by
                                  #18

                                  [quote author="wally123" date="1398330041"]maybe another hint to get behind what i setup wrong:

                                  When i open examples from Qt 5.2.1 i get :
                                  @.../Examples/basicdrawing/window.cpp:44: error: QtWidgets: No such file or directory
                                  #include <QtWidgets>
                                  ^@
                                  on every single example i tested so far.
                                  [/quote]

                                  I think SGaist is right and you open a Qt4 example.
                                  In Qt5 basicdrawing is located in
                                  @
                                  .../examples/widgets/painting/basicdrawing
                                  @

                                  1 Reply Last reply
                                  0
                                  • D Offline
                                    D Offline
                                    deleted28
                                    wrote on last edited by
                                    #19

                                    With "Clean environment" build is ok but run :
                                    @QXcbConnection: Could not connect to display @

                                    When i set to "System Environment" the recently built examples runs without error messages.
                                    No more libGL message.
                                    I'm confused

                                    I think i should delete all configuration files of QtCreator
                                    and restart creator to set all new.
                                    I s this possible ?
                                    Which files to delete ?

                                    1 Reply Last reply
                                    0
                                    • A Offline
                                      A Offline
                                      andreyc
                                      wrote on last edited by
                                      #20

                                      [quote author="wally123" date="1398369609"]With "Clean environment" build is ok but run :
                                      @QXcbConnection: Could not connect to display @
                                      [/quote]
                                      It is ok because there is no any X11 settings

                                      [quote author="wally123" date="1398369609"]
                                      When i set to "System Environment" the recently built examples runs without error messages.
                                      No more libGL message.
                                      [/quote]
                                      It confirms the fact that when you run the application from a terminal you don't have this message. So there is something wrong in Build Environment settings. You can compare the settings line by line if you would like.

                                      [quote author="wally123" date="1398369609"]
                                      I think i should delete all configuration files of QtCreator
                                      and restart creator to set all new.
                                      I s this possible ?
                                      Which files to delete ?
                                      [/quote]

                                      Build environment is a per project settings.
                                      I think that you can delete .pro.user file and then open this project again you will have a build environment that is consistent with a system environment.

                                      1 Reply Last reply
                                      0
                                      • D Offline
                                        D Offline
                                        deleted28
                                        wrote on last edited by
                                        #21

                                        Can not get rid of the libGL error, anyway.
                                        I removed qt4.8 kit and lib from Build&Run settings to make things more clear and focus to qt5 only.
                                        Tried several modifications in Build- and Run-environment.
                                        I have no idea what to search for and what causes the error message.
                                        i 'm totally confused now.
                                        Any idea what remains to do highly welcome.

                                        1 Reply Last reply
                                        0
                                        • D Offline
                                          D Offline
                                          deleted28
                                          wrote on last edited by
                                          #22

                                          creating a new qt5 project generates the following .pro file:
                                          @QT += core gui

                                          greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

                                          TARGET = test_1
                                          TEMPLATE = app

                                          SOURCES += main.cpp
                                          mainwindow.cpp

                                          HEADERS += mainwindow.h

                                          FORMS += mainwindow.ui
                                          @

                                          is this as should be ?
                                          Whats about "QT_MAJOR_VERSION, 4" ?

                                          1 Reply Last reply
                                          0

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved