From 5e0a5ca921524f8859808527a57655eec16efa52 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Tue, 18 Jul 2023 00:58:25 +0100 Subject: gentoo auto-resync : 18:07:2023 - 00:58:24 --- app-misc/openrgb/Manifest | 6 +- .../openrgb/files/OpenRGB-0.9-build-system.patch | 12 +++ .../openrgb/files/OpenRGB-0.9-udev-check.patch | 12 +++ app-misc/openrgb/openrgb-0.9.ebuild | 91 ++++++++++++++++++++++ app-misc/openrgb/openrgb-9999.ebuild | 14 ++-- 5 files changed, 128 insertions(+), 7 deletions(-) create mode 100644 app-misc/openrgb/files/OpenRGB-0.9-build-system.patch create mode 100644 app-misc/openrgb/files/OpenRGB-0.9-udev-check.patch create mode 100644 app-misc/openrgb/openrgb-0.9.ebuild (limited to 'app-misc/openrgb') diff --git a/app-misc/openrgb/Manifest b/app-misc/openrgb/Manifest index f32705544215..5d574f9ad7bb 100644 --- a/app-misc/openrgb/Manifest +++ b/app-misc/openrgb/Manifest @@ -1,8 +1,12 @@ AUX OpenRGB-0.5-build-system.patch 755 BLAKE2B bda13d7d9de39d3dd79245ff7a13e22e09381a62ceaa58413b0aaa28017b6e860d032ab6ceb84f1140dc7f6c23dfecc1cadbcf696c8f872016307ea34d8870dc SHA512 50e110c01833113504a3a64e438a404196ae0af8e75007d6c42f3fcab5c20468f3fcb80f83d1f98ac7e1f4f88b1808ee28d0bf342b416d581c354a2388af32bf AUX OpenRGB-0.7-r1-udev.patch 410 BLAKE2B 10e4ba5cc32abed1c5c6bf15426033b03c36929d0d54d247235793193d8e0df26dbd10e1a63edb626a88fbbc5b532f00fac997589afb8885205dad2f53022378 SHA512 0714dc6432fa0d75a8867079d6056f6dc35b98dd62da512643df8649cb2e6bf8de85408485e2b47b2707efef8727789549a216c8adf72447fd084320b1a8e931 AUX OpenRGB-0.8-includes.patch 769 BLAKE2B b996f9d9e8e68416814a763451f6b706eeed8a884e5672ab26c926811dcd4b340afbbf8dd093a56501696a5c95a250f4f7317f5d5658c3b1d60073735fa1fd58 SHA512 710058f60a916404b1850e82a4fdbe9689cee6af8ed783a4a74297dfad46165227d88bda39816ccddcbdff3ef939a930a2977206d746f455e788af504ab91405 +AUX OpenRGB-0.9-build-system.patch 667 BLAKE2B 905d0c4a73439b0f39bfbebc74fbcb43f7df8f5810869834f2cf72c200d8df5d189843977c359eb50acbba23cedae97f245b74870ee7e200319b911ad05c15c6 SHA512 9348c1cc2474ac2d2cfc7e9c4a215e1692310b53ceb42db927bac31e954f34e6f4b70956cf671cb2fbf49add7a9358373bff11b43cdb11526a4c059d10b80762 +AUX OpenRGB-0.9-udev-check.patch 342 BLAKE2B 9778b67d7e99ae0c4fecef5295c248c39784123a413cd4f7c8847642c2d439c1fd985c6bb21302d5a80ef877c3961dd9cf7ee68e273cea9a9e2f9d3135e56cdd SHA512 0949be76e4fed14dff55ce914364d84ed03c0fa851a6372be6eb8554922130fca6bfb55cd4b229f2f5ab62f88b37e107d4b668c0a7c10a8ece40c564b88d3f49 AUX openrgb-0.8-gcc-13.patch 1822 BLAKE2B ef10b19c587919a99e5343cb0f8280d8cc6fdc199b9b5b8dac7f4a9cbdb8af0d47cefb6a015b6720b3307558227673c657701d711e256a61a97c0760b442b1f6 SHA512 e0ea05b27ef3a7936e9f1a6b3119bec9764562885c990c3fa9fcbfbda1eb556e5f696ed3f217dff74b97c109d1ab0cbc987fa1be505b10301f6726c77c4d37c0 DIST OpenRGB-release_0.8.tar.bz2 28631365 BLAKE2B 3b328e38f1c52646da02b0b2b2c22b1285f3b31b0a2bc684e99d491d04bd14a91b49bc196b3b81b537320cd872e5568aaa8aec34744f4f15392d9424a81ac6f0 SHA512 d69686da7cab33099b13cfb5ab876fc2db047f79aa01bf8150507ec41321b4c6c092f81623823b89916c70a1a24c4a102f77b1001c5caa721ff4c0c52e0630d2 +DIST OpenRGB-release_0.9.tar.bz2 28689813 BLAKE2B 9fcf08d5e4d07ffc0f7867516f09044e18ce488bcdd99c8b44e0afe291b8a21a7ba92d6e7fd683ef22462a262004a992621efb59a5df6ed7551f4e9f75843241 SHA512 fb1bdbc7bcbd3bac888be313cfb6403a13d39de659ac6993858f9c1b17ad40e9c4a7d4c7c90682181841db1659a0ee298363c442a7120d43347aaf4485e7dccf EBUILD openrgb-0.8-r1.ebuild 2295 BLAKE2B 5afcfd34951da11f082158fa6cf672e64c6779a1c37b44745407d0be1259f73a21971977f8be2fb6aa67e0a86ab0cde44b299391879b3357eafb0b33113ad225 SHA512 80e3a01d1e9e5b1734ac2d10a42fe8c590f435b8de8088438d2d03d8e5918f999db47f749c2c4c2aa367562de42496c11949e199a1dc282d48958cb9bc020e9b -EBUILD openrgb-9999.ebuild 2214 BLAKE2B ff82e906f2a33ca4b8b015e133c7ebce737430884aece52b75a883944b6ebcd4def3bc60ef61bd5abb8a9df0840f401f046ab1660149f394670c614a2e8a810c SHA512 186284c9cfca9437388353ac8212e62a12559d34a1c12141972f8a5101e4c82d0bc11cba6e4dd86ecb1dffa075b2e1454afe07a31f9a1ae27b980a925f59a5d4 +EBUILD openrgb-0.9.ebuild 2271 BLAKE2B 93575941a56bab03fb55eaa9aff7ea4ee66912bb6ad9945e2bcef3c563be4852ad127678ba58348a6d46bb5a8896cf8af3f094d32d7ee3d199ac80d4d1992b9d SHA512 a874a21a2d108b498666e42b53e46b05bd3b75b013291ca5733d86d8ff69b9804fd97cd7203ed327db299cb7ec11d8a9c1ef2241f3ec5b16b388ff15a9f7e18f +EBUILD openrgb-9999.ebuild 2271 BLAKE2B 93575941a56bab03fb55eaa9aff7ea4ee66912bb6ad9945e2bcef3c563be4852ad127678ba58348a6d46bb5a8896cf8af3f094d32d7ee3d199ac80d4d1992b9d SHA512 a874a21a2d108b498666e42b53e46b05bd3b75b013291ca5733d86d8ff69b9804fd97cd7203ed327db299cb7ec11d8a9c1ef2241f3ec5b16b388ff15a9f7e18f MISC metadata.xml 1228 BLAKE2B b3844d9c8b09d9d976ee41d874675b179a8e38b1eaaaa06e3052d6bac824dfc8c67102de54d9f62a3f24e4cf0157825608c060a56de2cc21bb71f8c7831148ad SHA512 5067cb355010ada60bfe789a511d02bf3d3a26083544104d782b9c08b0c70457f998c91c71f8d99e48f2d73fef07ea029fcc8c7848bdc5d625f5c1a8c9ca9ca3 diff --git a/app-misc/openrgb/files/OpenRGB-0.9-build-system.patch b/app-misc/openrgb/files/OpenRGB-0.9-build-system.patch new file mode 100644 index 000000000000..567e60787b72 --- /dev/null +++ b/app-misc/openrgb/files/OpenRGB-0.9-build-system.patch @@ -0,0 +1,12 @@ +--- a/OpenRGB.pro ++++ b/OpenRGB.pro +@@ -46,9 +46,6 @@ TEMPLATE = app + #-----------------------------------------------------------------------------------------------# + win32:BUILDDATE = $$system(date /t) + unix:BUILDDATE = $$system(date -R -d "@${SOURCE_DATE_EPOCH:-$(date +%s)}") +-GIT_COMMIT_ID = $$system(git log -n 1 --pretty=format:"%H") +-GIT_COMMIT_DATE = $$system(git log -n 1 --pretty=format:"%ci") +-GIT_BRANCH = $$system(git branch --show-current) + + DEFINES += \ + VERSION_STRING=\\"\"\"$$VERSION\\"\"\" \ diff --git a/app-misc/openrgb/files/OpenRGB-0.9-udev-check.patch b/app-misc/openrgb/files/OpenRGB-0.9-udev-check.patch new file mode 100644 index 000000000000..e3525c116baf --- /dev/null +++ b/app-misc/openrgb/files/OpenRGB-0.9-udev-check.patch @@ -0,0 +1,12 @@ +We install udev to /lib/udev instead, which it doesn't check + +--- a/ResourceManager.cpp ++++ b/ResourceManager.cpp +@@ -895,7 +895,6 @@ void ResourceManager::DetectDevicesThreadFunction() + { + if(access("/usr/lib/udev/rules.d/60-openrgb.rules", F_OK) != 0) + { +- udev_not_exist = true; + } + } + else diff --git a/app-misc/openrgb/openrgb-0.9.ebuild b/app-misc/openrgb/openrgb-0.9.ebuild new file mode 100644 index 000000000000..0b3ebc85f6c8 --- /dev/null +++ b/app-misc/openrgb/openrgb-0.9.ebuild @@ -0,0 +1,91 @@ +# Copyright 2020-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit flag-o-matic qmake-utils udev xdg-utils + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI=${EGIT_REPO_URI:-"https://gitlab.com/CalcProgrammer1/OpenRGB"} +else + SRC_URI="https://gitlab.com/CalcProgrammer1/OpenRGB/-/archive/release_${PV}/OpenRGB-release_${PV}.tar.bz2" + S="${WORKDIR}/OpenRGB-release_${PV}" + KEYWORDS="~amd64 ~loong ~x86" + PATCHES=( "${FILESDIR}"/OpenRGB-0.9-build-system.patch ) +fi + +DESCRIPTION="Open source RGB lighting control" +HOMEPAGE="https://openrgb.org https://gitlab.com/CalcProgrammer1/OpenRGB/" +LICENSE="GPL-2" +# subslot is OPENRGB_PLUGIN_API_VERSION from +# https://gitlab.com/CalcProgrammer1/OpenRGB/-/blob/master/OpenRGBPluginInterface.h +SLOT="0/3" + +RDEPEND=" + dev-cpp/cpp-httplib:= + dev-libs/hidapi + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtwidgets:5 + net-libs/mbedtls:= + virtual/libusb:1 +" +DEPEND=" + ${RDEPEND} + dev-cpp/nlohmann_json + dev-libs/mdns +" +BDEPEND=" + dev-qt/linguist-tools:5 + virtual/pkgconfig +" + +PATCHES+=( + "${FILESDIR}"/OpenRGB-0.7-r1-udev.patch + "${FILESDIR}"/OpenRGB-0.9-udev-check.patch +) + +src_prepare() { + default + rm -r dependencies/{httplib,hidapi,libusb,mdns,json,mbedtls}* \ + || die "Failed to remove unneded deps" +} + +src_configure() { + # Some plugins require symbols defined in the main binary. + # The upstream build system of plugins bundles OpenRGB as a submodule + # instead, and compiles the .cpp file again. + append-ldflags -Wl,--export-dynamic + + # > warning: ‘-pipe’ ignored because ‘-save-temps’ specified + filter-flags -pipe + + eqmake5 \ + INCLUDEPATH+="${ESYSROOT}/usr/include/nlohmann" \ + DEFINES+="OPENRGB_EXTRA_PLUGIN_DIRECTORY=\\\\\"\\\"${EPREFIX}/usr/$(get_libdir)/OpenRGB/plugins\\\\\"\\\"" \ + LIBS+=-lhttplib +} + +src_install() { + emake INSTALL_ROOT="${ED}" install + + dodoc README.md OpenRGB.patch + + rm -r "${ED}"/usr/lib/udev/ || die + udev_dorules 60-openrgb.rules + + # This is for plugins. Upstream doesn't install any headers at all. + insinto /usr/include/OpenRGB + find . -name '*.h' -exec cp --parents '{}' "${ED}/usr/include/OpenRGB/" ';' || die +} + +pkg_postinst() { + xdg_icon_cache_update + udev_reload +} + +pkg_postrm() { + xdg_icon_cache_update + udev_reload +} diff --git a/app-misc/openrgb/openrgb-9999.ebuild b/app-misc/openrgb/openrgb-9999.ebuild index 291cae9fb808..0b3ebc85f6c8 100644 --- a/app-misc/openrgb/openrgb-9999.ebuild +++ b/app-misc/openrgb/openrgb-9999.ebuild @@ -12,14 +12,15 @@ else SRC_URI="https://gitlab.com/CalcProgrammer1/OpenRGB/-/archive/release_${PV}/OpenRGB-release_${PV}.tar.bz2" S="${WORKDIR}/OpenRGB-release_${PV}" KEYWORDS="~amd64 ~loong ~x86" - PATCHES=( "${FILESDIR}"/OpenRGB-0.5-build-system.patch ) + PATCHES=( "${FILESDIR}"/OpenRGB-0.9-build-system.patch ) fi DESCRIPTION="Open source RGB lighting control" HOMEPAGE="https://openrgb.org https://gitlab.com/CalcProgrammer1/OpenRGB/" LICENSE="GPL-2" -# subslot is OPENRGB_PLUGIN_API_VERSION from https://gitlab.com/CalcProgrammer1/OpenRGB/-/blob/master/OpenRGBPluginInterface.h -SLOT="0/2" +# subslot is OPENRGB_PLUGIN_API_VERSION from +# https://gitlab.com/CalcProgrammer1/OpenRGB/-/blob/master/OpenRGBPluginInterface.h +SLOT="0/3" RDEPEND=" dev-cpp/cpp-httplib:= @@ -42,6 +43,7 @@ BDEPEND=" PATCHES+=( "${FILESDIR}"/OpenRGB-0.7-r1-udev.patch + "${FILESDIR}"/OpenRGB-0.9-udev-check.patch ) src_prepare() { @@ -52,8 +54,8 @@ src_prepare() { src_configure() { # Some plugins require symbols defined in the main binary. - # The official build system bundles OpenRGB as a submodule instead, and - # compiles the .cpp file again. + # The upstream build system of plugins bundles OpenRGB as a submodule + # instead, and compiles the .cpp file again. append-ldflags -Wl,--export-dynamic # > warning: ‘-pipe’ ignored because ‘-save-temps’ specified @@ -70,8 +72,8 @@ src_install() { dodoc README.md OpenRGB.patch - udev_dorules 60-openrgb.rules rm -r "${ED}"/usr/lib/udev/ || die + udev_dorules 60-openrgb.rules # This is for plugins. Upstream doesn't install any headers at all. insinto /usr/include/OpenRGB -- cgit v1.2.3