xref: /freebsd/contrib/sendmail/include/sm/os/sm_os_freebsd.h (revision f97a19ecb98541455c6c940f4bab2dc7dc425468)
140266059SGregory Neil Shapiro /*
25b0945b5SGregory Neil Shapiro  * Copyright (c) 2000-2001, 2018 Proofpoint, Inc. and its suppliers.
340266059SGregory Neil Shapiro  *	All rights reserved.
440266059SGregory Neil Shapiro  *
540266059SGregory Neil Shapiro  * By using this file, you agree to the terms and conditions set
640266059SGregory Neil Shapiro  * forth in the LICENSE file which can be found at the top level of
740266059SGregory Neil Shapiro  * the sendmail distribution.
840266059SGregory Neil Shapiro  */
940266059SGregory Neil Shapiro 
1040266059SGregory Neil Shapiro /*
1140266059SGregory Neil Shapiro **  Platform definitions for FreeBSD
1240266059SGregory Neil Shapiro */
1340266059SGregory Neil Shapiro 
1440266059SGregory Neil Shapiro #define SM_OS_NAME	"freebsd"
1540266059SGregory Neil Shapiro 
1640266059SGregory Neil Shapiro #define SM_CONF_SYS_CDEFS_H	1
1740266059SGregory Neil Shapiro 
1840266059SGregory Neil Shapiro #if __FreeBSD__ >= 2
1940266059SGregory Neil Shapiro #  include <osreldate.h> /* defines __FreeBSD_version */
2040266059SGregory Neil Shapiro #  if __FreeBSD_version >= 199512	/* 2.2-current when it appeared */
2140266059SGregory Neil Shapiro #     define MI_SOMAXCONN	-1	/* listen() max backlog for milter */
2240266059SGregory Neil Shapiro #  endif /* __FreeBSD_version >= 199512 */
2340266059SGregory Neil Shapiro #  if __FreeBSD_version >= 330000
2440266059SGregory Neil Shapiro      /* 3.3.0-release and later have strlcpy()/strlcat() */
2540266059SGregory Neil Shapiro #    ifndef SM_CONF_STRL
2640266059SGregory Neil Shapiro #       define SM_CONF_STRL		1
2740266059SGregory Neil Shapiro #    endif
2840266059SGregory Neil Shapiro #  endif
29*2fb4f839SGregory Neil Shapiro #  if __FreeBSD_version >= 1200059
30*2fb4f839SGregory Neil Shapiro #   ifndef SM_CONF_SEM
31*2fb4f839SGregory Neil Shapiro #    define SM_CONF_SEM	2 /* union semun is no longer declared by default */
32*2fb4f839SGregory Neil Shapiro #   endif
33*2fb4f839SGregory Neil Shapiro #  endif
3440266059SGregory Neil Shapiro #endif
3540266059SGregory Neil Shapiro 
3640266059SGregory Neil Shapiro #ifndef SM_CONF_SHM
3740266059SGregory Neil Shapiro # define SM_CONF_SHM	1
385b0945b5SGregory Neil Shapiro #endif
3940266059SGregory Neil Shapiro #ifndef SM_CONF_SEM
405b0945b5SGregory Neil Shapiro # define SM_CONF_SEM	1
415b0945b5SGregory Neil Shapiro #endif
4240266059SGregory Neil Shapiro #ifndef SM_CONF_MSG
4340266059SGregory Neil Shapiro # define SM_CONF_MSG	1
445b0945b5SGregory Neil Shapiro #endif
45