1.1 --- a/scripts/build/companion_libs/mpc.sh Sun Jul 17 18:56:30 2011 +0200
1.2 +++ b/scripts/build/companion_libs/mpc.sh Sun Jul 24 23:53:14 2011 +0200
1.3 @@ -4,6 +4,7 @@
1.4
1.5 do_mpc_get() { :; }
1.6 do_mpc_extract() { :; }
1.7 +do_mpc_for_build() { :; }
1.8 do_mpc_for_host() { :; }
1.9
1.10 # Overide functions depending on configuration
1.11 @@ -21,6 +22,28 @@
1.12 CT_Patch "mpc" "${CT_MPC_VERSION}"
1.13 }
1.14
1.15 +# Build MPC for running on build
1.16 +# - always build statically
1.17 +# - we do not have build-specific CFLAGS
1.18 +# - install in build-tools prefix
1.19 +do_mpc_for_build() {
1.20 + local -a mpc_opts
1.21 +
1.22 + case "${CT_TOOLCHAIN_TYPE}" in
1.23 + native|cross) return 0;;
1.24 + esac
1.25 +
1.26 + CT_DoStep INFO "Installing MPC for build"
1.27 + CT_mkdir_pushd "${CT_BUILD_DIR}/build-mpc-build-${CT_BUILD}"
1.28 +
1.29 + mpc_opts+=( "host=${CT_BUILD}" )
1.30 + mpc_opts+=( "prefix=${CT_BUILDTOOLS_PREFIX_DIR}" )
1.31 + do_mpc_backend "${mpc_opts[@]}"
1.32 +
1.33 + CT_Popd
1.34 + CT_EndStep
1.35 +}
1.36 +
1.37 # Build MPC for running on host
1.38 do_mpc_for_host() {
1.39 local -a mpc_opts