diff --git a/patches/notes.txt b/patches/notes.txt index aaef8b4..7d6eed4 100644 --- a/patches/notes.txt +++ b/patches/notes.txt @@ -47,3 +47,8 @@ fastout.patch v2_as.patch Defines mount as _mount, gtty as _gtty, so that these symbols will not conflict with the pre-defined symbols in the V2 assembler. + +shell-s2.patch + A patch to the jun72 sh.s sources to make it build an identical + shell as the s2 /bin/sh (different only in the padding bytes). + diff --git a/patches/shell-s2.patch b/patches/shell-s2.patch new file mode 100644 index 0000000..5dfbf4f --- /dev/null +++ b/patches/shell-s2.patch @@ -0,0 +1,21 @@ +1a2,3 +> .. = 40014 +> +146a149,150 +> rts r5 +> +235,242d238 +< sys stat; binpb; inbuf / if can't execute does it +< / exist? +< bes 2f / branch if it doesn't +< mov $shell,parp-2 / does exist, not executable +< mov $binpb,parp / so it must be +< sys exec; shell; parp-2 / a command file, get it with +< / sh /bin/x (if x name of file) +< 2: +259a256,257 +> cmp r0,$'* / is it * +> beq 3f +362,363d359 +< shell: +<