libft_ssl/configure.ac
2026-04-29 12:25:55 +02:00

46 lines
913 B
Text

AC_PREREQ([2.69])
AC_INIT([libft_ssl], [0.0.1], [])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_MACRO_DIRS([m4])
AM_INIT_AUTOMAKE([foreign -Wall -Werror subdir-objects])
AC_PROG_CC
AM_PROG_AR
LT_PREREQ([2.2])
LT_INIT
# --enable-debug
AC_ARG_ENABLE(
[debug],
[AS_HELP_STRING([--enable-debug], [Enable debug build: -g -O0 (default: no)])],
[enable_debug=$enableval],
[enable_debug=no]
)
AM_CONDITIONAL([ENABLE_DEBUG], [test "x$enable_debug" = "xyes"])
AS_IF([test "x$enable_debug" = "xyes"],
[CFLAGS="-g -O0"],
[CFLAGS="-O2"],
)
STRICT_CFLAGS="-Wall -Wextra -Werror -pipe -Wpedantic -Wconversion -Wshadow -Wvla"
AC_SUBST([STRICT_CFLAGS])
AC_CONFIG_FILES([
Makefile
src/Makefile
libft_ssl.pc
])
AC_OUTPUT
AC_MSG_NOTICE([
libft_ssl $VERSION
---------------
prefix : $prefix
CC : $CC
CFLAGS : $STRICT_CFLAGS $CFLAGS
debug : $enable_debug
])