diff options
| author | Riley Beckett <rbeckettvt@gmail.com> | 2026-07-24 01:31:51 -0400 |
|---|---|---|
| committer | Riley Beckett <rbeckettvt@gmail.com> | 2026-07-24 01:31:51 -0400 |
| commit | cfcc59d16d7dd59a4c6470e6c94289f453d7dbb3 (patch) | |
| tree | f3fb991cd3ad9df0f5426f5af1b9f2f9d01e0d01 /snag/scripts | |
| parent | 9282991429a92d6df17213acdc49fe687f42da6c (diff) | |
basic api starter code
Diffstat (limited to 'snag/scripts')
| -rwxr-xr-x | snag/scripts/run_pkg_build.sh | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/snag/scripts/run_pkg_build.sh b/snag/scripts/run_pkg_build.sh index d48d831..3e4b867 100755 --- a/snag/scripts/run_pkg_build.sh +++ b/snag/scripts/run_pkg_build.sh @@ -2,15 +2,28 @@ # reads a package description script and runs the configure, build, and install # steps. intended only for use by snag program +if [ -z "$1" -a -z "$2" -a -z "$3" ]; then + echo "Usage: $0 <description script>" >&2 + exit 1 +fi if [ -z "$1" ]; then echo "Usage: $0 <description script>" >&2 exit 1 fi +api_send=$1 +api_recv=$2 + +# should remove +eval "printf '\x02\x00\x00\x00' >&$api_send" +IFS= read -r data 0<&"$api_recv" +echo "data=$data" + # load the description script -. $1 +. $3 # run all install steps for package configure build install +eval "printf '\x01\x00\x00\x00' >&$api_send" |
