diff options
Diffstat (limited to 'graphics/lprof-devel')
| -rw-r--r-- | graphics/lprof-devel/Makefile | 5 | ||||
| -rw-r--r-- | graphics/lprof-devel/files/patch-src-lprofqt-config.cpp | 11 | ||||
| -rw-r--r-- | graphics/lprof-devel/files/patch-src_lprofqt_config.cpp | 20 |
3 files changed, 23 insertions, 13 deletions
diff --git a/graphics/lprof-devel/Makefile b/graphics/lprof-devel/Makefile index 0941d0f7971d..b977def6a534 100644 --- a/graphics/lprof-devel/Makefile +++ b/graphics/lprof-devel/Makefile @@ -21,8 +21,6 @@ USE_XORG= x11 xext sm ice xxf86vm USE_QT4= corelib gui qt3support svg assistantclient \ linguisttools_build qmake_build moc_build uic_build rcc_build -CMAKE_ARGS= -DQTTRANS_LRELEASE_EXECUTABLE="${LOCALBASE}/bin/lrelease-qt4" - WRKSRC= ${WRKDIR}/${PORTNAME} PORTDOCS= * @@ -34,6 +32,9 @@ post-patch: @${REINPLACE_CMD} -e '/asm\/types.h/ d' ${WRKSRC}/src/argyll/spectro/hidio.c @${REINPLACE_CMD} -e '/DESTINATION/ s|data/|share/${PORTNAME}/data/|' \ ${WRKSRC}/data/CMakeLists.txt ${WRKSRC}/src/CMakeLists.txt +# Patch in the correct prefix of the Qt binaries into the sources. + @${REINPLACE_CMD} -e 's|%%QT_ARCHDIR%%|${QT_ARCHDIR}|g' \ + ${WRKSRC}/src/lprofqt/config.cpp post-install: ${INSTALL_DATA} ${WRKSRC}/data/icons/lprof.png ${STAGEDIR}${PREFIX}/share/pixmaps diff --git a/graphics/lprof-devel/files/patch-src-lprofqt-config.cpp b/graphics/lprof-devel/files/patch-src-lprofqt-config.cpp deleted file mode 100644 index 211328c71e0a..000000000000 --- a/graphics/lprof-devel/files/patch-src-lprofqt-config.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- ./src/lprofqt/config.cpp.orig 2008-03-09 01:31:11.000000000 +0300 -+++ ./src/lprofqt/config.cpp 2013-09-14 04:36:26.160226093 +0400 -@@ -206,7 +206,7 @@ - const QString assist = QString::fromLocal8Bit("assistant.app/Contents/MacOS/assistant"); - # else - QChar pathSep = QChar::fromLatin1(':'); -- const QString assist = QString::fromLocal8Bit("assistant"); -+ const QString assist = QString::fromLocal8Bit("assistant-qt4"); - # endif /* __WIN32__ */ - - QString Path = QString::fromLocal8Bit(getenv("PATH")); diff --git a/graphics/lprof-devel/files/patch-src_lprofqt_config.cpp b/graphics/lprof-devel/files/patch-src_lprofqt_config.cpp new file mode 100644 index 000000000000..7142449caa50 --- /dev/null +++ b/graphics/lprof-devel/files/patch-src_lprofqt_config.cpp @@ -0,0 +1,20 @@ +The function get_QTDIR reads the environment variable 'QTDIR'. Which is not set +most of the time. So define a sensible fallback value, and return that one in +this case. + +This should help the program find the assistant binary, without going over +qtchooser (and requiring to set QT_SELECT). + +--- src/lprofqt/config.cpp.orig 2017-02-04 19:46:56 UTC ++++ src/lprofqt/config.cpp +@@ -72,7 +72,9 @@ QString get_QTDIR() + { + // qDebug(QString::fromLocal8Bit("get_home_dir")); + const char* qtdir= "QTDIR"; +- return QString::fromLocal8Bit(getenv(qtdir)); ++ const QString fallback = "%%QT_ARCHDIR%%"; ++ QString env_qtdir = QString::fromLocal8Bit(getenv(qtdir)); ++ return (env_qtdir.isEmpty() ? fallback : env_qtdir); + } + + void init_env() |
