Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 451082
Collapse All | Expand All

(-)a/gx86/eclass/distutils-r1.eclass (-2 / +20 lines)
Lines 345-351 _distutils-r1_merge_root() { Link Here
345
	local src=${1}
345
	local src=${1}
346
	local dest=${2}
346
	local dest=${2}
347
347
348
	cp -a -l -n "${src}"/. "${dest}"/ || die "Merging ${EPYTHON} image failed."
348
	local lockfile=${T}/distutils-r1-merge-lock
349
350
	if type -P lockf &>/dev/null; then
351
		# On BSD, we have 'lockf' wrapper.
352
		tar -C "${src}" -f - -c . \
353
			| lockf "${lockfile}" tar -x -f - -C "${dest}"
354
	else
355
		if type -P flock &>/dev/null; then
356
			# On Linux, we have 'flock' which can lock fd.
357
			local lock_fd
358
			redirect_alloc_fd lock_fd "${lockfile}" '>>'
359
			flock ${lock_fd}
360
		else
361
			ewarn "distutils-r1: no locking service found, please report."
362
		fi
363
364
		cp -a -l -n "${src}"/. "${dest}"/
365
	fi
366
	[[ ${?} == 0 ]] || die "Merging ${EPYTHON} image failed."
367
349
	rm -rf "${src}"
368
	rm -rf "${src}"
350
}
369
}
351
370
352
- 

Return to bug 451082