bmake framework for contrib_amd

This commit is contained in:
David E. O'Brien 1998-08-27 08:09:42 +00:00
parent 87c1e71689
commit f4a9d83b40
19 changed files with 2378 additions and 2 deletions

View File

@ -1,5 +1,11 @@
# @(#)Makefile 8.1 (Berkeley) 6/6/93
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
SUBDIR= amd amq doc fsinfo mk-amd-map
SUBDIR= libamu amd amq fixmount fsinfo hlfsd mk-amd-map pawd wire-test
.include <bsd.subdir.mk>

51
usr.sbin/amd/Makefile.inc Normal file
View File

@ -0,0 +1,51 @@
# ex:ts=8
#
# $Id$
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998.
# Portions derived from
# $NetBSD: Makefile.inc,v 1.10 1998/08/08 22:33:27 christos Exp $
# Portions derived from amd/libamu/Makefile
# $NetBSD: Makefile,v 1.8 1998/08/08 22:33:37 christos Exp $
#
#INCGEN!= cd ${.CURDIR}/../include; \
# printf 'xwhere: .MAKE\n\t@echo \$${.OBJDIR}\n' | ${MAKE} -s -f-
#CFLAGS+= -I${INCGEN}
CFLAGS+= -I. -I${.CURDIR}
CFLAGS+= -I${.CURDIR}/../include
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/include
CFLAGS+= -I${.CURDIR}/../../../contrib/amd
CFLAGS+= -DHAVE_CONFIG_H
LIBAMUDIR!= cd ${.CURDIR}/../libamu; \
printf 'xwhere: .MAKE\n\t@echo \$${.OBJDIR}\n' | ${MAKE} -s -f-
LIBAMU= ${LIBAMUDIR}/libamu.a
SRCS+= config_local.h
CLEANFILES+= config_local.h
config_local.h: ${.CURDIR}/../include/newvers.sh
@rm -f ${.TARGET}
sh ${.ALLSRC} > ${.TARGET}
RPCCOM= rpcgen
MOUNT_X= ${DESTDIR}/usr/include/rpcsvc/mount.x
NFS_PROT_X= ${DESTDIR}/usr/include/rpcsvc/nfs_prot.x
# These are generated at compile time
SRCS+= mount.h nfs_prot.h
CLEANFILES+= mount.h nfs_prot.h
mount.h: ${MOUNT_X}
${RPCCOM} -h -DWANT_NFS3 ${MOUNT_X} -o ${.TARGET}
nfs_prot.h: ${NFS_PROT_X}
${RPCCOM} -h ${NFS_PROT_X} -o ${.TARGET}
.if exists(${.CURDIR}/../../Makefile.inc)
.include "${.CURDIR}/../../Makefile.inc"
.endif

3
usr.sbin/amd/NOTES Normal file
View File

@ -0,0 +1,3 @@
amd/amd supports HESIOD, LDAP, and NIS+ which we don't presently.
If they are added to FreeBSD, add info_hesiod.c, info_ldap.c, info_nisplus.c
to amd/amd's Makefile.

42
usr.sbin/amd/amd/Makefile Normal file
View File

@ -0,0 +1,42 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/amd
PROG= amd
MAN8= amd.8
SRCS= conf_parse.y conf_tok.l
SRCS+= am_ops.c amd.c amfs_auto.c amfs_direct.c amfs_error.c
SRCS+= amfs_host.c amfs_inherit.c amfs_link.c amfs_linkx.c amfs_nfsl.c
SRCS+= amfs_nfsx.c amfs_program.c amfs_root.c amfs_toplvl.c
SRCS+= amfs_union.c amq_subr.c amq_svc.c autil.c clock.c conf.c
SRCS+= get_args.c info_file.c info_ndbm.c info_nis.c info_passwd.c
SRCS+= info_union.c map.c mapc.c mntfs.c nfs_prot_svc.c nfs_start.c
SRCS+= nfs_subr.c ops_cdfs.c ops_lofs.c ops_mfs.c ops_nfs.c ops_nfs3.c
SRCS+= ops_nullfs.c ops_pcfs.c ops_tfs.c ops_ufs.c ops_umapfs.c
SRCS+= ops_unionfs.c opts.c restart.c rpc_fwd.c sched.c
SRCS+= srvr_amfs_auto.c srvr_nfs.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/amd
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU} -lrpcsvc
CLEANFILES+= conf_parse.c conf_parse.h conf_tok.c
conf_tok.o: conf_parse.h
# These are generated at compile time
SRCS+= mount_xdr.c
CLEANFILES+= mount_xdr.c
mount_xdr.c: ${MOUNT_X}
${RPCCOM} -c -DWANT_NFS3 ${MOUNT_X} -o ${.TARGET}
.include <bsd.prog.mk>

21
usr.sbin/amd/amq/Makefile Normal file
View File

@ -0,0 +1,21 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/amq
PROG= amq
MAN8= amq.8
SRCS= amq.c amq_clnt.c amq_xdr.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/amq
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU}
.include <bsd.prog.mk>

14
usr.sbin/amd/doc/Makefile Normal file
View File

@ -0,0 +1,14 @@
# This file is under a "BSD" copyright (c) by David O'Brien 1998.
# $Id$
.PATH: ${.CURDIR}/../../../contrib/amd/doc
INFO = am-utils
INFOSECTION= "AMD Documentation"
INFOENTRY_cpio="* Am-utils: (am-utils). The Amd automounter suite of utilities"
SRCDIR= ${.CURDIR}/../../../contrib/amd/doc
.include <bsd.info.mk>

View File

@ -0,0 +1,26 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/fixmount \
${.CURDIR}/../../../contrib/amd/conf/checkmount
PROG= fixmount
MAN8= fixmount.8
SRCS= fixmount.c
# These are generated at compile time
SRCS+= mount.h nfs_prot.h
# These would be links created by the GNU-style configure
SRCS+= checkmount_bsd44.c
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU} -lrpcsvc
.include <bsd.prog.mk>

View File

@ -0,0 +1,24 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/fsinfo
PROG= fsinfo
MAN8= fsinfo.8
SRCS= fsi_gram.y fsi_lex.l
SRCS+= fsi_analyze.c fsi_dict.c fsi_util.c fsinfo.c wr_atab.c
SRCS+= wr_bparam.c wr_dumpset.c wr_exportfs.c wr_fstab.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/fsinfo
CLEANFILES+= fsi_gram.c fsi_gram.h fsi_lex.c
fsi_lex.o: fsi_gram.h
.include <bsd.prog.mk>

View File

@ -0,0 +1,21 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/hlfsd
PROG= hlfsd
MAN8= hlfsd.8
SRCS= hlfsd.c homedir.c nfs_prot_svc.c stubs.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/hlfsd
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU} -lrpcsvc
.include <bsd.prog.mk>

View File

@ -0,0 +1,13 @@
# ex:ts=8
#
# $Id$
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998.
# Portions derived from amd/libamu/Makefile
# $NetBSD: Makefile,v 1.8 1998/08/08 22:33:37 christos Exp $
#
all: config_local.h
.include <bsd.prog.mk>

View File

@ -0,0 +1 @@
#include "conf/nfs_prot/nfs_prot_freebsd3.h"

View File

@ -0,0 +1,81 @@
/*
* aux_conf.h:
* This file gets "filled in" for each architecture.
* Generated automatically from aux_conf.h.in by configure.
*/
#ifndef _AUX_CONF_H
#define _AUX_CONF_H
/*
* The next line is a literal inclusion of a file which includes a
* definition for the MOUNT_TRAP macro for a particular architecture.
* If it defines the wrong entry, check the AC_CHECK_MOUNT_TRAP m4 macro
* in $srcdir/aux/macros.
*/
/* $srcdir/conf/trap/trap_freebsd3.h */
#ifdef COMMENT_GET_DIRECTLY_FROM_FILE
extern int mount_freebsd3(MTYPE_TYPE type, const char *dir, int flags, voidp data);
#define MOUNT_TRAP(type, mnt, flags, mnt_data) mount_freebsd3(type, mnt->mnt_dir, flags, mnt_data)
#endif /* COMMENT_GET_DIRECTLY_FROM_FILE */
#include "conf/trap/trap_freebsd3.h"
/* End of included MOUNT_TRAP macro definition file */
/*
* The next line is a literal replacement of a variable which defines the
* the UNMOUNT_TRAP macro for a particular architecture.
* If it defines the wrong entry, check the AC_CHECK_UNMOUNT_CALL m4 macro
* in $srcdir/aclocal.m4. If the arguments are being defined wrong, check
* the macro AC_CHECK_UNMOUNT_ARGS in $srcdir/aux/macros.
*/
#define UNMOUNT_TRAP(mnt) unmount(mnt->mnt_dir)
/* End of replaced UNMOUNT_TRAP macro definition */
/*
* The next line is a literal inclusion of a file which includes a
* definition for the NFS_FH_DREF macro for a particular architecture.
* If it defines the wrong entry, check the AC_CHECK_NFS_FH_DREF m4 macro
* in $srcdir/aux/macros.
*/
/* $srcdir/conf/fh_dref/fh_dref_freebsd22.h */
#ifdef COMMENT_GET_DIRECTLY_FROM_FILE
#define NFS_FH_DREF(dst, src) (dst) = (u_char *) (src)
#endif /* COMMENT_GET_DIRECTLY_FROM_FILE */
#include "conf/fh_dref/fh_dref_freebsd22.h"
/* End of included NFS_FH_DREF macro definition file */
/*
* The next line is a literal inclusion of a file which includes a
* definition for the NFS_SA_DREF macro for a particular architecture.
* If it defines the wrong entry, check the AC_CHECK_NFS_SA_DREF m4 macro
* in $srcdir/aux/macros.
*/
/* $srcdir/conf/sa_dref/sa_dref_bsd44.h */
#ifdef COMMENT_GET_DIRECTLY_FROM_FILE
#define NFS_SA_DREF(dst, src) { \
(dst)->addr = (struct sockaddr *) (src); \
(dst)->addrlen = sizeof(*src); \
}
#endif /* COMMENT_GET_DIRECTLY_FROM_FILE */
#include "conf/sa_dref/sa_dref_bsd44.h"
/* End of included NFS_SA_DREF macro definition file */
/*
* The next line is a literal inclusion of a file which includes a
* definition for the NFS_HN_DREF macro for a particular architecture.
* If it defines the wrong entry, check the AC_CHECK_NFS_HN_DREF m4 macro
* in $srcdir/aux/macros.
*/
/* $srcdir/conf/hn_dref/hn_dref_default.h */
#ifdef COMMENT_GET_DIRECTLY_FROM_FILE
#define NFS_HN_DREF(dst, src) (dst) = (src)
#endif /* COMMENT_GET_DIRECTLY_FROM_FILE */
#include "conf/hn_dref/hn_dref_default.h"
/* End of included NFS_HN_DREF macro definition file */
#endif /* not _AUX_CONF_H */

View File

@ -0,0 +1,6 @@
/* do not edit this file by hand */
/* auto-generated by update_build_version script */
/* #define AMU_BUILD_VERSION 1 */
#include <sys/param.h>
#define AMU_BUILD_VERSION __FreeBSD_version

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,33 @@
# $NetBSD: mkconf,v 1.1.1.1 1997/07/24 21:20:12 christos Exp $
# $Id$
# mkconf
# Generate local configuration parameters for amd
#
cat << __EOF
/* Define name of host machine's cpu (eg. sparc) */
/* #define HOST_CPU "`uname -p`" */
#define HOST_CPU "`uname -m`"
/* Define name of host machine's architecture (eg. sun4) */
#define HOST_ARCH "`uname -m`"
/* Define name and version of host machine (eg. solaris2.5.1) */
#define HOST_OS "`uname -s | tr '[A-Z]' '[a-z]'``uname -r`"
/* Define only name of host machine OS (eg. solaris2) */
#define HOST_OS_NAME "`uname -s | tr '[A-Z]' '[a-z]'``uname -r | cut -d. -f 1`"
/* Define only version of host machine (eg. 2.5.1) */
#define HOST_OS_VERSION "`uname -r`"
/* Define name of host */
#define HOST_NAME "`hostname`"
/* Define user name */
#define USER_NAME "`whoami`"
/* Define configuration date */
#define CONFIG_DATE "`date`"
__EOF

View File

@ -0,0 +1,35 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
.PATH: ${.CURDIR}/../../../contrib/amd/libamu \
${.CURDIR}/../../../contrib/amd/conf/transp \
${.CURDIR}/../../../contrib/amd/conf/mtab \
${.CURDIR}/../../../contrib/amd/conf/mount \
${.CURDIR}/../../../contrib/amd/conf/umount
LIB= amu
SRCS= hasmntopt.c misc_rpc.c mount_fs.c mtab.c nfs_prot_xdr.c \
util.c wire.c xutil.c
# These would be links created by the GNU-style configure
SRCS+= transp_sockets.c mtab_bsd.c mount_freebsd3.c umount_bsd44.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/libamu
NOMAN= noman
# Generated at compile time (replaces supplied xdr_func.c)
SRCS+= nfs_prot_x.c
CLEANFILES+= nfs_prot_x.c
nfs_prot_x.c: ${NFS_PROT_X}
${RPCCOM} -c ${NFS_PROT_X} -o ${.TARGET}
install:
.include <bsd.lib.mk>

View File

@ -0,0 +1,16 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/mk-amd-map
PROG= mk-amd-map
MAN8= mk-amd-map.8
SRCS= mk-amd-map.c
.include <bsd.prog.mk>

View File

@ -0,0 +1,23 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/amq
BINDIR= /usr/bin
PROG= pawd
MAN1= pawd.1
SRCS= pawd.c amq_clnt.c amq_xdr.c
CFLAGS+= -I${.CURDIR}/../../../contrib/amd/amq
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU}
.include <bsd.prog.mk>

View File

@ -0,0 +1,19 @@
# ex:ts=8
#
# Makefile for amd
# This file is under a "BSD" copyright (c) by David O'Brien 1998
#
# $Id$
#
.PATH: ${.CURDIR}/../../../contrib/amd/wire-test
PROG= wire-test
MAN8= wire-test.8
SRCS= wire-test.c
DPDADD+= ${LIBAMU}
LDADD+= ${LIBAMU}
.include <bsd.prog.mk>