install-category: fix for puzzles with Makefiles

- simplify outdir
- when running a Makefile in a puzzle, don't pass $(pwd) as a component of
  DESTDIR -- $tgt is an absolute path. Fixes: proto and others
This commit is contained in:
J. Patrick Avery, Jr 2015-06-03 20:06:11 -04:00
parent 7a4d2ba132
commit d6cb477dcb
1 changed files with 2 additions and 2 deletions

View File

@ -73,7 +73,7 @@ EOF
}
cat=$(basename $indir)
outdir=$(dirname $0)/../packages/$cat
outdir=$(dirname $(dirname $0))/packages/$cat
uanswers=$outdir/answers.unsorted
usummary=$outdir/summary.unsorted
umap=$outdir/map.unsorted
@ -100,7 +100,7 @@ for dn in $indir/[0-9]*; do
if [ -f $dn/Makefile ]; then
# If there's a Makefile, run make
make DESTDIR=$(pwd)/$tgt -C $dn || exit 1
make DESTDIR=$tgt -C $dn || exit 1
files=$(ls -1 $tgt | grep -v index.html || true)
elif [ -f $dn/00manifest.txt ]; then
# If there's a manifest, use that