make: Miscellaneous versatility improvements #83
1 changed files with 1 additions and 1 deletions
pgit.sh: Allow running under any projects-dir.mk
There's a random string "some-random-string-to-id-this-makefile" in projects-dir-minimial.mk intended to check if the Makefile in the projects-directory is actually the final link target. It's re-used in pgit.sh to find the projects toplevel directory, but since it doesn't need to be an actual projects-dir-minimal.mk copy, another case should also be taken into consideration: Check if projects-dir.mk is included. Signed-off-by: Jan Lindemann <jan@janware.com>
commit
f3f0ef10ca
|
|
@ -78,7 +78,7 @@ set_global_variables()
|
|||
# If we're in a toplevel directory, suppose projects_dir == project_dirs,
|
||||
# i.e. we only want to target this Git repo
|
||||
if [ ! -d .git ]; then
|
||||
while [ ! -r Makefile ] || ! grep -q some-random-string-to-id-this-makefile Makefile; do
|
||||
while [ ! -r Makefile ] || ! grep -q 'include $(JWBDIR)/make/projects-dir\.mk\|some-random-string-to-id-this-makefile' Makefile; do
|
||||
[ "$projects_dir" = / ] && fatal "Failed to find projects directory"
|
||||
projects_dir=`dirname $projects_dir`
|
||||
done
|
||||
|
|
|
|||
Loading…
Reference in a new issue