Index: server/buildpkgs/build_all.sh ================================================================== --- server/buildpkgs/build_all.sh +++ server/buildpkgs/build_all.sh @@ -180,21 +180,24 @@ fi if [ "${CLEANONLY}" = "1" ]; then exit 0 fi - mkdir -p "out/${PLATFORM}" >/dev/null 2>/dev/null + mkdir -p "out" >/dev/null 2>/dev/null - ./build.sh > "out/${PLATFORM}/build.log" 2>&1 || exit 1 + ./build.sh > "out/build-${PLATFORM}.log" 2>&1 || exit 1 ) || failed=1 if [ "${failed}" = "1" ]; then - cp "${dir}/out/${PLATFORM}/build.log" "${dir}/failed-${PLATFORM}-`hostname`.log" + cp "${dir}/out/build-${PLATFORM}.log" "${dir}/failed-${PLATFORM}-`hostname`.log" rm -rf "${dir}/out" faileddirs="${faileddirs} ${dir}" echo "Failed to build ${dir}" + else + outdir="$(ls -1d "${dir}/out"/*/"${PLATFORM}/" | head -1)" + mv "${dir}/out/build-${PLATFORM}.log" "${outdir}/build.log" fi done # Cleanup is done at this point if [ "${CLEANONLY}" = "1" ]; then @@ -212,8 +215,31 @@ if [ -z "${PKGHASHCODE}" ]; then OUTFILEBASE="tclpkgs-${PLATFORM}-${DATECODE}" else OUTFILEBASE="tclpkgs-${PKGHASHCODE}-${PLATFORM}-${DATECODE}" fi -tar -cf - */out | bzip2 -9c > "${OUTFILEBASE}.tar.bz2" + +rm -rf __tmp__ +mkdir __tmp__ +instdir="$(cd __tmp__ && pwd)" +for dir in */; do + basename="$(dirname "${dir}")" + pkginstdir="${instdir}/${dir}" + + ( + cd "${dir}/out" 2>/dev/null >/dev/null || exit 1 + + mkdir "${pkginstdir}" + + cp -r * "${pkginstdir}/" + ) +done + +( + cd __tmp__ || exit 1 + + tar -cf - * +) | bzip2 -9c > "${OUTFILEBASE}.tar.bz2" + +rm -rf __tmp__ exit 0 Index: server/buildpkgs/common.sh ================================================================== --- server/buildpkgs/common.sh +++ server/buildpkgs/common.sh @@ -107,9 +107,9 @@ done done } WORKDIR="${TMPDIR:-/tmp}/tcl-buildpkgs-$$${RANDOM}${RANDOM}${RANDOM}" -PLATDIR="$(pwd)/out/${PLATFORM}" +PLATDIR="$(pwd)/out/${VERS}/${PLATFORM}" export WORKDIR PLATDIR setup_tcl84