Project

General

Profile

Bug #13522

Solaris10上で make update-rubyspec が bad substitution で失敗

Added by ngoto (Naohisa Goto) about 2 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-dev:50102]

Description

おそらく r58467 以降、またもやSolaris 10上にて make update-rubyspec が bad substitution で失敗します。
現象は [Bug #13424] と同一ですが、原因は r58467 の変更にあると思いますので新チケットにしました。

$ make update-rubyspec V=1
./tool/git-refresh -C ./spec  \
        git://github.com/ruby/mspec.git mspec
retrieving mspec ...
./tool/git-refresh: bad substitution
make: *** [update-mspec] Error 1

Solaris の /bin/sh では、${branch:+git fetch "$@"} がエラーになっているようです。

$ branch="aaa"
$ export branch
$ ${branch:+/bin/echo abc}
bad substitution
$ /bin/echo xyz ${branch:+checkout} "${branch:-pull}" tuv
xyz checkout aaa tuv
$
$ unset branch
$ ${branch:+/bin/echo abc}
bad substitution
$ /bin/echo xyz ${branch:+checkout} "${branch:-pull}" tuv
xyz pull tuv

Related issues

Related to Ruby master - Bug #13424: Solaris10上で make update-rubyspec が bad substitution で失敗ClosedActions

Associated revisions

Revision eeed8b96
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: unset variable branch if it is null, to get rid of substitutions which are not supported old Solaris. [ruby-dev:50102] [Bug #13522]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58507 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 58507
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: unset variable branch if it is null, to get rid of substitutions which are not supported old Solaris. [ruby-dev:50102] [Bug #13522]

Revision 58507
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: unset variable branch if it is null, to get rid of substitutions which are not supported old Solaris. [ruby-dev:50102] [Bug #13522]

Revision 58507
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: unset variable branch if it is null, to get rid of substitutions which are not supported old Solaris. [ruby-dev:50102] [Bug #13522]

Revision e97e093a
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: expand for each words. [ruby-dev:50102] [Bug #13522]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58512 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 58512
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: expand for each words. [ruby-dev:50102] [Bug #13522]

Revision 58512
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: expand for each words. [ruby-dev:50102] [Bug #13522]

Revision 58512
Added by nobu (Nobuyoshi Nakada) about 2 years ago

git-refresh: fix for Solaris

  • tool/git-refresh: expand for each words. [ruby-dev:50102] [Bug #13522]

History

#1

Updated by ngoto (Naohisa Goto) about 2 years ago

  • Related to Bug #13424: Solaris10上で make update-rubyspec が bad substitution で失敗 added
#2

Updated by nobu (Nobuyoshi Nakada) about 2 years ago

  • Status changed from Open to Closed

Applied in changeset trunk|r58507.


git-refresh: fix for Solaris

  • tool/git-refresh: unset variable branch if it is null, to get rid of substitutions which are not supported old Solaris. [ruby-dev:50102] [Bug #13522]

Updated by ngoto (Naohisa Goto) about 2 years ago

  • Status changed from Closed to Open

bad substitution でエラーになるのは変わらないため再オープンします。

Solaris の /bin/sh では、以下のように、${branch+echo} のようにスペースが入っていなければOK、${branch+echo abc} のようにスペースが入っていると bad substitution でアウト、になります。説明不足ですみませんでした。
つまり、r58507 では本質ではない場所が変更されていますが、肝心の「${branch+git fetch "$@"}」や「${branch+--branch "$branch"}」の部分が実質そのままでエラー解消には至らず、でした。

$ var=pqr
$ branch=xyz
$ ${branch+echo aaa}
bad substitution
$ ${branch+echo} aaa
aaa
$ echo ${branch+${var}}
pqr
$ echo ${branch-${var}}
xyz
$ unset branch
$ ${branch+echo aaa}
bad substitution
$ ${branch+echo} aaa
aaa: not found
$ echo ${branch+${var}}

$ echo ${branch-${var}}
pqr
#4

Updated by nobu (Nobuyoshi Nakada) about 2 years ago

  • Status changed from Open to Closed

Applied in changeset trunk|r58512.


git-refresh: fix for Solaris

  • tool/git-refresh: expand for each words. [ruby-dev:50102] [Bug #13522]

Also available in: Atom PDF