Makefile revision 112044
191714Sdes#-
291714Sdes# Copyright (c) 1998 Juniper Networks, Inc.
341227Sjdp# All rights reserved.
492297Sdes# Copyright (c) 2002 Networks Associates Technology, Inc.
591714Sdes# All rights reserved.
641227Sjdp#
791714Sdes# Portions of this software was developed for the FreeBSD Project by
891714Sdes# ThinkSec AS and NAI Labs, the Security Research Division of Network
991714Sdes# Associates, Inc.  under DARPA/SPAWAR contract N66001-01-C-8035
1091714Sdes# ("CBOSS"), as part of the DARPA CHATS research program.
1191714Sdes#
1241227Sjdp# Redistribution and use in source and binary forms, with or without
1341227Sjdp# modification, are permitted provided that the following conditions
1441227Sjdp# are met:
1541227Sjdp# 1. Redistributions of source code must retain the above copyright
1641227Sjdp#    notice, this list of conditions and the following disclaimer.
1741227Sjdp# 2. Redistributions in binary form must reproduce the above copyright
1841227Sjdp#    notice, this list of conditions and the following disclaimer in the
1941227Sjdp#    documentation and/or other materials provided with the distribution.
2091714Sdes# 3. The name of the author may not be used to endorse or promote
2191714Sdes#    products derived from this software without specific prior written
2291714Sdes#    permission.
2341227Sjdp#
2441227Sjdp# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
2541227Sjdp# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2641227Sjdp# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
2741227Sjdp# ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
2841227Sjdp# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2941227Sjdp# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
3041227Sjdp# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
3141227Sjdp# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
3241227Sjdp# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
3341227Sjdp# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
3441227Sjdp# SUCH DAMAGE.
3541227Sjdp#
3691714Sdes# $FreeBSD: head/lib/libpam/libpam/Makefile 112044 2003-03-09 20:06:38Z obrien $
3741227Sjdp
38112044SobrienOPENPAM=	${.CURDIR}/../../../contrib/openpam
39112044Sobrien.PATH: ${OPENPAM}/include ${OPENPAM}/lib ${OPENPAM}/doc/man
4076242Smarkm
41112044SobrienLIB=	pam
42112044SobrienNOPROFILE=	YES
4341227Sjdp
44112044SobrienSRCS=	openpam_borrow_cred.c \
45112044Sobrien	openpam_configure.c \
46112044Sobrien	openpam_dispatch.c \
47112044Sobrien	openpam_dynamic.c \
48112044Sobrien	openpam_findenv.c \
49112044Sobrien	openpam_free_data.c \
50112044Sobrien	openpam_get_option.c \
51112044Sobrien	openpam_load.c \
52112044Sobrien	openpam_log.c \
53112044Sobrien	openpam_nullconv.c \
54112044Sobrien	openpam_restore_cred.c \
55112044Sobrien	openpam_set_option.c \
56112044Sobrien	openpam_ttyconv.c \
57112044Sobrien	pam_acct_mgmt.c \
58112044Sobrien	pam_authenticate.c \
59112044Sobrien	pam_chauthtok.c \
60112044Sobrien	pam_close_session.c \
61112044Sobrien	pam_end.c \
62112044Sobrien	pam_error.c \
63112044Sobrien	pam_get_authtok.c \
64112044Sobrien	pam_get_data.c \
65112044Sobrien	pam_get_item.c \
66112044Sobrien	pam_get_user.c \
67112044Sobrien	pam_getenv.c \
68112044Sobrien	pam_getenvlist.c \
69112044Sobrien	pam_info.c \
70112044Sobrien	pam_open_session.c \
71112044Sobrien	pam_prompt.c \
72112044Sobrien	pam_putenv.c \
73112044Sobrien	pam_set_data.c \
74112044Sobrien	pam_set_item.c \
75112044Sobrien	pam_setcred.c \
76112044Sobrien	pam_setenv.c \
77112044Sobrien	pam_start.c \
78112044Sobrien	pam_strerror.c \
79112044Sobrien	pam_verror.c \
80112044Sobrien	pam_vinfo.c \
81112044Sobrien	pam_vprompt.c
82112044Sobrien# Local additions
83112044SobrienSRCS+=	pam_debug_log.c \
84112044Sobrien	pam_std_option.c
8541227Sjdp
86112044SobrienMAN=	openpam.3 \
87112044Sobrien	openpam_borrow_cred.3 \
88112044Sobrien	openpam_free_data.3 \
89112044Sobrien	openpam_get_option.3 \
90112044Sobrien	openpam_log.3 \
91112044Sobrien	openpam_nullconv.3 \
92112044Sobrien	openpam_restore_cred.3 \
93112044Sobrien	openpam_set_option.3 \
94112044Sobrien	openpam_ttyconv.3 \
95112044Sobrien	pam.3 \
96112044Sobrien	pam_acct_mgmt.3 \
97112044Sobrien	pam_authenticate.3 \
98112044Sobrien	pam_chauthtok.3 \
99112044Sobrien	pam_close_session.3 \
100112044Sobrien	pam_conv.3 \
101112044Sobrien	pam_end.3 \
102112044Sobrien	pam_error.3 \
103112044Sobrien	pam_get_authtok.3 \
104112044Sobrien	pam_get_data.3 \
105112044Sobrien	pam_get_item.3 \
106112044Sobrien	pam_get_user.3 \
107112044Sobrien	pam_getenv.3 \
108112044Sobrien	pam_getenvlist.3 \
109112044Sobrien	pam_info.3 \
110112044Sobrien	pam_open_session.3 \
111112044Sobrien	pam_prompt.3 \
112112044Sobrien	pam_putenv.3 \
113112044Sobrien	pam_set_data.3 \
114112044Sobrien	pam_set_item.3 \
115112044Sobrien	pam_setcred.3 \
116112044Sobrien	pam_setenv.3 \
117112044Sobrien	pam_sm_acct_mgmt.3 \
118112044Sobrien	pam_sm_authenticate.3 \
119112044Sobrien	pam_sm_chauthtok.3 \
120112044Sobrien	pam_sm_close_session.3 \
121112044Sobrien	pam_sm_open_session.3 \
122112044Sobrien	pam_sm_setcred.3 \
123112044Sobrien	pam_start.3 \
124112044Sobrien	pam_strerror.3 \
125112044Sobrien	pam_verror.3 \
126112044Sobrien	pam_vinfo.3 \
127112044Sobrien	pam_vprompt.3
12841227Sjdp
129112044SobrienWARNS?=	4
130112044SobrienCFLAGS+= -I${.CURDIR} -I${OPENPAM}/include
131112044SobrienCFLAGS+= -DLIB_MAJ=${SHLIB_MAJOR}
13241227Sjdp
133112044SobrienHEADERS=	security/openpam.h \
134112044Sobrien		security/openpam_version.h \
135112044Sobrien		security/pam_appl.h \
136112044Sobrien		security/pam_constants.h \
137112044Sobrien		security/pam_modules.h \
138112044Sobrien		security/pam_types.h \
13987445Sdes
140112044SobrienADD_HEADERS=	security/pam_mod_misc.h
14141227Sjdp
14291714Sdes# Static modules
143112044SobrienMODULE_DIR=	../modules
14491714Sdes.include "${.CURDIR}/${MODULE_DIR}/modules.inc"
145112044SobrienSTATIC_MODULES=	${MODULES:C/.*/${MODULE_DIR}\/&\/lib&.a/}
146112044SobrienSTATICOBJS+=	openpam_static_modules.o
147112044SobrienCLEANFILES+=	openpam_static.o \
148112044Sobrien		openpam_static_modules.o
14942917Sjdp
15091714Sdesopenpam_static_modules.o: openpam_static.o ${STATIC_MODULES}
15142917Sjdp	${LD} -o ${.TARGET} -r --whole-archive ${.ALLSRC}
15242917Sjdp
15391714Sdes# Headers
15496462SruINCS=		${HEADERS} ${ADD_HEADERS}
15596462SruINCSDIR=	${INCLUDEDIR}/security
15641227Sjdp
15741227Sjdp.include <bsd.lib.mk>
15894428Sru
15994923Sru# Can't put openpam_static.c in SRCS but want it in .depend.
16094923Sru${DEPENDFILE}: openpam_static.c
161