Upgrading build system to new NetBSD revision
The tested targets are the followgin ones:
* tools
* distribution
* sets
* release
The remaining NetBSD targets have not been disabled nor tested
*at all*. Try them at your own risk, they may reboot the earth.
For all compliant Makefiles, objects and generated files are put in
MAKEOBJDIR, which means you can now keep objects between two branch
switching. Same for DESTDIR, please refer to build.sh options.
Regarding new or modifications of Makefiles a few things:
* Read share/mk/bsd.README
* If you add a subdirectory, add a Makefile in it, and have it called
by the parent through the SUBDIR variable.
* Do not add arbitrary inclusion which crosses to another branch of
the hierarchy; If you can't do without it, put a comment on why.
If possible, do not use inclusion at all.
* Use as much as possible the infrastructure, it is here to make
life easier, do not fight it.
Sets and package are now used to track files.
We have one set called "minix", composed of one package called "minix-sys"
2012-09-12 09:37:05 +02:00
|
|
|
# $NetBSD: Makefile,v 1.55 2012/04/24 16:52:26 christos Exp $
|
2012-04-07 03:41:28 +02:00
|
|
|
# @(#)Makefile 8.1 (Berkeley) 7/19/93
|
|
|
|
|
2013-08-14 14:29:26 +02:00
|
|
|
.if defined(__MINIX)
|
|
|
|
WARNS=2
|
|
|
|
.endif
|
|
|
|
|
2012-10-26 15:22:39 +02:00
|
|
|
WARNS?= 5
|
2012-04-07 03:41:28 +02:00
|
|
|
|
|
|
|
.include <bsd.own.mk>
|
|
|
|
|
2012-10-26 15:22:39 +02:00
|
|
|
USE_FORT?= yes # setuid
|
2012-04-07 03:41:28 +02:00
|
|
|
PROG= login
|
|
|
|
SRCS= copyrightstr.c
|
|
|
|
DPADD+= ${LIBUTIL} ${LIBCRYPT}
|
|
|
|
LDADD+= -lutil -lcrypt
|
|
|
|
BINOWN= root
|
|
|
|
BINMODE=4555
|
|
|
|
|
|
|
|
SRCS+= common.c
|
|
|
|
.if (${USE_PAM} != "no")
|
|
|
|
SRCS+= login_pam.c
|
|
|
|
LDADD+= -lpam ${PAM_STATIC_LDADD}
|
|
|
|
DPADD+= ${LIBPAM} ${PAM_STATIC_DPADD}
|
|
|
|
.else # USE_PAM == no
|
|
|
|
SRCS+= login.c
|
|
|
|
CPPFLAGS+= -DSUPPORT_UTMP -DSUPPORT_UTMPX #-DLOGIN_CAP
|
|
|
|
|
|
|
|
.if (${USE_KERBEROS} != "no")
|
|
|
|
SRCS+= k5login.c
|
|
|
|
CPPFLAGS+=-DKERBEROS5
|
|
|
|
DPADD+= ${LIBKRB5} ${LIBASN1}
|
|
|
|
LDADD+= -lkrb5 -lasn1
|
|
|
|
|
|
|
|
DPADD+= ${LIBCRYPTO} ${LIBROKEN} ${LIBCOM_ERR}
|
|
|
|
LDADD+= -lcrypto -lroken -lcom_err
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if (${USE_SKEY} != "no")
|
|
|
|
CPPFLAGS+=-DSKEY
|
|
|
|
DPADD+= ${LIBSKEY}
|
|
|
|
LDADD+= -lskey
|
|
|
|
.endif
|
|
|
|
.endif # USE_PAM == no
|
|
|
|
|
|
|
|
CLEANFILES+= copyrightstr.c
|
|
|
|
|
|
|
|
copyrightstr.c: ${NETBSDSRCDIR}/sys/conf/copyright
|
|
|
|
${_MKTARGET_CREATE}
|
|
|
|
rm -f ${.TARGET}
|
|
|
|
${TOOL_AWK} '\
|
|
|
|
BEGIN { print "const char copyrightstr[] =" }\
|
|
|
|
{ print "\""$$0"\\n\""}\
|
|
|
|
END { print "\"\\n\";" }\
|
|
|
|
' ${.ALLSRC} > ${.TARGET}
|
|
|
|
|
|
|
|
|
|
|
|
.include <bsd.prog.mk>
|