xbps-src: introduce "nocross" to not allow cross compilation.

This commit is contained in:
Juan RP 2014-08-21 12:07:44 +02:00
parent 954e1aff05
commit 108a6d3fac
3 changed files with 6 additions and 1 deletions

View File

@ -384,6 +384,8 @@ by all supported architectures.
- `nostrip` If set, the ELF binaries with debugging symbols won't be stripped. By
default all binaries are stripped.
- `nocross` If set, cross compilation won't be allowed and will exit with an error.
- `python_versions` A white space seperated list of python versions which will
be used to build that package. This is only used by the `python-module` build style.

View File

@ -3,7 +3,7 @@
## VARIABLES
unset -v pkgname version revision short_desc homepage license maintainer
unset -v only_for_archs distfiles checksum build_style nonfree
unset -v only_for_archs distfiles checksum build_style nonfree nocross
unset -v configure_script configure_args wrksrc build_wrksrc create_wrksrc
unset -v make_cmd make_build_args make_install_args make_build_target make_install_target python_versions
unset -v patch_args disable_parallel_build keep_libtool_archives

View File

@ -388,6 +388,9 @@ setup_pkg() {
wrksrc="$XBPS_BUILDDIR/$wrksrc"
fi
if [ "$cross" -a "$nocross" ]; then
msg_error "$pkgver: cannot be cross compiled, exiting...\n"
fi
}
setup_pkg_depends() {