forked from haskell-tls/hs-tls
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (41 loc) · 1.63 KB
/
Makefile
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
all:
@echo "use: make <target>"
@echo ""
@echo "where target is one of:"
@echo ""
@echo " reinstall"
@echo " tests"
@echo " build-openssl-server | build-openssl-server-mac-102"
@echo " build-openssl-client | build-openssl-client-mac-102"
.PHONY: reinstall
reinstall:
(cd core && cabal install --force-reinstalls --enable-tests && cd ../debug && cabal configure && cabal build && cabal install --force-reinstalls)
.PHONY: tests
tests: test-scripts/TestClient
./test-scripts/TestClient with-local
.PHONY: travis-tests
travis-tests: test-scripts/TestClient
./test-scripts/TestClient
.PHONY: test-scripts/TestClient
test-scripts/TestClient:
ghc -threaded --make test-scripts/TestClient
.PHONY: build-openssl-server
build-openssl-server:
gcc -Wall -o test-scripts/openssl-server -Wno-deprecated-declarations test-scripts/openssl-server.c -lcrypto -lssl
# for building on osx with the latest openssl version in brew
.PHONY: build-openssl-server-mac-102
build-openssl-server-mac-102:
gcc -Wall -o test-scripts/openssl-server \
-L/usr/local/Cellar/openssl/1.0.2g/lib \
-I/usr/local/Cellar/openssl/1.0.2g/include \
-lcrypto -lssl test-scripts/openssl-server.c
.PHONY: build-openssl-client
build-openssl-client:
gcc -Wall -o test-scripts/openssl-client -Wno-deprecated-declarations test-scripts/openssl-client.c -lcrypto -lssl
# for building on osx with the latest openssl version in brew
.PHONY: build-openssl-client-mac-102
build-openssl-client-mac-102:
gcc -Wall -o test-scripts/openssl-client \
-L/usr/local/Cellar/openssl/1.0.2a-1/lib \
-I/usr/local/Cellar/openssl/1.0.2a-1/include \
-lcrypto -lssl test-scripts/openssl-client.c