xref: /freebsd/contrib/sendmail/include/sm/os/sm_os_freebsd.h (revision 3078531de10dcae44b253a35125c949ff4235284)
1 /*
2  * Copyright (c) 2000-2001, 2018 Proofpoint, Inc. and its suppliers.
3  *	All rights reserved.
4  *
5  * By using this file, you agree to the terms and conditions set
6  * forth in the LICENSE file which can be found at the top level of
7  * the sendmail distribution.
8  */
9 
10 /*
11 **  Platform definitions for FreeBSD
12 */
13 
14 #define SM_OS_NAME	"freebsd"
15 
16 #define SM_CONF_SYS_CDEFS_H	1
17 
18 #if __FreeBSD__ >= 2
19 #  include <osreldate.h> /* defines __FreeBSD_version */
20 #  if __FreeBSD_version >= 199512	/* 2.2-current when it appeared */
21 #     define MI_SOMAXCONN	-1	/* listen() max backlog for milter */
22 #  endif /* __FreeBSD_version >= 199512 */
23 #  if __FreeBSD_version >= 330000
24      /* 3.3.0-release and later have strlcpy()/strlcat() */
25 #    ifndef SM_CONF_STRL
26 #       define SM_CONF_STRL		1
27 #    endif
28 #  endif
29 #endif
30 
31 #ifndef SM_CONF_SHM
32 # define SM_CONF_SHM	1
33 #endif
34 #ifndef SM_CONF_SEM
35 # if __FreeBSD_version >= 1200059
36 #  define SM_CONF_SEM	2 /* union semun is no longer declared by default */
37 # else
38 #  define SM_CONF_SEM	1
39 # endif
40 #endif
41 #ifndef SM_CONF_MSG
42 # define SM_CONF_MSG	1
43 #endif
44