Commit a06ac245 authored by Pierre Schmitz's avatar Pierre Schmitz
Browse files

makechrootpkg: Handle install and changelog file the same way as in commitpkg

parent fbdcf6e3
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -243,12 +243,12 @@ cp PKGBUILD "$copydir/build/"
	done

	# Find all changelog and install files, even inside functions
	for i in changelog install; do
		sed -n "s/^[[:space:]]*$i=//p" PKGBUILD | while IFS= read -r file; do
	for i in 'changelog' 'install'; do
		while read -r file; do
			# evaluate any bash variables used
			eval file="$file"
			eval file=\"$(sed 's/^\(['\''"]\)\(.*\)\1$/\2/' <<< "$file")\"
			[[ -f $file ]] && cp "$file" "$copydir/build/"
		done
		done < <(sed -n "s/^[[:space:]]*$i=//p" PKGBUILD)
	done
)