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

test -d zmq || mkdir zmq

ZMQ=4.1.5
ZMQ_REPO=zeromq/zeromq4-1

realpath() {
    [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"
}
export ZMQ_PREFIX="$(dirname $(realpath $0))/zmq"
export ZMQ_SRC_DIR=zeromq-$ZMQ
cd $ZMQ_PREFIX

export CFLAGS=-fPIC
export CXXFLAGS=-fPIC
export PKG_CONFIG_PATH=$ZMQ_PREFIX/lib/pkgconfig

test -f zeromq-$ZMQ.tar.gz || ZMQ=$ZMQ ZMQ_REPO=$ZMQ_REPO node "$(dirname $(realpath $0))/download-zmq.js"
test -d $ZMQ_SRC_DIR || tar xzf zeromq-$ZMQ.tar.gz
cd $ZMQ_SRC_DIR

test -f configure || ./autogen.sh
./configure --prefix=$ZMQ_PREFIX --with-relaxed --enable-static --disable-shared
V=1 make -j
make install
<commit_msg>Redirect node output to zmq-build.log<commit_after>#!/bin/sh
set -e

test -d zmq || mkdir zmq

ZMQ=4.1.5
ZMQ_REPO=zeromq/zeromq4-1

realpath() {
    [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"
}
export ZMQ_PREFIX="$(dirname $(realpath $0))/zmq"
export ZMQ_SRC_DIR=zeromq-$ZMQ
cd $ZMQ_PREFIX

export CFLAGS=-fPIC
export CXXFLAGS=-fPIC
export PKG_CONFIG_PATH=$ZMQ_PREFIX/lib/pkgconfig

test -f zeromq-$ZMQ.tar.gz || ZMQ=$ZMQ ZMQ_REPO=$ZMQ_REPO node "$(dirname $(realpath $0))/download-zmq.js" 2>&1 > ../zmq-build.log
test -d $ZMQ_SRC_DIR || tar xzf zeromq-$ZMQ.tar.gz
cd $ZMQ_SRC_DIR

test -f configure || ./autogen.sh
./configure --prefix=$ZMQ_PREFIX --with-relaxed --enable-static --disable-shared
V=1 make -j
make install

{'fraction_non_alphanumeric': 0.1829787234042553, 'fraction_numerical': 0.01702127659574468, 'mean_word_length': 4.130909090909091, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7508102', 'n_tokens_mistral': 655, 'n_tokens_neox': 610, 'n_words': 128}