File: Makefile

package info (click to toggle)
rhonabwy 1.1.13-2.1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 2,732 kB
  • sloc: ansic: 30,792; makefile: 274; sh: 146
file content (28 lines) | stat: -rw-r--r-- 769 bytes parent folder | download | duplicates (2)
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
#
# Rhonabwy library
#
# Makefile used to build the examples
#
# License: MIT
#

RHONABWY_INCLUDE=../include
RHONABWY_LOCATION=../src
RHONABWY_LIBRARY=$(RHONABWY_LOCATION)/librhonabwy.so
CC=gcc
CFLAGS+=-Wall -I$(RHONABWY_INCLUDE) -DDEBUG -g -O0 $(CPPFLAGS)
LDFLAGS=-lc -L$(RHONABWY_LIBRARY) -lrhonabwy
TARGET=jwt-sign-rs256 jwt-verify-es256 jwt-encrypt-pbes2-h256 jwt-decrypt-rsa-oaep256 jwks-parse-extract

all: build

clean:
	rm -f $(TARGET)

$(RHONABWY_LIBRARY): $(RHONABWY_LOCATION)/misc.c $(RHONABWY_LOCATION)/jwk.c $(RHONABWY_LOCATION)/jwks.c $(RHONABWY_LOCATION)/jws.c $(RHONABWY_LOCATION)/jwe.c $(RHONABWY_LOCATION)/jwt.c $(RHONABWY_INCLUDE)/rhonabwy.h
	cd $(RHONABWY_LOCATION) && $(MAKE) debug $*

%: %.c
	$(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS)

build: $(TARGET)