Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem
Forum Updated to NodeBB v4.3 + New Features

QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
44 Posts 6 Posters 22.9k Views 4 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.
  • A Offline
    A Offline
    ad5xj
    wrote on last edited by
    #19

    While you may be correct about removing the CONFIG lines, It makes no difference in the current problem.

    The LIBS line you mention was removed from the .pro in an effort to find the problem posted. It too make no difference in finding the problem.

    Ken AD5XJ

    kshegunovK VRoninV 2 Replies Last reply
    0
    • A Offline
      A Offline
      ad5xj
      wrote on last edited by
      #20

      I forgot to mention that I inserted the <<< lines to indicate the errant part of the output.

      Ken AD5XJ

      1 Reply Last reply
      0
      • A ad5xj

        While you may be correct about removing the CONFIG lines, It makes no difference in the current problem.

        The LIBS line you mention was removed from the .pro in an effort to find the problem posted. It too make no difference in finding the problem.

        kshegunovK Offline
        kshegunovK Offline
        kshegunov
        Moderators
        wrote on last edited by kshegunov
        #21

        @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

        While you may be correct about removing the CONFIG lines, It makes no difference in the current problem.

        You should remove it nonetheless.

        @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

        The LIBS line you mention was removed from the .pro in an effort to find the problem posted. It too make no difference in finding the problem.

        If you remove the LIBS line there is no sane way you'd be getting the same error. There's something very fishy here.

        Could you also attach the generated Makefile.Debug? I don't see anything obviously wrong from the build log. Additionally, please check, if you have any files like .qmake.conf in your project directory?

        Read and abide by the Qt Code of Conduct

        1 Reply Last reply
        0
        • A ad5xj

          While you may be correct about removing the CONFIG lines, It makes no difference in the current problem.

          The LIBS line you mention was removed from the .pro in an effort to find the problem posted. It too make no difference in finding the problem.

          VRoninV Offline
          VRoninV Offline
          VRonin
          wrote on last edited by VRonin
          #22

          @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

          The LIBS line you mention was removed from the .pro in an effort to find the problem posted. It too make no difference in finding the problem.

          This is strange!
          How do you recompile the project? Are you sure you are re-running qmake? Qt Creator is very bad at detecting changes in the .pro file so if you just click on "Build" it won't "process" your pro file from scratch but use a cached version of it (I'm oversimplifying but it's not the point here)

          also notice that the .dll part should not be included in the LIBS line.Your original post showed it.

          "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
          ~Napoleon Bonaparte

          On a crusade to banish setIndexWidget() from the holy land of Qt

          1 Reply Last reply
          1
          • A Offline
            A Offline
            ad5xj
            wrote on last edited by
            #23

            I shall post the Makefile.Debug for you.

            I seems strange because it is out of the ordinary. I posted here because I have done all the normal troubleshooting. I cleaned the project. Removed the Makefile. removed the compile generated folders (.obj, .moc, .ui, etc) and started over.

            I have run the compile with and without the .dll. With and without the user LIBS line. It makes no difference.

            As mentioned before this is a running project on Linux Mint 18. This is a problem unique to Microsoft Windows 10 Qt 5.7.0 32-bit MinGW. All the suggestions so far would affect the RUNNING application - NOT the problem posted. While I appreciate the suggestions, I would like to stay on topic.

            BTW I have done a text search in the Makefiles for any reference to c:\utils and there is none. The only support or configure file I have found that does is the one mentioned before in the Qt install folder under mkspecs files. It is not something I can change with the QtCreator options.

            I am still trying to figure out how to attach a file in this forum since the new format. I don't see it. Maybe someone can help there.

            Ken AD5XJ

            kshegunovK 1 Reply Last reply
            1
            • A ad5xj

              I shall post the Makefile.Debug for you.

              I seems strange because it is out of the ordinary. I posted here because I have done all the normal troubleshooting. I cleaned the project. Removed the Makefile. removed the compile generated folders (.obj, .moc, .ui, etc) and started over.

              I have run the compile with and without the .dll. With and without the user LIBS line. It makes no difference.

              As mentioned before this is a running project on Linux Mint 18. This is a problem unique to Microsoft Windows 10 Qt 5.7.0 32-bit MinGW. All the suggestions so far would affect the RUNNING application - NOT the problem posted. While I appreciate the suggestions, I would like to stay on topic.

              BTW I have done a text search in the Makefiles for any reference to c:\utils and there is none. The only support or configure file I have found that does is the one mentioned before in the Qt install folder under mkspecs files. It is not something I can change with the QtCreator options.

              I am still trying to figure out how to attach a file in this forum since the new format. I don't see it. Maybe someone can help there.

              kshegunovK Offline
              kshegunovK Offline
              kshegunov
              Moderators
              wrote on last edited by kshegunov
              #24

              @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

              I shall post the Makefile.Debug for you.

              Use an external site and just post the link here. We don't have file/image uploads in the forum.

              This is a problem unique to Microsoft Windows 10 Qt 5.7.0 32-bit MinGW.

              Or to your mint development setup being too lenient or both.

              All the suggestions so far would affect the RUNNING application - NOT the problem posted.

              Nope, all the suggestions so far were definitely referring to the BUILD error you're getting.

              While I appreciate the suggestions, I would like to stay on topic.

              No one has strayed so far.

              Read and abide by the Qt Code of Conduct

              1 Reply Last reply
              0
              • A Offline
                A Offline
                ad5xj
                wrote on last edited by
                #25

                Well I have some progress albeit minor overall. I am able to compile all but the linker is not seeing the references to the .dll in the application. I will note that both QWT and FFTW3 folders are in the project path.

                Here is the current .pro:

                TARGET = ardoptnc
                TEMPLATE = app
                target.path = bin
                
                QT     += widgets multimedia serialport
                CONFIG += qt thread c++11 #silent
                
                MOC_DIR = .moc
                OBJECTS_DIR = .obj
                UI_DIR  = .ui
                
                INCLUDEPATH += \
                    $$FFTW3_INCL_PATH \
                    $$QWT_INCL_PATH
                
                INCLUDEPATH += \
                    .ui \
                    inc \
                    inc/fft \
                    inc/network \
                    inc/ui \
                    inc/utils \
                    inc/sound \
                    inc/widgets \
                    inc/protocol
                
                DEPENDPATH += \
                    $$FFTW_LIB_PATH \
                    $$QWT_LIB_PATH
                
                HEADERS += $${FFTW3_LIB_PATH}/fftw3.h
                
                HEADERS += \
                    inc/widgets/vumeterwidget.hpp \
                    inc/widgets/waterfallwidget.hpp
                
                HEADERS += inc/globals.hpp
                
                HEADERS += \
                    $${QWT_INCL_PATH}/qwt.h \
                    $${QWT_INCL_PATH}/qwt_plot_spectrogram.h \
                    $${QWT_INCL_PATH}/qwt_scale_map.h
                
                HEADERS += \
                    inc/network/sslparams.h \
                    inc/network/tcpipserver.hpp
                
                HEADERS +=  inc/sound/audioio.hpp
                
                HEADERS += inc/utils/utils.hpp
                
                HEADERS += inc/fft/fftcalc.hpp
                
                HEADERS += \
                    inc/tncsetup.hpp \
                    inc/radiosetup.hpp \
                    inc/tncpanel.hpp
                
                SOURCES += \
                    network/sslparams.cpp \
                    network/tcpipserver.cpp
                
                SOURCES += sound/audioio.cpp
                
                SOURCES += fft/fftcalc.cpp
                
                SOURCES += utils/utils.cpp
                
                SOURCES += \
                    widgets/vumeterwidget.cpp \
                    widgets/waterfallwidget.cpp
                
                SOURCES += \
                    tncsetup.cpp \
                    radiosetup.cpp \
                    tncpanel.cpp \
                    main.cpp
                
                FORMS   += \
                    ui/tncsetup.ui \
                    ui/radiosetup.ui \
                    ui/tncpanel.ui
                
                LIBS += -L$${QWT_LIB_PATH}/ -lqwt
                LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll
                LIBS += -L$${FFTW3_LIB_PATH}/libfftw3l-3.dll
                LIBS += -L$${FFTW3_LIB_PATH}/libfftw3f-3.dll
                
                

                I get this error when linking (abbr for clarity):

                ./.obj\fftcalc.o: In function `ZN7fftCalcD2Ev':
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:15: undefined reference to `_imp__fftw_destroy_plan'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:16: undefined reference to `_imp__fftw_free'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:17: undefined reference to `_imp__fftw_free'
                ./.obj\fftcalc.o: In function `ZN7fftCalc5doFFTEv':
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:49: undefined reference to `_imp__fftw_execute'
                ./.obj\fftcalc.o: In function `ZN7fftCalc4initEiii':
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:64: undefined reference to `_imp__fftw_destroy_plan'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:65: undefined reference to `_imp__fftw_free'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:66: undefined reference to `_imp__fftw_free'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:67: undefined reference to `_imp__fftw_malloc'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:68: undefined reference to `_imp__fftw_malloc'
                C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:71: undefined reference to `_imp__fftw_plan_r2r_1d'
                collect2.exe: error: ld returned 1 exit status
                

                The lines referred to are just library calls to FFTW. The fftw3.h is specified in the includes. The LIBS does have the correct path and it is in the project path - yet the undefined referreces. Something is not right at all.

                Ken AD5XJ

                kshegunovK JKSHJ 2 Replies Last reply
                0
                • A ad5xj

                  Well I have some progress albeit minor overall. I am able to compile all but the linker is not seeing the references to the .dll in the application. I will note that both QWT and FFTW3 folders are in the project path.

                  Here is the current .pro:

                  TARGET = ardoptnc
                  TEMPLATE = app
                  target.path = bin
                  
                  QT     += widgets multimedia serialport
                  CONFIG += qt thread c++11 #silent
                  
                  MOC_DIR = .moc
                  OBJECTS_DIR = .obj
                  UI_DIR  = .ui
                  
                  INCLUDEPATH += \
                      $$FFTW3_INCL_PATH \
                      $$QWT_INCL_PATH
                  
                  INCLUDEPATH += \
                      .ui \
                      inc \
                      inc/fft \
                      inc/network \
                      inc/ui \
                      inc/utils \
                      inc/sound \
                      inc/widgets \
                      inc/protocol
                  
                  DEPENDPATH += \
                      $$FFTW_LIB_PATH \
                      $$QWT_LIB_PATH
                  
                  HEADERS += $${FFTW3_LIB_PATH}/fftw3.h
                  
                  HEADERS += \
                      inc/widgets/vumeterwidget.hpp \
                      inc/widgets/waterfallwidget.hpp
                  
                  HEADERS += inc/globals.hpp
                  
                  HEADERS += \
                      $${QWT_INCL_PATH}/qwt.h \
                      $${QWT_INCL_PATH}/qwt_plot_spectrogram.h \
                      $${QWT_INCL_PATH}/qwt_scale_map.h
                  
                  HEADERS += \
                      inc/network/sslparams.h \
                      inc/network/tcpipserver.hpp
                  
                  HEADERS +=  inc/sound/audioio.hpp
                  
                  HEADERS += inc/utils/utils.hpp
                  
                  HEADERS += inc/fft/fftcalc.hpp
                  
                  HEADERS += \
                      inc/tncsetup.hpp \
                      inc/radiosetup.hpp \
                      inc/tncpanel.hpp
                  
                  SOURCES += \
                      network/sslparams.cpp \
                      network/tcpipserver.cpp
                  
                  SOURCES += sound/audioio.cpp
                  
                  SOURCES += fft/fftcalc.cpp
                  
                  SOURCES += utils/utils.cpp
                  
                  SOURCES += \
                      widgets/vumeterwidget.cpp \
                      widgets/waterfallwidget.cpp
                  
                  SOURCES += \
                      tncsetup.cpp \
                      radiosetup.cpp \
                      tncpanel.cpp \
                      main.cpp
                  
                  FORMS   += \
                      ui/tncsetup.ui \
                      ui/radiosetup.ui \
                      ui/tncpanel.ui
                  
                  LIBS += -L$${QWT_LIB_PATH}/ -lqwt
                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll
                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3l-3.dll
                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3f-3.dll
                  
                  

                  I get this error when linking (abbr for clarity):

                  ./.obj\fftcalc.o: In function `ZN7fftCalcD2Ev':
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:15: undefined reference to `_imp__fftw_destroy_plan'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:16: undefined reference to `_imp__fftw_free'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:17: undefined reference to `_imp__fftw_free'
                  ./.obj\fftcalc.o: In function `ZN7fftCalc5doFFTEv':
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:49: undefined reference to `_imp__fftw_execute'
                  ./.obj\fftcalc.o: In function `ZN7fftCalc4initEiii':
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:64: undefined reference to `_imp__fftw_destroy_plan'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:65: undefined reference to `_imp__fftw_free'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:66: undefined reference to `_imp__fftw_free'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:67: undefined reference to `_imp__fftw_malloc'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:68: undefined reference to `_imp__fftw_malloc'
                  C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:71: undefined reference to `_imp__fftw_plan_r2r_1d'
                  collect2.exe: error: ld returned 1 exit status
                  

                  The lines referred to are just library calls to FFTW. The fftw3.h is specified in the includes. The LIBS does have the correct path and it is in the project path - yet the undefined referreces. Something is not right at all.

                  kshegunovK Offline
                  kshegunovK Offline
                  kshegunov
                  Moderators
                  wrote on last edited by
                  #26

                  @ad5xj
                  Your linkage is incorrect, thus the fftw isn't linked, thus you get the errors.

                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll
                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3l-3.dll
                  LIBS += -L$${FFTW3_LIB_PATH}/libfftw3f-3.dll
                  

                  should be:

                  LIBS += -L$${FFTW3_LIB_PATH} -lfftw3-3 -lfftw3l-3 -lfftw3f-3
                  

                  And you should have the appropriate .lib (or .a if you're using mingw) files in $${FFTW3_LIB_PATH}.

                  Read and abide by the Qt Code of Conduct

                  1 Reply Last reply
                  3
                  • A ad5xj

                    Well I have some progress albeit minor overall. I am able to compile all but the linker is not seeing the references to the .dll in the application. I will note that both QWT and FFTW3 folders are in the project path.

                    Here is the current .pro:

                    TARGET = ardoptnc
                    TEMPLATE = app
                    target.path = bin
                    
                    QT     += widgets multimedia serialport
                    CONFIG += qt thread c++11 #silent
                    
                    MOC_DIR = .moc
                    OBJECTS_DIR = .obj
                    UI_DIR  = .ui
                    
                    INCLUDEPATH += \
                        $$FFTW3_INCL_PATH \
                        $$QWT_INCL_PATH
                    
                    INCLUDEPATH += \
                        .ui \
                        inc \
                        inc/fft \
                        inc/network \
                        inc/ui \
                        inc/utils \
                        inc/sound \
                        inc/widgets \
                        inc/protocol
                    
                    DEPENDPATH += \
                        $$FFTW_LIB_PATH \
                        $$QWT_LIB_PATH
                    
                    HEADERS += $${FFTW3_LIB_PATH}/fftw3.h
                    
                    HEADERS += \
                        inc/widgets/vumeterwidget.hpp \
                        inc/widgets/waterfallwidget.hpp
                    
                    HEADERS += inc/globals.hpp
                    
                    HEADERS += \
                        $${QWT_INCL_PATH}/qwt.h \
                        $${QWT_INCL_PATH}/qwt_plot_spectrogram.h \
                        $${QWT_INCL_PATH}/qwt_scale_map.h
                    
                    HEADERS += \
                        inc/network/sslparams.h \
                        inc/network/tcpipserver.hpp
                    
                    HEADERS +=  inc/sound/audioio.hpp
                    
                    HEADERS += inc/utils/utils.hpp
                    
                    HEADERS += inc/fft/fftcalc.hpp
                    
                    HEADERS += \
                        inc/tncsetup.hpp \
                        inc/radiosetup.hpp \
                        inc/tncpanel.hpp
                    
                    SOURCES += \
                        network/sslparams.cpp \
                        network/tcpipserver.cpp
                    
                    SOURCES += sound/audioio.cpp
                    
                    SOURCES += fft/fftcalc.cpp
                    
                    SOURCES += utils/utils.cpp
                    
                    SOURCES += \
                        widgets/vumeterwidget.cpp \
                        widgets/waterfallwidget.cpp
                    
                    SOURCES += \
                        tncsetup.cpp \
                        radiosetup.cpp \
                        tncpanel.cpp \
                        main.cpp
                    
                    FORMS   += \
                        ui/tncsetup.ui \
                        ui/radiosetup.ui \
                        ui/tncpanel.ui
                    
                    LIBS += -L$${QWT_LIB_PATH}/ -lqwt
                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll
                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3l-3.dll
                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3f-3.dll
                    
                    

                    I get this error when linking (abbr for clarity):

                    ./.obj\fftcalc.o: In function `ZN7fftCalcD2Ev':
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:15: undefined reference to `_imp__fftw_destroy_plan'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:16: undefined reference to `_imp__fftw_free'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:17: undefined reference to `_imp__fftw_free'
                    ./.obj\fftcalc.o: In function `ZN7fftCalc5doFFTEv':
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:49: undefined reference to `_imp__fftw_execute'
                    ./.obj\fftcalc.o: In function `ZN7fftCalc4initEiii':
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:64: undefined reference to `_imp__fftw_destroy_plan'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:65: undefined reference to `_imp__fftw_free'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:66: undefined reference to `_imp__fftw_free'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:67: undefined reference to `_imp__fftw_malloc'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:68: undefined reference to `_imp__fftw_malloc'
                    C:\Projects\C++\ardoptnc/fft/fftcalc.cpp:71: undefined reference to `_imp__fftw_plan_r2r_1d'
                    collect2.exe: error: ld returned 1 exit status
                    

                    The lines referred to are just library calls to FFTW. The fftw3.h is specified in the includes. The LIBS does have the correct path and it is in the project path - yet the undefined referreces. Something is not right at all.

                    JKSHJ Offline
                    JKSHJ Offline
                    JKSH
                    Moderators
                    wrote on last edited by JKSH
                    #27

                    @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                    I get this error when linking (abbr for clarity)

                    Do you only get errors for FFTW, or Qwt as well?

                    LIBS += -L$${FFTW3_LIB_PATH} -lfftw3-3.dll
                    

                    That's supposed to be -lfftw3-3 (no ".dll")

                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll
                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3l-3.dll
                    LIBS += -L$${FFTW3_LIB_PATH}/libfftw3f-3.dll
                    

                    FFTW3_LIB_PATH == "C:/FFTW3/", right? That means your lines expand to things like LIBS += -LC:/FFTW//libfftw3-3.dll (2 slashes).

                    Let's do a sanity check: Replace all the variables in your *.pro file with hard-coded paths, e.g. LIBS += -L"C:/FFTW3/" -lfftw3-3 -lfftw3l-3 -lfftw3f-3 and see what happens.

                    [EDIT: @kshegunov beat me to it!]

                    HEADERS += $${FFTW3_LIB_PATH}/fftw3.h
                    
                    ...
                    
                    HEADERS += \
                        $${QWT_INCL_PATH}/qwt.h \
                        $${QWT_INCL_PATH}/qwt_plot_spectrogram.h \
                        $${QWT_INCL_PATH}/qwt_scale_map.h
                    

                    Do not add 3rd-party library headers to HEADER. Instead, add their folders to INCLUDEPATH.

                    By adding the files to HEADER, you are asking the toolchain to compile the headers into your binaries. This causes errors if the headers contain any definitions that have already been built into the 3rd party DLL. This also causes Qt's code generator (moc) to generate a new copy of the QObjects that are found in the headers, which breaks the signal-slot mechanism (among other things) for the library.

                    LIBS += -L$${QWT_LIB_PATH}/ -lqwt
                    

                    This is not strictly necessary, but the cleanest way to use Qwt in your project is to write include(C:/QWT/Qwt-6.1.3/features/qwt.prf) in your *.pro file. You can then get rid of all the other Qwt-related lines.

                    Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                    1 Reply Last reply
                    2
                    • A Offline
                      A Offline
                      ad5xj
                      wrote on last edited by
                      #28

                      Thanks for the QWT tip I will try that.

                      As to the fftw3 dlls ... I did have it the way you describe and the linker complains. With some experimentation, I did find the current syntax to work. It may not be as expected but it works. Go figure.

                      I have had little nor no problem with QWT. No error messages about the QWT .dlls at all.

                      Ken AD5XJ

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

                        What exact error do you still have with Qwt ?

                        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
                        • A ad5xj

                          Thanks for the QWT tip I will try that.

                          As to the fftw3 dlls ... I did have it the way you describe and the linker complains. With some experimentation, I did find the current syntax to work. It may not be as expected but it works. Go figure.

                          I have had little nor no problem with QWT. No error messages about the QWT .dlls at all.

                          JKSHJ Offline
                          JKSHJ Offline
                          JKSH
                          Moderators
                          wrote on last edited by
                          #30

                          @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                          With some experimentation, I did find the current syntax to work. It may not be as expected but it works. Go figure.

                          When you say "it works", do you mean everything builds and links correctly? Or that the linker doesn't complain about missing libraries? There's a difference.

                          A typo in -l gets reported directly by your toolchain. Example:

                          LIBS += -L"C:/FFTW3/" -lfftw4-4
                          
                          ...
                          
                          ld.exe: cannot find -lfftw4-4
                          

                          In contrast, a typo in -L does not get detected or reported directly. Instead, you just get the generic "undefined reference" errors.

                          Anyway, note also that:

                          • -L is for specifying a folder that the linker should search

                            • -LC:/FFTW3/libfftw3-3.dll makes your toolchain look inside a folder called "C:/FFTW3/libfftw3-3.dll/"... which probably doesn't exist (but the toolchain doesn't tell you that)
                          • -l is for specifying a filename root

                            • -lFoo makes your toolchain link against a file called libFoo.dll (inside the folders specified by -L)

                          As to the fftw3 dlls ... I did have it the way you describe and the linker complains.

                          Please try again, especially with hard-coded paths. Then, post your unmodified .pro file and error messages.

                          Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                          1 Reply Last reply
                          0
                          • A Offline
                            A Offline
                            ad5xj
                            wrote on last edited by
                            #31

                            Sorry for being ambiguous. I mean to say the linker finds the libraries and tries to link. Whereas before it could not find the libraries -lfftw3-3.dll or -lfftw3.

                            I understand your explanation to be the expected. I am only reporting the actual results of repeated attempts with failure before hitting on what works even if it is not what "should" be correct.

                            BTW SGiast I do not now, nor ever have had a problem with QWT libraries during the compile and link process. Sorry if I was not clear before.

                            Ken AD5XJ

                            JKSHJ 1 Reply Last reply
                            1
                            • A ad5xj

                              Sorry for being ambiguous. I mean to say the linker finds the libraries and tries to link. Whereas before it could not find the libraries -lfftw3-3.dll or -lfftw3.

                              I understand your explanation to be the expected. I am only reporting the actual results of repeated attempts with failure before hitting on what works even if it is not what "should" be correct.

                              BTW SGiast I do not now, nor ever have had a problem with QWT libraries during the compile and link process. Sorry if I was not clear before.

                              JKSHJ Offline
                              JKSHJ Offline
                              JKSH
                              Moderators
                              wrote on last edited by
                              #32

                              @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                              Sorry for being ambiguous. I mean to say the linker finds the libraries and tries to link.

                              No worries. So, does that mean all problems are gone now?

                              Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                              1 Reply Last reply
                              1
                              • A Offline
                                A Offline
                                ad5xj
                                wrote on last edited by
                                #33

                                Well I do not know how to answer you JKSH.

                                It seems the LIBS statement is not interpreting the path and .dll name correctly for FFTW3 dll's. As you pointed out earlier, if the correct syntax is used, the linker does not find the libraries. When specified as -L<path>/<libname.dll> the linker seems to find the libraries and tries to link with them. Not sure if that is a bug in the Windows 32 bit version of qmake or something else. It needs to work as advertised but doesn't.

                                I also notice that if a substitution like $$FFTW3_LIB_PATH is used but not defined, the qmake hangs indefinitely without giving a message. Something new I just discovered.

                                I will also say that in desperation, I have uninstalled Qt, cleaned the registry and file system, and reinstalled Qt with no change in the problem.

                                At this point I believe the LIBS problem is a bug and possibly the substitution problem as well.

                                Ken AD5XJ

                                JKSHJ kshegunovK 2 Replies Last reply
                                0
                                • A ad5xj

                                  Well I do not know how to answer you JKSH.

                                  It seems the LIBS statement is not interpreting the path and .dll name correctly for FFTW3 dll's. As you pointed out earlier, if the correct syntax is used, the linker does not find the libraries. When specified as -L<path>/<libname.dll> the linker seems to find the libraries and tries to link with them. Not sure if that is a bug in the Windows 32 bit version of qmake or something else. It needs to work as advertised but doesn't.

                                  I also notice that if a substitution like $$FFTW3_LIB_PATH is used but not defined, the qmake hangs indefinitely without giving a message. Something new I just discovered.

                                  I will also say that in desperation, I have uninstalled Qt, cleaned the registry and file system, and reinstalled Qt with no change in the problem.

                                  At this point I believe the LIBS problem is a bug and possibly the substitution problem as well.

                                  JKSHJ Offline
                                  JKSHJ Offline
                                  JKSH
                                  Moderators
                                  wrote on last edited by
                                  #34

                                  @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                                  When specified as -L<path>/<libname.dll> the linker seems to find the libraries and tries to link with them.

                                  How do you know that the linker found the libraries? What messages do you get?

                                  If you see "Undefined references", that means your linker couldn't find the libraries.

                                  I also notice that if a substitution like $$FFTW3_LIB_PATH is used but not defined, the qmake hangs indefinitely without giving a message. Something new I just discovered.

                                  Hmm... sounds like a bug, but I wouldn't worry about it for now.

                                  At this point I believe the LIBS problem is a bug and possibly the substitution problem as well.

                                  That's why I asked you to get rid of substitution and use hard-coded paths like LIBS += -LC:/FFTW3 -lfftw3-3

                                  You can also try LIBS += C:/FFTW3/libfftw3-3.dll (don't write "-L")

                                  Well I do not know how to answer you JKSH.

                                  The answer is, "No, the problems are not yet gone" ;)

                                  We'll get there eventually, I'm sure.

                                  Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                                  1 Reply Last reply
                                  1
                                  • A ad5xj

                                    Well I do not know how to answer you JKSH.

                                    It seems the LIBS statement is not interpreting the path and .dll name correctly for FFTW3 dll's. As you pointed out earlier, if the correct syntax is used, the linker does not find the libraries. When specified as -L<path>/<libname.dll> the linker seems to find the libraries and tries to link with them. Not sure if that is a bug in the Windows 32 bit version of qmake or something else. It needs to work as advertised but doesn't.

                                    I also notice that if a substitution like $$FFTW3_LIB_PATH is used but not defined, the qmake hangs indefinitely without giving a message. Something new I just discovered.

                                    I will also say that in desperation, I have uninstalled Qt, cleaned the registry and file system, and reinstalled Qt with no change in the problem.

                                    At this point I believe the LIBS problem is a bug and possibly the substitution problem as well.

                                    kshegunovK Offline
                                    kshegunovK Offline
                                    kshegunov
                                    Moderators
                                    wrote on last edited by
                                    #35

                                    @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                                    It seems the LIBS statement is not interpreting the path and .dll name correctly for FFTW3 dll's.

                                    What statement are you using? One doesn't link to .dll files, and one doesn't need a path to a .dll file for linkage.

                                    When specified as -L<path>/<libname.dll> the linker seems to find the libraries and tries to link with them.

                                    That most certainly isn't true. -L is for specifying only additional link directories.

                                    It needs to work as advertised but doesn't.

                                    How is it advertised?

                                    Read and abide by the Qt Code of Conduct

                                    1 Reply Last reply
                                    0
                                    • A Offline
                                      A Offline
                                      ad5xj
                                      wrote on last edited by
                                      #36

                                      JKSH

                                      I created a much smaller sub-project with only one form (mainwindow) and tested to see what would happen with the two different LIBS statements.

                                      When stated: LIBS += -L$${FFTW3_LIB_PATH}/ -llibfftw3-3.dll

                                      The linker does not find the dll.

                                      When stated: LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll

                                      The linker finds the dll and successfully links the exe. It does run as expected.

                                      However, in the larger project, this approach does not work - it does have the undefined reference error messages for the FFTW3 functions with the latter form of the LIBS statement and does not find the dlls (link output - file not found) with the former.

                                      kshegunov

                                      Your message seems contradictory to the thread messages so far. I have tried to eliminate the LIBS statement referencing the dlls but that does not even work at all.

                                      Ken AD5XJ

                                      kshegunovK JKSHJ 2 Replies Last reply
                                      0
                                      • A ad5xj

                                        JKSH

                                        I created a much smaller sub-project with only one form (mainwindow) and tested to see what would happen with the two different LIBS statements.

                                        When stated: LIBS += -L$${FFTW3_LIB_PATH}/ -llibfftw3-3.dll

                                        The linker does not find the dll.

                                        When stated: LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll

                                        The linker finds the dll and successfully links the exe. It does run as expected.

                                        However, in the larger project, this approach does not work - it does have the undefined reference error messages for the FFTW3 functions with the latter form of the LIBS statement and does not find the dlls (link output - file not found) with the former.

                                        kshegunov

                                        Your message seems contradictory to the thread messages so far. I have tried to eliminate the LIBS statement referencing the dlls but that does not even work at all.

                                        kshegunovK Offline
                                        kshegunovK Offline
                                        kshegunov
                                        Moderators
                                        wrote on last edited by kshegunov
                                        #37

                                        Contradictory? Redundant is more like it. Let me quote a couple:

                                        @VRonin said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                                        also you never set the LIBS variable

                                        LIBS += -L$${QWT_LIB_PATH} -L$${QWT_LIB_PATH} -lfftw3-3 -lqwt
                                        

                                        @kshegunov said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                                        should be:

                                        LIBS += -L$${FFTW3_LIB_PATH} -lfftw3-3 -lfftw3l-3 -lfftw3f-3
                                        

                                        And then I added:

                                        And you should have the appropriate .lib (or .a if you're using mingw) files in $${FFTW3_LIB_PATH}.

                                        Here's the qmake variable reference, as you can see yourself there's no guesswork involved in all this.

                                        Read and abide by the Qt Code of Conduct

                                        1 Reply Last reply
                                        0
                                        • A ad5xj

                                          JKSH

                                          I created a much smaller sub-project with only one form (mainwindow) and tested to see what would happen with the two different LIBS statements.

                                          When stated: LIBS += -L$${FFTW3_LIB_PATH}/ -llibfftw3-3.dll

                                          The linker does not find the dll.

                                          When stated: LIBS += -L$${FFTW3_LIB_PATH}/libfftw3-3.dll

                                          The linker finds the dll and successfully links the exe. It does run as expected.

                                          However, in the larger project, this approach does not work - it does have the undefined reference error messages for the FFTW3 functions with the latter form of the LIBS statement and does not find the dlls (link output - file not found) with the former.

                                          kshegunov

                                          Your message seems contradictory to the thread messages so far. I have tried to eliminate the LIBS statement referencing the dlls but that does not even work at all.

                                          JKSHJ Offline
                                          JKSHJ Offline
                                          JKSH
                                          Moderators
                                          wrote on last edited by
                                          #38

                                          @ad5xj said in QtCreator 4.1.0 Qt 5.7.0 Windows 10 MinGW problem:

                                          However, in the larger project, this approach does not work

                                          Did you set $${FFTW3_LIB_PATH} to different values in the 2 different projects?

                                          C:/FFTW3/ is not equal to C:/FFTW3

                                          When stated: LIBS += -L$${FFTW3_LIB_PATH}/ -llibfftw3-3.dll

                                          The linker does not find the dll.

                                          That should be -lfftw3-3, not -llibfftw3-3.dll

                                          Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                                          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