mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-03-09 15:50:02 +00:00
bin/package: reallow building old ksh versions (re: 6cc2f6a0
)
When building old code for debugging purposes (e.g. when doing 'git
bisect' runs), it's best to use the current build system even with
the old code, because the old build system was very broken. E.g.:
git checkout (some old commit)
git checkout master bin src/cmd/INIT # use new build system
bin/package make
However, that became impossible in 6cc2f6a0
because the new
SHOPT.sh script was unconditionally sourced. The error caused the
script to exit because '.' is a special builtin.
bin/package, src/cmd/INIT/package.sh:
- If src/cmd/ksh93/SHOPT.sh doesn't exist, issue a warning instasd
of trying to source it.
This commit is contained in:
parent
e3f6d2d0e6
commit
c2108888df
3 changed files with 11 additions and 3 deletions
|
@ -47,7 +47,7 @@ Though there are many bugs left to fix, we are confident at this point that
|
|||
## Build
|
||||
|
||||
To build ksh with a custom configuration of features, edit
|
||||
[`src/cmd/ksh93/SHOPT.sh`](/ksh93/ksh/blob/master/src/cmd/ksh93/SHOPT.sh).
|
||||
[`src/cmd/ksh93/SHOPT.sh`](https://github.com/ksh93/ksh/blob/master/src/cmd/ksh93/SHOPT.sh).
|
||||
|
||||
Then `cd` to the top directory and run:
|
||||
```sh
|
||||
|
|
|
@ -1436,7 +1436,11 @@ SHOPT()
|
|||
esac
|
||||
}
|
||||
ksh_shoptflags=
|
||||
. src/cmd/ksh93/SHOPT.sh # this script calls SHOPT() to set options
|
||||
shopt_sh='src/cmd/ksh93/SHOPT.sh' # this script calls SHOPT() to set options
|
||||
if test -f "$shopt_sh"
|
||||
then . "$shopt_sh"
|
||||
else echo "WARNING: $shopt_sh is missing" >&2
|
||||
fi
|
||||
case $ksh_shoptflags in
|
||||
?*) # add the extra flags as an argument to mamake
|
||||
assign="${assign:+$assign }KSH_SHOPTFLAGS=\"\$ksh_shoptflags\"" ;;
|
||||
|
|
|
@ -1435,7 +1435,11 @@ SHOPT()
|
|||
esac
|
||||
}
|
||||
ksh_shoptflags=
|
||||
. src/cmd/ksh93/SHOPT.sh # this script calls SHOPT() to set options
|
||||
shopt_sh='src/cmd/ksh93/SHOPT.sh' # this script calls SHOPT() to set options
|
||||
if test -f "$shopt_sh"
|
||||
then . "$shopt_sh"
|
||||
else echo "WARNING: $shopt_sh is missing" >&2
|
||||
fi
|
||||
case $ksh_shoptflags in
|
||||
?*) # add the extra flags as an argument to mamake
|
||||
assign="${assign:+$assign }KSH_SHOPTFLAGS=\"\$ksh_shoptflags\"" ;;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue