name = "GCC"
version = '4.7.1'
versionsuffix = "-CLooG-PPL"

homepage = 'http://gcc.gnu.org/'
description = """The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran,
 Java, and Ada, as well as libraries for these languages (libstdc++, libgcj,...)."""

toolchain = {'name': 'dummy', 'version': 'dummy'}

pplver = '0.12'

source_urls = [
    'http://ftpmirror.gnu.org/%(namelower)s/%(namelower)s-%(version)s',  # GCC auto-resolving HTTP mirror
    'http://ftpmirror.gnu.org/gmp',  # idem for GMP
    'http://ftpmirror.gnu.org/mpfr',  # idem for MPFR
    'http://www.multiprecision.org/mpc/download',  # MPC official
    'http://bugseng.com/products/ppl/download/ftp/releases/%s' % pplver,  # PPL official
    'http://www.bastoul.net/cloog/pages/download/',  # CLooG official
    'ftp://gcc.gnu.org/pub/gcc/infrastructure/',  # GCC dependencies, for PPL and CLooG-PPL
    'http://gcc.cybermirror.org/infrastructure/',  # HTTP mirror for GCC dependencies
]
sources = [
    SOURCELOWER_TAR_GZ,
    'gmp-5.0.5.tar.bz2',
    'mpfr-3.1.1.tar.gz',
    'mpc-1.0.tar.gz',
    'cloog-0.16.3.tar.gz',
    'ppl-%s.tar.gz' % pplver,
]

patches = ['mpfr-3.1.0-changes_fix.patch']

checksums = [
    '3d06e24570635c91eed6b114687513a6',     # gcc-4.7.1.tar.gz
    '041487d25e9c230b0c42b106361055fe',     # gmp-5.0.5.tar.bz2
    '769411e241a3f063ae1319eb5fac2462',     # mpfr-3.1.1.tar.gz
    '13370ceb2e266c5eeb2f7e78c24b7858',     # mpc-1.0.tar.gz
    'a0f8a241cd1c4f103f8d2c91642b3498',     # cloog-0.16.3.tar.gz
    '47a5548d4e3d98cf6b97e4fd3e5db513',     # ppl-0.12.tar.gz
    'fa4095252d843d465ac9aa5e2d760dd8',     # mpfr-3.1.0-changes_fix.patch
]

languages = ['c', 'c++', 'fortran']

withcloog = True
withppl = True

clooguseisl = True

# building GCC sometimes fails if make parallelism is too high, so let's limit it
maxparallel = 4

moduleclass = 'compiler'
