Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 506522 - net-misc/tigervnc: init script: make POSIX compliant (currently uses ${!var} and arrays)
Summary: net-misc/tigervnc: init script: make POSIX compliant (currently uses ${!var} ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords: NeedPatch, PullRequest
Depends on:
Blocks: 609070
  Show dependency tree
 
Reported: 2014-04-02 09:10 UTC by Patrick Lauer
Modified: 2022-03-22 18:01 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Lauer gentoo-dev 2014-04-02 09:10:26 UTC
# rc-status
 * Caching service dependencies ...
/lib64/rc/sh/gendepends.sh: /etc/init.d/tigervnc: line 44: syntax error: bad substitution

[ebuild   R    ] net-misc/tigervnc-1.3.1  USE="nptl opengl pam xorgmodule -gnutls -java -server*" 0 kB

# readlink /bin/sh
/bin/busybox
Comment 1 SpanKY gentoo-dev 2015-12-16 19:12:57 UTC
we do not track "compatible with XXX shell", we track "is it POSIX compliant"

in this case, it is not:
        usrname=${user%%:*}
        usropts=VNC_OPTS_${usrname}
        usrdisp=${user##*:}
        usrvar=$usropts"["$usrdisp"]"
        [ -z ${!usrvar} ] && vnc_opts=$VNC_OPTS || vnc_opts=${!usrvar}

rather than use VNC_OPTS_user[disp], we could use VNC_OPTS_user_disp and `eval` to get the value
Comment 2 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-03-02 14:09:11 UTC
This makes it impossible to use this on FreeBSD.
Comment 3 Larry the Git Cow gentoo-dev 2022-03-22 18:01:21 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f94f6f15314c9a4b161efacb57042744346bc234

commit f94f6f15314c9a4b161efacb57042744346bc234
Author:     Viorel Munteanu <ceamac.paragon@gmail.com>
AuthorDate: 2022-03-22 07:27:03 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-03-22 18:01:11 +0000

    net-misc/tigervnc: Fix the init script
    
    Remove $VNC_OPTS from conf.d
    Make init script POSIX compliant
    
    Closes: https://bugs.gentoo.org/835730
    Closes: https://bugs.gentoo.org/506522
    Signed-off-by: Viorel Munteanu <ceamac.paragon@gmail.com>
    Closes: https://github.com/gentoo/gentoo/pull/24703
    Signed-off-by: Sam James <sam@gentoo.org>

 net-misc/tigervnc/files/tigervnc-1.12.0.confd      |  4 ++--
 net-misc/tigervnc/files/tigervnc-1.12.0.initd      | 28 ++++++++++------------
 ...-1.12.0-r2.ebuild => tigervnc-1.12.0-r3.ebuild} |  0
 3 files changed, 14 insertions(+), 18 deletions(-)