File:  [ELWIX - Embedded LightWeight unIX -] / embedtools / src / Makefile.in
Revision 1.4.2.18: download - view: text, annotated - select for diffs - revision graph
Wed Feb 5 10:09:05 2014 UTC (10 years, 9 months ago) by misho
Branches: tools2_0
Diff to: branchpoint 1.4: preferred, unified
change name

#
# (C) 2009 AITnet - Sofia/Bulgaria - <misho@openbsd-bg.org>
# by Michael Pounov <misho@openbsd-bg.org>
#
# $Author: misho $
# $Id: Makefile.in,v 1.4.2.18 2014/02/05 10:09:05 misho Exp $
#

prefix = @prefix@
exec_prefix = @exec_prefix@
includedir = @includedir@
libdir = @libdir@

OS = @OS@
MACHINE = @host_cpu@

CC = @CC@
MKDEP = @MKDEP@

BIN = ../bin
INC = ../inc

LDADD = -lelwix
CFEXEC_LDADD = ${LDADD} -laitcfg
DPATCH_LDADD = ${LDADD} -laitsync -lcrypto
DIRER_LDADD = ${LDADD} -lcrypto -laitsync
DIRCMP_LDADD = ${LDADD} -lcrypto -laitsync
UBE_LDADD = ${LDADD} -laitcfg
CFGER_LDADD = ${LDADD} -laitcfg
WDOG_LDADD = 
ATHCTL_LDADD = 
DWDS_LDADD = ${LDADD} -laitcfg
CFI_LDADD = 
PCENG_LDADD = ${LDADD} -laitcfg
VOUCHER_LDADD = ${LDADD} -lcrypto -laitcfg
IMGUPD_LDADD = ${LDADD}

CFLAGS = -I. -I${INC} -I${includedir} @CFLAGS@
LDFLAGS = -L. -L${libdir} -Wl,-R${libdir} @LDFLAGS@

SRCS = ${CFEXEC_SRCS} ${GET1STETH_SRCS} ${DPATCH_SRCS} \
       ${DIRER_SRCS} ${DIRCMP_SRCS} ${WDOG_SRCS} \
       ${VOUCHER_SRCS} ${CFGER_SRCS} ${UBE_SRCS} ${IMGUPD_SRCS}
PROG = ${CFEXEC_PROG} ${GET1STETH_PROG} ${DPATCH_PROG} \
       ${DIRER_PROG} ${DIRCMP_PROG} ${WDOG_PROG} \
       ${VOUCHER_PROG} ${CFGER_PROG} ${UBE_PROG} ${IMGUPD_PROG}

.if ${MACHINE} == "i386" && ${OS} == "FreeBSD"
SRCS += ${PCENG_SRCS}
PROG += ${PCENG_PROG}
.endif

CFEXEC_SRCS = cfexec.c
CFEXEC_OBJS = cfexec.o compile.o
CFEXEC_PROG = cfexec

GET1STETH_SRCS = get1steth.c
GET1STETH_OBJS = get1steth.o compile.o
GET1STETH_PROG = get1steth

DPATCH_SRCS = dpatch.c
DPATCH_OBJS = dpatch.o compile.o
DPATCH_PROG = dpatch

DIRER_SRCS = direr.c
DIRER_OBJS = direr.o compile.o
DIRER_PROG = direr

DIRCMP_SRCS = dircmp.c
DIRCMP_OBJS = dircmp.o compile.o
DIRCMP_PROG = dircmp

CFGER_SRCS = cfger.c
CFGER_OBJS = cfger.o compile.o
CFGER_PROG = cfger

UBE_SRCS = ube.c ub_env.c
UBE_OBJS = ube.o compile.o ub_env.o
UBE_PROG = ube

WDOG_SRCS = wdog.c
WDOG_OBJS = wdog.o compile.o
WDOG_PROG = wdog

ATHCTL_SRCS = athctl.c
ATHCTL_OBJS = athctl.o compile.o
ATHCTL_PROG = athctl

DWDS_SRCS = dwds.c vap.c
DWDS_OBJS = dwds.o compile.o vap.o
DWDS_PROG = dwds

CFI_SRCS = cfi.c
CFI_OBJS = cfi.o compile.o
CFI_PROG = cfi

PCENG_SRCS = pceng.c pceng_run.c
PCENG_OBJS = pceng.o compile.o pceng_run.o
PCENG_PROG = pceng

VOUCHER_SRCS = voucher.c
VOUCHER_OBJS = voucher.o compile.o
VOUCHER_PROG = voucher

IMGUPD_SRCS = imgupd.c
IMGUPD_OBJS = imgupd.o compile.o
IMGUPD_PROG = imgupd


all: depend \
		${PROG} \
		${OS}

FreeBSD: ${ATHCTL_PROG} ${DWDS_PROG} ${CFI_PROG}

OpenBSD:

NetBSD:

.c.o: ${SRCS} compile.c
	${CC} -c ${CFLAGS} $<

depend:
	./compile.sh
	${MKDEP} ${CFLAGS} ${SRCS}

clean:
	rm -f *.o .depend compile.c *~

install:

${CFEXEC_PROG}: ${CFEXEC_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${CFEXEC_OBJS} ${CFEXEC_LDADD}

${GET1STETH_PROG}: ${GET1STETH_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${GET1STETH_OBJS}

${DPATCH_PROG}: ${DPATCH_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${DPATCH_OBJS} ${DPATCH_LDADD}

${DIRER_PROG}: ${DIRER_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${DIRER_OBJS} ${LDADD} ${DIRER_LDADD}

${DIRCMP_PROG}: ${DIRCMP_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${DIRCMP_OBJS} ${LDADD} ${DIRCMP_LDADD}

${CFGER_PROG}: ${CFGER_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${CFGER_OBJS} ${CFGER_LDADD}

${UBE_PROG}: ${UBE_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${UBE_OBJS} ${UBE_LDADD}

${WDOG_PROG}: ${WDOG_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${WDOG_OBJS} ${WDOG_LDADD}

${ATHCTL_PROG}: ${ATHCTL_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${ATHCTL_OBJS} ${ATHCTL_LDADD}

${DWDS_PROG}: ${DWDS_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${DWDS_OBJS} ${DWDS_LDADD}

${CFI_PROG}: ${CFI_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${CFI_OBJS} ${CFI_LDADD}

${PCENG_PROG}: ${PCENG_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${PCENG_OBJS} ${PCENG_LDADD}

${VOUCHER_PROG}: ${VOUCHER_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${VOUCHER_OBJS} ${VOUCHER_LDADD}

${IMGUPD_PROG}: ${IMGUPD_OBJS}
	${CC} ${LDFLAGS} -o${BIN}/$@ ${IMGUPD_OBJS} ${IMGUPD_LDADD}

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>