# $Id$ PortSystem 1.0 set major 4.2 name llvm-gcc42 version 2.2 categories lang platforms darwin maintainers erickt@macports.org openmaintainer description llvm is a next generation compiler infrastructure long_description llvm brings tools to work on the llvm intermediate \ language incl. a C and C++ frontend. homepage http://llvm.org/ master_sites http://llvm.org/releases/${version}/ distname llvm-gcc${major}-${version}.source checksums md5 7591c949eed3efc7a8b802b8f97effcc \ sha1 1b91f4575521cdad76ecbe57f0405eb0e50f17e6 \ rmd160 537c4085c2184277a39a92e3b631e327df57452d depends_lib port:llvm worksrcdir build pre-patch { file mkdir ${workpath}/build } patchfiles patch-gcc_Makefile.in configure.cmd ../llvm-gcc${major}-${version}.source/configure configure.args-append --enable-llvm=${prefix}/lib/llvm/obj \ --enable-languages=c,c++,objc,obj-c++ \ --libdir=${prefix}/lib/${name} \ --libexecdir=${prefix}/libexec/${name} \ --includedir=${prefix}/include/${name} \ --infodir=${prefix}/share/info \ --mandir=${prefix}/share/man \ --with-local-prefix=${prefix} \ --program-prefix=llvm- \ --program-suffix=-${major} \ --disable-nls destroot.destdir prefix=${destroot}${prefix} \ libdir=${destroot}${prefix}/lib/${name} \ libexecdir=${destroot}${prefix}/libexec/${name} \ includedir=${destroot}${prefix}/include/${name} \ infodir=${destroot}${prefix}/share/info \ mandir=${destroot}${prefix}/share/man post-destroot { cd ${destroot}${prefix} file delete -force share/man/man7 file delete -force share/info file delete -force bin/gccld file delete -force bin/gccas } platform darwin { post-extract { system "rm -rf ${workpath}/llvm-gcc${major}-${version}.source/libstdc++-v3" } configure.args-append --with-gxx-include-dir=/usr/include/c++/4.0.0 } platform powerpc { set triple powerpc-apple-darwin8 configure.env-append TRIPLE=${triple} configure.post_args --build=${triple} --host=${triple} --target=${triple} } platform x86 { set triple i686-apple-darwin8 configure.env-append TRIPLE=${triple} \ TARGETOPTIONS="--with-arch=nocona --with-tune=generic" configure.post_args --build=${triple} --host=${triple} --target=${triple} }