...
Info |
---|
Теперь Вы можете запустить его в формате
|
...
Code Block | ||
---|---|---|
| ||
cat > build_all.sh <<EOT
#!/bin/bash
BLD_PARALLEL="4"
WORKSPACE=/export/home/admin/du2
STOP_ON_ERROR=0
while read COMP; do
if [[ "" == "\$COMP" ]]; then
continue
fi./build_all.sh
BLD_RESULT="/data/repo/du/\$COMP"
test -z "\$COMP" && exit 1
test -d \${BLD_RESULT} && rm -rf \${BLD_RESULT}
if [[ "$COMP" == "bind9" ]]; then
cp /etc/apt/sources.list.dev /etc/apt/sources.list
apt-get update
apt-get install -y libssl1.0-dev
cp /etc/apt/sources.list.bak /etc/apt/sources.list
apt-get update
fi
# apt-get update && apt-get upgrade -y || exit 1
# apt-get install -y build-essential illumos-dev dpkg-dev gmake || exit 1
DEB_BUILD_OPTIONS="nocheck notest parallel=\${BLD_PARALLEL}"
export DEB_BUILD_OPTIONS
test -d \${WORKSPACE}/\$COMP && rm -rf \${WORKSPACE}/\$COMP
mkdir -p \${WORKSPACE}/\$COMP
cd \${WORKSPACE}/\$COMP
echo "====================== \$COMP ======================" | tee berror.log
if [[ \$STOP_ON_ERROR -eq 0 ]]; then
apt-get build-dep -y \$COMP >> berror.log || continue 2>&1
apt-get source --compile \$COMP >> berror.log || continue 2>&1
else
apt-get build-dep -y \$COMP >> berror.log || exit 1 2>&1
#DEB_BUILD_OPTIONS="nocheck notest parallel=4" apt-get source --compile \$COMP || exit 1
apt-get source --compile \$COMP >> berror.log || exit 1 2>&1
fi
mkdir -p \${BLD_RESULT}
cp -ax *.deb \${BLD_RESULT}/ || exit 1
cp -ax *.changes \${BLD_RESULT}/ || exit 1
cp -ax *.buildinfo \${BLD_RESULT}/ || exit 1
done < /data/repo/pkg/list_component
EOT
|
...