-
Notifications
You must be signed in to change notification settings - Fork 66
Expand file tree
/
Copy pathMakefile
More file actions
67 lines (58 loc) · 1.63 KB
/
Makefile
File metadata and controls
67 lines (58 loc) · 1.63 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
.PHONY: test install help clean all
# Default target
all:
@echo "OpenSSL RPM Builder"
@echo "Run 'make help' for available commands"
# Install OpenSSL 3.x
install:
@echo "Installing OpenSSL 3.x..."
@if [ -f install-openssl_3.sh ]; then
sudo ./install-openssl_3.sh
else
echo "Error: install-openssl_3.sh not found"
exit 1
fi
# Install OpenSSL 1.1.1
install-1.1.1:
@echo "Installing OpenSSL 1.1.1..."
@if [ -f install-openssl_1.1.1.sh ]; then
sudo ./install-openssl_1.1.1.sh
else
echo "Error: install-openssl_1.1.1.sh not found"
exit 1
fi
# Run tests
test:
@echo "Running test suite..."
@cd tests && $(MAKE) test
# Install test dependencies
test-setup:
@cd tests && $(MAKE) test-deps
# Build both versions (for testing)
build-test:
@echo "Building both OpenSSL versions for testing..."
@mkdir -p build-test
@VERSION=3.6.1 BUILD_ROOT=build-test/rpmbuild-3.6.1 ./install-openssl_3.sh
@VERSION=1.1.1w BUILD_ROOT=build-test/rpmbuild-1.1.1 ./install-openssl_1.1.1.sh
# Clean
clean:
@echo "Cleaning build artifacts..."
@rm -rf /root/rpmbuild
@rm -rf build-test
@rm -f *.rpm
# Clean test artifacts
clean-tests:
@cd tests && $(MAKE) clean
# Help
help:
@echo "Available targets:"
@echo " install - Install OpenSSL 3.x"
@echo " install-1.1.1- Install OpenSSL 1.1.1"
@echo " test - Run all tests"
@echo " test-setup - Install test dependencies"
@echo " build-test - Build both versions for testing"
@echo " clean - Remove build artifacts"
@echo " clean-tests - Remove test artifacts"
@echo " help - Show this help"
@echo ""
@echo "For more test options, use: cd tests && make help"