Index | Thread | Search

From:
Ingo Schwarze <schwarze@usta.de>
Subject:
Re: Support for /usr/bin/env -S (kind of)
To:
Theo de Raadt <deraadt@openbsd.org>
Cc:
Manuel Giraud <manuel@ledu-giraud.fr>, tech@openbsd.org
Date:
Tue, 22 Jul 2025 17:31:36 +0200

Download raw body.

Thread
  • Matthias Kilian:

    Support for /usr/bin/env -S (kind of)

  • Hello Theo,
    
    Theo de Raadt wrote on Tue, Jul 22, 2025 at 09:05:09AM -0600:
    > Stuart Henderson <stu@spacehopper.org> wrote:
    >> On 2025/07/22 13:12, Manuel Giraud wrote:
    >>> Crystal Kolipe <kolipe.c@exoticsilicon.com> writes:
    
    >>>> I can confirm that NetBSD does _not_ support env -S.
    
    >>> What I gather from this discussion is that it would be "nice to have"
    >>> user feature while not being standardized and potentially unsafe.  So
    >>> maybe, we should not support this.  Sorry for the noise.
    
    >> also, we didn't have to patch any instances of this in ports.
    
    > So nothing needs this now.  They don't even use the genv variation.
    > Is it actually _used_ in another operating system?
    > Can someone do the grep?
    
    https://codesearch.debian.net/search?q=env+-S&literal=1
    
    finds hits in 106 packages:
    
      aiocoap android-platform-tools apertium-nno-nob bash-unit bpftrace
      brltty calibre ceph cjs clisp containerd coreutils cpu-features
      emacs emscripten ess faiss firefox firefox-esr foot freedict-tools
      fwupd gambas3 gettext ghc gitaly gitlab gjs gmt gnome-maps gnome-shell
      gnome-shell-extension-gsconnect gnudatalanguage gnulib
      golang-github-alecthomas-chroma-v2 golang-golang-x-vuln gtk4 guile-ssh
      guix harfbuzz haskell-dhall howm hyprland identify ikiwiki
      intrusive-shared-ptr json2file-go kind kristall libfirefox-marionette-perl
      libunistring liquidsoap littler lunar-date manpages-l10n mariadb
      mawk meli mozjs128 mozjs140 mpd neovim nim nix node-speech-rule-engine
      node-undici o-saft package-lint-el pam-python parallel phcpack
      pyglossary python-aiohttp python-openai python-pdoc qt6-webengine
      qtwebengine-opensource-src radare2 rocksdb rsync rust-cargo rust-just
      rust-rpacket rust-rustls rust-rustls-platform-verifier rust-testresult
      rustc shellcheck shepherd sisu stumpwm texworks thunderbird tpm2-tools
      ts-node tuxguitar upower usbutils ustreamer vimium visidata votca
      weechat-matrix wordgrinder xelb zfs-linux
    
    A cursory look at the first few pages (of the 41 pages of results)
    gives me the impression that a significant number of these actually
    use "env -S", or suggest using it to the user - but i didn't bother
    onvestigating whether the purposes it is used for actually matter.
    On first sight, some of the uses are in test suites, for example.
    
    The fact that not having env -S didn't cause any pain for porters
    in the past tells us more than finding 106 packages with Debian
    codesearch, IMHO.
    
    I don't consider my opinion on this authoritative, but adding a
    non-standard option that might be prone to misuse to a standard
    utility does not sound very reasonable to me unless there are very
    strong reasons, and the demand seems sparse at best, so far.
    
    Yours,
      Ingo
    
    
  • Matthias Kilian:

    Support for /usr/bin/env -S (kind of)