proxmark3/tools/cryptorf/Makefile

37 lines
1,013 B
Makefile
Raw Normal View History

2020-08-20 03:38:21 +08:00
MYSRCPATHS = ../../common ../../common/cryptorf
MYSRCS = cryptolib.c util.c
MYINCLUDES = -I../../common/cryptorf
MYCFLAGS =
MYDEFS =
2023-09-13 02:22:04 +08:00
# Atomic
# RPi Zero gcc requires -latomic
# but MacOSX /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
# doesn't recognize option --as-needed
ifneq ($(platform),Darwin)
MYLDLIBS += -lpthread -Wl,--as-needed -latomic -Wl,--no-as-needed
endif
2020-08-20 03:38:21 +08:00
BINS = cm sm sma sma_multi
INSTALLTOOLS = $(BINS)
platform = $(shell uname)
ifeq ($(platform),Darwin)
CXXFLAGS = -std=c++14
endif
2020-08-20 03:38:21 +08:00
include ../../Makefile.host
2020-08-20 03:38:21 +08:00
# checking platform can be done only after Makefile.host
ifneq (,$(findstring MINGW,$(platform)))
# Mingw uses by default Microsoft printf, we want the GNU printf (e.g. for %z)
# and setting _ISOC99_SOURCE sets internally __USE_MINGW_ANSI_STDIO=1
CFLAGS += -D_ISOC99_SOURCE
endif
2020-08-20 03:38:21 +08:00
cm : $(OBJDIR)/cm.o $(MYOBJS)
sm : $(OBJDIR)/sm.o $(MYOBJS)
sma : $(OBJDIR)/sma.o $(MYOBJS)
sma_multi : $(OBJDIR)/sma_multi.o $(MYOBJS)