$NetBSD: patch-ac,v 1.5 2009/05/25 20:56:38 drochner Exp $ --- common/cpu.c.orig 2009-04-05 21:01:48.000000000 +0200 +++ common/cpu.c @@ -33,7 +33,7 @@ #include #include #endif -#ifdef SYS_OPENBSD +#if defined(SYS_OPENBSD) || defined(SYS_NETBSD) #include #include #include @@ -200,13 +200,13 @@ uint32_t x264_cpu_detect( void ) #elif defined( ARCH_PPC ) -#if defined(SYS_MACOSX) || defined(SYS_OPENBSD) +#if defined(SYS_MACOSX) || defined(SYS_OPENBSD) || defined(SYS_NETBSD) #include uint32_t x264_cpu_detect( void ) { /* Thank you VLC */ uint32_t cpu = 0; -#ifdef SYS_OPENBSD +#if defined(SYS_OPENBSD) || defined(SYS_NETBSD) int selectors[2] = { CTL_MACHDEP, CPU_ALTIVEC }; #else int selectors[2] = { CTL_HW, HW_VECTORUNIT }; @@ -223,7 +223,7 @@ uint32_t x264_cpu_detect( void ) return cpu; } -#elif defined( SYS_LINUX ) +#elif defined(SYS_LINUX) || defined(SYS_NETBSD) #include #include static sigjmp_buf jmpbuf;