janstary / sox

resurrect SoX
Other
5 stars 1 forks source link

don't hardwire wget #32

Open janstary opened 5 months ago

janstary commented 5 months ago

Make the network operation optional: if the user defines NETTOOL (or whatever) at build, use that: popen() what the user said, expecting the audio stream from the pipe.

janstary commented 5 months ago

See also sox_version_have_popen

martinwguy commented 5 months ago

In fact, the only significant patch in the macports version of sox is to replace wget with curl https://github.com/macports/macports-ports/tree/master/audio/sox/files so --with-wget or --with-curl if have_popen would be better - or neither. Does the macports' patch suggest that someone out there is using URL filenames for something, or just that they don't have wget but do have curl and felt they shouldn't remove the functionality just in case?

janstary commented 5 months ago

That's my patch :-) The point is that curl comes natively with macOS, while wget doesn't. Similarly, https://man.openbsd.org/ftp comes with OpenBSD, while both wget and curl are external packages.

So make it general: if the builder has something they want to use, let them. If not, drop the network functionality.