#!/bin/sh
# xsubpkg [-m] PKG - lists all subpackages of a package

followsym="-L"

case "$1" in
	-m) followsym="-P"; shift
esac

PKG=$1
cd $(xdistdir)
find $followsym srcpkgs -maxdepth 2 -samefile srcpkgs/"$PKG"/template | cut -d/ -f 2
