summaryrefslogtreecommitdiffstats
path: root/SoftHSMv2/m4/acx_yield.m4
blob: 335c190fbc615d3032d36a1ca3172dc87dd4f684 (plain)
1
2
3
4
5
6
7
8
9
10
AC_DEFUN([ACX_YIELD],[
	YIELD_LIB=
	# Solaris has sched_yield in librt, not in libpthread or libc.
	# Solaris 2.5.1, 2.6 has sched_yield in libposix4, not librt.
	AC_CHECK_LIB(rt, sched_yield, [YIELD_LIB=-lrt],
		[AC_CHECK_LIB(posix4, sched_yield, [YIELD_LIB=-lposix4])])
	AC_SUBST([YIELD_LIB])

	AC_CHECK_HEADER([sched.h])
])