Skip to content

Commit

Permalink
Fix pathes for FreeBSD
Browse files Browse the repository at this point in the history
  • Loading branch information
lbartoletti authored and 3nids committed Jan 29, 2018
1 parent e0c12d5 commit 8d4d08f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
4 changes: 4 additions & 0 deletions cmake/FindPyQt5.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,12 @@
import PyQt5.QtCore
import sipconfig # won't work for SIP v5
import os.path
import sys
cfg = sipconfig.Configuration()
sip_dir = cfg.default_sip_dir
if sys.platform.startswith('freebsd'):
py_version = str(sys.version_info.major) + str(sys.version_info.minor)
sip_dir = sip_dir.replace(py_version, '')
for p in (os.path.join(sip_dir, "PyQt5"), sip_dir):
if os.path.exists(os.path.join(p, "QtCore", "QtCoremod.sip")):
sip_dir = p
Expand Down
1 change: 1 addition & 0 deletions cmake/FindQScintilla.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ ELSE(EXISTS QSCINTILLA_VERSION_STR)
PATHS
"${QT_LIBRARY_DIR}"
/usr/local/lib
/usr/local/lib/qt5
/usr/lib
)

Expand Down
4 changes: 3 additions & 1 deletion cmake/FindQwt.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,14 @@
#


set(QWT_LIBRARY_NAMES qwt-qt5 qwt6-qt5 qwt)
set(QWT_LIBRARY_NAMES qwt-qt5 qwt6-qt5 qwt qwt6)

find_library(QWT_LIBRARY
NAMES ${QWT_LIBRARY_NAMES}
PATHS
/usr/lib
/usr/local/lib
/usr/local/lib/qt5
"$ENV{LIB_DIR}/lib"
"$ENV{LIB}"
)
Expand All @@ -32,6 +33,7 @@ FIND_PATH(QWT_INCLUDE_DIR NAMES qwt.h PATHS
"${_qwt_fw}/Headers"
/usr/include
/usr/local/include
/usr/local/include/qt5
"$ENV{LIB_DIR}/include"
"$ENV{INCLUDE}"
PATH_SUFFIXES qwt-qt5 qwt qwt6
Expand Down

0 comments on commit 8d4d08f

Please sign in to comment.