head	1.15;
access;
symbols
	netbsd-11-0-RC4:1.15
	netbsd-11-0-RC3:1.15
	netbsd-11-0-RC2:1.15
	netbsd-11-0-RC1:1.15
	perseant-exfatfs-base-20250801:1.15
	netbsd-11:1.15.0.4
	netbsd-11-base:1.15
	netbsd-10-1-RELEASE:1.14
	perseant-exfatfs-base-20240630:1.15
	perseant-exfatfs:1.15.0.2
	perseant-exfatfs-base:1.15
	netbsd-8-3-RELEASE:1.12
	netbsd-9-4-RELEASE:1.12
	netbsd-10-0-RELEASE:1.14
	netbsd-10-0-RC6:1.14
	netbsd-10-0-RC5:1.14
	netbsd-10-0-RC4:1.14
	netbsd-10-0-RC3:1.14
	netbsd-10-0-RC2:1.14
	netbsd-10-0-RC1:1.14
	netbsd-10:1.14.0.2
	netbsd-10-base:1.14
	netbsd-9-3-RELEASE:1.12
	cjep_sun2x-base1:1.13
	cjep_sun2x:1.13.0.6
	cjep_sun2x-base:1.13
	cjep_staticlib_x-base1:1.13
	netbsd-9-2-RELEASE:1.12
	cjep_staticlib_x:1.13.0.4
	cjep_staticlib_x-base:1.13
	netbsd-9-1-RELEASE:1.12
	phil-wifi-20200421:1.13
	phil-wifi-20200411:1.13
	is-mlppp:1.13.0.2
	is-mlppp-base:1.13
	phil-wifi-20200406:1.13
	netbsd-8-2-RELEASE:1.12
	netbsd-9-0-RELEASE:1.12
	netbsd-9-0-RC2:1.12
	netbsd-9-0-RC1:1.12
	phil-wifi-20191119:1.13
	netbsd-9:1.12.0.12
	netbsd-9-base:1.12
	phil-wifi-20190609:1.12
	netbsd-8-1-RELEASE:1.12
	netbsd-8-1-RC1:1.12
	pgoyette-compat-merge-20190127:1.12
	pgoyette-compat-20190127:1.12
	pgoyette-compat-20190118:1.12
	pgoyette-compat-1226:1.12
	pgoyette-compat-1126:1.12
	pgoyette-compat-1020:1.12
	pgoyette-compat-0930:1.12
	pgoyette-compat-0906:1.12
	netbsd-7-2-RELEASE:1.10
	pgoyette-compat-0728:1.12
	netbsd-8-0-RELEASE:1.12
	phil-wifi:1.12.0.10
	phil-wifi-base:1.12
	pgoyette-compat-0625:1.12
	netbsd-8-0-RC2:1.12
	pgoyette-compat-0521:1.12
	pgoyette-compat-0502:1.12
	pgoyette-compat-0422:1.12
	netbsd-8-0-RC1:1.12
	pgoyette-compat-0415:1.12
	pgoyette-compat-0407:1.12
	pgoyette-compat-0330:1.12
	pgoyette-compat-0322:1.12
	pgoyette-compat-0315:1.12
	netbsd-7-1-2-RELEASE:1.10
	pgoyette-compat:1.12.0.8
	pgoyette-compat-base:1.12
	netbsd-7-1-1-RELEASE:1.10
	matt-nb8-mediatek:1.12.0.6
	matt-nb8-mediatek-base:1.12
	perseant-stdc-iso10646:1.12.0.4
	perseant-stdc-iso10646-base:1.12
	netbsd-8:1.12.0.2
	netbsd-8-base:1.12
	prg-localcount2-base3:1.11
	prg-localcount2-base2:1.11
	prg-localcount2-base1:1.11
	prg-localcount2:1.11.0.6
	prg-localcount2-base:1.11
	pgoyette-localcount-20170426:1.11
	bouyer-socketcan-base1:1.11
	pgoyette-localcount-20170320:1.11
	netbsd-7-1:1.10.0.16
	netbsd-7-1-RELEASE:1.10
	netbsd-7-1-RC2:1.10
	netbsd-7-nhusb-base-20170116:1.10
	bouyer-socketcan:1.11.0.4
	bouyer-socketcan-base:1.11
	pgoyette-localcount-20170107:1.11
	netbsd-7-1-RC1:1.10
	pgoyette-localcount-20161104:1.11
	netbsd-7-0-2-RELEASE:1.10
	localcount-20160914:1.11
	netbsd-7-nhusb:1.10.0.14
	netbsd-7-nhusb-base:1.10
	pgoyette-localcount-20160806:1.11
	pgoyette-localcount-20160726:1.11
	pgoyette-localcount:1.11.0.2
	pgoyette-localcount-base:1.11
	netbsd-7-0-1-RELEASE:1.10
	netbsd-7-0:1.10.0.12
	netbsd-7-0-RELEASE:1.10
	netbsd-7-0-RC3:1.10
	netbsd-7-0-RC2:1.10
	netbsd-7-0-RC1:1.10
	netbsd-5-2-3-RELEASE:1.1
	netbsd-5-1-5-RELEASE:1.1
	netbsd-6-0-6-RELEASE:1.9
	netbsd-6-1-5-RELEASE:1.9
	netbsd-7:1.10.0.10
	netbsd-7-base:1.10
	yamt-pagecache-base9:1.10
	yamt-pagecache-tag8:1.9
	netbsd-6-1-4-RELEASE:1.9
	netbsd-6-0-5-RELEASE:1.9
	tls-earlyentropy:1.10.0.8
	tls-earlyentropy-base:1.10
	riastradh-xf86-video-intel-2-7-1-pre-2-21-15:1.10
	riastradh-drm2-base3:1.10
	netbsd-6-1-3-RELEASE:1.9
	netbsd-6-0-4-RELEASE:1.9
	netbsd-5-2-2-RELEASE:1.1
	netbsd-5-1-4-RELEASE:1.1
	netbsd-6-1-2-RELEASE:1.9
	netbsd-6-0-3-RELEASE:1.9
	netbsd-5-2-1-RELEASE:1.1
	netbsd-5-1-3-RELEASE:1.1
	netbsd-6-1-1-RELEASE:1.9
	riastradh-drm2-base2:1.10
	riastradh-drm2-base1:1.10
	riastradh-drm2:1.10.0.2
	riastradh-drm2-base:1.10
	netbsd-6-1:1.9.0.12
	netbsd-6-0-2-RELEASE:1.9
	netbsd-6-1-RELEASE:1.9
	khorben-n900:1.10.0.6
	netbsd-6-1-RC4:1.9
	netbsd-6-1-RC3:1.9
	agc-symver:1.10.0.4
	agc-symver-base:1.10
	netbsd-6-1-RC2:1.9
	netbsd-6-1-RC1:1.9
	yamt-pagecache-base8:1.9
	netbsd-5-2:1.1.0.2
	netbsd-6-0-1-RELEASE:1.9
	yamt-pagecache-base7:1.9
	netbsd-5-2-RELEASE:1.1
	netbsd-5-2-RC1:1.1
	matt-nb6-plus-nbase:1.9
	yamt-pagecache-base6:1.9
	netbsd-6-0:1.9.0.10
	netbsd-6-0-RELEASE:1.9
	netbsd-6-0-RC2:1.9
	tls-maxphys:1.9.0.8
	tls-maxphys-base:1.10
	matt-nb6-plus:1.9.0.6
	matt-nb6-plus-base:1.9
	netbsd-6-0-RC1:1.9
	yamt-pagecache-base5:1.9
	yamt-pagecache-base4:1.9
	netbsd-6:1.9.0.4
	netbsd-6-base:1.9
	netbsd-5-1-2-RELEASE:1.1
	netbsd-5-1-1-RELEASE:1.1
	yamt-pagecache-base3:1.9
	yamt-pagecache-base2:1.9
	yamt-pagecache:1.9.0.2
	yamt-pagecache-base:1.9
	cherry-xenmp:1.6.0.2
	cherry-xenmp-base:1.6
	bouyer-quota2-nbase:1.5
	bouyer-quota2:1.5.0.2
	bouyer-quota2-base:1.5
	matt-mips64-premerge-20101231:1.5
	matt-nb5-mips64-premerge-20101231:1.1
	matt-nb5-pq3:1.1.0.16
	matt-nb5-pq3-base:1.1
	netbsd-5-1:1.1.0.14
	netbsd-5-1-RELEASE:1.1
	netbsd-5-1-RC4:1.1
	matt-nb5-mips64-k15:1.1
	netbsd-5-1-RC3:1.1
	netbsd-5-1-RC2:1.1
	netbsd-5-1-RC1:1.1
	netbsd-5-0-2-RELEASE:1.1
	matt-nb5-mips64-premerge-20091211:1.1
	matt-premerge-20091211:1.4
	matt-nb5-mips64-u2-k2-k4-k7-k8-k9:1.1
	matt-nb4-mips64-k7-u2a-k9b:1.1
	matt-nb5-mips64-u1-k1-k5:1.1
	matt-nb5-mips64:1.1.0.12
	netbsd-5-0-1-RELEASE:1.1
	jym-xensuspend-nbase:1.3
	netbsd-5-0:1.1.0.10
	netbsd-5-0-RELEASE:1.1
	netbsd-5-0-RC4:1.1
	netbsd-5-0-RC3:1.1
	netbsd-5-0-RC2:1.1
	jym-xensuspend:1.1.0.8
	jym-xensuspend-base:1.3
	netbsd-5-0-RC1:1.1
	haad-dm-base:1.1
	haad-dm-base2:1.1
	haad-nbase2:1.1
	netbsd-5:1.1.0.6
	netbsd-5-base:1.1
	matt-mips64-base2:1.1
	haad-dm:1.1.0.4
	haad-dm-base1:1.1;
locks; strict;
comment	@# @;


1.15
date	2023.06.03.09.09.03;	author lukem;	state Exp;
branches;
next	1.14;
commitid	aBaIRnuykonRStrE;

1.14
date	2021.08.14.16.17.57;	author christos;	state Exp;
branches;
next	1.13;
commitid	Nk1GyMLiupi4pX4D;

1.13
date	2019.10.13.07.28.05;	author mrg;	state Exp;
branches;
next	1.12;
commitid	vRNwN94v7NgB2GGB;

1.12
date	2017.05.21.15.28.38;	author riastradh;	state Exp;
branches
	1.12.10.1;
next	1.11;
commitid	qFvwLLy2KgFGNgSz;

1.11
date	2015.01.25.14.56.22;	author christos;	state Exp;
branches;
next	1.10;
commitid	VVtsZEeQnsthSp7y;

1.10
date	2013.02.14.01.57.42;	author christos;	state Exp;
branches;
next	1.9;

1.9
date	2011.08.17.09.03.47;	author christos;	state Exp;
branches
	1.9.2.1
	1.9.8.1;
next	1.8;

1.8
date	2011.06.22.02.49.42;	author mrg;	state Exp;
branches;
next	1.7;

1.7
date	2011.06.20.07.43.57;	author mrg;	state Exp;
branches;
next	1.6;

1.6
date	2011.05.26.12.56.25;	author joerg;	state Exp;
branches
	1.6.2.1;
next	1.5;

1.5
date	2010.02.08.07.56.38;	author plunky;	state Exp;
branches;
next	1.4;

1.4
date	2009.10.29.14.42.54;	author christos;	state Exp;
branches;
next	1.3;

1.3
date	2009.04.20.16.05.29;	author drochner;	state Exp;
branches;
next	1.2;

1.2
date	2009.03.20.21.15.29;	author christos;	state Exp;
branches;
next	1.1;

1.1
date	2008.09.19.21.38.40;	author christos;	state Exp;
branches
	1.1.4.1
	1.1.8.1;
next	;

1.12.10.1
date	2020.04.13.07.45.48;	author martin;	state Exp;
branches;
next	;
commitid	X01YhRUPVUDaec4C;

1.9.2.1
date	2014.05.22.15.41.06;	author yamt;	state Exp;
branches;
next	;
commitid	SFbWOH8OpGAX5yBx;

1.9.8.1
date	2013.02.25.00.24.53;	author tls;	state Exp;
branches;
next	;

1.6.2.1
date	2011.06.23.14.18.26;	author cherry;	state Exp;
branches;
next	;

1.1.4.1
date	2008.09.19.21.38.40;	author haad;	state dead;
branches;
next	1.1.4.2;

1.1.4.2
date	2008.10.19.22.39.28;	author haad;	state Exp;
branches;
next	;

1.1.8.1
date	2009.05.13.18.49.01;	author jym;	state Exp;
branches;
next	;


desc
@@


1.15
log
@bsd.own.mk: rename GCC_NO_* to CC_WNO_*

Rename compiler-warning-disable variables from
	GCC_NO_warning
to
	CC_WNO_warning
where warning is the full warning name as used by the compiler.

GCC_NO_IMPLICIT_FALLTHRU is CC_WNO_IMPLICIT_FALLTHROUGH

Using the convention CC_compilerflag, where compilerflag
is based on the full compiler flag name.
@
text
@#	$NetBSD: Makefile,v 1.14 2021/08/14 16:17:57 christos Exp $

.include "${.CURDIR}/../Makefile.inc"

PROG=	amd

DIST=	${IDIST}/amd
.PATH:	${DIST}

SRCS=	am_ops.c amd.c amfs_auto.c amfs_generic.c amfs_direct.c \
	amfs_error.c amfs_host.c \
	amfs_link.c amfs_linkx.c amfs_nfsl.c amfs_nfsx.c \
	amfs_program.c amfs_root.c amfs_toplvl.c amfs_union.c amq_subr.c \
	amq_svc.c autil.c clock.c conf.c get_args.c info_exec.c info_file.c \
	info_ndbm.c info_passwd.c info_sun.c \
	info_union.c map.c mapc.c mntfs.c nfs_prot_svc.c nfs_start.c \
	nfs_subr.c ops_cdfs.c ops_efs.c \
	ops_mfs.c ops_nfs.c ops_nfs3.c ops_nullfs.c ops_pcfs.c \
	ops_tfs.c ops_tmpfs.c ops_udf.c ops_ufs.c ops_umapfs.c ops_unionfs.c \
	opts.c readdir.c restart.c rpc_fwd.c sched.c srvr_amfs_auto.c \
	srvr_nfs.c sun_map.c sun_map_parse.y sun_map_tok.l \
	conf_parse.y conf_tok.l

.if (${USE_HESIOD} != "no")
SRCS+=	info_hesiod.c
.endif

.if (${USE_LDAP} != "no")
SRCS+=	info_ldap.c

LDADD+=	${LIBLDAP_LDADD}
DPADD+=	${LIBLDAP_DPADD}
.endif

.if (${USE_YP} != "no")
SRCS+=	info_nis.c
.endif

# the following are not supported on NetBSD
#	info_ldap.c info_nisplus.c ops_cachefs.c ops_efs.c ops_lofs.c ops_xfs.c
MAN+=	amd.8

AMDOBJDIR!=cd ${.CURDIR} && ${PRINTOBJDIR}

CPPFLAGS+=	-I${DIST} -I${AMDOBJDIR}
LDADD+=		-lrpcsvc
DPADD+=		${LIBRPCSVC}
YHEADER=	1

YPREFIX.sun_map_parse.y =	sun_map_
LPREFIX.sun_map_tok.l =	sun_map_

CWARNFLAGS.clang+=	-Wno-unneeded-internal-declaration

YPREFIX.conf_parse.y =	conf_
LPREFIX.conf_tok.l =	conf_

CLEANFILES+=	build_version.h
DPSRCS+=	build_version.h

get_args.o get_args.d: build_version.h

build_version.h: get_args.c
	${_MKTARGET_CREATE}
	echo '#define AMU_BUILD_VERSION	1' > ${.TARGET}
	echo '#define BUILD_USER "'unknown'"' >> ${.TARGET}
	echo '#define BUILD_HOST "'unknown'"' >> ${.TARGET}
	echo '#define BUILD_DATE "'unknown'"' >> ${.TARGET}

COPTS.sun_map.c+=	${CC_WNO_STRINGOP_TRUNCATION}

.include <bsd.prog.mk>
@


1.14
log
@Adjust for new OpenLDAP
- use centralized library variables
- ldap_connect -> ldap_xconnect
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.13 2019/10/13 07:28:05 mrg Exp $
d70 1
a70 1
COPTS.sun_map.c+=	${GCC_NO_STRINGOP_TRUNCATION}
@


1.13
log
@introduce some common variables for use in GCC warning disables:

GCC_NO_FORMAT_TRUNCATION    -Wno-format-truncation (GCC 7/8)
GCC_NO_STRINGOP_TRUNCATION  -Wno-stringop-truncation (GCC 8)
GCC_NO_STRINGOP_OVERFLOW    -Wno-stringop-overflow (GCC 8)
GCC_NO_CAST_FUNCTION_TYPE   -Wno-cast-function-type (GCC 8)

use these to turn off warnings for most GCC-8 complaints.  many
of these are false positives, most of the real bugs are already
commited, or are yet to come.


we plan to introduce versions of (some?) of these that use the
"-Wno-error=" form, which still displays the warnings but does
not make it an error, and all of the above will be re-considered
as either being "fix me" (warning still displayed) or "warning
is wrong."
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.12 2017/05/21 15:28:38 riastradh Exp $
d31 2
a32 8
LDADD+=	-lldap
DPADD+=	${LIBLDAP}
.if (${MKPIC} == "no" || (defined(LDSTATIC) && ${LDSTATIC} != ""))
LDADD+=	-llber
DPADD+=	${LIBLBER}
DPADD+=	${LIBSSL} ${LIBCRYPTO}
LDADD+=	-lssl -lcrypto
.endif
@


1.12
log
@Remove MKCRYPTO option.

Originally, MKCRYPTO was introduced because the United States
classified cryptography as a munition and restricted its export.  The
export controls were substantially relaxed fifteen years ago, and are
essentially irrelevant for software with published source code.

In the intervening time, nobody bothered to remove the option after
its motivation -- the US export restriction -- was eliminated.  I'm
not aware of any other operating system that has a similar option; I
expect it is mainly out of apathy for churn that we still have it.
Today, cryptography is an essential part of modern computing -- you
can't use the internet responsibly without cryptography.

The position of the TNF board of directors is that TNF makes no
representation that MKCRYPTO=no satisfies any country's cryptography
regulations.

My personal position is that the availability of cryptography is a
basic human right; that any local laws restricting it to a privileged
few are fundamentally immoral; and that it is wrong for developers to
spend effort crippling cryptography to work around such laws.

As proposed on tech-crypto, tech-security, and tech-userlevel to no
objections:

https://mail-index.netbsd.org/tech-crypto/2017/05/06/msg000719.html
https://mail-index.netbsd.org/tech-security/2017/05/06/msg000928.html
https://mail-index.netbsd.org/tech-userlevel/2017/05/06/msg010547.html

P.S.  Reviewing all the uses of MKCRYPTO in src revealed a lot of
*bad* crypto that was conditional on it, e.g. DES in telnet...  That
should probably be removed too, but on the grounds that it is bad,
not on the grounds that it is (nominally) crypto.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.11 2015/01/25 14:56:22 christos Exp $
d76 1
@


1.12.10.1
log
@Mostly merge changes from HEAD upto 20200411
@
text
@d1 1
a1 1
#	$NetBSD$
a75 1
COPTS.sun_map.c+=	${GCC_NO_STRINGOP_TRUNCATION}
@


1.11
log
@new lex/yacc need less help with prefixes.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.10 2013/02/14 01:57:42 christos Exp $
a35 1
.if ${MKCRYPTO} != "no" 
a39 1
.endif
@


1.10
log
@add PROGDPLIBS, and remove duplicate dependencies.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.9 2011/08/17 09:03:47 christos Exp $
a59 1
CPPFLAGS.sun_map_tok.c += -Dyylval=sun_map_lval -Dyyerror=sun_map_error
a64 1
CPPFLAGS.conf_tok.c += -Dyylval=conf_lval -Dyyerror=conf_error
@


1.9
log
@fix aliasing issues and remove gcc hacks.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.8 2011/06/22 02:49:42 mrg Exp $
d54 1
a54 1
LDADD+=		${LIBAMU} -lrpcsvc
@


1.9.2.1
log
@sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs.  ("Protocol error: too many arguments")
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.9 2011/08/17 09:03:47 christos Exp $
d54 1
a54 1
LDADD+=		-lrpcsvc
@


1.9.8.1
log
@resync with head
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.9 2011/08/17 09:03:47 christos Exp $
d54 1
a54 1
LDADD+=		-lrpcsvc
@


1.8
log
@apply some -Wno-error and/or -fno-strict-aliasing.


all of this should be looked at closer, but some of them are not
very trivial.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.7 2011/06/20 07:43:57 mrg Exp $
a46 4
.if defined(HAVE_GCC)
COPTS.amq_subr.c+=	-fno-strict-aliasing
.endif

a81 5

# XXX
.if ${HAVE_GCC} == 45
COPTS.readdir.c+=	-fno-strict-aliasing
.endif
@


1.7
log
@remove most of the remaining HAVE_GCC tests that are always true in
the modern world.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.6 2011/05/26 12:56:25 joerg Exp $
d86 5
@


1.6
log
@Default to -Wno-sign-compare -Wno-pointer-sign for clang.
Push -Wno-array-bounds down to the cases that depend on it.
Selectively disable warnings for 3rd party software or non-trivial
issues to be reviewed later to get clang -Werror to build most of the
tree.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.5 2010/02/08 07:56:38 plunky Exp $
d47 1
a47 1
.if defined(HAVE_GCC) && ${HAVE_GCC} == 4
@


1.6.2.1
log
@Catchup with rmind-uvmplock merge.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.7 2011/06/20 07:43:57 mrg Exp $
d47 1
a47 1
.if defined(HAVE_GCC)
@


1.5
log
@use

.if defined(HAVE_GCC) && ${HAVE_GCC} == 4

rather than

.if ${HAVE_GCC} == 4

as HAVE_GCC may be undefined
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.4 2009/10/29 14:42:54 christos Exp $
d66 2
@


1.4
log
@no need for YY_NO here.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.3 2009/04/20 16:05:29 drochner Exp $
d47 1
a47 1
.if ${HAVE_GCC} == 4
@


1.3
log
@define YY_NO_INPUT where appropriate, from Kurt J. Lidl per PR misc/41160
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.2 2009/03/20 21:15:29 christos Exp $
d57 1
a57 1
CPPFLAGS+=	-I${DIST} -I${AMDOBJDIR} -DYY_NO_INPUT
@


1.2
log
@need udf.
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.1 2008/09/19 21:38:40 christos Exp $
d57 1
a57 1
CPPFLAGS+=	-I${DIST} -I${AMDOBJDIR}
@


1.1
log
@resolve issues and add build glue
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.30 2008/07/15 18:10:50 perry Exp $
d19 1
a19 1
	ops_tfs.c ops_tmpfs.c ops_ufs.c ops_umapfs.c ops_unionfs.c \
@


1.1.8.1
log
@Sync with HEAD.

Second commit. See http://mail-index.netbsd.org/source-changes/2009/05/13/msg221222.html
@
text
@d1 1
a1 1
#	$NetBSD: Makefile,v 1.3 2009/04/20 16:05:29 drochner Exp $
d19 1
a19 1
	ops_tfs.c ops_tmpfs.c ops_udf.c ops_ufs.c ops_umapfs.c ops_unionfs.c \
d57 1
a57 1
CPPFLAGS+=	-I${DIST} -I${AMDOBJDIR} -DYY_NO_INPUT
@


1.1.4.1
log
@file Makefile was added on branch haad-dm on 2008-10-19 22:39:28 +0000
@
text
@d1 83
@


1.1.4.2
log
@Sync with HEAD.
@
text
@a0 83
#	$NetBSD: Makefile,v 1.1 2008/09/19 21:38:40 christos Exp $

.include "${.CURDIR}/../Makefile.inc"

PROG=	amd

DIST=	${IDIST}/amd
.PATH:	${DIST}

SRCS=	am_ops.c amd.c amfs_auto.c amfs_generic.c amfs_direct.c \
	amfs_error.c amfs_host.c \
	amfs_link.c amfs_linkx.c amfs_nfsl.c amfs_nfsx.c \
	amfs_program.c amfs_root.c amfs_toplvl.c amfs_union.c amq_subr.c \
	amq_svc.c autil.c clock.c conf.c get_args.c info_exec.c info_file.c \
	info_ndbm.c info_passwd.c info_sun.c \
	info_union.c map.c mapc.c mntfs.c nfs_prot_svc.c nfs_start.c \
	nfs_subr.c ops_cdfs.c ops_efs.c \
	ops_mfs.c ops_nfs.c ops_nfs3.c ops_nullfs.c ops_pcfs.c \
	ops_tfs.c ops_tmpfs.c ops_ufs.c ops_umapfs.c ops_unionfs.c \
	opts.c readdir.c restart.c rpc_fwd.c sched.c srvr_amfs_auto.c \
	srvr_nfs.c sun_map.c sun_map_parse.y sun_map_tok.l \
	conf_parse.y conf_tok.l

.if (${USE_HESIOD} != "no")
SRCS+=	info_hesiod.c
.endif

.if (${USE_LDAP} != "no")
SRCS+=	info_ldap.c

LDADD+=	-lldap
DPADD+=	${LIBLDAP}
.if (${MKPIC} == "no" || (defined(LDSTATIC) && ${LDSTATIC} != ""))
LDADD+=	-llber
DPADD+=	${LIBLBER}
.if ${MKCRYPTO} != "no" 
DPADD+=	${LIBSSL} ${LIBCRYPTO}
LDADD+=	-lssl -lcrypto
.endif
.endif
.endif

.if (${USE_YP} != "no")
SRCS+=	info_nis.c
.endif

.if ${HAVE_GCC} == 4
COPTS.amq_subr.c+=	-fno-strict-aliasing
.endif

# the following are not supported on NetBSD
#	info_ldap.c info_nisplus.c ops_cachefs.c ops_efs.c ops_lofs.c ops_xfs.c
MAN+=	amd.8

AMDOBJDIR!=cd ${.CURDIR} && ${PRINTOBJDIR}

CPPFLAGS+=	-I${DIST} -I${AMDOBJDIR}
LDADD+=		${LIBAMU} -lrpcsvc
DPADD+=		${LIBRPCSVC}
YHEADER=	1

YPREFIX.sun_map_parse.y =	sun_map_
LPREFIX.sun_map_tok.l =	sun_map_
CPPFLAGS.sun_map_tok.c += -Dyylval=sun_map_lval -Dyyerror=sun_map_error

YPREFIX.conf_parse.y =	conf_
LPREFIX.conf_tok.l =	conf_
CPPFLAGS.conf_tok.c += -Dyylval=conf_lval -Dyyerror=conf_error

CLEANFILES+=	build_version.h
DPSRCS+=	build_version.h

get_args.o get_args.d: build_version.h

build_version.h: get_args.c
	${_MKTARGET_CREATE}
	echo '#define AMU_BUILD_VERSION	1' > ${.TARGET}
	echo '#define BUILD_USER "'unknown'"' >> ${.TARGET}
	echo '#define BUILD_HOST "'unknown'"' >> ${.TARGET}
	echo '#define BUILD_DATE "'unknown'"' >> ${.TARGET}


.include <bsd.prog.mk>
@
