|
|
| |
LICENSE="GPL-2" | LICENSE="GPL-2" |
SLOT="0" | SLOT="0" |
KEYWORDS="alpha amd64 hppa mips ppc x86" |
KEYWORDS="alpha amd64 hppa mips ppc ~sparc x86" |
IUSE="doc emacs" | IUSE="doc emacs" |
| |
DEPEND="doc? ( virtual/tetex )" | DEPEND="doc? ( virtual/tetex )" |
|
|
# Fix usage of toolchain | # Fix usage of toolchain |
tc-getAS; tc-getLD; tc-getCC; tc-getCXX | tc-getAS; tc-getLD; tc-getCC; tc-getCXX |
| |
|
# Special handling for sparc |
|
local myhost |
|
[ "${PROFILE_ARCH}" == "sparc64" ] && myhost="sparc64-linux" \ |
|
|| myhost="$(echo ${CHOST} | cut -f "1 3" -d '-')" |
|
einfo "Building for ${myhost}" |
|
|
#need to force optimization here, as it breaks without | #need to force optimization here, as it breaks without |
if is-flag -O0; then | if is-flag -O0; then |
replace-flags -O0 -O2 | replace-flags -O0 -O2 |
|
|
if [ "${ARCH}" = "amd64" ] && ! is-flag -fPIC; then append-flags -fPIC; fi | if [ "${ARCH}" = "amd64" ] && ! is-flag -fPIC; then append-flags -fPIC; fi |
| |
./Configure \ | ./Configure \ |
--host="$(echo ${CHOST} | cut -f "1 3" -d '-')" \ |
--host=${myhost} \ |
--prefix=/usr \ | --prefix=/usr \ |
--miscdir=/usr/share/doc/${PF} \ | --miscdir=/usr/share/doc/${PF} \ |
--datadir=/usr/share/${P} \ | --datadir=/usr/share/${P} \ |