It's one of the steps to be able to cross-build 'dev-util/mingw64-runtime'
("CBUILD != (CHOST = CTARGET)" case).
Noticed by Marty E. Plummer.
Package-Manager: Portage-2.3.24, Repoman-2.3.6
[[ ${CHOST} != ${CTARGET} ]]
}
just_headers() {
- use headers-only && [[ ${CHOST} != ${CTARGET} ]]
+ is_crosscompile && use headers-only
+}
+alt_prefix() {
+ is_crosscompile && echo /usr/${CTARGET}
}
crt_with() {
just_headers && echo --without-$1 || echo --with-$1
fi
CHOST=${CTARGET} econf \
- --prefix="${EPREFIX}"/usr/${CTARGET} \
- --includedir="${EPREFIX}"/usr/${CTARGET}/usr/include \
- --libdir="${EPREFIX}"/usr/${CTARGET}/usr/lib \
+ --prefix="${EPREFIX}"$(alt_prefix) \
+ --includedir="${EPREFIX}"$(alt_prefix)/usr/include \
+ --libdir="${EPREFIX}"$(alt_prefix)/usr/lib \
--with-headers \
--enable-sdk \
$(crt_with crt) \