Currently, the USE flag plugins installs all plugins when I would prefer to have everything except sysinfo specifically because I have a plugin that conflicts with that. And I have an ebuild that installs the plugin aforementioned and would like to not conflict or tell the user to delete/chmod the conflicting so file. USE flags would be: plugins-checksum plugins-doat plugins-fishlim plugins-sysinfo instead of one 'plugins' USE flag. Reproducible: Always Steps to Reproduce: 1. USE="plugins-checksum plugins-doat plugins-fishlim -plugins-sysinfo" emerge net-irc/hexchat 2. (test -f /usr/lib/hexchat/plugins/sysinfo.so && echo 1) || echo 0 Actual Results: 1 Current work-around without deleting the file is to do this as root (as my ebuild suggests): chmod 0700 /usr/lib/hexchat/plugins/sysinfo.so
Probably we should introduce USE_EXPAND variable, for example - "hexchat_plugins". Then correct USE flags will be hexchat_plugins_checksum, hexchat_plugins_sysinfo etc. Denis, what do you think about this as a maintainer?
Sergey I have been thinking about doing this for some time now. I was going to suggest exactly USE_EXPAND as this is what I thought doing initially some time ago. If anyone is fast enough and submit a patch until tomorrow you're welcome to do so, otherwise I'll upload an ebuild patch until tomorrow night including this enhancement.
Created attachment 342670 [details, diff] hexchat-2.9.4.ebuild.patch Things that changed here: * added IUSE_HEXCHAT_PLUGINS * added --enable-plugin so that the plugin interface will always be enabled even if you won't use plugins Whoever commits this, don't forget to add HEXCHAT_PLUGINS into the USE_EXPAND var in ${PORTDIR}/base/make.defaults I'm unsure if this needs a revision bump, probably yes. --- a/hexchat-2.9.4.ebuild 2013-03-09 15:31:24.000000000 +0100 +++ b/hexchat-2.9.4.ebuild 2013-03-19 22:00:55.202065702 +0100 @@ -13,7 +13,13 @@ LICENSE="GPL-2" SLOT="0" KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 sparc x86 ~amd64-linux" -IUSE="dbus fastscroll +gtk ipv6 libnotify libproxy nls ntlm perl +plugins python spell ssl threads" +IUSE_HEXCHAT_PLUGINS=" + hexchat_plugins_checksum + hexchat_plugins_doat + hexchat_plugins_fishlim + hexchat_plugins_sysinfo +" +IUSE="${IUSE_HEXCHAT_PLUGINS} dbus fastscroll +gtk ipv6 libnotify libproxy nls ntlm perl python spell ssl threads" RDEPEND="dev-libs/glib:2 x11-libs/pango @@ -63,6 +69,7 @@ econf \ --disable-tcl \ --enable-shm \ + --enable-plugin \ $(use_enable dbus) \ $(use_enable ipv6) \ $(use_enable nls) \ @@ -74,11 +81,10 @@ $(use_enable gtk gtkfe) \ $(use_enable !gtk textfe) \ $(use_enable fastscroll xft) \ - $(use_enable plugins plugin) \ - $(use_enable plugins checksum) \ - $(use_enable plugins doat) \ - $(use_enable plugins fishlim) \ - $(use_enable plugins sysinfo) \ + $(use_enable hexchat_plugins_checksum checksum) \ + $(use_enable hexchat_plugins_doat doat) \ + $(use_enable hexchat_plugins_fishlim fishlim) \ + $(use_enable hexchat_plugins_sysinfo sysinfo) \ $(use_enable libproxy) \ $(use_enable libproxy socks) \ $(use_enable threads)
This does not use USE_EXPAND as discussed previously http://devmanual.gentoo.org/general-concepts/use-flags/index.html If you don't want to use USE_EXPAND then I suggest you rename them to plugin-checksum plugin-doat etc.
Created attachment 342676 [details, diff] metadata.xml.patch --- a/metadata.xml 2012-11-25 14:01:23.000000000 +0100 +++ b/metadata.xml 2013-03-19 22:22:05.696971629 +0100 @@ -11,5 +11,10 @@ <flag name='ntlm'>Enable NTLM authentication</flag> <flag name='libproxy'>Enable proxy support.</flag> <flag name='plugins'>Enable plugin support and installs some built-in plugins</flag> + <flag name='hexchat_plugins_checksum'>Installs the checksum plugin</flag> + <flag name='hexchat_plugins_doat'>Installs the DoAt plugin</flag> + <flag name='hexchat_plugins_fishlim'>Installs the fishlim plugin for sending/recieving + encrypted messages</flag> + <flag name='hexchat_plugins_sysinfo'>Installs the sysinfo plugin for posting system information</flag> </use> </pkgmetadata>
(In reply to comment #0) > Currently, the USE flag plugins installs all plugins when I would prefer to > have everything except sysinfo specifically because I have a plugin that > conflicts with that. And I have an ebuild that installs the plugin > aforementioned and would like to not conflict or tell the user to > delete/chmod the conflicting so file. Erm, shouldn't hexchat be fixed to be able to handle conflicting plugins? For example, by allowing the user to disable one of them. I don't think ebuild is the place to fix this.
(In reply to comment #6) > Erm, shouldn't hexchat be fixed to be able to handle conflicting plugins? > For example, by allowing the user to disable one of them. I don't think > ebuild is the place to fix this. Whatever his use case might be, making the hexchat ebuild able to install only some plugins is certainly a good approach here. Anyways, he might be using some locally installed plugin or an ebuild he made himself, in either cases there is no way AFAIK to deal with such issues in the hexchat ebuild.
(In reply to comment #7) > (In reply to comment #6) > > Erm, shouldn't hexchat be fixed to be able to handle conflicting plugins? > > For example, by allowing the user to disable one of them. I don't think > > ebuild is the place to fix this. > > Whatever his use case might be, making the hexchat ebuild able to install > only some plugins is certainly a good approach here. I disagree. As long as this doesn't get bigger, there's no point in establishing the whole USE_EXPAND machine just for this. Especially if the plugins don't introduce any deps nor consume large amounts of disk space / build time.
(In reply to comment #8) > I disagree. As long as this doesn't get bigger, there's no point in > establishing the whole USE_EXPAND machine just for this. Especially if the > plugins don't introduce any deps nor consume large amounts of disk space / > build time. We really don't know if upstream will expand the list any time soon. Anyways, at this point I'll have to agree with you. I'll resubmit the ebuild with plain plugin-<...> USE flags for the plugins.
*hexchat-2.9.4-r1 (31 Mar 2013) 31 Mar 2013; Julian Ospald <hasufell@gentoo.org> +hexchat-2.9.4-r1.ebuild, +files/hexchat-2.9.4-build.patch, metadata.xml: revbump: rework, add theme-manager, fix deps, convert to plugin-<..> syntax, use python-single-r1, fix build system instead of sedding it, use eautoreconf rather than autogen.sh, remove obsolete sed, update icon cache and gconf schemas properly