Skip to content

Commit 1fe0254

Browse files
committed
Enabling examples thatw we're actually interested in
1 parent 6edb041 commit 1fe0254

File tree

2 files changed

+33
-0
lines changed

2 files changed

+33
-0
lines changed

Makefile

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
examples: simple-ctx simple-backend mnist-eval mnist-train
2+
@echo Done making examples
3+
4+
simple-ctx: ggml/examples/simple/simple-ctx.cpp libggml.a \
5+
$(OBJ_ALL)
6+
$(CXX) $(CXXFLAGS) -c $< -o $(call GET_OBJ_FILE, $<)
7+
$(CXX) $(CXXFLAGS) $(filter-out %.h $<,$^) $(call GET_OBJ_FILE, $<) libggml.a -o $@ $(LDFLAGS)
8+
9+
simple-backend: ggml/examples/simple/simple-backend.cpp libggml.a \
10+
$(OBJ_ALL)
11+
$(CXX) $(CXXFLAGS) -c $< -o $(call GET_OBJ_FILE, $<)
12+
$(CXX) $(CXXFLAGS) $(filter-out %.h $<,$^) $(call GET_OBJ_FILE, $<) libggml.a -o $@ $(LDFLAGS)
13+
14+
mnist-eval: ggml/examples/mnist/mnist-eval.cpp ggml/examples/mnist/mnist-common.cpp libggml.a \
15+
$(OBJ_ALL)
16+
$(CXX) $(CXXFLAGS) -c $< -o $(call GET_OBJ_FILE, $<)
17+
$(CXX) $(CXXFLAGS) $(filter-out %.h $<,$^) $(call GET_OBJ_FILE, $<) libggml.a -o $@ $(LDFLAGS)
18+
19+
mnist-train: ggml/examples/mnist/mnist-train.cpp ggml/examples/mnist/mnist-common.cpp libggml.a \
20+
$(OBJ_ALL)
21+
$(CXX) $(CXXFLAGS) -c $< -o $(call GET_OBJ_FILE, $<)
22+
$(CXX) $(CXXFLAGS) $(filter-out %.h $<,$^) $(call GET_OBJ_FILE, $<) libggml.a -o $@ $(LDFLAGS)
23+
24+
125
# Define the default target now so that it is always the first target
226
BUILD_TARGETS = \
327
libllava.a \

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# How to get going
2+
3+
```
4+
$ git clone https://github.com/aifoundry-org/ggmlux
5+
$ cd ggmlux
6+
$ git submodule update
7+
$ make LLAMA_DEBUG=1 GGML_NO_LLAMAFILE=1 -j examples
8+
$ ./simple-ctx
9+
```

0 commit comments

Comments
 (0)