diff options
author | ngie <ngie@FreeBSD.org> | 2014-08-29 18:26:55 +0000 |
---|---|---|
committer | ngie <ngie@FreeBSD.org> | 2014-08-29 18:26:55 +0000 |
commit | f4fd8ca123dc4ee8f99360e00b5196f563d90a41 (patch) | |
tree | 7f9427978429216cd043706e67d1ab6e5c7951fb /sbin/atm/atmconfig/Makefile | |
parent | 29ecd8ce13d5ce74b4267865ba5b14edb1b04597 (diff) | |
download | FreeBSD-src-f4fd8ca123dc4ee8f99360e00b5196f563d90a41.zip FreeBSD-src-f4fd8ca123dc4ee8f99360e00b5196f563d90a41.tar.gz |
MFC r270027:
tmconfig compilation when MK_ATM == yes and MK_BSNMP == no
Makefile.inc1:
Always compile gensnmptree with bootstrap-tools when MK_BSNMP != no
instead of depending on a potentially stale tool installed on the build host
sbin/atm/atmconfig/Makefile:
- Always remove oid.h to avoid cluttering up the build/src tree.
- Consolidate all of the RESCUE/MK_BSNMP != no logic under one
conditional to improve readability
- Remove unnecessary ${.OBJDIR} prefixing for oid.h and use ${.TARGET} instead
of spelling out oid.h
- Add a missing DPADD for ${LIBCRYPTO} when compiled MK_BSNMP == yes and
MK_OPENSSL == yes and not compiling for /rescue/rescue
sbin/atm/atmconfig/main.c:
Change #ifndef RESCUE to #ifdef WITH_BSNMP in main.c to make it
clear that we're compiling bsnmp support into atmconfig
Diffstat (limited to 'sbin/atm/atmconfig/Makefile')
-rw-r--r-- | sbin/atm/atmconfig/Makefile | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/sbin/atm/atmconfig/Makefile b/sbin/atm/atmconfig/Makefile index 0d64fea..be1adda 100644 --- a/sbin/atm/atmconfig/Makefile +++ b/sbin/atm/atmconfig/Makefile @@ -8,29 +8,24 @@ .include <bsd.own.mk> PROG= atmconfig -.ifndef RESCUE -SRCS= ${.OBJDIR}/oid.h -.endif -SRCS+= main.c diag.c natm.c -.ifndef RESCUE -SRCS+= atmconfig_device.c -.endif +SRCS= main.c diag.c natm.c MAN= atmconfig.8 # CFLAGS+= -DPATH_HELP='".:/usr/share/doc/atm:/usr/local/share/doc/atm"' CFLAGS+= -I${.OBJDIR} -.ifndef RESCUE -DPADD= ${LIBBSNMP} -LDADD= -lbsnmp +.if !defined(RESCUE) && ${MK_BSNMP} != "no" +CFLAGS+= -DWITH_BSNMP +SRCS+= oid.h atmconfig_device.c +DPADD+= ${LIBBSNMP} +LDADD+= -lbsnmp . if ${MK_DYNAMICROOT} == "no" && ${MK_OPENSSL} != "no" +DPADD+= ${LIBCRYPTO} LDADD+= -lcrypto . endif .endif -.ifndef RESCUE CLEANFILES+= oid.h -.endif # XXX - this is verboten .if ${MACHINE_CPUARCH} == "arm" @@ -43,8 +38,8 @@ FILESDIR= /usr/share/doc/atm SNMP_ATM_DEF= ${.CURDIR}/../../../contrib/ngatm/snmp_atm/atm_tree.def \ ${.CURDIR}/../../../usr.sbin/bsnmpd/modules/snmp_atm/atm_freebsd.def -${.OBJDIR}/oid.h: atm_oid.list ${SNMP_ATM_DEF} +oid.h: atm_oid.list ${SNMP_ATM_DEF} cat ${SNMP_ATM_DEF} | gensnmptree -e `tail -n +2 ${.CURDIR}/atm_oid.list` \ - > ${.OBJDIR}/oid.h + > ${.TARGET} .include <bsd.prog.mk> |