<commit_before>dnl $Id$
dnl This source file is a part of the Berlin Project.
dnl Copyright (C) 2004 <NAME> <<EMAIL>>
dnl http://www.fresco.org/
dnl
dnl This library is free software; you can redistribute it and/or
dnl modify it under the terms of the GNU Library General Public
dnl License as published by the Free Software Foundation; either
dnl version 2 of the License, or (at your option) any later version.
dnl
dnl This library is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
dnl Library General Public License for more details.
dnl
dnl You should have received a copy of the GNU Library General Public
dnl License along with this library; if not, write to the
dnl Free Software Foundation, Inc., 675 Mass Ave, Cambridge,
dnl MA 02139, USA.

dnl
dnl FRESCO_ICONV
dnl
dnl Checks for iconv support. If found, $ac_cv_iconv is set to "yes",
dnl and $iconv_cppflags and $iconv_lib are defined
AC_DEFUN([FRESCO_ICONV],[

    AC_ARG_WITH([iconv-prefix],
                AC_HELP_STRING([--with-iconv-prefix=PRF],
                               [search for iconv library in prefix]),
                [
                    if test -d $withval/include ; then
                        ICONV_CPPFLAGS="$CPPFLAGS -I$withval/include"
                    fi
                    if test -d $withval/lib ; then
                        ICONV_LIBS="$LIBS -L$withval/lib"
                    fi
                ]
    )

    am_cv_iconv="no"

    saved_LIBS="$LIBS"
    saved_CPPFLAGS="$CPPFLAGS"

    LIBS="$ICONV_LIBS"
    CPPFLAGS="$ICONV_CPPFLAGS"

    AC_MSG_CHECKING([whether -liconv is needed])

    AC_TRY_LINK([#include <stdlib.h>
#include <iconv.h>],<commit_msg>Do not include CPPFLAGS/LIBS into ICONV_CPPFLAGS/LIBS when --with-iconv-prefix is provided.<commit_after>dnl $Id$
dnl This source file is a part of the Berlin Project.
dnl Copyright (C) 2004 <NAME> <<EMAIL>>
dnl http://www.fresco.org/
dnl
dnl This library is free software; you can redistribute it and/or
dnl modify it under the terms of the GNU Library General Public
dnl License as published by the Free Software Foundation; either
dnl version 2 of the License, or (at your option) any later version.
dnl
dnl This library is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
dnl Library General Public License for more details.
dnl
dnl You should have received a copy of the GNU Library General Public
dnl License along with this library; if not, write to the
dnl Free Software Foundation, Inc., 675 Mass Ave, Cambridge,
dnl MA 02139, USA.

dnl
dnl FRESCO_ICONV
dnl
dnl Checks for iconv support. If found, $ac_cv_iconv is set to "yes",
dnl and $iconv_cppflags and $iconv_lib are defined
AC_DEFUN([FRESCO_ICONV],[

    AC_ARG_WITH([iconv-prefix],
                AC_HELP_STRING([--with-iconv-prefix=PRF],
                               [search for iconv library in prefix]),
                [
                    if test -d $withval/include ; then
                        ICONV_CPPFLAGS="-I$withval/include"
                    fi
                    if test -d $withval/lib ; then
                        ICONV_LIBS="-L$withval/lib"
                    fi
                ]
    )

    am_cv_iconv="no"

    saved_LIBS="$LIBS"
    saved_CPPFLAGS="$CPPFLAGS"

    LIBS="$ICONV_LIBS"
    CPPFLAGS="$ICONV_CPPFLAGS"

    AC_MSG_CHECKING([whether -liconv is needed])

    AC_TRY_LINK([#include <stdlib.h>
#include <iconv.h>],
{'fraction_non_alphanumeric': 0.07365826944140197, 'fraction_numerical': 0.007119386637458927, 'mean_word_length': 2.634825870646766, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2044408', 'n_tokens_mistral': 1151, 'n_tokens_neox': 1086, 'n_words': 428}