From: Rafael Sadowski Subject: net/libaccounts-qt: qt6 flavor To: ports@openbsd.org Cc: kn@openbsd.org Date: Mon, 8 Apr 2024 07:25:49 +0200 The same pattern like in the perverse qt6 flavor diffs. OK? diff --git a/net/libaccounts-qt/Makefile b/net/libaccounts-qt/Makefile index 83723cd0e9c..cb67cfb1ca1 100644 --- a/net/libaccounts-qt/Makefile +++ b/net/libaccounts-qt/Makefile @@ -3,10 +3,13 @@ COMMENT = Qt-based client library for the accounts database CATEGORIES = net V = VERSION_1.16 +DIST_TUPLE = gitlab nicolasfella libaccounts-qt \ + 18557f7def9af8f4a9e0e93e9f575ae11e5066aa . DISTNAME = libaccounts-qt-${V:S/VERSION_//} -REVISION = 2 +REVISION = 3 SHARED_LIBS += accounts-qt5 0.0 # 1.4 +SHARED_LIBS += accounts-qt6 0.0 # 1.4 HOMEPAGE = https://accounts-sso.gitlab.io/ @@ -15,28 +18,40 @@ MAINTAINER = Rafael Sadowski # LGPLv2.1+, GPLv2+ PERMIT_PACKAGE = Yes -SITES = https://gitlab.com/accounts-sso/libaccounts-qt/-/archive/${V}/ -WANTLIB += ${COMPILER_LIBCXX} Qt5Core Qt5Test Qt5Xml accounts-glib -WANTLIB += c gio-2.0 glib-2.0 gobject-2.0 intl m +FLAVORS= qt6 +FLAVOR ?= +.if ${FLAVOR:Mqt6} +FULLPKGNAME= libaccounts-qt6-${V:S/VERSION_//} +MODULES = x11/qt6 \ + devel/qmake +WANTLIB += ${COMPILER_LIBCXX} Qt6Core Qt6Test Qt6Xml accounts-glib +WANTLIB += c gio-2.0 glib-2.0 gobject-2.0 intl m +QT_VERSION = qt6 +.else MODULES = x11/qt5 \ devel/qmake - -BUILD_DEPENDS = devel/doxygen>=1.10.0 \ - textproc/gtk-doc +WANTLIB += ${COMPILER_LIBCXX} Qt5Core Qt5Test Qt5Xml accounts-glib +WANTLIB += c gio-2.0 glib-2.0 gobject-2.0 intl m +QT_VERSION = qt5 +.endif LIB_DEPENDS = net/libaccounts-glib \ devel/glib2 -WRKDIST = ${WRKDIR}/libaccounts-qt-${V}-525ec684cfa8d234f797d7e49e21c476eea04d8e +WRKDIST = ${WRKDIR}/libaccounts-qt-18557f7def9af8f4a9e0e93e9f575ae11e5066aa TEST_TARGET = check TEST_IS_INTERACTIVE = Yes pre-configure: - ln -sf ${LOCALBASE}/lib/qt5/bin/q{collection,help}generator ${WRKDIR}/bin/ - ${SUBST_CMD} ${WRKSRC}/Accounts/AccountsQt5Config.cmake.in + ln -sf ${LOCALBASE}/lib/${QT_VERSION}/bin/q{collection,help}generator ${WRKDIR}/bin/ + ${SUBST_CMD} ${WRKSRC}/Accounts/AccountsQt5Config.cmake.in \ + ${WRKSRC}/Accounts/AccountsQt6Config.cmake.in + +post-install: + mv ${PREFIX}/bin/accountstest ${PREFIX}/bin/accountstest-${QT_VERSION} .include diff --git a/net/libaccounts-qt/distinfo b/net/libaccounts-qt/distinfo index ee0597cf09e..01aab518a38 100644 --- a/net/libaccounts-qt/distinfo +++ b/net/libaccounts-qt/distinfo @@ -1,2 +1,2 @@ -SHA256 (libaccounts-qt-1.16.tar.gz) = KG6wL5NoU+MuYQADoqMyoSUkBQ0iZwfnYwtqKb0732Y= -SIZE (libaccounts-qt-1.16.tar.gz) = 64445 +SHA256 (nicolasfella-libaccounts-qt-18557f7def9af8f4a9e0e93e9f575ae11e5066aa.tar.gz) = yJ35yVN6+lsvAVVqmaKMt4vKYyVYgUfA6QLVKgbGTEk= +SIZE (nicolasfella-libaccounts-qt-18557f7def9af8f4a9e0e93e9f575ae11e5066aa.tar.gz) = 65468 diff --git a/net/libaccounts-qt/patches/patch-Accounts_AccountsQt5Config_cmake_in b/net/libaccounts-qt/patches/patch-Accounts_AccountsQt5Config_cmake_in index 649a8539009..5b37053778d 100644 --- a/net/libaccounts-qt/patches/patch-Accounts_AccountsQt5Config_cmake_in +++ b/net/libaccounts-qt/patches/patch-Accounts_AccountsQt5Config_cmake_in @@ -6,7 +6,5 @@ Index: Accounts/AccountsQt5Config.cmake.in # ACCOUNTSQT_LIBRARIES - The libraries needed to use libaccounts-qt -set(ACCOUNTSQT_LIBRARIES $${INSTALL_LIBDIR}/lib$${TARGET}.so) --set(ACCOUNTSQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET}/) -\ No newline at end of file +set(ACCOUNTSQT_LIBRARIES $${INSTALL_LIBDIR}/lib$${TARGET}.so.${LIBaccounts-qt5_VERSION}) -+set(ACCOUNTSQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET}/) + set(ACCOUNTSQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET}/) diff --git a/net/libaccounts-qt/patches/patch-Accounts_AccountsQt6Config_cmake_in b/net/libaccounts-qt/patches/patch-Accounts_AccountsQt6Config_cmake_in new file mode 100644 index 00000000000..c129c13e6a1 --- /dev/null +++ b/net/libaccounts-qt/patches/patch-Accounts_AccountsQt6Config_cmake_in @@ -0,0 +1,12 @@ +Index: Accounts/AccountsQt6Config.cmake.in +--- Accounts/AccountsQt6Config.cmake.in.orig ++++ Accounts/AccountsQt6Config.cmake.in +@@ -1,5 +1,5 @@ + # ACCOUNTSQT_INCLUDE_DIRS - The libaccounts-qt include directories + # ACCOUNTSQT_LIBRARIES - The libraries needed to use libaccounts-qt + +-set(ACCOUNTSQT_LIBRARIES $${INSTALL_LIBDIR}/lib$${TARGET}.so) +-set(ACCOUNTSQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET}/) +\ No newline at end of file ++set(ACCOUNTSQT_LIBRARIES $${INSTALL_LIBDIR}/lib$${TARGET}.so.${LIBaccounts-qt6_VERSION}) ++set(ACCOUNTSQT_INCLUDE_DIRS $${INSTALL_PREFIX}/include/$${TARGET}/) diff --git a/net/libaccounts-qt/patches/patch-accounts-qt_pro b/net/libaccounts-qt/patches/patch-accounts-qt_pro new file mode 100644 index 00000000000..bd05329914f --- /dev/null +++ b/net/libaccounts-qt/patches/patch-accounts-qt_pro @@ -0,0 +1,12 @@ +Index: accounts-qt.pro +--- accounts-qt.pro.orig ++++ accounts-qt.pro +@@ -5,7 +5,7 @@ CONFIG += ordered + SUBDIRS += Accounts tests + + include( common-project-config.pri ) +-include( doc/doc.pri ) ++#include( doc/doc.pri ) + + DISTNAME = $${PROJECT_NAME}-$${PROJECT_VERSION} + EXCLUDES = \ diff --git a/net/libaccounts-qt/pkg/PFRAG.no-qt6 b/net/libaccounts-qt/pkg/PFRAG.no-qt6 new file mode 100644 index 00000000000..54785e2337d --- /dev/null +++ b/net/libaccounts-qt/pkg/PFRAG.no-qt6 @@ -0,0 +1,29 @@ +@bin bin/accountstest-qt5 +include/accounts-qt5/ +include/accounts-qt5/Accounts/ +include/accounts-qt5/Accounts/Account +include/accounts-qt5/Accounts/AccountService +include/accounts-qt5/Accounts/Application +include/accounts-qt5/Accounts/AuthData +include/accounts-qt5/Accounts/Error +include/accounts-qt5/Accounts/Manager +include/accounts-qt5/Accounts/Provider +include/accounts-qt5/Accounts/Service +include/accounts-qt5/Accounts/ServiceType +include/accounts-qt5/Accounts/account-service.h +include/accounts-qt5/Accounts/account.h +include/accounts-qt5/Accounts/accountscommon.h +include/accounts-qt5/Accounts/application.h +include/accounts-qt5/Accounts/auth-data.h +include/accounts-qt5/Accounts/error.h +include/accounts-qt5/Accounts/manager.h +include/accounts-qt5/Accounts/manager_p.h +include/accounts-qt5/Accounts/provider.h +include/accounts-qt5/Accounts/service-type.h +include/accounts-qt5/Accounts/service.h +include/accounts-qt5/Accounts/utils.h +lib/cmake/AccountsQt5/ +lib/cmake/AccountsQt5/AccountsQt5Config.cmake +lib/cmake/AccountsQt5/AccountsQt5ConfigVersion.cmake +@lib lib/libaccounts-qt5.so.${LIBaccounts-qt5_VERSION} +lib/pkgconfig/accounts-qt5.pc diff --git a/net/libaccounts-qt/pkg/PFRAG.qt6 b/net/libaccounts-qt/pkg/PFRAG.qt6 new file mode 100644 index 00000000000..6ad65887dc0 --- /dev/null +++ b/net/libaccounts-qt/pkg/PFRAG.qt6 @@ -0,0 +1,30 @@ +@bin bin/accountstest-qt6 +include/accounts-qt6/ +include/accounts-qt6/Accounts/ +include/accounts-qt6/Accounts/Account +include/accounts-qt6/Accounts/AccountService +include/accounts-qt6/Accounts/Application +include/accounts-qt6/Accounts/AuthData +include/accounts-qt6/Accounts/Error +include/accounts-qt6/Accounts/Manager +include/accounts-qt6/Accounts/Provider +include/accounts-qt6/Accounts/Service +include/accounts-qt6/Accounts/ServiceType +include/accounts-qt6/Accounts/account-service.h +include/accounts-qt6/Accounts/account.h +include/accounts-qt6/Accounts/accountscommon.h +include/accounts-qt6/Accounts/application.h +include/accounts-qt6/Accounts/auth-data.h +include/accounts-qt6/Accounts/error.h +include/accounts-qt6/Accounts/manager.h +include/accounts-qt6/Accounts/manager_p.h +include/accounts-qt6/Accounts/provider.h +include/accounts-qt6/Accounts/service-type.h +include/accounts-qt6/Accounts/service.h +include/accounts-qt6/Accounts/utils.h +lib/cmake/ +lib/cmake/AccountsQt6/ +lib/cmake/AccountsQt6/AccountsQt6Config.cmake +lib/cmake/AccountsQt6/AccountsQt6ConfigVersion.cmake +@lib lib/libaccounts-qt6.so.${LIBaccounts-qt6_VERSION} +lib/pkgconfig/accounts-qt6.pc diff --git a/net/libaccounts-qt/pkg/PLIST b/net/libaccounts-qt/pkg/PLIST index 910cb25be32..48224473412 100644 --- a/net/libaccounts-qt/pkg/PLIST +++ b/net/libaccounts-qt/pkg/PLIST @@ -1,143 +1,2 @@ -@bin bin/accountstest -include/accounts-qt5/ -include/accounts-qt5/Accounts/ -include/accounts-qt5/Accounts/Account -include/accounts-qt5/Accounts/AccountService -include/accounts-qt5/Accounts/Application -include/accounts-qt5/Accounts/AuthData -include/accounts-qt5/Accounts/Error -include/accounts-qt5/Accounts/Manager -include/accounts-qt5/Accounts/Provider -include/accounts-qt5/Accounts/Service -include/accounts-qt5/Accounts/ServiceType -include/accounts-qt5/Accounts/account-service.h -include/accounts-qt5/Accounts/account.h -include/accounts-qt5/Accounts/accountscommon.h -include/accounts-qt5/Accounts/application.h -include/accounts-qt5/Accounts/auth-data.h -include/accounts-qt5/Accounts/error.h -include/accounts-qt5/Accounts/manager.h -include/accounts-qt5/Accounts/manager_p.h -include/accounts-qt5/Accounts/provider.h -include/accounts-qt5/Accounts/service-type.h -include/accounts-qt5/Accounts/service.h -include/accounts-qt5/Accounts/utils.h -lib/cmake/AccountsQt5/ -lib/cmake/AccountsQt5/AccountsQt5Config.cmake -lib/cmake/AccountsQt5/AccountsQt5ConfigVersion.cmake -@lib lib/libaccounts-qt5.so.${LIBaccounts-qt5_VERSION} -lib/pkgconfig/accounts-qt5.pc -share/doc/accounts-qt/ -share/doc/accounts-qt/html/ -share/doc/accounts-qt/html/account-service_8cpp_source.html -share/doc/accounts-qt/html/account-service_8h_source.html -share/doc/accounts-qt/html/account_8cpp_source.html -share/doc/accounts-qt/html/account_8h_source.html -share/doc/accounts-qt/html/accountscommon_8h_source.html -share/doc/accounts-qt/html/annotated.html -share/doc/accounts-qt/html/annotated_dup.js -share/doc/accounts-qt/html/application_8cpp_source.html -share/doc/accounts-qt/html/application_8h_source.html -share/doc/accounts-qt/html/auth-data_8cpp_source.html -share/doc/accounts-qt/html/auth-data_8h_source.html -share/doc/accounts-qt/html/bc_s.png -share/doc/accounts-qt/html/bc_sd.png -share/doc/accounts-qt/html/classAccounts_1_1AccountService-members.html -share/doc/accounts-qt/html/classAccounts_1_1AccountService.html -share/doc/accounts-qt/html/classAccounts_1_1AccountService.js -share/doc/accounts-qt/html/classAccounts_1_1Application-members.html -share/doc/accounts-qt/html/classAccounts_1_1Application.html -share/doc/accounts-qt/html/classAccounts_1_1Application.js -share/doc/accounts-qt/html/classAccounts_1_1AuthData-members.html -share/doc/accounts-qt/html/classAccounts_1_1AuthData.html -share/doc/accounts-qt/html/classAccounts_1_1AuthData.js -share/doc/accounts-qt/html/classAccounts_1_1Error-members.html -share/doc/accounts-qt/html/classAccounts_1_1Error.html -share/doc/accounts-qt/html/classAccounts_1_1Error.js -share/doc/accounts-qt/html/classAccounts_1_1Manager-members.html -share/doc/accounts-qt/html/classAccounts_1_1Manager.html -share/doc/accounts-qt/html/classAccounts_1_1Manager.js -share/doc/accounts-qt/html/classAccounts_1_1Provider-members.html -share/doc/accounts-qt/html/classAccounts_1_1Provider.html -share/doc/accounts-qt/html/classAccounts_1_1Provider.js -share/doc/accounts-qt/html/classAccounts_1_1Service-members.html -share/doc/accounts-qt/html/classAccounts_1_1Service.html -share/doc/accounts-qt/html/classAccounts_1_1Service.js -share/doc/accounts-qt/html/classAccounts_1_1ServiceType-members.html -share/doc/accounts-qt/html/classAccounts_1_1ServiceType.html -share/doc/accounts-qt/html/classAccounts_1_1ServiceType.js -share/doc/accounts-qt/html/classes.html -share/doc/accounts-qt/html/clipboard.js -share/doc/accounts-qt/html/closed.png -share/doc/accounts-qt/html/cookie.js -share/doc/accounts-qt/html/deprecated.html -share/doc/accounts-qt/html/dir_9b945efebb006547a94415eadaa12921.html -share/doc/accounts-qt/html/dir_9b945efebb006547a94415eadaa12921.js -share/doc/accounts-qt/html/doc.svg -share/doc/accounts-qt/html/docd.svg -share/doc/accounts-qt/html/doxygen.css -share/doc/accounts-qt/html/doxygen.svg -share/doc/accounts-qt/html/doxygen_crawl.html -share/doc/accounts-qt/html/dynsections.js -share/doc/accounts-qt/html/error_8cpp_source.html -share/doc/accounts-qt/html/error_8h_source.html -share/doc/accounts-qt/html/files.html -share/doc/accounts-qt/html/files_dup.js -share/doc/accounts-qt/html/folderclosed.svg -share/doc/accounts-qt/html/folderclosedd.svg -share/doc/accounts-qt/html/folderopen.svg -share/doc/accounts-qt/html/folderopend.svg -share/doc/accounts-qt/html/functions.html -share/doc/accounts-qt/html/functions_enum.html -share/doc/accounts-qt/html/functions_eval.html -share/doc/accounts-qt/html/functions_func.html -share/doc/accounts-qt/html/graph_legend.html -share/doc/accounts-qt/html/graph_legend.md5 -share/doc/accounts-qt/html/graph_legend.png -share/doc/accounts-qt/html/index.html -share/doc/accounts-qt/html/index.qhp -share/doc/accounts-qt/html/jquery.js -share/doc/accounts-qt/html/manager_8cpp_source.html -share/doc/accounts-qt/html/manager_8h_source.html -share/doc/accounts-qt/html/manager__p_8h_source.html -share/doc/accounts-qt/html/menu.js -share/doc/accounts-qt/html/menudata.js -share/doc/accounts-qt/html/minus.svg -share/doc/accounts-qt/html/minusd.svg -share/doc/accounts-qt/html/nav_f.png -share/doc/accounts-qt/html/nav_fd.png -share/doc/accounts-qt/html/nav_g.png -share/doc/accounts-qt/html/nav_h.png -share/doc/accounts-qt/html/nav_hd.png -share/doc/accounts-qt/html/navtree.css -share/doc/accounts-qt/html/navtree.js -share/doc/accounts-qt/html/navtreedata.js -share/doc/accounts-qt/html/navtreeindex0.js -share/doc/accounts-qt/html/open.png -share/doc/accounts-qt/html/pages.html -share/doc/accounts-qt/html/plus.svg -share/doc/accounts-qt/html/plusd.svg -share/doc/accounts-qt/html/provider_8cpp_source.html -share/doc/accounts-qt/html/provider_8h_source.html -share/doc/accounts-qt/html/resize.js -share/doc/accounts-qt/html/service-type_8cpp_source.html -share/doc/accounts-qt/html/service-type_8h_source.html -share/doc/accounts-qt/html/service_8cpp_source.html -share/doc/accounts-qt/html/service_8h_source.html -share/doc/accounts-qt/html/splitbar.png -share/doc/accounts-qt/html/splitbard.png -share/doc/accounts-qt/html/sync_off.png -share/doc/accounts-qt/html/sync_on.png -share/doc/accounts-qt/html/tab_a.png -share/doc/accounts-qt/html/tab_ad.png -share/doc/accounts-qt/html/tab_b.png -share/doc/accounts-qt/html/tab_bd.png -share/doc/accounts-qt/html/tab_h.png -share/doc/accounts-qt/html/tab_hd.png -share/doc/accounts-qt/html/tab_s.png -share/doc/accounts-qt/html/tab_sd.png -share/doc/accounts-qt/html/tabs.css -share/doc/accounts-qt/html/utils_8cpp_source.html -share/doc/accounts-qt/html/utils_8h_source.html -share/doc/accounts-qt/qch/ -share/doc/accounts-qt/qch/accounts.qch +%%qt6%% +!%%qt6%%