<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-infrastructure.
</pre>
<p><a href="https://github.com/macports/macports-infrastructure/commit/ef2636b13b81915f0ca14cd7e16254ff29fcda35">https://github.com/macports/macports-infrastructure/commit/ef2636b13b81915f0ca14cd7e16254ff29fcda35</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit ef2636b13b81915f0ca14cd7e16254ff29fcda35
</span>Author: Ryan Schmidt <ryandesign@macports.org>
AuthorDate: Mon Nov 14 16:43:48 2016 -0600
<span style='display:block; white-space:pre;color:#404040;'> mprsyncup: Generate all PortIndex files simultaneously
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> portindex is a CPU-bound operation. Run multiple portindexes at the
</span><span style='display:block; white-space:pre;color:#404040;'> same time to better use multiple CPU cores.
</span>---
jobs/mprsyncup | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/jobs/mprsyncup b/jobs/mprsyncup
</span><span style='display:block; white-space:pre;color:#808080;'>index c3c1776..4ae8830 100755
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/jobs/mprsyncup
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/jobs/mprsyncup
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -40,6 +40,7 @@ MKDIR="/bin/mkdir"
</span> LN="/bin/ln"
TAR="/usr/bin/tar"
OPENSSL="/usr/bin/openssl"
<span style='display:block; white-space:pre;background:#e0ffe0;'>+SED="/usr/bin/sed"
</span>
# Paths we'll work on:
ROOT=/var/tmp/macports
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -115,8 +116,6 @@ else
</span> ${SVN} checkout ${PORTSURL} ${PORTS}
fi
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# generate platform-specific indexes
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-pushd ${PORTS} >> /dev/null
</span> # build MP in a private location for indexing
pushd ${RBASE} >> /dev/null
./configure \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -129,10 +128,17 @@ make install
</span> make distclean
popd
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# generate platform-specific indexes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+pushd ${PORTS} >> /dev/null
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+PIDS=()
</span> for PLATFORM in $PLATFORMS; do
<span style='display:block; white-space:pre;background:#ffe0e0;'>- $PORTINDEX -p macosx_${PLATFORM} -o PortIndex_darwin_${PLATFORM};
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ INDEX="PortIndex_darwin_${PLATFORM}"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${PORTINDEX} -p macosx_${PLATFORM} -o ${INDEX} | ${SED} "s/^/Updating ${INDEX}: /" &
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PIDS+=($!)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+done
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+for PID in ${PIDS[*]}; do
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ wait ${PID}
</span> done
<span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> popd
if [ ! -d ${RSYNCROOT}/release/ports ]; then
</pre><pre style='margin:0'>
</pre>