Skip to content

Commit

Permalink
Fixed compilation on ARM platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
Lava Git committed Aug 13, 2021
1 parent 29714a1 commit d3cfe54
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
14 changes: 9 additions & 5 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -42,26 +42,30 @@ AC_CHECK_FUNCS([memset])

# x86 CPU features (without automatic gcc flags)
AC_CANONICAL_HOST
X86_SIMD=""
AS_CASE([$host_cpu],
[x86_64],
[
X86_SIMD="true"
CFLAGS="$CFLAGS -DX86_SIMD -std=c99"
],
[i?86],
[
X86_SIMD="true"
CFLAGS="$CFLAGS -DX86_SIMD -std=c99"
],
[amd64],
[
X86_SIMD="true"
],)
CFLAGS="$CFLAGS -DX86_SIMD -std=c99"
],
[default],
[
CFLAGS="$CFLAGS -std=c99"
]
)
AC_SUBST([X86_SIMD])
AM_CONDITIONAL([X86_SIMD], [test x$X86_SIMD = xtrue])

# C99
CFLAGS="$CFLAGS -DX86_SIMD -std=c99"

AC_CONFIG_FILES([Makefile
src/Makefile])
AC_OUTPUT
4 changes: 2 additions & 2 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ if X86_SIMD

else

SIMDOBJ = hardnested/hardnested_bf_core_NOSIMD.o hardnested/hardnested_bitarray_core_NOSIMD.o
hardnested/%_NOSIMD.o : hardnested/%.c
SIMD = hardnested/hardnested_bf_core_NOSIMD.o hardnested/hardnested_bitarray_core_NOSIMD.o
hardnested/%_NOSIMD.o : hardnested/%_NOSIMD.c
$(CC) $(DEPFLAGS) $(CFLAGS) -c -o $@ $<

endif

0 comments on commit d3cfe54

Please sign in to comment.