3.18. gmp-6.2.1
#!/bin/sh # Copyright © 1999-2022 Gerard Beekmans # Copyright © 2017-2022 Random Crew # Distributed under the terms of MIT License.
Configuration
Variable target is given to configure to ensure correct detection of platform.
We check automatically for 32 or 64 capacity by string:
$(ause_enable 'cap32' 'ABI=32' ) \
ause_enable is method of any build system. It checks, whether condition cap32 is present in current build configuration. If it is, then method prints the second argument, ABI=32. If no, it prints nothing and parameter is not added. In this way we may dynamically detect some conditions and add options, depending on them.
cap32 is an element of configuration, when build goes in 32-bit mode.
src_config() { cp configfsf.guess config.guess cp configfsf.sub config.sub target="$(uname -m)-unknown-linux-gnu" $(ause_enable 'cap32' 'ABI=32' ) \ ./configure \ --prefix=${PREFIX} \ --build=${target} \ --enable-cxx \ --disable-static \ --docdir=${PREFIX}/share/doc/${P} }
Compilation
src_compile() { make ${MAKEOPTS} make ${MAKEOPTS} html }
Installation
src_install() { make install ${MAKEOPTS} DESTDIR=${D} make install-html ${MAKEOPTS} DESTDIR=${D} }
Unit testing
src_check() { make check 2>&1 | tee gmp-check-log awk '/# PASS:/{total+=$3} ; END{print total}' gmp-check-log }
Build code
Other files
Links
- url.lfs: https://linuxfromscratch.org/lfs/view/11.1/chapter08/gmp.html
- url.lfs.stage1: