]> git.lyx.org Git - lyx.git/commit
Check path of Qt tools if qtchooser is detected
authorEnrico Forestieri <forenr@lyx.org>
Sun, 17 Jul 2016 10:31:24 +0000 (12:31 +0200)
committerEnrico Forestieri <forenr@lyx.org>
Sun, 17 Jul 2016 10:31:24 +0000 (12:31 +0200)
commit0c7bd9a57f2a308bb9659200eda3b7e45f8d5d3c
tree4f1f7cd250e6db2ab7625d8a69d0615f1f8dbde0
parentc4a6d8d568f58132814fd11fc70e44277e318b11
Check path of Qt tools if qtchooser is detected

The full path of the tools is retained only if the Qt directory is
specified using --with-qt-dir. Now, when qtchooser was detected it
was blindly assumed that the corresponding system tools were being
used. These tools discriminate between Qt4 and Qt5 through the
option -qt=qt4 or -qt=qt5. However, the original Qt tools don't
understand these options, so that if they come first in the PATH,
configuration fails. So, only use those options if we are reasonably
sure that the system Qt is wanted. This is achieved by comparing the
paths of qtchooser and tools as, typically, they are located in the
same directory. In this way, if one prepends the bin directory of a
custom Qt build to PATH (and accordingly adjusts PKG_CONFIG_PATH),
configuration succeeds even if --with-qt-dir is not specified.
config/qt4.m4