diff options
Diffstat (limited to 'sh/platdep.sh')
-rwxr-xr-x | sh/platdep.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sh/platdep.sh b/sh/platdep.sh new file mode 100755 index 0000000..dda0588 --- /dev/null +++ b/sh/platdep.sh @@ -0,0 +1,17 @@ +#! /bin/sh + +# Of all the available platform-dependent object file sets defined in the +# working directory's make file of the form 'OBJS_...', list all those that +# could be relevant to the current platform. + +keywords=$(uname -a) + +sets="" +for k in $keywords +do + sets="$sets\n$(echo "$k" | tr '[:lower:]' '[:upper:]' | xargs -I '%' grep '^OBJS_%[ =]' Makefile)" + +done + +echo "$sets" | sort | uniq | awk '/\n\n/ { print '\n' }' + |