-
-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathMakefile
More file actions
554 lines (502 loc) · 19.2 KB
/
Copy pathMakefile
File metadata and controls
554 lines (502 loc) · 19.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
# Makefile for gollama.cpp
# Cross-platform Go bindings for llama.cpp using purego
# Version information
VERSION ?= 0.2.3
LLAMA_CPP_BUILD ?= b6862
FULL_VERSION = v$(VERSION)-llamacpp.$(LLAMA_CPP_BUILD)
# Check everything
.PHONY: check
check: fmt vet lint sec test
# Package releases
# Go configuration
GO ?= go
GOOS ?= $(shell go env GOOS)
GOARCH ?= $(shell go env GOARCH)
# Build directories
BUILD_DIR = build
DIST_DIR = dist
EXAMPLES_DIR = examples
# llama.cpp configuration
LLAMA_CPP_DIR = $(BUILD_DIR)/llama.cpp
LLAMA_CPP_REPO = https://github.com/ggerganov/llama.cpp.git
# Platform-specific configurations
PLATFORMS = darwin/amd64 darwin/arm64 linux/amd64 linux/arm64 windows/amd64 windows/arm64
# Default target
.PHONY: all
all: build
# Clean everything
.PHONY: clean
clean:
rm -rf $(BUILD_DIR) $(DIST_DIR)
$(GO) clean -cache
# Clean libraries only
.PHONY: clean-libs
clean-libs:
@echo "Cleaning library cache..."
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -clean-cache
# Initialize/update dependencies
.PHONY: deps
deps:
$(GO) mod download
$(GO) mod tidy
# Build for current platform
.PHONY: build
build: deps
@echo "Building gollama.cpp for $(GOOS)/$(GOARCH)"
mkdir -p $(BUILD_DIR)/$(GOOS)_$(GOARCH)
GOOS=$(GOOS) GOARCH=$(GOARCH) $(GO) build -o $(BUILD_DIR)/$(GOOS)_$(GOARCH)/ ./...
# Build for all platforms
.PHONY: build-all
build-all: deps
@for platform in $(PLATFORMS); do \
os=$$(echo $$platform | cut -d'/' -f1); \
arch=$$(echo $$platform | cut -d'/' -f2); \
echo "Building for $$os/$$arch"; \
mkdir -p $(BUILD_DIR)/$$os\_$$arch; \
GOOS=$$os GOARCH=$$arch $(GO) build -o $(BUILD_DIR)/$$os\_$$arch/ ./...; \
done
# Build examples
.PHONY: build-examples
build-examples: build
@echo "Building examples"
cd $(EXAMPLES_DIR) && $(GO) build ./...
# Test with library download
.PHONY: test
test: deps download-libs
@echo "Running tests (libraries will be downloaded automatically)"
$(GO) test -v -p 1 -failfast -timeout 120s -tags embedallowed_no -coverprofile=coverage.out -cover ./... && \
$(GO) tool cover -func=coverage.out | grep total: | awk '{print "Total coverage: " $$3}'
# Test with race detection
.PHONY: test-race
test-race: deps
@echo "Running tests with race detection"
$(GO) test -race -v ./...
# Test library download functionality
.PHONY: test-download
test-download: deps
@echo "Testing library download functionality"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -test-download
# Test GPU detection and backend functionality
.PHONY: test-gpu
test-gpu: deps
@echo "Testing GPU detection and backend functionality"
$(GO) test -v -run TestGpu ./...
make detect-gpu
# Run platform-specific tests
.PHONY: test-platform
test-platform:
@echo "Running platform-specific tests"
$(GO) test -v -run TestPlatformSpecific ./...
# Test cross-compilation for all platforms
.PHONY: test-cross-compile
test-cross-compile:
@echo "Testing cross-compilation for all platforms..."
@for platform in $(PLATFORMS); do \
GOOS=$$(echo $$platform | cut -d'/' -f1); \
GOARCH=$$(echo $$platform | cut -d'/' -f2); \
echo "Building for $$GOOS/$$GOARCH..."; \
env GOOS=$$GOOS GOARCH=$$GOARCH $(GO) build -v ./... || exit 1; \
done
@echo "All cross-compilation tests passed!"
# Test library download for specific platforms
.PHONY: test-download-platforms
test-download-platforms:
@echo "Testing library download for different platforms..."
@for platform in $(PLATFORMS); do \
GOOS=$$(echo $$platform | cut -d'/' -f1); \
GOARCH=$$(echo $$platform | cut -d'/' -f2); \
echo "Testing download for $$GOOS/$$GOARCH..."; \
env GOOS=$$GOOS GOARCH=$$GOARCH $(GO) run ./cmd/gollama-download -test-download || echo "Download test for $$GOOS/$$GOARCH completed"; \
done
# Download and verify libraries for current platform
.PHONY: download-libs
download-libs: deps
@echo "Downloading llama.cpp libraries for $(GOOS)/$(GOARCH)"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -download -download-variants -version $(LLAMA_CPP_BUILD)
# Download libraries for all platforms (for testing)
.PHONY: download-libs-all
download-libs-all: deps
@echo "Downloading llama.cpp libraries for all platforms"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -download-all -download-variants -version $(LLAMA_CPP_BUILD)
# Download libraries for all platforms with parallel processing
.PHONY: download-libs-parallel
download-libs-parallel: deps
@echo "Downloading llama.cpp libraries for all platforms (parallel)"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -download-all -version $(LLAMA_CPP_BUILD) -checksum
# Download libraries for specific platforms
.PHONY: download-libs-platforms
download-libs-platforms: deps
@echo "Downloading llama.cpp libraries for specific platforms"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -platforms "linux/amd64,darwin/arm64,windows/amd64" -version $(LLAMA_CPP_BUILD) -checksum
# Populate embedded libs directory with the configured llama.cpp build
.PHONY: populate-libs
populate-libs: deps
@echo "Synchronizing embedded libraries in ./libs for llama.cpp $(LLAMA_CPP_BUILD)"
env GOOS= GOARCH= $(GO) run ./cmd/gollama-download -download-all -download-variants -version $(LLAMA_CPP_BUILD) -copy-libs -libs-dir libs
# Test compilation for specific platform
.PHONY: test-compile-windows
test-compile-windows:
@echo "Testing Windows compilation"
GOOS=windows GOARCH=amd64 $(GO) build -v ./...
GOOS=windows GOARCH=arm64 $(GO) build -v ./...
.PHONY: test-compile-linux
test-compile-linux:
@echo "Testing Linux compilation"
GOOS=linux GOARCH=amd64 $(GO) build -v ./...
GOOS=linux GOARCH=arm64 $(GO) build -v ./...
.PHONY: test-compile-darwin
test-compile-darwin:
@echo "Testing macOS compilation"
GOOS=darwin GOARCH=amd64 $(GO) build -v ./...
GOOS=darwin GOARCH=arm64 $(GO) build -v ./...
# Benchmark
.PHONY: bench
bench: deps
@echo "Running benchmarks (libraries will be downloaded automatically)"
$(GO) test -bench=. -benchmem ./...
# Lint
.PHONY: lint
lint:
@echo "Running linter"
$(GO) run github.com/golangci/golangci-lint/cmd/golangci-lint@latest run
# Format code
.PHONY: fmt
fmt:
@echo "Formatting code"
$(GO) fmt ./...
# Vet code
.PHONY: vet
vet:
@echo "Vetting code"
$(GO) vet ./...
# Security check
.PHONY: sec
sec:
@echo "Running security check"
$(GO) run github.com/securego/gosec/v2/cmd/gosec@latest -exclude=G103,G104,G115,G304 -severity=medium ./...
# Check everything
.PHONY: check
check: fmt vet lint sec test
# GPU Detection Logic
.PHONY: detect-gpu
detect-gpu:
@echo "Detecting available GPU backends..."
@echo "Platform: $(GOOS)/$(GOARCH)"
@if command -v nvcc >/dev/null 2>&1; then \
echo "✅ CUDA detected (nvcc found)"; \
nvcc --version 2>/dev/null | head -1 || echo " Version info not available"; \
else \
echo "❌ CUDA not detected"; \
fi
@if command -v hipconfig >/dev/null 2>&1; then \
echo "✅ HIP/ROCm detected (hipconfig found)"; \
hipconfig --version 2>/dev/null || echo " Version info not available"; \
else \
echo "❌ HIP/ROCm not detected"; \
fi
@if command -v vulkaninfo >/dev/null 2>&1; then \
echo "✅ Vulkan detected (vulkaninfo found)"; \
vulkaninfo --summary 2>/dev/null | head -5 || echo " Summary not available"; \
else \
echo "❌ Vulkan not detected"; \
fi
@if command -v clinfo >/dev/null 2>&1; then \
echo "✅ OpenCL detected (clinfo found)"; \
clinfo --list 2>/dev/null | head -10 || echo " Device list not available"; \
else \
echo "❌ OpenCL not detected"; \
fi
@if command -v sycl-ls >/dev/null 2>&1; then \
echo "✅ SYCL detected (sycl-ls found)"; \
sycl-ls 2>/dev/null || echo " Device list not available"; \
else \
echo "❌ SYCL not detected"; \
fi
@if [ "$(GOOS)" = "darwin" ]; then \
if system_profiler SPDisplaysDataType 2>/dev/null | grep -q "Metal"; then \
echo "✅ Metal detected"; \
else \
echo "❌ Metal not detected"; \
fi \
fi
# Clone llama.cpp repository for cross-reference checks
.PHONY: clone-llamacpp
clone-llamacpp:
@if [ ! -d "$(LLAMA_CPP_DIR)" ]; then \
echo "Cloning llama.cpp repository for cross-reference"; \
mkdir -p $(BUILD_DIR); \
git clone $(LLAMA_CPP_REPO) $(LLAMA_CPP_DIR); \
fi
@echo "Checking out build $(LLAMA_CPP_BUILD)"
cd $(LLAMA_CPP_DIR) && git fetch && git checkout $(LLAMA_CPP_BUILD)
@echo "Copying hf.sh script if different or missing"
@if [ ! -f "scripts/hf.sh" ] || ! cmp -s "$(LLAMA_CPP_DIR)/scripts/hf.sh" "scripts/hf.sh"; then \
echo "Copying hf.sh from llama.cpp/scripts/"; \
cp "$(LLAMA_CPP_DIR)/scripts/hf.sh" "scripts/hf.sh"; \
chmod +x "scripts/hf.sh"; \
echo "hf.sh script updated"; \
else \
echo "hf.sh script is already up to date"; \
fi
# Update hf.sh script from llama.cpp repository
.PHONY: update-hf-script
update-hf-script: clone-llamacpp
@echo "Forcing update of hf.sh script from llama.cpp"
@if [ -f "$(LLAMA_CPP_DIR)/scripts/hf.sh" ]; then \
cp "$(LLAMA_CPP_DIR)/scripts/hf.sh" "scripts/hf.sh"; \
chmod +x "scripts/hf.sh"; \
echo "hf.sh script updated from llama.cpp build $(LLAMA_CPP_BUILD)"; \
else \
echo "Error: hf.sh script not found in llama.cpp repository"; \
exit 1; \
fi
# Automated tag and release
.PHONY: tag-release
tag-release:
@echo "Starting automated tag and release process..."
@starting_commit=$$(git rev-parse HEAD); \
current_branch=$$(git rev-parse --abbrev-ref HEAD); \
if [ "$$current_branch" != "main" ]; then \
echo "Error: tag-release can only be run from the main branch. Current branch: $$current_branch"; \
exit 1; \
fi; \
echo "Checking if main branch is up to date with origin..."; \
git fetch origin main >/dev/null 2>&1; \
local_commit=$$(git rev-parse HEAD); \
remote_commit=$$(git rev-parse origin/main); \
if [ "$$local_commit" != "$$remote_commit" ]; then \
echo "Error: Local main branch is not up to date with origin/main"; \
echo "Local: $$local_commit"; \
echo "Remote: $$remote_commit"; \
echo "Please pull latest changes: git pull origin main"; \
exit 1; \
fi; \
echo "Updating CHANGELOG.md for release $(FULL_VERSION)..."; \
if ! bash scripts/update-changelog.sh "$(FULL_VERSION)" "release"; then \
echo "Error: Failed to update CHANGELOG.md"; \
exit 1; \
fi; \
echo "CHANGELOG.md updated successfully"; \
echo "Committing CHANGELOG.md update..."; \
git add CHANGELOG.md; \
if ! git commit -m ":rocket: chore(release): update CHANGELOG.md for $(FULL_VERSION)"; then \
echo "Error: Failed to commit CHANGELOG.md"; \
git reset --hard $$starting_commit; \
exit 1; \
fi; \
echo "CHANGELOG.md committed successfully"; \
tag_name="$(FULL_VERSION)"; \
echo "Checking if tag $$tag_name exists..."; \
tag_existed=false; \
if git tag -l | grep -q "^$$tag_name$$"; then \
echo "Tag $$tag_name already exists"; \
tag_existed=true; \
echo "Checking if GitHub release exists for tag $$tag_name..."; \
if command -v gh >/dev/null 2>&1; then \
if gh release view $$tag_name >/dev/null 2>&1; then \
echo "GitHub release already exists for tag $$tag_name"; \
echo "Will move tag to current HEAD after all steps complete"; \
else \
echo "Tag exists but no GitHub release found"; \
fi; \
else \
echo "Warning: GitHub CLI (gh) not found. Cannot check for existing releases."; \
fi; \
git tag -d $$tag_name; \
fi; \
echo "Creating tag $$tag_name..."; \
if ! git tag $$tag_name HEAD; then \
echo "Error: Failed to create tag $$tag_name"; \
git reset --hard $$starting_commit; \
exit 1; \
fi; \
echo "Tag $$tag_name created locally"; \
echo "Incrementing patch version for next development cycle..."; \
if ! bash scripts/increment-version.sh patch; then \
echo "Error: Failed to increment version"; \
git tag -d $$tag_name; \
if [ "$$tag_existed" = "true" ]; then \
git push origin :refs/tags/$$tag_name 2>/dev/null || true; \
fi; \
git reset --hard $$starting_commit; \
exit 1; \
fi; \
echo "Version incremented successfully"; \
echo "Adding new [Unreleased] section to CHANGELOG.md..."; \
new_version=$$(echo $(VERSION) | awk -F. '{print $$1"."$$2"."$$3+1}'); \
new_full_version="v$$new_version-llamacpp.$(LLAMA_CPP_BUILD)"; \
if ! bash scripts/update-changelog.sh "$$new_full_version" "unreleased"; then \
echo "Error: Failed to add [Unreleased] section to CHANGELOG.md"; \
git tag -d $$tag_name; \
if [ "$$tag_existed" = "true" ]; then \
git push origin :refs/tags/$$tag_name 2>/dev/null || true; \
fi; \
git reset --hard $$starting_commit; \
exit 1; \
fi; \
echo "[Unreleased] section added successfully"; \
echo "All steps completed successfully. Pushing changes to origin..."; \
if ! git push origin main; then \
echo "Error: Failed to push CHANGELOG commit to origin"; \
git tag -d $$tag_name; \
if [ "$$tag_existed" = "true" ]; then \
git push origin :refs/tags/$$tag_name 2>/dev/null || true; \
fi; \
git reset --hard $$starting_commit; \
exit 1; \
fi; \
echo "CHANGELOG commit pushed successfully"; \
if [ "$$tag_existed" = "true" ]; then \
echo "Deleting remote tag $$tag_name..."; \
if ! git push origin :refs/tags/$$tag_name; then \
echo "Warning: Failed to delete remote tag $$tag_name"; \
fi; \
fi; \
if ! git push origin $$tag_name; then \
echo "Error: Failed to push tag $$tag_name to origin"; \
echo "CHANGELOG commit was pushed, but tag push failed"; \
echo "Manual intervention may be required"; \
exit 1; \
fi; \
echo "Tag $$tag_name pushed successfully"; \
echo "Waiting for GitHub Actions to process the tag and create release artifacts..."; \
echo "You can monitor the progress at: https://github.com/$$(git config --get remote.origin.url | sed 's/.*github.com[:/]\([^/]*\/[^/]*\)\.git/\1/')/actions"; \
echo ""; \
echo "Tag and release process completed successfully!"; \
echo "Released version: $(FULL_VERSION)"; \
echo "Next development version: $$new_full_version"
# Package releases
.PHONY: release
release: clean build-all
@echo "Creating release packages"
mkdir -p $(DIST_DIR)
@for platform in $(PLATFORMS); do \
os=$$(echo $$platform | cut -d'/' -f1); \
arch=$$(echo $$platform | cut -d'/' -f2); \
echo "Packaging $$os/$$arch"; \
pkg_name="gollama.cpp-$(FULL_VERSION)-$$os-$$arch"; \
mkdir -p $(DIST_DIR)/$$pkg_name; \
cp -r $(BUILD_DIR)/$$os\_$$arch/* $(DIST_DIR)/$$pkg_name/ 2>/dev/null || true; \
cp README.md LICENSE CHANGELOG.md $(DIST_DIR)/$$pkg_name/; \
cd $(DIST_DIR) && zip -r $$pkg_name.zip $$pkg_name && rm -rf $$pkg_name; \
done
# Quick release for current platform
.PHONY: release-current
release-current: clean build
@echo "Creating release package for $(GOOS)/$(GOARCH)"
mkdir -p $(DIST_DIR)
pkg_name="gollama.cpp-$(FULL_VERSION)-$(GOOS)-$(GOARCH)"
mkdir -p $(DIST_DIR)/$$pkg_name
cp -r $(BUILD_DIR)/$(GOOS)_$(GOARCH)/* $(DIST_DIR)/$$pkg_name/ 2>/dev/null || true
cp README.md LICENSE CHANGELOG.md $(DIST_DIR)/$$pkg_name/
cd $(DIST_DIR) && zip -r $$pkg_name.zip $$pkg_name && rm -rf $$pkg_name
@echo "Release package created: $(DIST_DIR)/$$pkg_name.zip"
# Install development tools
.PHONY: install-tools
install-tools:
@echo "Installing development tools"
$(GO) install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
$(GO) install github.com/securego/gosec/v2/cmd/gosec@latest
# Download model file using hf.sh script
.PHONY: model_download
model_download:
@echo "Downloading models using hf.sh script"
@mkdir -p models
@if [ ! -f "scripts/hf.sh" ]; then \
echo "Error: hf.sh script not found. Run 'make clone-llamacpp' first."; \
exit 1; \
fi
@if [ ! -f "models/tinyllama-1.1b-chat-v1.0.Q2_K.gguf" ]; then \
echo "Downloading TinyLlama model using hf.sh..."; \
bash scripts/hf.sh --repo TheBloke/TinyLlama-1.1B-Chat-v1.0-GGUF --file tinyllama-1.1b-chat-v1.0.Q2_K.gguf --outdir models; \
echo "TinyLlama model downloaded successfully"; \
else \
echo "TinyLlama model already exists in models/tinyllama-1.1b-chat-v1.0.Q2_K.gguf"; \
fi
@if [ ! -f "models/gritlm-7b_q4_1.gguf" ]; then \
echo "Downloading GritLM model using hf.sh..."; \
bash scripts/hf.sh --repo cohesionet/GritLM-7B_gguf --file gritlm-7b_q4_1.gguf --outdir models; \
echo "GritLM model downloaded successfully"; \
else \
echo "GritLM model already exists in models/gritlm-7b_q4_1.gguf"; \
fi
# Roadmap management
.PHONY: roadmap-update
roadmap-update:
@echo "Updating ROADMAP.md last updated date"
@bash scripts/roadmap-update.sh update-date
.PHONY: roadmap-validate
roadmap-validate:
@echo "Validating ROADMAP.md format and content"
@bash scripts/roadmap-update.sh validate
.PHONY: roadmap-scan
roadmap-scan:
@echo "Scanning for potential roadmap items in code"
@bash scripts/roadmap-update.sh scan-todos
.PHONY: roadmap-scan-missing
roadmap-scan-missing:
@echo "Scanning for code that depends on missing llama.cpp functions"
@bash scripts/roadmap-update.sh scan-missing
.PHONY: roadmap-scan-purego
roadmap-scan-purego:
@echo "Scanning for code that depends on purego struct support"
@bash scripts/roadmap-update.sh scan-purego
# Show version information
.PHONY: version
version:
@echo "Gollama.cpp Version: $(VERSION)"
@echo "llama.cpp Build: $(LLAMA_CPP_BUILD)"
@echo "Full Version: $(FULL_VERSION)"
# Help
.PHONY: help
help:
@echo "Gollama.cpp Makefile"
@echo ""
@echo "Main targets:"
@echo " build Build for current platform"
@echo " build-all Build for all platforms"
@echo " build-examples Build examples"
@echo " test Run tests (downloads libraries automatically)"
@echo " test-race Run tests with race detection"
@echo " bench Run benchmarks"
@echo " clean Clean all build artifacts"
@echo ""
@echo "Library management:"
@echo " download-libs Download llama.cpp libraries for current platform"
@echo " download-libs-all Download llama.cpp libraries for all platforms"
@echo " test-download Test library download functionality"
@echo " test-download-platforms Test downloads for all platforms"
@echo " populate-libs Download all platforms and synchronize embedded libs directory"
@echo " clean-libs Clean library cache (forces re-download)"
@echo ""
@echo "Quality assurance:"
@echo " check Run all checks (fmt, vet, lint, sec, test)"
@echo " fmt Format code"
@echo " vet Vet code"
@echo " lint Run linter"
@echo " sec Run security check"
@echo ""
@echo "Release:"
@echo " release Create release packages for all platforms"
@echo " release-current Create release package for current platform"
@echo " tag-release Automated tag and release (main branch only)"
@echo ""
@echo "Utilities:"
@echo " deps Update dependencies"
@echo " clone-llamacpp Clone llama.cpp repository for cross-reference"
@echo " update-hf-script Update hf.sh script from llama.cpp repository"
@echo " model_download Download example models using hf.sh script"
@echo " install-tools Install development tools"
@echo " roadmap-update Update ROADMAP.md last updated date"
@echo " roadmap-validate Validate ROADMAP.md format and content"
@echo " roadmap-scan Scan for potential roadmap items in code"
@echo " roadmap-scan-missing Scan for code depending on missing llama.cpp functions"
@echo " roadmap-scan-purego Scan for code depending on purego struct support"
@echo " version Show version information"
@echo " help Show this help"
@echo ""
@echo "Variables:"
@echo " VERSION=$(VERSION)"
@echo " LLAMA_CPP_BUILD=$(LLAMA_CPP_BUILD)"
@echo " GOOS=$(GOOS)"
@echo " GOARCH=$(GOARCH)"