diff --git a/common/lib/libc/arch/arm/atomic/Makefile.inc b/common/lib/libc/arch/arm/atomic/Makefile.inc index 9f0233780..2d1c864e9 100644 --- a/common/lib/libc/arch/arm/atomic/Makefile.inc +++ b/common/lib/libc/arch/arm/atomic/Makefile.inc @@ -1,7 +1,7 @@ # $NetBSD: Makefile.inc,v 1.8 2009/01/04 17:54:29 pooka Exp $ .if defined(LIB) && (${LIB} == "kern" || ${LIB} == "c" || ${LIB} == "pthread" \ - || ${LIB} == "rump") + || ${LIB} == "rump" || (defined(__MINIX) && ${LIB} == "sys")) SRCS+= atomic_add_32_cas.c atomic_add_32_nv_cas.c atomic_and_32_cas.c \ atomic_and_32_nv_cas.c atomic_dec_32_cas.c atomic_dec_32_nv_cas.c \ diff --git a/common/lib/libc/atomic/atomic_init_testset.c b/common/lib/libc/atomic/atomic_init_testset.c index 9769d62b5..74baecf12 100644 --- a/common/lib/libc/atomic/atomic_init_testset.c +++ b/common/lib/libc/atomic/atomic_init_testset.c @@ -112,11 +112,14 @@ _atomic_cas_32(volatile uint32_t *ptr, uint32_t old, uint32_t new) void __libc_atomic_init(void) { +#if !defined(__minix) int ncpu, mib[2]; size_t len; +#endif _atomic_cas_fn = _atomic_cas_mp; +#if !defined(__minix) mib[0] = CTL_HW; mib[1] = HW_NCPU; len = sizeof(ncpu); @@ -129,6 +132,7 @@ __libc_atomic_init(void) _atomic_cas_fn = _atomic_cas_up; return; } +#endif } #undef atomic_cas_32