Menu

#293 make error <QtCORE> not found

None
open
nobody
None
None
2024-03-18
2024-03-15
Anonymous
No

I'm trying to install gnuplot-5-4.10 on a macbook air with MAC OS Catalina. I get the following error:

eriknelson@Eriks-MacBook-Air gnuplot-5.4.10 % make
.
.
.
qtterminal/qt_term.cpp:51:10: fatal error: 'QtCore' file not found

include <qtcore></qtcore>

     ^~~~~~~~

1 error generated.
make[4]: *** [qtterminal/qt_term.o] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
eriknelson@Eriks-MacBook-Air gnuplot-5.4.10 %

I have both hombrew and XQuartz installed. I'm not sure what to do about this. I've also tried installing the binary for MacOS Catalina, but my computer won't let me open the package saying that it can't verify that the package does not contain malware.

Any suggestions?

Discussion

  • Ethan Merritt

    Ethan Merritt - 2024-03-15

    That appears to indicate that the Qt support packages are not installed.
    The text below is taken from gnuplot's INSTALL file for version 6, but may well be useful also for building version 5:

    macOS + homebrew
    ----------------
    
      As of the time of writing (Feb 2023) homebrew provides a bottled gnuplot
      with Qt support.  However it was not built with all the optional features
      or terminals that you might want.  This is a quick summary of what is
      needed to configure and build from source.
    
      If you have gnuplot installed from homebrew you can do
            brew info gnuplot
      to see that it has already installed these dependencies:
            Build: pkg-config 
            Required: gd , libcerf , lua , pango , qt@5 , readline 
      Otherwise you must install these first.  Depending on what you intend to
      add to the configuration you may have to install other dependencies also.
    
      Gnuplot's default ./configure and make will automatically compile gnuplot
      support for the x11 terminal and for the qt terminal if it finds the Qt
      libraries.  However, it seems that the Qt installed by homebrew is not
      found automatically.   If you say, for example,  ./configure --with-qt
      you get a problem like "fatal error: 'QtCore' file not found".
      To solve this you can add the homebrew installation path to the environment
      prior to running ./configure so that it knows where to look:
    
            $ CXXFLAGS=' -std=c++11 ' \
              PKG_CONFIG_PATH='/opt/homebrew/opt/qt5/lib/pkgconfig' \
              configure --with-qt
    
      If for some reason your qt5/lib/pkgconfig is installed somewhere else,
      change that command accordingly.
    
      Look carefully at the summary of terminal support printed out by the
      configure command.  If all looks well, continue with
    
            $ make
            $ make check
            $ sudo make install
    
     
  • Ethan Merritt

    Ethan Merritt - 2024-03-18

    Ticket moved from /p/gnuplot/bugs/2698/

    Can't be converted:

    • _milestone:
    • _priority:
     

Log in to post a comment.