aboutsummaryrefslogtreecommitdiff
path: root/sample/Makefile
blob: 8b9ee32cd123beb3ea8c1c1198bd11148038a0d2 (plain)
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
# Copyright 2019 ~ 2021 YuutaW Minecraft, All Rights Reserved.
# Proprietary and confidential.
# Unauthorized copying of any parts of this file, via any medium is strictly prohibited.
# Written by Yuuta Liang <yuuta@yuuta.moe>, April 2021.

CFLAGS= \
	-I.\
       -g \
       -std=c99 \
       -Wall \
       -D_POSIX_C_SOURCE=200809L \
       

LDFLAGS= \

OBJ=main.o

BIN=libsample.so

%.o: %.c
	$(CC) -c -o $@ $< $(CFLAGS) -fpic

$(BIN): $(OBJ)
	$(CC) -shared -o $@ $^ $(CFLAGS) $(LDFLAGS)

.PHONY: clean
clean:
	$(RM) *~ *.o $(BIN)