Wouldn't it make more sense to use separate subpackages for Qt5 and Qt6?
On 2022/10/14 08:47, Rafael Sadowski wrote:
> On Mon Oct 10, 2022 at 02:14:39PM +0800, Kevin Lo wrote:
> > Hi Yifei,
> >
> > The diff belows enable Qt6 support in fcitx-qt.
> > With this diff, I can type Chinese on net/tdesktop.
> >
> > OK?
>
> Looks good, x11/qt5 comes from devel/kf5. First port where we mix Qt5
> and Qt6 libs.
>
> ok rsadowski
> >
> > Index: inputmethods/fcitx-qt/Makefile
> > ===================================================================
> > RCS file: /cvs/ports/inputmethods/fcitx-qt/Makefile,v
> > retrieving revision 1.2
> > diff -u -p -u -p -r1.2 Makefile
> > --- inputmethods/fcitx-qt/Makefile 13 May 2022 18:59:19 -0000 1.2
> > +++ inputmethods/fcitx-qt/Makefile 10 Oct 2022 06:06:10 -0000
> > @@ -2,10 +2,11 @@ COMMENT = Qt library and IM module for f
> >
> > DISTNAME = fcitx5-qt-5.0.9
> > PKGNAME = ${DISTNAME:S/fcitx5/fcitx/}
> > -REVISION = 0
> > +REVISION = 1
> >
> > SHARED_LIBS += Fcitx5Qt5WidgetsAddons 0.0 # 0.0
> > SHARED_LIBS += Fcitx5Qt5DBusAddons 0.0 # 0.0
> > +SHARED_LIBS += Fcitx5Qt6DBusAddons 0.0 # 0.0
> >
> > CATEGORIES = inputmethods
> >
> > @@ -17,12 +18,14 @@ MAINTAINER = Yifei Zhan <[email protected]
> > # LGPL2.1+ for other files
> > PERMIT_PACKAGE= Yes
> >
> > -WANTLIB += ${COMPILER_LIBCXX} Fcitx5Utils Qt5Concurrent Qt5Core
> > -WANTLIB += Qt5DBus Qt5Gui Qt5Widgets c m xcb xkbcommon
> > +WANTLIB += ${COMPILER_LIBCXX} Fcitx5Utils GL Qt5Concurrent Qt5Core
> > +WANTLIB += Qt5DBus Qt5Gui Qt5Widgets Qt6Core Qt6DBus Qt6Gui c
> > +WANTLIB += m xcb xkbcommon
> >
> > MASTER_SITES = https://download.fcitx-im.org/fcitx5/fcitx5-qt/
> >
> > -MODULES = devel/kf5
> > +MODULES = devel/kf5 \
> > + x11/qt6
> >
> > BUILD_DEPENDS = devel/gettext,-tools \
> > inputmethods/fcitx \
> > @@ -35,6 +38,7 @@ RUN_DEPENDS = devel/desktop-file-utils
> >
> > LIB_DEPENDS = inputmethods/fcitx
> >
> > -CONFIGURE_ARGS = -DENABLE_QT4=OFF
> > +CONFIGURE_ARGS = -DENABLE_QT4=OFF \
> > + -DENABLE_QT6=ON
> >
> > .include <bsd.port.mk>
> > Index: inputmethods/fcitx-qt/pkg/PLIST
> > ===================================================================
> > RCS file: /cvs/ports/inputmethods/fcitx-qt/pkg/PLIST,v
> > retrieving revision 1.1
> > diff -u -p -u -p -r1.1 PLIST
> > --- inputmethods/fcitx-qt/pkg/PLIST 13 May 2022 15:37:49 -0000 1.1
> > +++ inputmethods/fcitx-qt/pkg/PLIST 10 Oct 2022 06:06:10 -0000
> > @@ -15,6 +15,15 @@ include/Fcitx5Qt5/Fcitx5QtWidgetsAddons/
> > include/Fcitx5Qt5/Fcitx5QtWidgetsAddons/fcitxqtkeysequencewidget.h
> > include/Fcitx5Qt5/fcitx5qt5dbusaddons_version.h
> > include/Fcitx5Qt5/fcitx5qt5widgetsaddons_version.h
> > +include/Fcitx5Qt6/
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitx5qt6dbusaddons_export.h
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitxqtcontrollerproxy.h
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitxqtdbustypes.h
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitxqtinputcontextproxy.h
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitxqtinputmethodproxy.h
> > +include/Fcitx5Qt6/Fcitx5Qt6DBusAddons/fcitxqtwatcher.h
> > +include/Fcitx5Qt6/fcitx5qt6dbusaddons_version.h
> > lib/cmake/Fcitx5Qt5DBusAddons/
> > lib/cmake/Fcitx5Qt5DBusAddons/Fcitx5Qt5DBusAddonsConfig.cmake
> > lib/cmake/Fcitx5Qt5DBusAddons/Fcitx5Qt5DBusAddonsConfigVersion.cmake
> > @@ -25,11 +34,18 @@ lib/cmake/Fcitx5Qt5WidgetsAddons/Fcitx5Q
> > lib/cmake/Fcitx5Qt5WidgetsAddons/Fcitx5Qt5WidgetsAddonsConfigVersion.cmake
> >
> > lib/cmake/Fcitx5Qt5WidgetsAddons/Fcitx5Qt5WidgetsAddonsTargets${MODCMAKE_BUILD_SUFFIX}
> > lib/cmake/Fcitx5Qt5WidgetsAddons/Fcitx5Qt5WidgetsAddonsTargets.cmake
> > +lib/cmake/Fcitx5Qt6DBusAddons/
> > +lib/cmake/Fcitx5Qt6DBusAddons/Fcitx5Qt6DBusAddonsConfig.cmake
> > +lib/cmake/Fcitx5Qt6DBusAddons/Fcitx5Qt6DBusAddonsConfigVersion.cmake
> > +lib/cmake/Fcitx5Qt6DBusAddons/Fcitx5Qt6DBusAddonsTargets${MODCMAKE_BUILD_SUFFIX}
> > +lib/cmake/Fcitx5Qt6DBusAddons/Fcitx5Qt6DBusAddonsTargets.cmake
> > lib/fcitx5/qt5/
> > @so lib/fcitx5/qt5/libfcitx-quickphrase-editor5.so
> > @lib lib/libFcitx5Qt5DBusAddons.so.${LIBFcitx5Qt5DBusAddons_VERSION}
> > @lib lib/libFcitx5Qt5WidgetsAddons.so.${LIBFcitx5Qt5WidgetsAddons_VERSION}
> > +@lib lib/libFcitx5Qt6DBusAddons.so.${LIBFcitx5Qt6DBusAddons_VERSION}
> > @so
> > lib/qt5/plugins/platforminputcontexts/libfcitx5platforminputcontextplugin.so
> > +@so
> > lib/qt6/plugins/platforminputcontexts/libfcitx5platforminputcontextplugin.so
> > @bin libexec/fcitx5-qt5-gui-wrapper
> > share/locale/ca/LC_MESSAGES/fcitx5-qt.mo
> > share/locale/da/LC_MESSAGES/fcitx5-qt.mo
> >
>