Initial C commit
This commit is contained in:
parent
80c977769e
commit
00589cf691
4 changed files with 38 additions and 0 deletions
20
TPs/TP02/c/Makefile
Normal file
20
TPs/TP02/c/Makefile
Normal file
|
@ -0,0 +1,20 @@
|
|||
CC=gcc
|
||||
CFLAGS=-Wall -Wextra -O2
|
||||
LDFLAGS=-lssl -lcrypto
|
||||
ARCH=$(shell uname -m)
|
||||
|
||||
ifeq ($(ARCH), arm64)
|
||||
# Mac ARM installation
|
||||
CFLAGS+= -I/opt/homebrew/opt/openssl@3.2/include
|
||||
LDFLAGS+= -L/opt/homebrew/opt/openssl@3.2/lib
|
||||
endif
|
||||
|
||||
all: main
|
||||
|
||||
main: main.c
|
||||
$(info Detected $(ARCH) arquitecture.)
|
||||
$(CC) $(CFLAGS) $(LDFLAGS) main.c -o bin/main.out
|
||||
|
||||
clean:
|
||||
rm -f main.out
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue