Blame vars/perl.vars

Lucio Andrés Illanes Albornoz (arab, vxp) 15af12
#
Lucio Andrés Illanes Albornoz e1d469
# set +o errexit -o noglob -o nounset is assumed.
Lucio Andrés Illanes Albornoz (arab, vxp) 15af12
#
Lucio Andrés Illanes Albornoz (arab, vxp) 15af12
Lucio Andrés Illanes Albornoz (arab, vxp) c27bea
pkg_perl_fetch_extract_post() {
e9fa07
	local _cflag="" _dname_dst="" _fname_dst="" _fname_src="";
Lucio Andrés Illanes Albornoz bf9edf
	if ! (		if ! rtl_fileop cd "${PKG_BASE_DIR}"; then
Lucio Andrés Illanes Albornoz bf9edf
				return 1;
Lucio Andrés Illanes Albornoz bf9edf
			else
Lucio Andrés Illanes Albornoz bf9edf
				for _fname_src in $(find perl-cross -type f -not -path perl-cross/.git/\* -not -name .gitignore); do
Lucio Andrés Illanes Albornoz bf9edf
					_fname_dst="perl-${PKG_VERSION}${_fname_src#perl-cross}";
Lucio Andrés Illanes Albornoz bf9edf
					if [ -f "${_fname_dst}" ]; then
Lucio Andrés Illanes Albornoz bf9edf
						if ! rtl_fileop mv "${_fname_dst}" "${_fname_dst}.orig"; then
Lucio Andrés Illanes Albornoz bf9edf
							return 1;
Lucio Andrés Illanes Albornoz bf9edf
						fi;
Lucio Andrés Illanes Albornoz bf9edf
					fi;
e9fa07
					rtl_dirname2 \$_fname_dst \$_dname_dst;
e9fa07
					if ! [ -d "${_dname_dst}" ]; then
e9fa07
						if ! rtl_fileop mkdir "${_dname_dst}"; then
Lucio Andrés Illanes Albornoz bf9edf
							return 1;
Lucio Andrés Illanes Albornoz bf9edf
						fi;
Lucio Andrés Illanes Albornoz bf9edf
					fi;
Lucio Andrés Illanes Albornoz bf9edf
					if ! rtl_fileop cp "${_fname_src}" "${_fname_dst}"; then
Lucio Andrés Illanes Albornoz bf9edf
						return 1;
Lucio Andrés Illanes Albornoz bf9edf
					fi;
Lucio Andrés Illanes Albornoz bf9edf
				done;
Lucio Andrés Illanes Albornoz bf9edf
			fi); then
Lucio Andrés Illanes Albornoz bf9edf
		return 1;
Lucio Andrés Illanes Albornoz bf9edf
	else
Lucio Andrés Illanes Albornoz bf9edf
		for _cflag in ${PKG_CFLAGS_CONFIGURE}; do
e9fa07
			rtl_lconcat \$PKG_CONFIGURE_ARGS "-A ccflags=${_cflag}";
Lucio Andrés Illanes Albornoz bf9edf
		done;
Lucio Andrés Illanes Albornoz bf9edf
	fi;
Lucio Andrés Illanes Albornoz (arab, vxp) 15af12
};
Lucio Andrés Illanes Albornoz (arab, vxp) 15af12
Lucio Andrés Illanes Albornoz bf9edf
# vim:filetype=sh textwidth=0