[Bug 268479] lib/libc/stdlib/getenv.c may have a problem with putenv()

[email protected]
Newsgroups gmane.os.freebsd.devel.standards
Message-ID <[email protected]/bugzilla/>
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=268479

--- Comment #4 from Mark Millard <[email protected]> ---
(In reply to Dennis Clarke from comment #3)

FreeBSD and poudriere depend on using UNAME_[rvmp]= . . .
assignments, expecting the relevant changes to appear
in the specific activities targetted:

# grep -r UNAME_ /usr/local/share/poudriere/
/usr/local/share/poudriere/jail.sh:                 -e
's#:\(setenv.*\),UNAME_r=.*UNAME_v=FreeBSD.*,OSVERSION=[^:,]*\([,:]\)#:\1\2#' \
/usr/local/share/poudriere/jail.sh:                 -e
's#:\(setenv.*\),UNAME_m=.*,UNAME_p=[^:,]*\([,:]\)#:\1\2#' \
/usr/local/share/poudriere/common.sh:   login_env=",UNAME_r=${version%
*},UNAME_v=FreeBSD ${version},OSVERSION=${osversion}"
/usr/local/share/poudriere/common.sh:          
login_env="${login_env},UNAME_m=${arch%.*},UNAME_p=${arch#*.}"
/usr/local/share/poudriere/common.sh:   sed -i "" -e "s/,UNAME_r.*:/:/ ;
s/:\(setenv.*\):/:\1${login_env}:/" \
/usr/local/share/poudriere/common.sh:   export "UNAME_r=${version% *}"
/usr/local/share/poudriere/common.sh:   export "UNAME_v=FreeBSD ${version}"
/usr/local/share/poudriere/common.sh:   export "UNAME_m=${arch%.*}"
/usr/local/share/poudriere/common.sh:   export "UNAME_p=${arch#*.}"
/usr/local/share/poudriere/common.sh:   unset UNAME_r
/usr/local/share/poudriere/common.sh:   unset UNAME_v
/usr/local/share/poudriere/common.sh:   unset UNAME_m
/usr/local/share/poudriere/common.sh:   unset UNAME_p

# grep -r "UNAME_[rvmp]" /usr/main-src/ | more
/usr/main-src/release/Makefile.gce:     env UNAME_r=${UNAME_r} make -C
${PORTSDIR}/net/google-cloud-sdk BATCH=1 all install clean
/usr/main-src/release/release.sh:                      
UNAME_r=${REVISION}-${BRANCH}
/usr/main-src/release/release.sh:                      
PBUILD_FLAGS="${PBUILD_FLAGS} UNAME_r=${UNAME_r}"
/usr/main-src/release/release.sh:               UNAME_r=${REVISION}-${BRANCH}
/usr/main-src/release/release.sh:               PBUILD_FLAGS="${PBUILD_FLAGS}
UNAME_r=${UNAME_r}"
/usr/main-src/release/Makefile.inc1:# Override UNAME_r to allow building ports
for a different branch.
/usr/main-src/release/Makefile.inc1:UNAME_r=    ${REVISION}-${BRANCH}
/usr/main-src/release/Makefile.inc1:.export UNAME_r
/usr/main-src/release/Makefile.ec2:     env - UNAME_r=${UNAME_r} PATH=$$PATH
make -C ${PORTSDIR}/net/bsdec2-image-upload BATCH=1 all install clean
/usr/main-src/release/Makefile.vagrant: env UNAME_r=${UNAME_r} make -C
${PORTSDIR}/ftp/curl BATCH=1 all install clean
/usr/main-src/release/Makefile.azure:   env UNAME_r=${UNAME_r} make -C
${PORTSDIR}/sysutils/py-azure-cli BATCH=1 all install clean
/usr/main-src/release/Makefile.vm:      env - UNAME_r=${UNAME_r} PATH=$$PATH
make -C ${PORTSDIR}/emulators/qemu-user-static BATCH=1 all install clean
/usr/main-src/release/tools/arm.subr:   export UNAME_r=${REVISION}-${BRANCH}
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:        UNAME_r=$1
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:        if echo
${UNAME_r} | grep -qE '^[0-9.]+$'; then
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:               
UNAME_r="${UNAME_r}-RELEASE"
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:        export UNAME_r
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:       
UNAME_r=$(freebsd-version -j ${JAIL})
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:        if [ -z
${BASEDIR} ] || [ -z ${UNAME_r} ]; then
/usr/main-src/usr.sbin/freebsd-update/freebsd-update.sh:        export UNAME_r
/usr/main-src/lib/libc/gen/__xuname.c:  if ((p = getenv("UNAME_r")))
/usr/main-src/lib/libc/gen/__xuname.c:  if ((p = getenv("UNAME_v")))
/usr/main-src/lib/libc/gen/__xuname.c:  if ((p = getenv("UNAME_m")))
/usr/main-src/lib/libc/gen/uname.3:.It Ev UNAME_r
/usr/main-src/lib/libc/gen/uname.3:.Ev UNAME_r
/usr/main-src/lib/libc/gen/uname.3:.It Ev UNAME_v
/usr/main-src/lib/libc/gen/uname.3:.Ev UNAME_v
/usr/main-src/lib/libc/gen/uname.3:.It Ev UNAME_m
/usr/main-src/lib/libc/gen/uname.3:.Ev UNAME_m
/usr/main-src/tools/test/stress2/misc/ldt2.sh:1) Install wine. For example by
"UNAME_m=i386 pkg_add -r wine"
/usr/main-src/tools/test/stress2/misc/ldt2.sh:Remember to set the environment
variable UNAME_m to "i386".
/usr/main-src/tools/tools/nanobsd/dhcpd/common: CR "env UNAME_p=${NANO_ARCH}
TARGET=${NANO_ARCH} \

For what purpose do you want to avoid tracking what FreeBSD
is deliberately doing that controls FreeBSD's its later
behavior for some specific activity?

-- 
You are receiving this mail because:
You are the assignee for the bug.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.