diff options
| -rw-r--r-- | pkg/xz/config.h | 4 | ||||
| -rw-r--r-- | pkg/xz/gen.lua | 9 | ||||
| -rw-r--r-- | probe/HAVE_IMMINTRIN_H | 4 | ||||
| -rw-r--r-- | probe/HAVE__MM_MOVEMASK_EPI8 | 6 | ||||
| -rw-r--r-- | probe/gen.lua | 3 |
5 files changed, 23 insertions, 3 deletions
diff --git a/pkg/xz/config.h b/pkg/xz/config.h index e9413abd..d9a9bc42 100644 --- a/pkg/xz/config.h +++ b/pkg/xz/config.h @@ -47,7 +47,7 @@ #define HAVE_GETOPT_LONG 1 /* #undef HAVE_GETTEXT */ #define HAVE_ICONV 1 -#define HAVE_IMMINTRIN_H 1 +/* probe HAVE_IMMINTRIN_H */ #define HAVE_INTTYPES_H 1 #define HAVE_LIMITS_H 1 #define HAVE_MBRTOWC 1 @@ -93,7 +93,7 @@ #define HAVE_WCWIDTH 1 #define HAVE__BOOL 1 /* #undef HAVE__FUTIME */ -#define HAVE__MM_MOVEMASK_EPI8 1 +/* probe HAVE__MM_MOVEMASK_EPI8 */ #define LT_OBJDIR ".libs/" #define MYTHREAD_POSIX 1 /* #undef MYTHREAD_VISTA */ diff --git a/pkg/xz/gen.lua b/pkg/xz/gen.lua index b4c0a405..92547d02 100644 --- a/pkg/xz/gen.lua +++ b/pkg/xz/gen.lua @@ -1,6 +1,6 @@ cflags{ '-D HAVE_CONFIG_H', - '-I $dir', + '-I $outdir', '-I $srcdir/src/common', '-I $srcdir/src/liblzma/api', '-I $srcdir/src/liblzma/check', @@ -12,6 +12,13 @@ cflags{ '-I $srcdir/src/liblzma/simple', } +build('cat', '$outdir/config.h', { + '$dir/config.h', + '$builddir/probe/HAVE_IMMINTRIN_H', + '$builddir/probe/HAVE__MM_MOVEMASK_EPI8', +}) +pkg.deps = {'$outdir/config.h'} + lib('liblzma.a', [[src/( common/( tuklib_physmem.c diff --git a/probe/HAVE_IMMINTRIN_H b/probe/HAVE_IMMINTRIN_H new file mode 100644 index 00000000..cab4bd82 --- /dev/null +++ b/probe/HAVE_IMMINTRIN_H @@ -0,0 +1,4 @@ +#include <immintrin.h> +int main(void) { + return 0; +} diff --git a/probe/HAVE__MM_MOVEMASK_EPI8 b/probe/HAVE__MM_MOVEMASK_EPI8 new file mode 100644 index 00000000..8f39b50a --- /dev/null +++ b/probe/HAVE__MM_MOVEMASK_EPI8 @@ -0,0 +1,6 @@ +#include <immintrin.h> +static __m128i x; +int main(void) { + _mm_movemask_epi8(x); + return 0; +} diff --git a/probe/gen.lua b/probe/gen.lua index 641443d1..eebb877f 100644 --- a/probe/gen.lua +++ b/probe/gen.lua @@ -1,3 +1,6 @@ local function probe(var) build('probe', '$outdir/'..var, '$dir/'..var, {var=var}) end + +probe('HAVE_IMMINTRIN_H') +probe('HAVE__MM_MOVEMASK_EPI8') |
