Skip to content
Permalink
d7aaa06a20
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
executable file 61 lines (40 sloc) 872 Bytes
#!/bin/bash
{
set -x
set -e
set -u
. build.profile
. ${PREFIX}/${BUILD_python}/profile
. ${PREFIX}/${BUILD_leptonica}/profile
function B_JBIG2ENC {
BUILD_PKG=${BUILD_jbig2enc}
PREFIX="${PREFIX}/${BUILD_PKG}"
mkdir -p "${PREFIX}"
cat >"${PREFIX}/profile" <<-EOF
PATH=${PREFIX}/bin:\$PATH
EOF
if [ ! -d "${BUILD_PKG}" ]; then
if [ ! -e ${BUILD_PKG}.tar ]; then
git clone https://github.com/agl/jbig2enc.git ${BUILD_PKG}
tar cf ${BUILD_PKG}.tar ${BUILD_PKG}
else
tar -xf ${BUILD_PKG}.tar
fi
fi
pushd ${BUILD_PKG}
local _conf=(
--prefix ${PREFIX}
)
LDFLAGS=$(PKG_CONFIG_PATH=${PKG_CONFIG_PATH} pkg-config --libs-only-L lept)
export LDFLAGS
CPPFLAGS="-I${PROJECT}/${BUILD_leptonica}/include"
export CPPFLAGS
./autogen.sh
./configure "${_conf[@]}"
make -j ${NPROC} install
popd
}
pushd "${BUILD_DIR}"
B_JBIG2ENC
popd
}