Browse Source

use which to locate apps (useful for non-Linux systems like OS X)

Mike Frysinger 20 năm trước cách đây
mục cha
commit
f336cfc9db
1 tập tin đã thay đổi với 3 bổ sung3 xóa
  1. 3 3
      toolchain/binutils/binutils.mk

+ 3 - 3
toolchain/binutils/binutils.mk

@@ -58,15 +58,15 @@ $(STAGING_DIR)/$(REAL_GNU_TARGET_NAME)/bin/ld: $(BINUTILS_DIR1)/binutils/objdump
 	$(MAKE) -C $(BINUTILS_DIR1) install
 
 binutils-dependancies:
-	@if [ ! -x /usr/bin/bison ] ; then \
+	@if ! which bison ; then \
 		echo -e "\n\nYou must install 'bison' on your build machine\n"; \
 		exit 1; \
 	fi;
-	@if [ ! -x /usr/bin/flex ] ; then \
+	@if ! which flex ; then \
 		echo -e "\n\nYou must install 'flex' on your build machine\n"; \
 		exit 1; \
 	fi;
-	@if [ ! -x /usr/bin/msgfmt ] ; then \
+	@if ! which msgfmt ; then \
 		echo -e "\n\nYou must install 'gettext' on your build machine\n"; \
 		exit 1; \
 	fi;