1
0
mirror of https://gitlab.com/klmp200/LO27.git synced 2025-02-17 04:07:08 +00:00
LO27/LibMatrix/Makefile

30 lines
609 B
Makefile
Raw Normal View History

2016-12-10 05:04:13 +01:00
CC=gcc
2016-12-27 01:43:49 +01:00
CFLAGS=-Wall -Werror -pedantic -fpic -g -std=c89
2016-12-10 05:04:13 +01:00
2016-12-11 00:33:02 +01:00
LIBSDIR=-L/usr/lib -L../Libs
2016-12-10 05:04:13 +01:00
INCLUDEDIR=-I/usr/include -I.
#Library variables
2016-12-28 18:49:26 +01:00
LIBTARGET=libMatrix.so
LIBSOURCE=list CellElement matrix
2016-12-10 05:04:13 +01:00
LIBSOURCECFILE=$(LIBSOURCE:=.c)
LIBSOURCEOFILE=$(LIBSOURCE:=.o)
#Generating the library binary
$(LIBTARGET): $(LIBSOURCEOFILE)
@echo "\n Generating the library binary"
$(CC) $(CFLAGS) -shared $(LIBSOURCEOFILE) -o ../Libs/$(LIBTARGET)
#Generating object files
.c.o:
@echo "\n Generating " $@ " from " $<
$(CC) $(CFLAGS) $(INCLUDEDIR) -c -o $@ $<
#Cleaning
clean:
@echo "\n Cleaning"
rm -rf *.o *.exe *.so