-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
49 lines (45 loc) · 1.59 KB
/
Makefile
File metadata and controls
49 lines (45 loc) · 1.59 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
.PHONY: release clean help test-service
# Default target
help:
@echo "Available targets:"
@echo " release - Build static x86_64 binary and prepare for GitHub release"
@echo " clean - Clean build artifacts"
@echo " test-servie - Build the Docker image `arangodb/test-service`
# Build static binary for GitHub release
release:
@echo "=== Building static x86_64 binary for release ==="
@echo ""
@echo "Step 1: Adding x86_64-unknown-linux-musl target..."
rustup target add x86_64-unknown-linux-musl
@echo ""
@echo "Step 2: Building release binary..."
cargo build --release --target x86_64-unknown-linux-musl
@echo ""
@echo "Step 3: Copying binary to project root..."
cp target/x86_64-unknown-linux-musl/release/servicemaker ./servicemaker
@echo ""
@echo "✓ Static binary built successfully!"
@echo ""
@echo "Binary details:"
@file servicemaker
@ls -lh servicemaker
@echo ""
@echo "=== Release Ready ==="
@echo "The static binary is now in the project root:"
@echo " - servicemaker"
@echo ""
@echo "This binary is statically linked and can run on any x86_64 Linux system."
@echo ""
@echo "You can now create a binary release on GitHub:"
@echo " 1. Go to: https://github.com/arangodb/servicemaker/releases/new"
@echo " 2. Create a new tag (e.g., v0.9.3)"
@echo " 3. Upload the 'servicemaker' binary"
@echo " 4. Publish the release"
@echo ""
# Clean build artifacts
clean:
cargo clean
rm -f servicemaker
@echo "✓ Cleaned build artifacts"
test-service:
target/release/servicemaker --project-home arango-test-service --port 8000 --make-tar-gz --push --image-name arangodb/test-service