aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--testcase/find_command.mk8
1 files changed, 8 insertions, 0 deletions
diff --git a/testcase/find_command.mk b/testcase/find_command.mk
index 54c2c07..89b3dcf 100644
--- a/testcase/find_command.mk
+++ b/testcase/find_command.mk
@@ -1,5 +1,11 @@
# TODO(go): This test is only for ckati.
+ifeq ($(shell uname),Darwin)
+USE_GNU_FIND:=
+else
+USE_GNU_FIND:=1
+endif
+
define run_find
@echo $$ '$(strip $(1))'
@echo $(sort $(shell $(1)))
@@ -23,11 +29,13 @@ test2:
@echo no options
$(call run_find, find testdir)
$(call run_find, find .)
+ifeq ($(USE_GNU_FIND),1)
$(call run_find, find ./)
$(call run_find, find .///)
$(call run_find, find )
$(call run_find, find ./.)
$(call run_find, find ././)
+endif
$(call run_find, find testdir/../testdir)
@echo print
$(call run_find, find testdir -print)