Skip to content
This repository was archived by the owner on Jun 26, 2025. It is now read-only.

Commit af16d19

Browse files
committed
reorganize tests into demos
1 parent 0a2a989 commit af16d19

File tree

7 files changed

+13
-19
lines changed

7 files changed

+13
-19
lines changed

Makefile

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ NATIVE_LIB=$(GEN)/opencv.cmxa
2525
BYTE_LIB=$(GEN)/opencv.cma
2626
BUILT_LIBS=$(BUILD)/$(NATIVE_LIB) $(BUILD)/$(BYTE_LIB)
2727

28-
TESTS=$(wildcard tests/*)
29-
TESTS_CLEAN=$(TESTS:=.clean)
28+
DEMOS=$(wildcard demos/*)
29+
DEMOS_CLEAN=$(DEMOS:=.clean)
3030

3131
default: install
3232

@@ -66,23 +66,21 @@ install: $(INSTALLED_SHARED_LIB) libinstall
6666
docs: $(BUILT_LIBS)
6767
ocamlbuild $(FLAGS) -docflags -stars opencv.docdir/index.html
6868

69-
$(TESTS):
70-
@echo "Running test: $@"
69+
$(DEMOS): $(INSTALLED_SHARED_LIB) libinstall
70+
@echo "Running demo: $@"
7171
# clean first to guarantee that we pick up changes to the library
72-
$(MAKE) -C $@ clean test
72+
$(MAKE) -C $@ clean run
7373

74-
test: $(INSTALLED_SHARED_LIB) libinstall $(TESTS)
75-
76-
$(TESTS_CLEAN):
74+
$(DEMOS_CLEAN):
7775
# this is a stupid hack
7876
$(MAKE) -C $(basename $@) clean
7977

80-
clean: $(TESTS_CLEAN)
78+
clean: $(DEMOS_CLEAN)
8179
ocamlbuild -clean
8280
rm -f $(BUILD)/$(SHARED_LIB)
8381
rm -rf $(GEN)
8482
sudo rm -f $(INSTALLED_SHARED_LIB)
8583
ocamlfind remove $(LIB_NAME)
8684

87-
.PHONY: default sharedlib lib libinstall install docs test clean \
88-
$(TESTS) $(TESTS_CLEAN)
85+
.PHONY: default sharedlib lib libinstall install docs clean \
86+
$(DEMOS) $(DEMOS_CLEAN)
File renamed without changes.
Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
OUT=demo.native
2+
OUT=basic.native
33

44
default:
55
ocamlbuild -use-ocamlfind -pkgs opencv,owl $(OUT)
@@ -10,6 +10,4 @@ run: default
1010
clean:
1111
ocamlbuild -clean
1212

13-
test: run
14-
15-
.PHONY: default run clean test
13+
.PHONY: default run clean
File renamed without changes.
Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
OUT=demo_reuse.native
2+
OUT=reuse.native
33

44
default:
55
ocamlbuild -use-ocamlfind -pkgs opencv,owl $(OUT)
@@ -10,6 +10,4 @@ run: default
1010
clean:
1111
ocamlbuild -clean
1212

13-
test: run
14-
15-
.PHONY: default run clean test
13+
.PHONY: default run clean

0 commit comments

Comments
 (0)