Files
retrobsd/src/cmd/wiznet/Makefile
Serge 8458c9e3c4 Fix linking of user programs.
Start fixing awk.
2022-05-25 23:05:45 -07:00

50 lines
1.1 KiB
Makefile

TOPSRC = $(shell cd ../../..; pwd)
include $(TOPSRC)/target.mk
CFLAGS += -O -Wall -Werror
LIBS += -lwiznet -lc
EXAMPLES = telnet \
ntpdate \
chat-server \
web-client \
web-server
all: $(EXAMPLES)
web-client: web-client.o
${LD} ${LDFLAGS} -o $@.elf $< ${LIBS}
${OBJDUMP} -S $@.elf > $@.dis
${SIZE} $@.elf
${ELF2AOUT} $@.elf $@
web-server: web-server.o
${LD} ${LDFLAGS} -o $@.elf $< ${LIBS}
${OBJDUMP} -S $@.elf > $@.dis
${SIZE} $@.elf
${ELF2AOUT} $@.elf $@
telnet: telnet.o
${LD} ${LDFLAGS} -o $@.elf $< ${LIBS}
${OBJDUMP} -S $@.elf > $@.dis
${SIZE} $@.elf
${ELF2AOUT} $@.elf $@
ntpdate: ntpdate.o
${LD} ${LDFLAGS} -o $@.elf $< ${LIBS}
${OBJDUMP} -S $@.elf > $@.dis
${SIZE} $@.elf
${ELF2AOUT} $@.elf $@
chat-server: chat-server.o
${LD} ${LDFLAGS} -o $@.elf $< ${LIBS}
${OBJDUMP} -S $@.elf > $@.dis
${SIZE} $@.elf
${ELF2AOUT} $@.elf $@
clean:
rm -f *.o *.elf *.dis $(EXAMPLES)
install: all
install $(EXAMPLES) $(DESTDIR)/bin/