| 1 | cd "${PREFIX}" |
| 2 | umask 022 |
| 3 | |
| 4 | mkdir -p bin lib libexec share/terminfo |
| 5 | mkdir -p lib/{python3.10,alibrary} |
| 6 | |
| 7 | echo -e '#/bin/sh\necho hello world' > bin/hello-1.0 |
| 8 | chmod 755 bin/hello-1.0 |
| 9 | |
| 10 | echo -n "" >share/terminfo/xterm.dat |
| 11 | chmod 644 share/terminfo/xterm.dat |
| 12 | |
| 13 | echo -n "" >lib/alibrary/alib.lib |
| 14 | echo -n "" >lib/python3.10/amodule.py |
| 15 | |
| 16 | # Tests for symlink... |
| 17 | pushd bin >/dev/null |
| 18 | ln -sn hello-1.0 hello # ...to file in same dir |
| 19 | popd >/dev/null |
| 20 | |
| 21 | pushd libexec >/dev/null |
| 22 | ln -sn ../bin/hello greetings # ...to file in another dir |
| 23 | popd >/dev/null |
| 24 | |
| 25 | pushd share >/dev/null |
| 26 | ln -sn terminfo termcap # ...to subdir in same dir |
| 27 | popd >/dev/null |
| 28 | |
| 29 | pushd lib >/dev/null |
| 30 | ln -sn alibrary alib # ...to subdir in same dir |
| 31 | ln -sn python3.10 python3.1 # ...to subdir in same dir |
| 32 | ln -sn ../share/terminfo terminfo # ...to subdir of another dir |
| 33 | ln -sn libdangle.lib.1 libdangle.lib # ...dangling link |
| 34 | popd >/dev/null |