1 # This file adds the functions to build the PPL library
2 # Copyright 2009 Yann E. MORIN
3 # Licensed under the GPL v2. See COPYING in the root of this package
6 do_ppl_extract() { :; }
7 do_ppl_for_host() { :; }
9 # Overide functions depending on configuration
10 if [ "${CT_PPL}" = "y" ]; then
14 CT_GetFile "ppl-${CT_PPL_VERSION}" \
15 http://www.cs.unipr.it/ppl/Download/ftp/releases/${CT_PPL_VERSION} \
16 ftp://ftp.cs.unipr.it/pub/ppl/releases/${CT_PPL_VERSION} \
17 ftp://gcc.gnu.org/pub/gcc/infrastructure
22 CT_Extract "ppl-${CT_PPL_VERSION}"
23 CT_Patch "ppl" "${CT_PPL_VERSION}"
26 # Build PPL for running on host
30 CT_DoStep INFO "Installing PPL for host"
31 CT_mkdir_pushd "${CT_BUILD_DIR}/build-ppl-host-${CT_HOST}"
33 ppl_opts+=( "host=${CT_HOST}" )
34 ppl_opts+=( "prefix=${CT_COMPLIBS_DIR}" )
35 ppl_opts+=( "cflags=${CT_CFLAGS_FOR_HOST}" )
36 do_ppl_backend "${ppl_opts[@]}"
43 # Parameter : description : type : default
44 # host : machine to run on : tuple : (none)
45 # prefix : prefix to install into : dir : (none)
46 # cflags : host cflags to use : string : (empty)
57 CT_DoLog EXTRA "Configuring PPL"
61 CXXFLAGS="${cflags}" \
62 "${CT_SRC_DIR}/ppl-${CT_PPL_VERSION}/configure" \
65 --prefix="${prefix}" \
66 --with-libgmp-prefix="${prefix}" \
67 --with-libgmpxx-prefix="${prefix}" \
68 --with-gmp-prefix="${prefix}" \
71 --disable-assertions \
75 --enable-interfaces='c c++' \
79 # --enable-optimization=speed or sspeed (yes, with 2 's')
81 CT_DoLog EXTRA "Building PPL"
82 CT_DoExecLog ALL make ${JOBSFLAGS}
84 if [ "${CT_COMPLIBS_CHECK}" = "y" ]; then
85 CT_DoLog EXTRA "Checking PPL"
86 CT_DoExecLog ALL make ${JOBSFLAGS} -s check
89 CT_DoLog EXTRA "Installing PPL"
90 CT_DoExecLog ALL make install
92 # Remove spuriously installed file
93 CT_DoExecLog ALL rm -f "${prefix}/bin/ppl-config"