ootp/urd/Makefile

49 lines
1.3 KiB
Makefile
Raw Permalink Normal View History

2017-01-03 11:16:53 +00:00
# $Id: Makefile 155 2011-04-06 02:25:43Z maf $
2017-01-03 11:10:10 +00:00
what:
@echo
@echo "make hardware-systype"
@echo
@echo "This Makefile knows about the following"
@echo
@echo i386-fbsd i386-linux i386-macosx
@echo
i386-fbsd:
2017-01-03 11:16:53 +00:00
@make CC="gcc" CFLAGS="-I../common -g -DOOTP_ENABLE -DHAVE_STRING_H -DHAVE_STRINGS_H -DDEBUG -Wall -std=c99 -pedantic" LIBS="-lssl -lcrypt -lpam" all
2017-01-03 11:10:10 +00:00
i386-linux:
2017-01-03 11:16:53 +00:00
@make CC="gcc" CFLAGS="-I../common -g -DOOTP_ENABLE -DHAVE_STRING_H -DHAVE_STRINGS_H -DDEBUG -D_BSD_SOURCE -D_XOPEN_SOURCE -Wall -std=c99 -pedantic" LIBS="-lssl -lcrypt -lpam" all
2017-01-03 11:10:10 +00:00
i386-macosx:
2017-01-03 11:16:53 +00:00
@make CC="gcc" CFLAGS="-I../common -g -DOOTP_ENABLE -DHAVE_STRING_H -DHAVE_STRINGS_H -DDEBUG -Wall -std=c99 -pedantic" LIBS="-lssl -lcrypto -lpam" all
2017-01-03 11:10:10 +00:00
INSTALL=install -c -m0755
.c.o:; $(CC) $(CFLAGS) -c $*.c -o $*.o
2017-01-03 11:16:53 +00:00
BIN = urd
COBJS = ../common/xerr.o ../common/str.o ../common/otplib.o ../common/ffdb.o
OBJS = version.o ${BIN}.o pw.o rad.o fileio.o
2017-01-03 11:10:10 +00:00
BINDIR=/usr/local/ootp/bin
2017-01-03 11:16:53 +00:00
all: version ${COBJS} ${OBJS} ${BIN}
version:
rm -f version.c; ../build/version ../VERSION ${BIN} > version.c
version.c:
2017-01-03 11:10:10 +00:00
install:
mkdir -p ${BINDIR}
2017-01-03 11:16:53 +00:00
${INSTALL} ${BIN} ${BINDIR}
2017-01-03 11:10:10 +00:00
@echo files installed in ${BINDIR}
clean:
2017-01-03 11:16:53 +00:00
/bin/rm -f ${BIN} ${COBJS}
2017-01-03 11:10:10 +00:00
2017-01-03 11:16:53 +00:00
urd: ${COBJS} ${OBJS}
$(CC) $(CFLAGS) $(LFLAGS) $(INC) -o ${BIN} ${OBJS} ${COBJS} $(LIBS)
2017-01-03 11:10:10 +00:00