<commit_before>#!/bin/sh
set -e

UNAME=`uname`
if [ "${UNAME}" = "Darwin" ]; then
    export EXTRA_LINK_ARGS=-headerpad_max_install_names
elif [ "${UNAME}" = "Linux" ]; then
    export CC=gcc-4.8
    export CXX=g++-4.8
else
    echo "unsupported os: ${UNAME}"
    exit 1
fi

mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${PREFIX} -DEXTRA_INCLUDE_PATH=${PREFIX}/include -DEXTRA_LIBRARY_PATH=${PREFIX}/lib ..
make VERBOSE=1 && make install
cd ..
OFFICIAL_BUILD=1 LIBRARY_PATH=${PREFIX}/lib EXTRA_INCLUDE_PATH=${PREFIX}/include $PYTHON setup.py install
<commit_msg>be smarter about setting CC/CXX on linux [skip ci]<commit_after>#!/bin/sh
set -e

UNAME=`uname`
if [ "${UNAME}" = "Darwin" ]; then
    export EXTRA_LINK_ARGS=-headerpad_max_install_names
elif [ "${UNAME}" = "Linux" ]; then
    if (which g++-4.8 >/dev/null 2>&1); then
      export CXX=g++-4.8
    fi
    if (which gcc-4.8 >/dev/null 2>&1); then
      export CC=gcc-4.8
    fi
else
    echo "unsupported os: ${UNAME}"
    exit 1
fi

mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${PREFIX} -DEXTRA_INCLUDE_PATH=${PREFIX}/include -DEXTRA_LIBRARY_PATH=${PREFIX}/lib ..
make VERBOSE=1 && make install
cd ..
OFFICIAL_BUILD=1 LIBRARY_PATH=${PREFIX}/lib EXTRA_INCLUDE_PATH=${PREFIX}/include $PYTHON setup.py install

{'fraction_non_alphanumeric': 0.1530993278566094, 'fraction_numerical': 0.016430171769977596, 'mean_word_length': 4.36, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, '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': '397248', 'n_tokens_mistral': 525, 'n_tokens_neox': 486, 'n_words': 114}