Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 823194 - app-admin/sxid-4.2-r2 the mandatory RDEPEND=virtual/mailx should instead be on a USE flag
Summary: app-admin/sxid-4.2-r2 the mandatory RDEPEND=virtual/mailx should instead be o...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Low enhancement (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2021-11-11 23:13 UTC by genBTC
Modified: 2021-11-12 17:51 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Emerge showing the dependency tree it pulls in by default, along with command lines showing the program being run with --help , default, and -n options (for reference). (sxidbug.txt,2.05 KB, text/plain)
2021-11-11 23:15 UTC, genBTC
Details
successful build log with RDEPEND=virtual/mailx commented out (sxidbuildstrip.txt,7.71 KB, text/plain)
2021-11-11 23:16 UTC, genBTC
Details
Diff .patch to the ebuild , enhancement complete, request for submission (sxid.patch,1005 bytes, patch)
2021-11-12 00:09 UTC, genBTC
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description genBTC 2021-11-11 23:13:57 UTC
app-admin/sxid-4.2r2 .ebuild has RDEPEND=virtual/mailx, which then pulls in mailutils and nullmailer. The program is capable of being compiled without this, as is, with no code changes.

After simply deleting RDEPEND=virtual/mailx , the configure script and compile process is very happy to complete successfully. It just hardcodes a path of /usr/bin/mail. The program also includes a runtime parameter: the -n option, which just outputs to stdout instead of using the mail program.

Running the program without any arguments just produces a standard error of: /usr/bin/mail No such file or directory.
(Ideally the default behavior and messages could be improved with a patch, but the software is very old and other things should be fixed with the configure scripts too, but that is neither here nor there)

I hereby suggest the "+mail" USE flag be added, enabled by default, as the means by which the virtual/mailx dependency is pulled in.

That way someone can opt to disable the flag and use it as a standalone binary with the -n option.
Finding out about the the -n "no Mail" option will be easy if you run --help.
Portage can spit out a helpful "elog" message telling you to do this if you manually disable the flag.
These fixes/enhancements can be handled in the ebuild itself with minimal effort.

I have included 2 attachments:
1 - Emerge showing the dependency tree it pulls in by default, along with command lines showing the program being run with --help , default, and -n options (for reference).
2 - The entire build log completing successfully when RDEPEND=virtual/mailx is commented out (proof of success).

Reproducible: Always
Comment 1 genBTC 2021-11-11 23:15:19 UTC
Created attachment 750501 [details]
Emerge showing the dependency tree it pulls in by default, along with command lines showing the program being run with --help , default, and -n options (for reference).
Comment 2 genBTC 2021-11-11 23:16:13 UTC
Created attachment 750504 [details]
successful build log with RDEPEND=virtual/mailx commented out
Comment 3 Tee KOBAYASHI 2021-11-12 00:05:42 UTC
That usage of USE flags is not allowed. You can use /etc/portage/profile/package.provided to prevent virtual/mailx from being pulled in.
Comment 4 genBTC 2021-11-12 00:09:31 UTC
Created attachment 750510 [details, diff]
Diff .patch to the ebuild , enhancement complete, request for submission

Signed-off-by: genBTC <genBTC@gmx.com>

+mail USE flag added
Helpful elog information messages changed/added