summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /dev-lang
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/R/Manifest7
-rw-r--r--dev-lang/R/R-3.0.1.ebuild206
-rw-r--r--dev-lang/R/R-3.0.3.ebuild203
-rw-r--r--dev-lang/R/R-3.1.0.ebuild206
-rw-r--r--dev-lang/R/R-3.1.1.ebuild206
-rw-r--r--dev-lang/R/R-3.1.2.ebuild206
-rw-r--r--dev-lang/R/R-3.2.0-r1.ebuild207
-rw-r--r--dev-lang/R/files/R-2.11.1-parallel.patch17
-rw-r--r--dev-lang/R/files/R-2.12.1-ldflags.patch15
-rw-r--r--dev-lang/R/files/R-2.13.1-zlib_header_fix.patch20
-rw-r--r--dev-lang/R/files/R-2.14.1-rmath-shared.patch24
-rw-r--r--dev-lang/R/files/R-3.0.0-rmath-shared.patch28
-rw-r--r--dev-lang/R/files/R-3.2.0-omitted-extern-R_running_as_main_program.patch12
-rw-r--r--dev-lang/R/metadata.xml25
-rw-r--r--dev-lang/ats/Manifest1
-rw-r--r--dev-lang/ats/ats-0.2.9.ebuild34
-rw-r--r--dev-lang/ats/metadata.xml8
-rw-r--r--dev-lang/bas/Manifest1
-rw-r--r--dev-lang/bas/bas-2.4.ebuild40
-rw-r--r--dev-lang/bas/files/bas-2.1-makefile.patch49
-rw-r--r--dev-lang/bas/metadata.xml10
-rw-r--r--dev-lang/bashforth/Manifest1
-rw-r--r--dev-lang/bashforth/bashforth-0.58a.ebuild25
-rw-r--r--dev-lang/bashforth/metadata.xml8
-rw-r--r--dev-lang/bff/Manifest2
-rw-r--r--dev-lang/bff/bff-1.0.3.1.ebuild41
-rw-r--r--dev-lang/bff/metadata.xml12
-rw-r--r--dev-lang/blassic/Manifest1
-rw-r--r--dev-lang/blassic/blassic-0.10.2.ebuild33
-rw-r--r--dev-lang/blassic/files/blassic-0.10.2-tinfo.patch12
-rw-r--r--dev-lang/blassic/metadata.xml14
-rw-r--r--dev-lang/c-intercal/Manifest1
-rw-r--r--dev-lang/c-intercal/c-intercal-29.0.ebuild76
-rw-r--r--dev-lang/c-intercal/files/50c-intercal-gentoo.el4
-rw-r--r--dev-lang/c-intercal/metadata.xml17
-rw-r--r--dev-lang/cfortran/Manifest2
-rw-r--r--dev-lang/cfortran/cfortran-4.4-r2.ebuild38
-rw-r--r--dev-lang/cfortran/cfortran-4.4-r3.ebuild50
-rw-r--r--dev-lang/cfortran/metadata.xml11
-rw-r--r--dev-lang/cilk/Manifest1
-rw-r--r--dev-lang/cilk/cilk-5.4.6-r1.ebuild36
-rw-r--r--dev-lang/cilk/files/cilk-5.4.6-autotools.patch81
-rw-r--r--dev-lang/cilk/metadata.xml16
-rw-r--r--dev-lang/cll1h/Manifest1
-rw-r--r--dev-lang/cll1h/cll1h-0.6-r1.ebuild26
-rw-r--r--dev-lang/cll1h/metadata.xml7
-rw-r--r--dev-lang/clojure/Manifest2
-rw-r--r--dev-lang/clojure/clojure-1.5.1.ebuild33
-rw-r--r--dev-lang/clojure/clojure-1.6.0.ebuild33
-rw-r--r--dev-lang/clojure/metadata.xml11
-rw-r--r--dev-lang/closure-compiler-bin/Manifest5
-rw-r--r--dev-lang/closure-compiler-bin/closure-compiler-bin-20120305.ebuild30
-rw-r--r--dev-lang/closure-compiler-bin/closure-compiler-bin-20121212.ebuild30
-rw-r--r--dev-lang/closure-compiler-bin/closure-compiler-bin-20130227.ebuild30
-rw-r--r--dev-lang/closure-compiler-bin/closure-compiler-bin-20130411.ebuild30
-rw-r--r--dev-lang/closure-compiler-bin/closure-compiler-bin-20150126.ebuild30
-rw-r--r--dev-lang/closure-compiler-bin/metadata.xml11
-rw-r--r--dev-lang/coffee-script/Manifest1
-rw-r--r--dev-lang/coffee-script/coffee-script-1.9.3-r1.ebuild48
-rw-r--r--dev-lang/coffee-script/metadata.xml11
-rw-r--r--dev-lang/confluence/Manifest1
-rw-r--r--dev-lang/confluence/confluence-0.10.6.ebuild47
-rw-r--r--dev-lang/confluence/metadata.xml5
-rw-r--r--dev-lang/dmd-bin/Manifest2
-rw-r--r--dev-lang/dmd-bin/dmd-bin-1.016.ebuild109
-rw-r--r--dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild105
-rw-r--r--dev-lang/dmd-bin/files/25dmd2
-rw-r--r--dev-lang/dmd-bin/metadata.xml9
-rw-r--r--dev-lang/ekopath/Manifest3
-rw-r--r--dev-lang/ekopath/ekopath-6.0.430_p20150629.ebuild74
-rw-r--r--dev-lang/ekopath/ekopath-6.0.439_p20150707.ebuild74
-rw-r--r--dev-lang/ekopath/ekopath-6.0.468_p20150803.ebuild74
-rw-r--r--dev-lang/ekopath/metadata.xml16
-rw-r--r--dev-lang/elixir/Manifest11
-rw-r--r--dev-lang/elixir/elixir-0.11.2.ebuild28
-rw-r--r--dev-lang/elixir/elixir-0.12.5.ebuild28
-rw-r--r--dev-lang/elixir/elixir-0.13.3.ebuild28
-rw-r--r--dev-lang/elixir/elixir-0.14.3.ebuild28
-rw-r--r--dev-lang/elixir/elixir-0.15.1.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.0.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.1.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.2.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.3.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.4.ebuild28
-rw-r--r--dev-lang/elixir/elixir-1.0.5.ebuild28
-rw-r--r--dev-lang/elixir/metadata.xml26
-rw-r--r--dev-lang/epic/Manifest4
-rw-r--r--dev-lang/epic/epic-0.9.2.ebuild27
-rw-r--r--dev-lang/epic/epic-0.9.3.2.ebuild33
-rw-r--r--dev-lang/epic/epic-0.9.3.3.ebuild34
-rw-r--r--dev-lang/epic/epic-0.9.3.ebuild29
-rw-r--r--dev-lang/epic/files/epic-0.9.3-ghc-7.6.patch53
-rw-r--r--dev-lang/epic/files/respect-user-cflags.patch13
-rw-r--r--dev-lang/epic/metadata.xml17
-rw-r--r--dev-lang/erlang/Manifest12
-rw-r--r--dev-lang/erlang/erlang-15.2.3.1.ebuild175
-rw-r--r--dev-lang/erlang/erlang-17.3.ebuild159
-rw-r--r--dev-lang/erlang/erlang-17.5.ebuild159
-rw-r--r--dev-lang/erlang/erlang-18.0.ebuild158
-rw-r--r--dev-lang/erlang/files/16.2-tinfo.patch11
-rw-r--r--dev-lang/erlang/files/17.0-systemd.patch85
-rw-r--r--dev-lang/erlang/files/50erlang-gentoo.el5
-rw-r--r--dev-lang/erlang/files/epmd.init20
-rw-r--r--dev-lang/erlang/files/epmd.service9
-rw-r--r--dev-lang/erlang/metadata.xml22
-rw-r--r--dev-lang/esco/Manifest1
-rw-r--r--dev-lang/esco/esco-0.512.ebuild32
-rw-r--r--dev-lang/esco/metadata.xml11
-rw-r--r--dev-lang/execline/Manifest1
-rw-r--r--dev-lang/execline/execline-2.1.1.0.ebuild55
-rw-r--r--dev-lang/execline/metadata.xml13
-rw-r--r--dev-lang/f2c/Manifest3
-rw-r--r--dev-lang/f2c/f2c-20060507.ebuild37
-rw-r--r--dev-lang/f2c/f2c-20100827.ebuild51
-rw-r--r--dev-lang/f2c/metadata.xml15
-rw-r--r--dev-lang/falcon/Manifest1
-rw-r--r--dev-lang/falcon/falcon-0.9.6.4.ebuild51
-rw-r--r--dev-lang/falcon/metadata.xml5
-rw-r--r--dev-lang/ferite/Manifest1
-rw-r--r--dev-lang/ferite/ferite-1.1.17-r1.ebuild79
-rw-r--r--dev-lang/ferite/files/ferite-pcre.patch26
-rw-r--r--dev-lang/ferite/metadata.xml10
-rw-r--r--dev-lang/fpc/Manifest18
-rw-r--r--dev-lang/fpc/fpc-2.6.2.ebuild174
-rw-r--r--dev-lang/fpc/fpc-2.6.4.ebuild175
-rw-r--r--dev-lang/fpc/metadata.xml11
-rw-r--r--dev-lang/fsharp/Manifest1
-rw-r--r--dev-lang/fsharp/fsharp-3.1.1.31.ebuild28
-rw-r--r--dev-lang/fsharp/metadata.xml11
-rw-r--r--dev-lang/gdl/Manifest2
-rw-r--r--dev-lang/gdl/files/0.9.2-antlr.patch76
-rw-r--r--dev-lang/gdl/files/0.9.2-include.patch10
-rw-r--r--dev-lang/gdl/files/0.9.2-proj4.patch27
-rw-r--r--dev-lang/gdl/files/0.9.2-semaphore.patch22
-rw-r--r--dev-lang/gdl/files/0.9.3-plwidth.patch158
-rw-r--r--dev-lang/gdl/files/0.9.4-gsl.patch62
-rw-r--r--dev-lang/gdl/files/0.9.4-plplot.patch18
-rw-r--r--dev-lang/gdl/files/0.9.4-python.patch12
-rw-r--r--dev-lang/gdl/files/0.9.4-python2.patch17
-rw-r--r--dev-lang/gdl/files/0.9.4-reorder.patch380
-rw-r--r--dev-lang/gdl/files/0.9.5-antlr.patch91
-rw-r--r--dev-lang/gdl/files/0.9.5-plplot.patch134
-rw-r--r--dev-lang/gdl/files/0.9.5-png.patch15
-rw-r--r--dev-lang/gdl/files/0.9.5-proj4.patch41
-rw-r--r--dev-lang/gdl/gdl-0.9.4.ebuild161
-rw-r--r--dev-lang/gdl/gdl-0.9.5.ebuild156
-rw-r--r--dev-lang/gdl/metadata.xml21
-rw-r--r--dev-lang/gforth/Manifest1
-rw-r--r--dev-lang/gforth/files/0.6.2-c-to-forth-to-c.patch30
-rw-r--r--dev-lang/gforth/files/0.6.2-ppc-configure-gentoo.patch13
-rw-r--r--dev-lang/gforth/files/50gforth-gentoo.el7
-rw-r--r--dev-lang/gforth/files/gforth-0.7.0-make-elc.patch14
-rw-r--r--dev-lang/gforth/files/gforth.el-gentoo.patch37
-rw-r--r--dev-lang/gforth/gforth-0.7.3.ebuild60
-rw-r--r--dev-lang/gforth/metadata.xml9
-rw-r--r--dev-lang/ghc/Manifest34
-rw-r--r--dev-lang/ghc/files/ghc-7.0.4-CHOST-prefix.patch17
-rw-r--r--dev-lang/ghc/files/ghc-7.0.4-darwin8.patch18
-rw-r--r--dev-lang/ghc/files/ghc-7.10.1-T10590-dequeue.patch89
-rw-r--r--dev-lang/ghc/files/ghc-7.10.1-rc3-ghc-7.10-bootstrap.patch78
-rw-r--r--dev-lang/ghc/files/ghc-7.2.1-freebsd-CHOST.patch13
-rw-r--r--dev-lang/ghc/files/ghc-7.4-rc2-macos-prefix-respect-gcc.patch23
-rw-r--r--dev-lang/ghc/files/ghc-7.4.1-darwin-CHOST.patch18
-rw-r--r--dev-lang/ghc/files/ghc-7.4.1-ticket-7339-fix-unaligned-unreg.patch28
-rw-r--r--dev-lang/ghc/files/ghc-7.4.2-system-libffi.patch119
-rw-r--r--dev-lang/ghc/files/ghc-7.5.20120505-system-libffi.patch88
-rw-r--r--dev-lang/ghc/files/ghc-7.6.2-integer-simple-div-mod.patch57
-rw-r--r--dev-lang/ghc/files/ghc-7.6.3-preserve-inplace-xattr.patch14
-rw-r--r--dev-lang/ghc/files/ghc-7.6.3-trac-3333-weak-syms.patch387
-rw-r--r--dev-lang/ghc/files/ghc-7.8.1_rc1-libbfd.patch81
-rw-r--r--dev-lang/ghc/files/ghc-7.8.2-cgen-constify.patch34
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-cc-lang.patch129
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-deRefStablePtr.patch38
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-ia64-prim.patch69
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-linker-warn.patch35
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-pic-asm.patch107
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-pic-sparc.patch31
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-ppc32-fPIC.patch351
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-prim-lm.patch12
-rw-r--r--dev-lang/ghc/files/ghc-7.8.3-unreg-lit.patch84
-rw-r--r--dev-lang/ghc/files/ghc-7.8.4-gold.patch27
-rw-r--r--dev-lang/ghc/files/ghc-7.8.4-ia64-CLOSUREs.patch66
-rw-r--r--dev-lang/ghc/files/ghc-bash-completion218
-rw-r--r--dev-lang/ghc/files/terminfo-0.3.2.5-tinfo.patch25
-rw-r--r--dev-lang/ghc/ghc-7.10.2.ebuild643
-rw-r--r--dev-lang/ghc/ghc-7.4.2.ebuild639
-rw-r--r--dev-lang/ghc/ghc-7.6.3-r1.ebuild828
-rw-r--r--dev-lang/ghc/ghc-7.8.3.ebuild615
-rw-r--r--dev-lang/ghc/ghc-7.8.4.ebuild618
-rw-r--r--dev-lang/ghc/metadata.xml11
-rw-r--r--dev-lang/gnat-gcc/Manifest28
-rw-r--r--dev-lang/gnat-gcc/files/gcc-configure-LANG.patch41
-rw-r--r--dev-lang/gnat-gcc/files/gnat-Make-lang.in.patch14
-rw-r--r--dev-lang/gnat-gcc/files/gnat-gcc-4.5.4-tex-version-workaround.patch75
-rw-r--r--dev-lang/gnat-gcc/files/patches/4.3/01-siginfo.patch121
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-3.4.6.ebuild33
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.1.2.ebuild47
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.2.3.ebuild50
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.3.5.ebuild70
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.3.6.ebuild64
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.4.7.ebuild63
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.5.4.ebuild75
-rw-r--r--dev-lang/gnat-gcc/gnat-gcc-4.6.4.ebuild61
-rw-r--r--dev-lang/gnat-gcc/metadata.xml15
-rw-r--r--dev-lang/gnat-gpl/Manifest16
-rw-r--r--dev-lang/gnat-gpl/files/gcc-configure-LANG.patch41
-rw-r--r--dev-lang/gnat-gpl/files/gnat-Make-lang.in.patch14
-rw-r--r--dev-lang/gnat-gpl/files/patches/51_all_gcc-3.4-libiberty-pic.patch10
-rw-r--r--dev-lang/gnat-gpl/files/patches/74_all_sh-pr24836.patch25
-rw-r--r--dev-lang/gnat-gpl/gnat-gpl-3.4.5.2005.ebuild79
-rw-r--r--dev-lang/gnat-gpl/gnat-gpl-3.4.6.2006-r1.ebuild86
-rw-r--r--dev-lang/gnat-gpl/gnat-gpl-4.1.3.2007.ebuild67
-rw-r--r--dev-lang/gnat-gpl/gnat-gpl-4.1.3.2008-r2.ebuild75
-rw-r--r--dev-lang/gnat-gpl/metadata.xml12
-rw-r--r--dev-lang/gnu-smalltalk/Manifest1
-rw-r--r--dev-lang/gnu-smalltalk/files/50gnu-smalltalk-gentoo.el7
-rw-r--r--dev-lang/gnu-smalltalk/files/SequenceableCollection-size-3.2.4.patch23
-rw-r--r--dev-lang/gnu-smalltalk/gnu-smalltalk-3.2.4.ebuild73
-rw-r--r--dev-lang/gnu-smalltalk/metadata.xml14
-rw-r--r--dev-lang/go-bootstrap/Manifest1
-rw-r--r--dev-lang/go-bootstrap/go-bootstrap-1.4.2.ebuild83
-rw-r--r--dev-lang/go-bootstrap/metadata.xml13
-rw-r--r--dev-lang/go/Manifest1
-rw-r--r--dev-lang/go/go-1.4.2.ebuild126
-rw-r--r--dev-lang/go/go-9999.ebuild127
-rw-r--r--dev-lang/go/metadata.xml13
-rw-r--r--dev-lang/gpc/Manifest3
-rw-r--r--dev-lang/gpc/gpc-20051104.ebuild160
-rw-r--r--dev-lang/gpc/gpc-20070904.ebuild161
-rw-r--r--dev-lang/gpc/metadata.xml8
-rw-r--r--dev-lang/gprolog/Manifest1
-rw-r--r--dev-lang/gprolog/files/gprolog-1.4.4-ldflags.patch40
-rw-r--r--dev-lang/gprolog/files/gprolog-1.4.4-links.patch16
-rw-r--r--dev-lang/gprolog/files/gprolog-1.4.4-nodocs.patch30
-rw-r--r--dev-lang/gprolog/files/gprolog-1.4.4-txt-file.patch11
-rw-r--r--dev-lang/gprolog/gprolog-1.4.4.ebuild68
-rw-r--r--dev-lang/gprolog/metadata.xml5
-rw-r--r--dev-lang/gwydion-dylan-bin/Manifest1
-rw-r--r--dev-lang/gwydion-dylan-bin/files/20gwydion-dylan-bin4
-rw-r--r--dev-lang/gwydion-dylan-bin/gwydion-dylan-bin-2.4.0-r1.ebuild30
-rw-r--r--dev-lang/gwydion-dylan-bin/metadata.xml17
-rw-r--r--dev-lang/helium/Manifest3
-rw-r--r--dev-lang/helium/files/helium-1.6-respect-cflags-ldflags-nostrip.patch59
-rw-r--r--dev-lang/helium/files/helium-wrapper-1.631
-rw-r--r--dev-lang/helium/helium-1.6.ebuild105
-rw-r--r--dev-lang/helium/helium-1.8.1.ebuild32
-rw-r--r--dev-lang/helium/metadata.xml5
-rw-r--r--dev-lang/hy/Manifest4
-rw-r--r--dev-lang/hy/hy-0.10.0.ebuild32
-rw-r--r--dev-lang/hy/hy-0.10.1.ebuild32
-rw-r--r--dev-lang/hy/hy-0.11.0.ebuild34
-rw-r--r--dev-lang/hy/hy-0.9.12.ebuild32
-rw-r--r--dev-lang/hy/metadata.xml11
-rw-r--r--dev-lang/icc/Manifest23
-rw-r--r--dev-lang/icc/icc-13.0.0.079.ebuild37
-rw-r--r--dev-lang/icc/icc-13.0.1.117.ebuild37
-rw-r--r--dev-lang/icc/icc-13.1.2.146.ebuild39
-rw-r--r--dev-lang/icc/icc-13.1.3.163.ebuild39
-rw-r--r--dev-lang/icc/icc-13.1.5.192.ebuild36
-rw-r--r--dev-lang/icc/icc-14.0.0.080.ebuild37
-rw-r--r--dev-lang/icc/icc-14.0.1.106.ebuild37
-rw-r--r--dev-lang/icc/icc-14.0.2.144.ebuild37
-rw-r--r--dev-lang/icc/icc-14.0.3.174.ebuild37
-rw-r--r--dev-lang/icc/icc-15.0.0.090.ebuild37
-rw-r--r--dev-lang/icc/icc-15.0.1.133.ebuild37
-rw-r--r--dev-lang/icc/icc-15.0.2.164.ebuild37
-rw-r--r--dev-lang/icc/icc-15.0.3.187.ebuild37
-rw-r--r--dev-lang/icc/metadata.xml16
-rw-r--r--dev-lang/icon/Manifest2
-rw-r--r--dev-lang/icon/files/icon-9.4.3-flags.patch62
-rw-r--r--dev-lang/icon/files/icon-9.5.0-flags.patch75
-rw-r--r--dev-lang/icon/files/tests-943.patch113
-rw-r--r--dev-lang/icon/icon-9.4.3-r5.ebuild107
-rw-r--r--dev-lang/icon/icon-9.5.0.ebuild104
-rw-r--r--dev-lang/icon/metadata.xml6
-rw-r--r--dev-lang/idb/Manifest19
-rw-r--r--dev-lang/idb/files/50idb-gentoo.el5
-rw-r--r--dev-lang/idb/idb-13.0.0.079.ebuild24
-rw-r--r--dev-lang/idb/idb-13.0.1.117-r1.ebuild32
-rw-r--r--dev-lang/idb/idb-13.0.2.146.ebuild34
-rw-r--r--dev-lang/idb/idb-13.0.3.163.ebuild34
-rw-r--r--dev-lang/idb/idb-13.0.5.192.ebuild34
-rw-r--r--dev-lang/idb/idb-14.0.0.080.ebuild41
-rw-r--r--dev-lang/idb/idb-14.0.1.106.ebuild41
-rw-r--r--dev-lang/idb/idb-14.0.2.144.ebuild41
-rw-r--r--dev-lang/idb/idb-14.0.3.174.ebuild41
-rw-r--r--dev-lang/idb/metadata.xml18
-rw-r--r--dev-lang/ifc/Manifest23
-rw-r--r--dev-lang/ifc/ifc-13.0.0.079-r1.ebuild38
-rw-r--r--dev-lang/ifc/ifc-13.0.1.117.ebuild38
-rw-r--r--dev-lang/ifc/ifc-13.1.2.146.ebuild38
-rw-r--r--dev-lang/ifc/ifc-13.1.3.163.ebuild38
-rw-r--r--dev-lang/ifc/ifc-13.1.5.192.ebuild34
-rw-r--r--dev-lang/ifc/ifc-14.0.0.080.ebuild35
-rw-r--r--dev-lang/ifc/ifc-14.0.1.106.ebuild35
-rw-r--r--dev-lang/ifc/ifc-14.0.2.144.ebuild35
-rw-r--r--dev-lang/ifc/ifc-14.0.3.174.ebuild35
-rw-r--r--dev-lang/ifc/ifc-15.0.0.090.ebuild35
-rw-r--r--dev-lang/ifc/ifc-15.0.1.133.ebuild35
-rw-r--r--dev-lang/ifc/ifc-15.0.2.164.ebuild38
-rw-r--r--dev-lang/ifc/ifc-15.0.3.187.ebuild36
-rw-r--r--dev-lang/ifc/metadata.xml14
-rw-r--r--dev-lang/inform/Manifest1
-rw-r--r--dev-lang/inform/inform-6.33.1_p2.ebuild26
-rw-r--r--dev-lang/inform/metadata.xml41
-rw-r--r--dev-lang/interprolog/Manifest1
-rw-r--r--dev-lang/interprolog/files/build.xml45
-rw-r--r--dev-lang/interprolog/files/interprolog-2.1.2-java1.4.patch24
-rw-r--r--dev-lang/interprolog/interprolog-2.1.2.ebuild61
-rw-r--r--dev-lang/interprolog/metadata.xml5
-rw-r--r--dev-lang/io/Manifest1
-rw-r--r--dev-lang/io/files/io-2011.09.12-gentoo-fixes.patch160
-rw-r--r--dev-lang/io/io-2011.09.12-r2.ebuild101
-rw-r--r--dev-lang/io/metadata.xml27
-rw-r--r--dev-lang/ispc/Manifest2
-rw-r--r--dev-lang/ispc/ispc-1.8.1.ebuild52
-rw-r--r--dev-lang/ispc/ispc-1.8.2.ebuild52
-rw-r--r--dev-lang/ispc/metadata.xml11
-rw-r--r--dev-lang/j/Manifest1
-rw-r--r--dev-lang/j/j-701-r2.ebuild45
-rw-r--r--dev-lang/j/metadata.xml8
-rw-r--r--dev-lang/jimtcl/Manifest5
-rw-r--r--dev-lang/jimtcl/files/jimtcl-0.75-bootstrap.patch15
-rw-r--r--dev-lang/jimtcl/jimtcl-0.70_pre20110317.ebuild38
-rw-r--r--dev-lang/jimtcl/jimtcl-0.73.ebuild43
-rw-r--r--dev-lang/jimtcl/jimtcl-0.74-r1.ebuild47
-rw-r--r--dev-lang/jimtcl/jimtcl-0.75-r1.ebuild72
-rw-r--r--dev-lang/jimtcl/jimtcl-0.75.ebuild47
-rw-r--r--dev-lang/jimtcl/jimtcl-0.76.ebuild72
-rw-r--r--dev-lang/jimtcl/jimtcl-9999.ebuild72
-rw-r--r--dev-lang/jimtcl/metadata.xml13
-rw-r--r--dev-lang/julia/Manifest10
-rw-r--r--dev-lang/julia/files/63julia-gentoo.el2
-rw-r--r--dev-lang/julia/files/julia-0.2.1-patchelf.patch16
-rw-r--r--dev-lang/julia/files/julia-0.2.1-readline63.patch17
-rw-r--r--dev-lang/julia/julia-0.2.0-r1.ebuild106
-rw-r--r--dev-lang/julia/julia-0.2.0.ebuild79
-rw-r--r--dev-lang/julia/julia-0.2.1-r2.ebuild152
-rw-r--r--dev-lang/julia/julia-0.3.0.ebuild156
-rw-r--r--dev-lang/julia/metadata.xml24
-rw-r--r--dev-lang/jwasm/Manifest2
-rw-r--r--dev-lang/jwasm/files/jwasm-2.10-gcc-4.8-fwdecl.patch41
-rw-r--r--dev-lang/jwasm/files/jwasm-2.10-types-test.patch60
-rw-r--r--dev-lang/jwasm/files/jwasm-2.10-uint_32-on-amd64.patch28
-rw-r--r--dev-lang/jwasm/files/jwasm-2.11-types-test.patch58
-rw-r--r--dev-lang/jwasm/jwasm-2.10-r1.ebuild42
-rw-r--r--dev-lang/jwasm/jwasm-2.11.ebuild40
-rw-r--r--dev-lang/jwasm/metadata.xml9
-rw-r--r--dev-lang/lazarus/Manifest4
-rw-r--r--dev-lang/lazarus/files/lazarus-0.9.26-fpcsrc.patch13
-rw-r--r--dev-lang/lazarus/lazarus-1.0.12.ebuild76
-rw-r--r--dev-lang/lazarus/lazarus-1.2.2.ebuild76
-rw-r--r--dev-lang/lazarus/lazarus-1.2.4.ebuild76
-rw-r--r--dev-lang/lazarus/lazarus-1.2.6.ebuild76
-rw-r--r--dev-lang/lazarus/metadata.xml14
-rw-r--r--dev-lang/lfe/Manifest1
-rw-r--r--dev-lang/lfe/lfe-0.7.ebuild32
-rw-r--r--dev-lang/lfe/metadata.xml11
-rw-r--r--dev-lang/lisaac/Manifest1
-rw-r--r--dev-lang/lisaac/files/50lisaac-gentoo.el4
-rw-r--r--dev-lang/lisaac/files/lisaac-0.13.1-makefile.patch33
-rw-r--r--dev-lang/lisaac/lisaac-0.13.1-r2.ebuild74
-rw-r--r--dev-lang/lisaac/metadata.xml7
-rw-r--r--dev-lang/logtalk/Manifest3
-rw-r--r--dev-lang/logtalk/files/logtalk-3.00.0-no-user-docs.patch34
-rw-r--r--dev-lang/logtalk/logtalk-2.41.0.ebuild100
-rw-r--r--dev-lang/logtalk/logtalk-2.42.2.ebuild100
-rw-r--r--dev-lang/logtalk/logtalk-3.00.0.ebuild133
-rw-r--r--dev-lang/logtalk/metadata.xml14
-rw-r--r--dev-lang/lua/Manifest3
-rw-r--r--dev-lang/lua/files/5.1.4/01_all_boolean_expression.upstream.patch48
-rw-r--r--dev-lang/lua/files/5.1.4/02_all_table.upstream.patch22
-rw-r--r--dev-lang/lua/files/5.1.4/03_all_debug_getfenv.upstream.patch10
-rw-r--r--dev-lang/lua/files/5.1.4/04_all_gc_performance.upstream.patch14
-rw-r--r--dev-lang/lua/files/5.1.4/05_all_string_format.upstream.patch21
-rw-r--r--dev-lang/lua/files/5.1.4/06_all_io_read.upstream.patch15
-rw-r--r--dev-lang/lua/files/5.1.4/07_all_boolean_expression.upstream.patch30
-rw-r--r--dev-lang/lua/files/5.1.4/08_all_metatable.upstream.patch10
-rw-r--r--dev-lang/lua/files/5.1.4/09_all_prototype_collection.upstream.patch13
-rw-r--r--dev-lang/lua/files/5.2.0/01_all_memory_hoarding.upstream.patch49
-rw-r--r--dev-lang/lua/files/5.2.0/02_all_hex_number_handling.upstream.patch26
-rw-r--r--dev-lang/lua/files/configure.in5
-rw-r--r--dev-lang/lua/files/lua-5.1-make-r1.patch66
-rw-r--r--dev-lang/lua/files/lua-5.1-make-r2.patch97
-rw-r--r--dev-lang/lua/files/lua-5.1-make.patch64
-rw-r--r--dev-lang/lua/files/lua-5.1-make_static-r1.patch12
-rw-r--r--dev-lang/lua/files/lua-5.1-make_static.patch12
-rw-r--r--dev-lang/lua/files/lua-5.1-module_paths.patch30
-rw-r--r--dev-lang/lua/files/lua-5.1-readline.patch10
-rw-r--r--dev-lang/lua/files/lua-5.1.4-deprecated.patch46
-rw-r--r--dev-lang/lua/files/lua-5.1.4-test.patch11
-rw-r--r--dev-lang/lua/files/lua-5.2-make-r1.patch75
-rw-r--r--dev-lang/lua/files/lua-5.2-make.patch60
-rw-r--r--dev-lang/lua/files/lua.pc31
-rw-r--r--dev-lang/lua/lua-5.1.4-r8.ebuild118
-rw-r--r--dev-lang/lua/lua-5.1.5-r1.ebuild119
-rw-r--r--dev-lang/lua/lua-5.1.5-r100.ebuild132
-rw-r--r--dev-lang/lua/lua-5.1.5-r2.ebuild124
-rw-r--r--dev-lang/lua/lua-5.1.5-r3.ebuild127
-rw-r--r--dev-lang/lua/lua-5.1.5.ebuild119
-rw-r--r--dev-lang/lua/lua-5.2.3-r1.ebuild130
-rw-r--r--dev-lang/lua/lua-5.2.3.ebuild118
-rw-r--r--dev-lang/lua/metadata.xml13
-rw-r--r--dev-lang/luajit/Manifest4
-rw-r--r--dev-lang/luajit/luajit-1.1.6.ebuild55
-rw-r--r--dev-lang/luajit/luajit-2.0.2.ebuild67
-rw-r--r--dev-lang/luajit/luajit-2.0.3-r1.ebuild62
-rw-r--r--dev-lang/luajit/luajit-2.0.3.ebuild67
-rw-r--r--dev-lang/luajit/luajit-2.0.4.ebuild62
-rw-r--r--dev-lang/luajit/metadata.xml18
-rw-r--r--dev-lang/maude/Manifest2
-rw-r--r--dev-lang/maude/files/maude-2.5.0-prll.patch24
-rw-r--r--dev-lang/maude/files/maude-2.6-gcc47.patch25
-rw-r--r--dev-lang/maude/files/maude-2.6-search-datadir.patch37
-rw-r--r--dev-lang/maude/maude-2.6-r1.ebuild64
-rw-r--r--dev-lang/maude/metadata.xml13
-rw-r--r--dev-lang/mercury-extras/Manifest14
-rw-r--r--dev-lang/mercury-extras/mercury-extras-11.01.ebuild193
-rw-r--r--dev-lang/mercury-extras/mercury-extras-11.07.1.ebuild194
-rw-r--r--dev-lang/mercury-extras/mercury-extras-11.07.2.ebuild194
-rw-r--r--dev-lang/mercury-extras/mercury-extras-11.07.ebuild194
-rw-r--r--dev-lang/mercury-extras/mercury-extras-13.05.1.ebuild194
-rw-r--r--dev-lang/mercury-extras/mercury-extras-13.05.2.ebuild194
-rw-r--r--dev-lang/mercury-extras/mercury-extras-13.05.ebuild194
-rw-r--r--dev-lang/mercury-extras/metadata.xml8
-rw-r--r--dev-lang/mercury/Manifest18
-rw-r--r--dev-lang/mercury/files/50mercury-gentoo.el5
-rw-r--r--dev-lang/mercury/mercury-11.01.ebuild216
-rw-r--r--dev-lang/mercury/mercury-11.07.1.ebuild216
-rw-r--r--dev-lang/mercury/mercury-11.07.2.ebuild216
-rw-r--r--dev-lang/mercury/mercury-11.07.ebuild216
-rw-r--r--dev-lang/mercury/mercury-13.05.1.ebuild197
-rw-r--r--dev-lang/mercury/mercury-13.05.2.ebuild197
-rw-r--r--dev-lang/mercury/mercury-13.05.ebuild196
-rw-r--r--dev-lang/mercury/metadata.xml11
-rw-r--r--dev-lang/metadata.xml40
-rw-r--r--dev-lang/mlton/Manifest3
-rw-r--r--dev-lang/mlton/files/mlton-20070826-no-execmem.patch29
-rw-r--r--dev-lang/mlton/files/mlton-20130715-no-PIE.patch66
-rw-r--r--dev-lang/mlton/files/mlton-20130715-split-make-for-pax-mark.patch11
-rw-r--r--dev-lang/mlton/metadata.xml11
-rw-r--r--dev-lang/mlton/mlton-20130715.ebuild120
-rw-r--r--dev-lang/mmix/Manifest1
-rw-r--r--dev-lang/mmix/files/mmix-20110420-makefile.patch71
-rw-r--r--dev-lang/mmix/metadata.xml8
-rw-r--r--dev-lang/mmix/mmix-20131017.ebuild48
-rw-r--r--dev-lang/moarvm/Manifest7
-rw-r--r--dev-lang/moarvm/files/Configure-9999.patch15
-rw-r--r--dev-lang/moarvm/files/Configure.patch14
-rw-r--r--dev-lang/moarvm/metadata.xml12
-rw-r--r--dev-lang/moarvm/moarvm-2015.01.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.02.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.03.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.04.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.05.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.06.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-2015.07.ebuild31
-rw-r--r--dev-lang/moarvm/moarvm-9999.ebuild36
-rw-r--r--dev-lang/mono-basic/Manifest1
-rw-r--r--dev-lang/mono-basic/metadata.xml9
-rw-r--r--dev-lang/mono-basic/mono-basic-2.10.ebuild17
-rw-r--r--dev-lang/mono/Manifest5
-rw-r--r--dev-lang/mono/files/mono-2.10.1-ppc-len.patch13
-rw-r--r--dev-lang/mono/files/mono-2.10.2-threads-access.patch40
-rw-r--r--dev-lang/mono/files/mono-2.10.9-CVE-2012-3382.patch13
-rw-r--r--dev-lang/mono/files/mono-2.10.9-CVE-2012-3543.patch196
-rw-r--r--dev-lang/mono/files/mono-2.10.9-CVE-2012-3543_2.patch34
-rw-r--r--dev-lang/mono/files/mono-3.2.8-disable-missing-test.patch7
-rw-r--r--dev-lang/mono/metadata.xml9
-rw-r--r--dev-lang/mono/mono-2.10.9-r2.ebuild265
-rw-r--r--dev-lang/mono/mono-3.0.7.ebuild100
-rw-r--r--dev-lang/mono/mono-3.12.1.ebuild117
-rw-r--r--dev-lang/mono/mono-3.2.3.ebuild119
-rw-r--r--dev-lang/mono/mono-3.2.8.ebuild123
-rw-r--r--dev-lang/mozart-stdlib/Manifest1
-rw-r--r--dev-lang/mozart-stdlib/files/mozart-stdlib-1.3.2-doc.patch179
-rw-r--r--dev-lang/mozart-stdlib/files/mozart-stdlib-1.3.2-ozmake.patch78
-rw-r--r--dev-lang/mozart-stdlib/files/mozart-stdlib-1.3.2-r1-ozmake.patch78
-rw-r--r--dev-lang/mozart-stdlib/files/mozart-stdlib-1.4.0-docroot.patch13
-rw-r--r--dev-lang/mozart-stdlib/files/mozart-stdlib-1.4.0-ozload.patch13
-rw-r--r--dev-lang/mozart-stdlib/metadata.xml8
-rw-r--r--dev-lang/mozart-stdlib/mozart-stdlib-1.4.0-r1.ebuild41
-rw-r--r--dev-lang/mozart/Manifest3
-rw-r--r--dev-lang/mozart/files/50mozart-gentoo.el11
-rw-r--r--dev-lang/mozart/metadata.xml8
-rw-r--r--dev-lang/mozart/mozart-1.4.0-r2.ebuild131
-rw-r--r--dev-lang/mozart/mozart-1.4.0-r3.ebuild125
-rw-r--r--dev-lang/mujs/Manifest1
-rw-r--r--dev-lang/mujs/files/mujs-0_p20150202-Makefile.patch28
-rw-r--r--dev-lang/mujs/metadata.xml8
-rw-r--r--dev-lang/mujs/mujs-0_p20150202.ebuild27
-rw-r--r--dev-lang/nacl-toolchain-newlib/Manifest19
-rw-r--r--dev-lang/nacl-toolchain-newlib/files/binutils-texinfo-r0.patch58
-rw-r--r--dev-lang/nacl-toolchain-newlib/files/gcc-parallel-build-r0.patch15
-rw-r--r--dev-lang/nacl-toolchain-newlib/files/gcc-texinfo-r0.patch132
-rw-r--r--dev-lang/nacl-toolchain-newlib/metadata.xml5
-rw-r--r--dev-lang/nacl-toolchain-newlib/nacl-toolchain-newlib-0_p10520.ebuild98
-rw-r--r--dev-lang/nacl-toolchain-newlib/nacl-toolchain-newlib-0_p10915.ebuild104
-rw-r--r--dev-lang/nacl-toolchain-newlib/nacl-toolchain-newlib-0_p11846.ebuild104
-rw-r--r--dev-lang/nacl-toolchain-newlib/nacl-toolchain-newlib-0_p9093.ebuild104
-rw-r--r--dev-lang/nasm/Manifest1
-rw-r--r--dev-lang/nasm/metadata.xml16
-rw-r--r--dev-lang/nasm/nasm-2.11.08.ebuild42
-rw-r--r--dev-lang/niecza-bin/Manifest4
-rw-r--r--dev-lang/niecza-bin/metadata.xml11
-rw-r--r--dev-lang/niecza-bin/niecza-bin-20.ebuild34
-rw-r--r--dev-lang/niecza-bin/niecza-bin-21.ebuild34
-rw-r--r--dev-lang/niecza-bin/niecza-bin-22.ebuild34
-rw-r--r--dev-lang/niecza-bin/niecza-bin-24.ebuild34
-rw-r--r--dev-lang/niecza/Manifest4
-rw-r--r--dev-lang/niecza/files/fix-bootstrap-21.patch13
-rw-r--r--dev-lang/niecza/files/fix-bootstrap-22.patch13
-rw-r--r--dev-lang/niecza/files/fix-bootstrap-24.patch13
-rw-r--r--dev-lang/niecza/files/fix-bootstrap-9999.patch13
-rw-r--r--dev-lang/niecza/files/fix-bootstrap.patch13
-rw-r--r--dev-lang/niecza/metadata.xml11
-rw-r--r--dev-lang/niecza/niecza-19.ebuild57
-rw-r--r--dev-lang/niecza/niecza-21.ebuild58
-rw-r--r--dev-lang/niecza/niecza-22.ebuild58
-rw-r--r--dev-lang/niecza/niecza-24.ebuild58
-rw-r--r--dev-lang/niecza/niecza-9999.ebuild57
-rw-r--r--dev-lang/nqc/Manifest1
-rw-r--r--dev-lang/nqc/files/nqc-3.1_p6-flags.patch73
-rw-r--r--dev-lang/nqc/files/nqc-3.1_p6-gcc-4.7.patch15
-rw-r--r--dev-lang/nqc/metadata.xml8
-rw-r--r--dev-lang/nqc/nqc-3.1_p6.ebuild56
-rw-r--r--dev-lang/nqp/Manifest7
-rw-r--r--dev-lang/nqp/metadata.xml16
-rw-r--r--dev-lang/nqp/nqp-2015.01.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.02.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.03.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.04.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.05.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.06.ebuild66
-rw-r--r--dev-lang/nqp/nqp-2015.07.2.ebuild66
-rw-r--r--dev-lang/nwcc/Manifest1
-rw-r--r--dev-lang/nwcc/metadata.xml8
-rw-r--r--dev-lang/nwcc/nwcc-0.8.2.ebuild25
-rw-r--r--dev-lang/ocaml/Manifest8
-rw-r--r--dev-lang/ocaml/files/ocaml-3.11.2-Fix-ocamlopt-w.r.t.-binutils-2.21.patch66
-rw-r--r--dev-lang/ocaml/files/ocaml-4.01.0-pkg-config-ncurses.patch15
-rw-r--r--dev-lang/ocaml/files/ocaml-rebuild.sh51
-rw-r--r--dev-lang/ocaml/files/ocaml.conf5
-rw-r--r--dev-lang/ocaml/metadata.xml5
-rw-r--r--dev-lang/ocaml/ocaml-3.12.1.ebuild132
-rw-r--r--dev-lang/ocaml/ocaml-4.01.0.ebuild128
-rw-r--r--dev-lang/ocaml/ocaml-4.02.1.ebuild114
-rw-r--r--dev-lang/ocaml/ocaml-4.02.2.ebuild115
-rw-r--r--dev-lang/ocaml/ocaml-4.02.3.ebuild115
-rw-r--r--dev-lang/open-cobol/Manifest1
-rw-r--r--dev-lang/open-cobol/metadata.xml11
-rw-r--r--dev-lang/open-cobol/open-cobol-1.1.ebuild34
-rw-r--r--dev-lang/opendylan-bin/Manifest10
-rw-r--r--dev-lang/opendylan-bin/metadata.xml8
-rw-r--r--dev-lang/opendylan-bin/opendylan-bin-2011.1.ebuild33
-rw-r--r--dev-lang/opendylan-bin/opendylan-bin-2012.1.ebuild33
-rw-r--r--dev-lang/opendylan-bin/opendylan-bin-2013.1.ebuild33
-rw-r--r--dev-lang/opendylan-bin/opendylan-bin-2013.2.ebuild33
-rw-r--r--dev-lang/opendylan-bin/opendylan-bin-2014.1.ebuild33
-rw-r--r--dev-lang/opendylan/Manifest3
-rw-r--r--dev-lang/opendylan/metadata.xml8
-rw-r--r--dev-lang/opendylan/opendylan-2013.1-r1.ebuild104
-rw-r--r--dev-lang/opendylan/opendylan-2013.2.ebuild109
-rw-r--r--dev-lang/opendylan/opendylan-2014.1.ebuild105
-rw-r--r--dev-lang/opendylan/opendylan-9999.ebuild66
-rw-r--r--dev-lang/orc/Manifest2
-rw-r--r--dev-lang/orc/metadata.xml5
-rw-r--r--dev-lang/orc/orc-0.4.23.ebuild39
-rw-r--r--dev-lang/orc/orc-0.4.24.ebuild55
-rw-r--r--dev-lang/parrot/Manifest5
-rw-r--r--dev-lang/parrot/metadata.xml5
-rw-r--r--dev-lang/parrot/parrot-7.0.2.ebuild84
-rw-r--r--dev-lang/parrot/parrot-7.1.0.ebuild84
-rw-r--r--dev-lang/parrot/parrot-7.2.0.ebuild84
-rw-r--r--dev-lang/parrot/parrot-7.3.0.ebuild84
-rw-r--r--dev-lang/parrot/parrot-7.5.0.ebuild84
-rw-r--r--dev-lang/pasm/Manifest1
-rw-r--r--dev-lang/pasm/files/pasm-1.7-ppc.patch29
-rw-r--r--dev-lang/pasm/metadata.xml15
-rw-r--r--dev-lang/pasm/pasm-1.7.ebuild29
-rw-r--r--dev-lang/path64/Manifest16
-rw-r--r--dev-lang/path64/metadata.xml17
-rw-r--r--dev-lang/path64/path64-1.0.0_pre20110821.ebuild94
-rw-r--r--dev-lang/path64/path64-1.0.0_pre20110924.ebuild94
-rw-r--r--dev-lang/path64/path64-1.0.0_pre20111108.ebuild94
-rw-r--r--dev-lang/path64/path64-1.0.0_pre20120223.ebuild94
-rw-r--r--dev-lang/pcc/Manifest1
-rw-r--r--dev-lang/pcc/files/pcc-1.1.0-multiarch.patch11
-rw-r--r--dev-lang/pcc/metadata.xml8
-rw-r--r--dev-lang/pcc/pcc-1.1.0-r1.ebuild38
-rw-r--r--dev-lang/pcc/pcc-9999.ebuild45
-rw-r--r--dev-lang/perl/Manifest5
-rw-r--r--dev-lang/perl/files/eblits/common-v50160001.eblit71
-rw-r--r--dev-lang/perl/files/eblits/pkg_postinst-v50160001.eblit67
-rw-r--r--dev-lang/perl/files/eblits/pkg_postinst-v50220001.eblit67
-rw-r--r--dev-lang/perl/files/eblits/pkg_postrm-v50160001.eblit12
-rw-r--r--dev-lang/perl/files/eblits/pkg_postrm-v50220001.eblit12
-rw-r--r--dev-lang/perl/files/eblits/pkg_setup-v50160001.eblit70
-rw-r--r--dev-lang/perl/files/eblits/pkg_setup-v50220001.eblit72
-rw-r--r--dev-lang/perl/files/eblits/src_configure-v50180002.eblit146
-rw-r--r--dev-lang/perl/files/eblits/src_install-v50160001.eblit61
-rw-r--r--dev-lang/perl/files/eblits/src_install-v50200001.eblit51
-rw-r--r--dev-lang/perl/files/eblits/src_prepare-v50160001.eblit70
-rw-r--r--dev-lang/perl/files/eblits/src_test-v50160001.eblit12
-rw-r--r--dev-lang/perl/metadata.xml8
-rw-r--r--dev-lang/perl/perl-5.20.2-r1.ebuild122
-rw-r--r--dev-lang/perl/perl-5.20.2.ebuild122
-rw-r--r--dev-lang/perl/perl-5.22.0.ebuild120
-rw-r--r--dev-lang/php/Manifest14
-rw-r--r--dev-lang/php/files/20php5-envd2
-rw-r--r--dev-lang/php/files/all_mysql_socket_location-gentoo.patch13
-rw-r--r--dev-lang/php/files/all_strict_aliasing.patch14
-rw-r--r--dev-lang/php/files/bison_any_version.patch16
-rw-r--r--dev-lang/php/files/bison_build_2.patch29
-rw-r--r--dev-lang/php/files/bison_build_2a.patch30
-rw-r--r--dev-lang/php/files/fix-libstdc++-underlinking.patch10
-rw-r--r--dev-lang/php/files/freetype-2.5.1-linking-fix.patch64
-rw-r--r--dev-lang/php/files/iodbc-pkgconfig-r1.patch52
-rw-r--r--dev-lang/php/files/iodbc-pkgconfig.patch52
-rw-r--r--dev-lang/php/files/missing-openssl-include.patch14
-rw-r--r--dev-lang/php/files/php-fpm-r1.conf311
-rwxr-xr-xdev-lang/php/files/php-fpm-r4.init47
-rw-r--r--dev-lang/php/files/php-fpm_at-simple.service13
-rw-r--r--dev-lang/php/files/php-fpm_at.service14
-rw-r--r--dev-lang/php/files/php-libvpx.patch24
-rw-r--r--dev-lang/php/files/php5-ldvs1
-rw-r--r--dev-lang/php/files/stricter-libc-client-symlink-check.patch15
-rw-r--r--dev-lang/php/metadata.xml28
-rw-r--r--dev-lang/php/php-5.4.41.ebuild802
-rw-r--r--dev-lang/php/php-5.4.42.ebuild802
-rw-r--r--dev-lang/php/php-5.4.43.ebuild802
-rw-r--r--dev-lang/php/php-5.4.44.ebuild802
-rw-r--r--dev-lang/php/php-5.5.25-r1.ebuild787
-rw-r--r--dev-lang/php/php-5.5.26.ebuild784
-rw-r--r--dev-lang/php/php-5.5.27.ebuild784
-rw-r--r--dev-lang/php/php-5.5.28.ebuild784
-rw-r--r--dev-lang/php/php-5.6.10.ebuild784
-rw-r--r--dev-lang/php/php-5.6.11.ebuild784
-rw-r--r--dev-lang/php/php-5.6.12.ebuild784
-rw-r--r--dev-lang/php/php-5.6.9.ebuild787
-rw-r--r--dev-lang/php/php-7.0.0_beta1.ebuild760
-rw-r--r--dev-lang/pocl/Manifest1
-rw-r--r--dev-lang/pocl/metadata.xml8
-rw-r--r--dev-lang/pocl/pocl-0.11.ebuild32
-rw-r--r--dev-lang/polyml/Manifest4
-rw-r--r--dev-lang/polyml/files/polyml-5.4.1-asm.patch28
-rw-r--r--dev-lang/polyml/files/polyml-5.4.1-configure.patch11
-rw-r--r--dev-lang/polyml/files/polyml-5.5.0-asm.patch10
-rw-r--r--dev-lang/polyml/files/polyml-5.5.0-configure.patch138
-rw-r--r--dev-lang/polyml/files/polyml-5.5.0-x-it-basis.patch21
-rw-r--r--dev-lang/polyml/files/polyml-5.5.1-inputN-return-for-zero-chars.patch33
-rw-r--r--dev-lang/polyml/files/polyml-5.5.1-mprotect-exec.patch29
-rw-r--r--dev-lang/polyml/files/polyml-5.5.1-optimize-closure.patch141
-rw-r--r--dev-lang/polyml/files/polyml-5.5.2-r1952-check_for_negative_sized_array.patch13
-rw-r--r--dev-lang/polyml/files/polyml-5.5.2-r1954_Fix_segfault_in_FFI_when_malloc_runs_out_of_memory.patch112
-rw-r--r--dev-lang/polyml/files/polyml-5.5.2-r2007_Ensure_the_large_object_cache_pointer_is_cleared.patch27
-rw-r--r--dev-lang/polyml/files/polyml-5.5.2-r2009_Initialise_the_largeObjectCache_fully_in_the_constructor.patch21
-rw-r--r--dev-lang/polyml/metadata.xml15
-rw-r--r--dev-lang/polyml/polyml-5.4.1.ebuild45
-rw-r--r--dev-lang/polyml/polyml-5.5.0.ebuild51
-rw-r--r--dev-lang/polyml/polyml-5.5.1.ebuild72
-rw-r--r--dev-lang/polyml/polyml-5.5.2.ebuild72
-rw-r--r--dev-lang/python-exec/Manifest2
-rw-r--r--dev-lang/python-exec/metadata.xml13
-rw-r--r--dev-lang/python-exec/python-exec-2.0.1-r1.ebuild37
-rw-r--r--dev-lang/python-exec/python-exec-2.0.2.ebuild37
-rw-r--r--dev-lang/python-exec/python-exec-2.9999.ebuild50
-rw-r--r--dev-lang/python/Manifest19
-rw-r--r--dev-lang/python/files/CVE-2013-4238_py27.patch247
-rw-r--r--dev-lang/python/files/CVE-2013-4238_py33.patch241
-rw-r--r--dev-lang/python/files/pydoc.conf7
-rwxr-xr-xdev-lang/python/files/pydoc.init25
-rw-r--r--dev-lang/python/files/python-2.5-tcl86.patch11
-rw-r--r--dev-lang/python/files/python-2.7-issue16248.patch19
-rw-r--r--dev-lang/python/files/python-2.7-issue18851.patch287
-rw-r--r--dev-lang/python/files/python-2.7.10-semaphore-pid.patch51
-rw-r--r--dev-lang/python/files/python-2.7.5-library-path.patch25
-rw-r--r--dev-lang/python/files/python-2.7.5-nonfatal-compileall.patch18
-rw-r--r--dev-lang/python/files/python-2.7.5-re_unsigned_ptrdiff.patch23
-rw-r--r--dev-lang/python/files/python-2.7.6-recvfrom_into_buffer_overflow.patch17
-rw-r--r--dev-lang/python/files/python-2.7.9-ncurses-pkg-config.patch13
-rw-r--r--dev-lang/python/files/python-3.2-CVE-2013-2099.patch51
-rw-r--r--dev-lang/python/files/python-3.2-CVE-2014-1912.patch51
-rw-r--r--dev-lang/python/files/python-3.2-CVE-2014-4616.patch39
-rw-r--r--dev-lang/python/files/python-3.2-issue16248.patch19
-rw-r--r--dev-lang/python/files/python-3.3-CVE-2013-2099.patch51
-rw-r--r--dev-lang/python/files/python-3.3-CVE-2014-4616.patch52
-rw-r--r--dev-lang/python/files/python-3.3.5-ncurses-pkg-config.patch40
-rw-r--r--dev-lang/python/files/python-3.4.3-ncurses-pkg-config.patch13
-rw-r--r--dev-lang/python/files/python-config-2.4-r158
-rw-r--r--dev-lang/python/metadata.xml10
-rw-r--r--dev-lang/python/python-2.6.9.ebuild371
-rw-r--r--dev-lang/python/python-2.7.10.ebuild357
-rw-r--r--dev-lang/python/python-2.7.9-r1.ebuild358
-rw-r--r--dev-lang/python/python-2.7.9-r2.ebuild359
-rw-r--r--dev-lang/python/python-3.2.5-r6.ebuild384
-rw-r--r--dev-lang/python/python-3.3.5-r1.ebuild325
-rw-r--r--dev-lang/python/python-3.4.0.ebuild320
-rw-r--r--dev-lang/python/python-3.4.1.ebuild319
-rw-r--r--dev-lang/python/python-3.4.2.ebuild319
-rw-r--r--dev-lang/python/python-3.4.3.ebuild318
-rw-r--r--dev-lang/qu-prolog/Manifest2
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.1-cerr-ptr.patch40
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.1-cflags.patch34
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.1-gcc.patch33
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.1-portage.patch32
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.5-cflags.patch34
-rw-r--r--dev-lang/qu-prolog/files/qu-prolog-9.5-portage.patch32
-rw-r--r--dev-lang/qu-prolog/metadata.xml8
-rw-r--r--dev-lang/qu-prolog/qu-prolog-9.1-r1.ebuild96
-rw-r--r--dev-lang/qu-prolog/qu-prolog-9.1.ebuild103
-rw-r--r--dev-lang/qu-prolog/qu-prolog-9.5.ebuild94
-rw-r--r--dev-lang/rakudo/Manifest7
-rw-r--r--dev-lang/rakudo/files/jakudo-fix-paths.patch23
-rw-r--r--dev-lang/rakudo/metadata.xml13
-rw-r--r--dev-lang/rakudo/rakudo-2015.01.1.ebuild58
-rw-r--r--dev-lang/rakudo/rakudo-2015.02.ebuild58
-rw-r--r--dev-lang/rakudo/rakudo-2015.03.ebuild45
-rw-r--r--dev-lang/rakudo/rakudo-2015.04.ebuild45
-rw-r--r--dev-lang/rakudo/rakudo-2015.05-r1.ebuild47
-rw-r--r--dev-lang/rakudo/rakudo-2015.06.ebuild43
-rw-r--r--dev-lang/rakudo/rakudo-2015.07.2.ebuild43
-rw-r--r--dev-lang/rebol-bin/Manifest1
-rw-r--r--dev-lang/rebol-bin/metadata.xml8
-rw-r--r--dev-lang/rebol-bin/rebol-bin-3_pre111.ebuild31
-rw-r--r--dev-lang/rebol/metadata.xml8
-rw-r--r--dev-lang/rebol/rebol-9999.ebuild40
-rw-r--r--dev-lang/regina-rexx/Manifest1
-rw-r--r--dev-lang/regina-rexx/files/regina-rexx-3.6-gentoo.patch28
-rw-r--r--dev-lang/regina-rexx/files/rxstack14
-rw-r--r--dev-lang/regina-rexx/files/rxstack-r114
-rw-r--r--dev-lang/regina-rexx/metadata.xml18
-rw-r--r--dev-lang/regina-rexx/regina-rexx-3.6-r2.ebuild48
-rw-r--r--dev-lang/rubinius/Manifest2
-rw-r--r--dev-lang/rubinius/files/auto_gem.rb7
-rw-r--r--dev-lang/rubinius/metadata.xml10
-rw-r--r--dev-lang/rubinius/rubinius-2.5.3.ebuild86
-rw-r--r--dev-lang/rubinius/rubinius-2.5.5.ebuild86
-rw-r--r--dev-lang/ruby/Manifest8
-rw-r--r--dev-lang/ruby/metadata.xml30
-rw-r--r--dev-lang/ruby/ruby-1.9.3_p551-r1.ebuild217
-rw-r--r--dev-lang/ruby/ruby-2.0.0_p645.ebuild230
-rw-r--r--dev-lang/ruby/ruby-2.1.6-r1.ebuild227
-rw-r--r--dev-lang/ruby/ruby-2.2.2-r1.ebuild238
-rw-r--r--dev-lang/rust-bin/Manifest2
-rw-r--r--dev-lang/rust-bin/metadata.xml8
-rw-r--r--dev-lang/rust-bin/rust-bin-1.1.0.ebuild93
-rw-r--r--dev-lang/rust/Manifest3
-rw-r--r--dev-lang/rust/files/rust-1.1.0-install.patch16
-rw-r--r--dev-lang/rust/metadata.xml22
-rw-r--r--dev-lang/rust/rust-1.1.0.ebuild131
-rw-r--r--dev-lang/scala-bin/Manifest2
-rw-r--r--dev-lang/scala-bin/metadata.xml8
-rw-r--r--dev-lang/scala-bin/scala-bin-2.11.6.ebuild77
-rw-r--r--dev-lang/scala-bin/scala-bin-2.11.7.ebuild77
-rw-r--r--dev-lang/scala/Manifest165
-rw-r--r--dev-lang/scala/files/scala-2.10.2-jdk-1.7-swing-SI-7455.patch165
-rw-r--r--dev-lang/scala/files/scala-2.10.2-jdk-1.7-swing.patch236
-rw-r--r--dev-lang/scala/files/scala-2.10.2-maven-deps.patch70
-rw-r--r--dev-lang/scala/files/scala-2.10.2-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.10.3-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.10.4-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.11.1-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.11.2-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.11.4-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.11.6-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.11.7-no-git.patch24
-rw-r--r--dev-lang/scala/files/scala-2.7.3-build.xml.patch10
-rw-r--r--dev-lang/scala/metadata.xml6
-rw-r--r--dev-lang/scala/scala-2.10.2-r2.ebuild256
-rw-r--r--dev-lang/scala/scala-2.10.3-r1.ebuild227
-rw-r--r--dev-lang/scala/scala-2.10.4-r1.ebuild227
-rw-r--r--dev-lang/scala/scala-2.11.1-r1.ebuild220
-rw-r--r--dev-lang/scala/scala-2.11.2-r1.ebuild222
-rw-r--r--dev-lang/scala/scala-2.11.4-r1.ebuild222
-rw-r--r--dev-lang/scala/scala-2.11.6.ebuild222
-rw-r--r--dev-lang/scala/scala-2.11.7.ebuild226
-rw-r--r--dev-lang/scala/scala-2.9.2-r1.ebuild148
-rw-r--r--dev-lang/smlnj/Manifest22
-rw-r--r--dev-lang/smlnj/metadata.xml5
-rw-r--r--dev-lang/smlnj/smlnj-110.75.ebuild113
-rw-r--r--dev-lang/snobol/Manifest4
-rw-r--r--dev-lang/snobol/metadata.xml8
-rw-r--r--dev-lang/snobol/snobol-0.99.4.ebuild46
-rw-r--r--dev-lang/snobol/snobol-0.99.44.ebuild52
-rw-r--r--dev-lang/snobol/snobol-1.1.ebuild60
-rw-r--r--dev-lang/snobol/snobol-1.4.1.ebuild53
-rw-r--r--dev-lang/spidermonkey/Manifest5
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.5-build.patch138
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.6-header.patch13
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.7.0-ldflags.patch42
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.7.0-threadsafe.diff18
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-arm_respect_cflags-2.patch102
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-arm_respect_cflags-3.patch99
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-fix-install-symlinks.patch15
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-fix-ppc64.patch61
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-ia64-fix.patch53
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-ia64-static-strings.patch381
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-isfinite.patch11
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-perf_event-check.patch21
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.5-symbol-versions.patch32
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.7-filter_desc.patch18
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.7-freebsd-pthreads.patch11
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.7-symbol-versions.patch32
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.8.7-x32.patch25
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-1.9.2.13-as-needed.patch22
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-17-ia64-mmap.patch67
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-17-js-config-shebang.patch22
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-17.0.0-fix-file-permissions.patch37
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-24-system-icu.patch199
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-24-upward-growing-stack.patch41
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-24.2.0-fix-file-permissions.patch29
-rw-r--r--dev-lang/spidermonkey/files/spidermonkey-perl-defined-array-check.patch11
-rw-r--r--dev-lang/spidermonkey/metadata.xml14
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.7.0-r1.ebuild51
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.7.0-r2.ebuild52
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.7.0-r3.ebuild52
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.7.0.ebuild50
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.8.2.15-r2.ebuild77
-rw-r--r--dev-lang/spidermonkey/spidermonkey-1.8.5-r4.ebuild136
-rw-r--r--dev-lang/spidermonkey/spidermonkey-17.0.0-r4.ebuild132
-rw-r--r--dev-lang/spidermonkey/spidermonkey-24.2.0-r3.ebuild147
-rw-r--r--dev-lang/squirrel/Manifest1
-rw-r--r--dev-lang/squirrel/files/squirrel-2.2.4-autotools.patch302
-rw-r--r--dev-lang/squirrel/files/squirrel-2.2.4-gcc47.patch59
-rw-r--r--dev-lang/squirrel/files/squirrel-2.2.4-stdint.h.patch75
-rw-r--r--dev-lang/squirrel/files/squirrel-2.2.4-supertux-const.patch22
-rw-r--r--dev-lang/squirrel/metadata.xml11
-rw-r--r--dev-lang/squirrel/squirrel-2.2.4-r1.ebuild46
-rw-r--r--dev-lang/squirrel/squirrel-2.2.4-r2.ebuild47
-rw-r--r--dev-lang/srf/Manifest1
-rw-r--r--dev-lang/srf/metadata.xml14
-rw-r--r--dev-lang/srf/srf-1.0-r1.ebuild35
-rw-r--r--dev-lang/swi-prolog/Manifest14
-rw-r--r--dev-lang/swi-prolog/metadata.xml8
-rw-r--r--dev-lang/swi-prolog/swi-prolog-6.6.6.ebuild125
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.2.0.ebuild128
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.2.1.ebuild128
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.2.2.ebuild128
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.3.2.ebuild128
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.3.3.ebuild128
-rw-r--r--dev-lang/swi-prolog/swi-prolog-7.3.4.ebuild128
-rw-r--r--dev-lang/swig/Manifest7
-rw-r--r--dev-lang/swig/metadata.xml25
-rw-r--r--dev-lang/swig/swig-1.3.40-r2.ebuild40
-rw-r--r--dev-lang/swig/swig-2.0.12.ebuild35
-rw-r--r--dev-lang/swig/swig-2.0.9.ebuild35
-rw-r--r--dev-lang/swig/swig-3.0.2.ebuild35
-rw-r--r--dev-lang/swig/swig-3.0.4.ebuild35
-rw-r--r--dev-lang/swig/swig-3.0.5.ebuild35
-rw-r--r--dev-lang/swig/swig-3.0.6.ebuild35
-rw-r--r--dev-lang/tcc/Manifest1
-rw-r--r--dev-lang/tcc/metadata.xml5
-rw-r--r--dev-lang/tcc/tcc-0.9.26-r1.ebuild67
-rw-r--r--dev-lang/tcc/tcc-0.9.26-r2.ebuild64
-rw-r--r--dev-lang/tcc/tcc-9999.ebuild64
-rw-r--r--dev-lang/tcl/Manifest2
-rw-r--r--dev-lang/tcl/files/tcl-8.4.15-tclm4-soname.patch11
-rw-r--r--dev-lang/tcl/files/tcl-8.4.16-multilib.patch21
-rw-r--r--dev-lang/tcl/files/tcl-8.4.9-strtod.patch11
-rw-r--r--dev-lang/tcl/files/tcl-8.5.10-conf.patch26
-rw-r--r--dev-lang/tcl/files/tcl-8.5.13-autopath.patch19
-rw-r--r--dev-lang/tcl/files/tcl-8.5.13-conf.patch20
-rw-r--r--dev-lang/tcl/files/tcl-8.5.13-multilib.patch12
-rw-r--r--dev-lang/tcl/files/tcl-8.5.14-conf.patch11
-rw-r--r--dev-lang/tcl/files/tcl-8.5.9-gentoo-fbsd.patch13
-rw-r--r--dev-lang/tcl/files/tcl-8.5_alpha6-multilib.patch24
-rw-r--r--dev-lang/tcl/files/tcl-8.5_alpha6-tclm4-soname.patch11
-rw-r--r--dev-lang/tcl/files/tcl-8.6.1-conf.patch11
-rw-r--r--dev-lang/tcl/files/tcl-configure-LANG.patch41
-rw-r--r--dev-lang/tcl/metadata.xml12
-rw-r--r--dev-lang/tcl/tcl-8.5.17-r100.ebuild94
-rw-r--r--dev-lang/tcl/tcl-8.5.17.ebuild115
-rw-r--r--dev-lang/tcl/tcl-8.6.4.ebuild126
-rw-r--r--dev-lang/teyjus/Manifest1
-rw-r--r--dev-lang/teyjus/files/50teyjus-gentoo.el3
-rw-r--r--dev-lang/teyjus/files/teyjus-2.0.2-flags.patch14
-rw-r--r--dev-lang/teyjus/metadata.xml29
-rw-r--r--dev-lang/teyjus/teyjus-2.0.2.ebuild108
-rw-r--r--dev-lang/tinycobol/Manifest1
-rw-r--r--dev-lang/tinycobol/files/tinycobol-0.65.9.patch140
-rw-r--r--dev-lang/tinycobol/metadata.xml10
-rw-r--r--dev-lang/tinycobol/tinycobol-0.65.9.ebuild47
-rw-r--r--dev-lang/tk/Manifest3
-rw-r--r--dev-lang/tk/files/tcl-8.5.9-gentoo-fbsd.patch13
-rw-r--r--dev-lang/tk/files/tk-8.4-lastevent.patch28
-rw-r--r--dev-lang/tk/files/tk-8.4.11-multilib.patch24
-rw-r--r--dev-lang/tk/files/tk-8.4.15-aqua.patch11
-rw-r--r--dev-lang/tk/files/tk-8.4.15-tclm4-soname.patch12
-rw-r--r--dev-lang/tk/files/tk-8.4.9-man.patch29
-rw-r--r--dev-lang/tk/files/tk-8.5.10-conf.patch31
-rw-r--r--dev-lang/tk/files/tk-8.5.11-fedora-xft.patch13
-rw-r--r--dev-lang/tk/files/tk-8.5.11-fix-name-collision-uclibc.patch35
-rw-r--r--dev-lang/tk/files/tk-8.5.13-conf.patch25
-rw-r--r--dev-lang/tk/files/tk-8.5.13-multilib.patch12
-rw-r--r--dev-lang/tk/files/tk-8.5.14-conf.patch16
-rw-r--r--dev-lang/tk/files/tk-8.5_alpha6-tclm4-soname.patch12
-rw-r--r--dev-lang/tk/files/tk-configure-LANG.patch41
-rw-r--r--dev-lang/tk/metadata.xml8
-rw-r--r--dev-lang/tk/tk-8.5.17-r100.ebuild94
-rw-r--r--dev-lang/tk/tk-8.5.17.ebuild124
-rw-r--r--dev-lang/tk/tk-8.6.4-r1.ebuild139
-rw-r--r--dev-lang/tuprolog/Manifest6
-rw-r--r--dev-lang/tuprolog/files/build.xml99
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.3.1_beta-javadocs.patch228
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.4.0_rc5-javadocs.patch315
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.5.0-javadocs.patch315
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.6.0-javadocs.patch454
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.7.0-javadocs.patch437
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.7.2-javadocs.patch479
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.7.2-no-ikvm.patch105
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.9.0-no-ikvm.patch116
-rw-r--r--dev-lang/tuprolog/metadata.xml5
-rw-r--r--dev-lang/tuprolog/tuprolog-2.4.0_rc5.ebuild57
-rw-r--r--dev-lang/tuprolog/tuprolog-2.5.0.ebuild55
-rw-r--r--dev-lang/tuprolog/tuprolog-2.6.0.ebuild59
-rw-r--r--dev-lang/tuprolog/tuprolog-2.7.0.ebuild59
-rw-r--r--dev-lang/tuprolog/tuprolog-2.7.2.ebuild60
-rw-r--r--dev-lang/tuprolog/tuprolog-2.9.0.ebuild60
-rw-r--r--dev-lang/ucblogo/Manifest1
-rw-r--r--dev-lang/ucblogo/files/50ucblogo-gentoo.el12
-rw-r--r--dev-lang/ucblogo/files/ucblogo-5.5-destdir.patch75
-rw-r--r--dev-lang/ucblogo/files/ucblogo-5.5-dont-require-tetex.patch40
-rw-r--r--dev-lang/ucblogo/files/ucblogo-5.5-fhs.patch28
-rw-r--r--dev-lang/ucblogo/files/ucblogo-5.5-no-emacs.patch28
-rw-r--r--dev-lang/ucblogo/metadata.xml16
-rw-r--r--dev-lang/ucblogo/ucblogo-5.5-r1.ebuild48
-rw-r--r--dev-lang/ucblogo/ucblogo-5.5.ebuild37
-rw-r--r--dev-lang/vala/Manifest5
-rw-r--r--dev-lang/vala/files/vala-0.24.0-atk-metadata.patch248
-rw-r--r--dev-lang/vala/metadata.xml8
-rw-r--r--dev-lang/vala/vala-0.20.1.ebuild36
-rw-r--r--dev-lang/vala/vala-0.22.1.ebuild38
-rw-r--r--dev-lang/vala/vala-0.24.0-r1.ebuild44
-rw-r--r--dev-lang/vala/vala-0.26.2.ebuild36
-rw-r--r--dev-lang/vala/vala-0.28.0.ebuild36
-rw-r--r--dev-lang/whitespace/Manifest1
-rw-r--r--dev-lang/whitespace/files/whitespace-cabal.patch24
-rw-r--r--dev-lang/whitespace/metadata.xml11
-rw-r--r--dev-lang/whitespace/whitespace-0.3.ebuild34
-rw-r--r--dev-lang/xsb/Manifest6
-rw-r--r--dev-lang/xsb/metadata.xml5
-rw-r--r--dev-lang/xsb/xsb-3.3.6.ebuild210
-rw-r--r--dev-lang/xsb/xsb-3.3.7.ebuild210
-rw-r--r--dev-lang/xsb/xsb-3.5.0.ebuild207
-rw-r--r--dev-lang/yap/Manifest6
-rw-r--r--dev-lang/yap/metadata.xml8
-rw-r--r--dev-lang/yap/yap-6.2.2.ebuild106
-rw-r--r--dev-lang/yap/yap-6.3.2.ebuild111
-rw-r--r--dev-lang/yap/yap-6.3.3.ebuild111
-rw-r--r--dev-lang/yasm/Manifest3
-rw-r--r--dev-lang/yasm/files/yasm-1.2.0-fix_cython_check.patch23
-rw-r--r--dev-lang/yasm/metadata.xml9
-rw-r--r--dev-lang/yasm/yasm-1.2.0-r1.ebuild51
-rw-r--r--dev-lang/yasm/yasm-1.3.0.ebuild41
-rw-r--r--dev-lang/yasm/yasm-9999.ebuild66
956 files changed, 66113 insertions, 0 deletions
diff --git a/dev-lang/R/Manifest b/dev-lang/R/Manifest
new file mode 100644
index 00000000000..d6134ee943d
--- /dev/null
+++ b/dev-lang/R/Manifest
@@ -0,0 +1,7 @@
+DIST R-20130129.bash_completion.bz2 4209 SHA256 487e969b94563fec98ec58de7e6142e9361d4219088add0fca282b482a9e01b1 SHA512 910b26e16cfebe677f438abfa5f2652e582db143d91dbf0e7d4b1ea33462c7e5c89c3a3619c63ae98bba26b11a5adb16eda9d344f8cdbe4f0feabc546993c1a5 WHIRLPOOL 2368efaed37fcb6e010f6a234864631f68549bd8e3f733561170cc5b28f5557e546d8561246fb265a481a47991a262fec3acf6abc1dc3929a9357405e0d3c6fc
+DIST R-3.0.1.tar.gz 25508280 SHA256 af90488af3141103b211dc81b6f17d1f0faf4f17684c579a32dfeb25d0d87134 SHA512 470edbf4a4fccf9310add110d7fa7f338e410e412b3ec84f6ea5f1253e94a435e185a7a1b62b22aee443293147ff7bcca139015b490a9271a502b1bfbf1426a2 WHIRLPOOL f45c960280f51cba3a4f3730fa79671808b3c07fd49f97b2cdce4a1de45986e62ac9bb24c6f764386a3ef1034a266b86f041a1a1652ec7f687a4db08a074d22e
+DIST R-3.0.3.tar.gz 28075821 SHA256 b97cfd9540f294ab786e846153f3dd8605610d7e27616bfb4296795bc4fde6d6 SHA512 881c9c0a8d866eb87218a5cdca72153c9ef0fa0a0f091595fc065bdcbc1ea8b0bd1a2fb3008457b12e1b5025a7e70bd7764de4286a57ad3f73226367b2fc4e83 WHIRLPOOL 076d041c0581dc211a4ee53cf5cad731dc0ece33bbb34f8c066dc660ef0c1f7dcfc1b3359c6a0cebfa2ccec9b689776965a530edcf9f81758c4e003242347225
+DIST R-3.1.0.tar.gz 28469975 SHA256 8a680390f84c58c01dcdefd682eaa0e90389f09e6d2f2e090c71af40065f5fe2 SHA512 bb21fc90c7d37a5328031ed784e7dcbd20259d1837c33db3b51c14a116939a53496683d5de142a1223e89fc12406294efc67bed3595131615e9607d5ffab5ce2 WHIRLPOOL b376180d700d18780eb344b737a3a1bfc8b40f67967032e0f34abf940d76c3ffd7694be9f2f10be985571e8f94d92a6970a3d1cba503280e3fcf6df7a5e4298e
+DIST R-3.1.1.tar.gz 28606569 SHA256 ce5c4d5e34414ce8f1ec2d5642861435fa1ddc4cd89bd336172bbe25a62c7a19 SHA512 a75d8b82645bd9486873669b802924448d591013076e3d7dc958502dc6f0dac7d7fb78f3921d34a1eac1383f141b6e800f4293f7fac09651e0176cf84c431af9 WHIRLPOOL ec05c70193a229cbaf15f3432853070c6666c3963a4e2719a6d8ff188bfc2cada0d1f2fe90a9dd6b43f46913138afed0be387ba73b7f9c4d87abc362cc8a5393
+DIST R-3.1.2.tar.gz 28655941 SHA256 bcd150afcae0e02f6efb5f35a6ab72432be82e849ec52ce0bb89d8c342a8fa7a SHA512 fee20cd94d14bd46cc36fb265ed4d64f44eaa3929dd13c62d29a5883fde607aba63e28a4b0f265ede63f78788996deaee36acf6a70cc0bc90a705c9782be01a1 WHIRLPOOL f02d543c0fd7e89e63aba844b7c0f651a9a6bb5dbfcd58bdb64b49d08335c3270383eb62291b9f2f20ef6ec9f39eef5cf77ae1af3109296f8b1898227cca99d1
+DIST R-3.2.0.tar.gz 29124927 SHA256 f5ae953f18ba6f3d55b46556bbbf73441350f9fd22625402b723a2b81ff64f35 SHA512 c6041c854251d51dd936d3a3632c2958a0437c58488f93e5ba810e957fb7f2276e3fe4f615fb4705f2fc5a66aa50a828b54b5e4e7b4358c7fd465c71531b9828 WHIRLPOOL e21a65b9197a202691dbe903b441caf7d8b92efdffb86dcccdbf09d080177cfd472a54d381df1cca749937434ffb9c08ac74198457e320353207cd00837e1086
diff --git a/dev-lang/R/R-3.0.1.ebuild b/dev-lang/R/R-3.0.1.ebuild
new file mode 100644
index 00000000000..da39c790010
--- /dev/null
+++ b/dev-lang/R/R-3.0.1.ebuild
@@ -0,0 +1,206 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ bash-completion? ( http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2 )"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="amd64 hppa ia64 ppc ppc64 sparc x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="bash-completion cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2
+ app-text/ghostscript-gpl
+ dev-libs/libpcre
+ virtual/blas
+ cairo? ( x11-libs/cairo[X] x11-libs/pango )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1 >=sys-libs/zlib-1.2.5.1-r2[minizip] ) )
+ app-arch/xz-utils
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ FORTRAN_NEED_OPENMP=1
+ tc-has-openmp || die "Please enable openmp support in your compiler"
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ # gentoo bug #322965 (not applied upstream)
+ # https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14505
+ epatch "${FILESDIR}"/${PN}-2.11.1-parallel.patch
+
+ # respect ldflags (not applied upstream)
+ # https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14506
+ epatch "${FILESDIR}"/${PN}-2.12.1-ldflags.patch
+
+ # gentoo bug #383431
+ # https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14951
+ epatch "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch
+
+ # https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14953
+ epatch "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --without-blas \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ use bash-completion && newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than what
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/R-3.0.3.ebuild b/dev-lang/R/R-3.0.3.ebuild
new file mode 100644
index 00000000000..6b4fe58cb7c
--- /dev/null
+++ b/dev-lang/R/R-3.0.3.ebuild
@@ -0,0 +1,203 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ bash-completion? ( http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2 )"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="bash-completion cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2:0=
+ app-arch/xz-utils:0=
+ app-text/ghostscript-gpl
+ dev-libs/libpcre:3=
+ virtual/blas:0
+ || ( >=sys-apps/coreutils-8.15 sys-freebsd/freebsd-bin app-misc/realpath )
+ cairo? ( x11-libs/cairo[X] x11-libs/pango )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack:0 )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tiff? ( media-libs/tiff:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu:0= x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1:0 >=sys-libs/zlib-1.2.5.1-r2:0[minizip] ) )
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
+ ewarn "OpenMP is not available in your current selected gcc"
+ die "need openmp capable gcc"
+ fi
+ FORTRAN_NEED_OPENMP=1
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.11.1-parallel.patch \
+ "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch \
+ "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --with-blas="$($(tc-getPKG_CONFIG) --libs blas)" \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with tk tk-config "${EPREFIX}"/usr/lib/tkConfig.sh) \
+ $(use_with tk tcl-config "${EPREFIX}"/usr/lib/tclConfig.sh) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ use bash-completion && newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than what
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/R-3.1.0.ebuild b/dev-lang/R/R-3.1.0.ebuild
new file mode 100644
index 00000000000..0ff21980d8f
--- /dev/null
+++ b/dev-lang/R/R-3.1.0.ebuild
@@ -0,0 +1,206 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ bash-completion? ( http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2 )"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="bash-completion cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2:0=
+ app-arch/xz-utils:0=
+ app-text/ghostscript-gpl
+ dev-libs/libpcre:3=
+ virtual/blas:0
+ || ( >=sys-apps/coreutils-8.15 sys-freebsd/freebsd-bin app-misc/realpath )
+ cairo? ( x11-libs/cairo:0=[X] x11-libs/pango:0= )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack:0 )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tiff? ( media-libs/tiff:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu:0= x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1:0 >=sys-libs/zlib-1.2.5.1-r2:0[minizip] ) )
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
+ ewarn "OpenMP is not available in your current selected gcc"
+ die "need openmp capable gcc"
+ fi
+ FORTRAN_NEED_OPENMP=1
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.11.1-parallel.patch \
+ "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch \
+ "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ # --with-system-tre \
+ # tre is patched from upstream
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --with-blas="$($(tc-getPKG_CONFIG) --libs blas)" \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with tk tk-config "${EPREFIX}"/usr/lib/tkConfig.sh) \
+ $(use_with tk tcl-config "${EPREFIX}"/usr/lib/tclConfig.sh) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone \
+ shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ use bash-completion && newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/R-3.1.1.ebuild b/dev-lang/R/R-3.1.1.ebuild
new file mode 100644
index 00000000000..695519aa819
--- /dev/null
+++ b/dev-lang/R/R-3.1.1.ebuild
@@ -0,0 +1,206 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2:0=
+ app-arch/xz-utils:0=
+ app-text/ghostscript-gpl
+ >=dev-libs/libpcre-8.35:3=
+ virtual/blas:0
+ || ( >=sys-apps/coreutils-8.15 sys-freebsd/freebsd-bin app-misc/realpath )
+ cairo? ( x11-libs/cairo:0=[X] x11-libs/pango:0= )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack:0 )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tiff? ( media-libs/tiff:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu:0= x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1:0 >=sys-libs/zlib-1.2.5.1-r2:0[minizip] ) )
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
+ ewarn "OpenMP is not available in your current selected gcc"
+ die "need openmp capable gcc"
+ fi
+ FORTRAN_NEED_OPENMP=1
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.11.1-parallel.patch \
+ "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch \
+ "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ # --with-system-tre \
+ # tre is patched from upstream
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --with-blas="$($(tc-getPKG_CONFIG) --libs blas)" \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with tk tk-config "${EPREFIX}"/usr/lib/tkConfig.sh) \
+ $(use_with tk tcl-config "${EPREFIX}"/usr/lib/tclConfig.sh) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone \
+ shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/R-3.1.2.ebuild b/dev-lang/R/R-3.1.2.ebuild
new file mode 100644
index 00000000000..695519aa819
--- /dev/null
+++ b/dev-lang/R/R-3.1.2.ebuild
@@ -0,0 +1,206 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2:0=
+ app-arch/xz-utils:0=
+ app-text/ghostscript-gpl
+ >=dev-libs/libpcre-8.35:3=
+ virtual/blas:0
+ || ( >=sys-apps/coreutils-8.15 sys-freebsd/freebsd-bin app-misc/realpath )
+ cairo? ( x11-libs/cairo:0=[X] x11-libs/pango:0= )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack:0 )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tiff? ( media-libs/tiff:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu:0= x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1:0 >=sys-libs/zlib-1.2.5.1-r2:0[minizip] ) )
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
+ ewarn "OpenMP is not available in your current selected gcc"
+ die "need openmp capable gcc"
+ fi
+ FORTRAN_NEED_OPENMP=1
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.11.1-parallel.patch \
+ "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch \
+ "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ # --with-system-tre \
+ # tre is patched from upstream
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --with-blas="$($(tc-getPKG_CONFIG) --libs blas)" \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with tk tk-config "${EPREFIX}"/usr/lib/tkConfig.sh) \
+ $(use_with tk tcl-config "${EPREFIX}"/usr/lib/tclConfig.sh) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone \
+ shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/R-3.2.0-r1.ebuild b/dev-lang/R/R-3.2.0-r1.ebuild
new file mode 100644
index 00000000000..f8ee36f425b
--- /dev/null
+++ b/dev-lang/R/R-3.2.0-r1.ebuild
@@ -0,0 +1,207 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit bash-completion-r1 autotools eutils flag-o-matic fortran-2 multilib versionator toolchain-funcs
+
+BCP=${PN}-20130129.bash_completion
+DESCRIPTION="Language and environment for statistical computing and graphics"
+HOMEPAGE="http://www.r-project.org/"
+SRC_URI="
+ mirror://cran/src/base/R-3/${P}.tar.gz
+ http://dev.gentoo.org/~bicatali/distfiles/${BCP}.bz2"
+
+LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="cairo doc icu java jpeg lapack minimal nls openmp perl png prefix profile readline static-libs tiff tk X"
+REQUIRED_USE="png? ( || ( cairo X ) ) jpeg? ( || ( cairo X ) ) tiff? ( || ( cairo X ) )"
+
+CDEPEND="
+ app-arch/bzip2:0=
+ app-arch/xz-utils:0=
+ app-text/ghostscript-gpl
+ >=dev-libs/libpcre-8.35:3=
+ virtual/blas:0
+ || ( >=sys-apps/coreutils-8.15 sys-freebsd/freebsd-bin app-misc/realpath )
+ cairo? ( x11-libs/cairo:0=[X] x11-libs/pango:0= )
+ icu? ( dev-libs/icu:= )
+ jpeg? ( virtual/jpeg:0 )
+ lapack? ( virtual/lapack:0 )
+ perl? ( dev-lang/perl )
+ png? ( media-libs/libpng:0= )
+ readline? ( sys-libs/readline:0= )
+ tiff? ( media-libs/tiff:0= )
+ tk? ( dev-lang/tk:0= )
+ X? ( x11-libs/libXmu:0= x11-misc/xdg-utils )"
+
+DEPEND="${CDEPEND}
+ virtual/pkgconfig
+ doc? (
+ virtual/latex-base
+ dev-texlive/texlive-fontsrecommended
+ )"
+
+RDEPEND="${CDEPEND}
+ ( || ( <sys-libs/zlib-1.2.5.1-r1:0 >=sys-libs/zlib-1.2.5.1-r2:0[minizip] ) )
+ java? ( >=virtual/jre-1.5 )"
+
+RESTRICT="minimal? ( test )"
+
+R_DIR="${EROOT%/}/usr/$(get_libdir)/${PN}"
+
+pkg_setup() {
+ if use openmp; then
+ if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
+ ewarn "OpenMP is not available in your current selected gcc"
+ die "need openmp capable gcc"
+ fi
+ FORTRAN_NEED_OPENMP=1
+ fi
+ fortran-2_pkg_setup
+ filter-ldflags -Wl,-Bdirect -Bdirect
+ # avoid using existing R installation
+ unset R_HOME
+ # Temporary fix for bug #419761
+ if [[ ($(tc-getCC) == *gcc) && ($(gcc-version) == 4.7) ]]; then
+ append-flags -fno-ipa-cp-clone
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.11.1-parallel.patch \
+ "${FILESDIR}"/${PN}-2.13.1-zlib_header_fix.patch \
+ "${FILESDIR}"/${PN}-3.0.0-rmath-shared.patch \
+ "${FILESDIR}"/${PN}-3.2.0-omitted-extern-R_running_as_main_program.patch
+
+ # fix packages.html for doc (gentoo bug #205103)
+ sed -i \
+ -e "s:../../../library:../../../../$(get_libdir)/R/library:g" \
+ src/library/tools/R/Rd.R || die
+
+ # fix Rscript path when installed (gentoo bug #221061)
+ sed -i \
+ -e "s:-DR_HOME='\"\$(rhome)\"':-DR_HOME='\"${R_DIR}\"':" \
+ src/unix/Makefile.in || die "sed unix Makefile failed"
+
+ # fix HTML links to manual (gentoo bug #273957)
+ sed -i \
+ -e 's:\.\./manual/:manual/:g' \
+ $(grep -Flr ../manual/ doc) || die "sed for HTML links failed"
+
+ use lapack && \
+ export LAPACK_LIBS="$($(tc-getPKG_CONFIG) --libs lapack)"
+
+ if use X; then
+ export R_BROWSER="$(type -p xdg-open)"
+ export R_PDFVIEWER="$(type -p xdg-open)"
+ fi
+ use perl && \
+ export PERL5LIB="${S}/share/perl:${PERL5LIB:+:}${PERL5LIB}"
+
+ # don't search /usr/local
+ sed -i -e '/FLAGS=.*\/local\//c\: # removed by ebuild' configure.ac || die
+ # Fix for Darwin (OS X)
+ if use prefix; then
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e 's:-install_name libR.dylib:-install_name ${libdir}/R/lib/libR.dylib:' \
+ -e 's:-install_name libRlapack.dylib:-install_name ${libdir}/R/lib/libRlapack.dylib:' \
+ -e 's:-install_name libRblas.dylib:-install_name ${libdir}/R/lib/libRblas.dylib:' \
+ -e "/SHLIB_EXT/s/\.so/.dylib/" \
+ configure.ac || die
+ # sort of "undo" 2.14.1-rmath-shared.patch
+ sed -i \
+ -e "s:-Wl,-soname=libRmath.so:-install_name ${EROOT%/}/usr/$(get_libdir)/libRmath.dylib:" \
+ src/nmath/standalone/Makefile.in || die
+ else
+ append-ldflags -Wl,-rpath="${EROOT%/}/usr/$(get_libdir)/R/lib"
+ fi
+ fi
+ AT_M4DIR=m4 eaclocal
+ eautoconf
+}
+
+src_configure() {
+ # --with-system-tre \
+ # tre is patched from upstream
+ econf \
+ --enable-byte-compiled-packages \
+ --enable-R-shlib \
+ --disable-R-framework \
+ --with-system-zlib \
+ --with-system-bzlib \
+ --with-system-pcre \
+ --with-system-xz \
+ --with-blas="$($(tc-getPKG_CONFIG) --libs blas)" \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}" \
+ rdocdir="${EPREFIX}/usr/share/doc/${PF}" \
+ $(use_enable nls) \
+ $(use_enable openmp) \
+ $(use_enable profile R-profiling) \
+ $(use_enable profile memory-profiling) \
+ $(use_enable static-libs static) \
+ $(use_enable static-libs R-static-lib) \
+ $(use_with cairo) \
+ $(use_with icu ICU) \
+ $(use_with jpeg jpeglib) \
+ $(use_with lapack) \
+ $(use_with !minimal recommended-packages) \
+ $(use_with png libpng) \
+ $(use_with readline) \
+ $(use_with tiff libtiff) \
+ $(use_with tk tcltk) \
+ $(use_with tk tk-config "${EPREFIX}"/usr/lib/tkConfig.sh) \
+ $(use_with tk tcl-config "${EPREFIX}"/usr/lib/tclConfig.sh) \
+ $(use_with X x)
+}
+
+src_compile() {
+ export VARTEXFONTS="${T}/fonts"
+ emake AR="$(tc-getAR)"
+ emake -C src/nmath/standalone \
+ shared $(use static-libs && echo static) AR="$(tc-getAR)"
+ use doc && emake info pdf
+}
+
+src_install() {
+ default
+ emake -j1 -C src/nmath/standalone DESTDIR="${D}" install
+
+ if use doc; then
+ emake DESTDIR="${D}" install-info install-pdf
+ dosym ../manual /usr/share/doc/${PF}/html/manual
+ fi
+
+ cat > 99R <<-EOF
+ LDPATH=${R_DIR}/lib
+ R_HOME=${R_DIR}
+ EOF
+ doenvd 99R
+ newbashcomp "${WORKDIR}"/${BCP} ${PN}
+ # The buildsystem has a different understanding of install_names than
+ # we require. Since it builds modules like shared objects (wrong), many
+ # objects (all modules) get an incorrect install_name. Fixing the build
+ # system here is not really trivial.
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ local mod
+ pushd "${ED}"/usr/lib/R > /dev/null
+ for mod in $(find . -name "*.dylib") ; do
+ mod=${mod#./}
+ install_name_tool -id "${EPREFIX}/usr/lib/R/${mod}" \
+ "${mod}"
+ done
+ popd > /dev/null
+ fi
+ docompress -x /usr/share/doc/${PF}/NEWS.rds
+}
+
+pkg_postinst() {
+ if use java; then
+ einfo "Re-initializing java paths for ${P}"
+ R CMD javareconf
+ fi
+}
diff --git a/dev-lang/R/files/R-2.11.1-parallel.patch b/dev-lang/R/files/R-2.11.1-parallel.patch
new file mode 100644
index 00000000000..c713d335bad
--- /dev/null
+++ b/dev-lang/R/files/R-2.11.1-parallel.patch
@@ -0,0 +1,17 @@
+Fix ocasional failure with parallel install
+Gentoo bug: https://bugs.gentoo.org/show_bug.cgi?id=322965
+R bug: https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14505
+
+Patch by Sebastien Fabbro
+
+--- src/include/Makefile.in.orig 2010-06-15 18:18:54.000000000 +0000
++++ src/include/Makefile.in 2010-06-15 18:19:48.000000000 +0000
+@@ -81,7 +81,7 @@
+ Rmath.h0: $(srcdir)/Rmath.h0.in $(top_builddir)/config.status
+ @cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
+
+-install: installdirs install-intl-@USE_INCLUDED_LIBINTL@
++install: $(OBJ_HEADERS) installdirs install-intl-@USE_INCLUDED_LIBINTL@
+ @for d in $(SUBDIRS); do \
+ (cd $${d} && $(MAKE) $@) || exit 1; \
+ done
diff --git a/dev-lang/R/files/R-2.12.1-ldflags.patch b/dev-lang/R/files/R-2.12.1-ldflags.patch
new file mode 100644
index 00000000000..2876ac3a416
--- /dev/null
+++ b/dev-lang/R/files/R-2.12.1-ldflags.patch
@@ -0,0 +1,15 @@
+Respect ldflags on rscript
+Patch by Sebastien Fabbro
+https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14506
+
+--- src/unix/Makefile.in.orig 2010-12-22 16:58:19.000000000 +0000
++++ src/unix/Makefile.in 2010-12-22 16:54:16.000000000 +0000
+@@ -66,7 +66,7 @@
+
+ ## we need to build at install time to capture the correct 'rhome'
+ install-Rscript:
+- $(CC) $(ALL_CPPFLAGS) $(ALL_CFLAGS) -DR_HOME='"$(rhome)"' -o Rscript \
++ $(CC) $(ALL_CPPFLAGS) $(ALL_CFLAGS) $(LDFLAGS) -DR_HOME='"$(rhome)"' -o Rscript \
+ $(srcdir)/Rscript.c
+ @$(MKINSTALLDIRS) "$(DESTDIR)$(Rexecbindir)"
+ @$(INSTALL_PROGRAM) Rscript "$(DESTDIR)$(Rexecbindir)/Rscript"
diff --git a/dev-lang/R/files/R-2.13.1-zlib_header_fix.patch b/dev-lang/R/files/R-2.13.1-zlib_header_fix.patch
new file mode 100644
index 00000000000..136acb26055
--- /dev/null
+++ b/dev-lang/R/files/R-2.13.1-zlib_header_fix.patch
@@ -0,0 +1,20 @@
+Update for zlib header changes for zlib > 1.2.5
+
+Gentoo bug: https://bugs.gentoo.org/show_bug.cgi?id=383431
+R bug: https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14951
+
+Patch by Michael Schreckenbauer
+
+--- src/main/unzip.h.orig 2011-09-24 19:35:53.000000000 -0700
++++ src/main/unzip.h 2011-09-24 19:37:06.000000000 -0700
+@@ -58,6 +58,10 @@
+ #define ZLIB_FILEFUNC_SEEK_END (2)
+ #define ZLIB_FILEFUNC_SEEK_SET (0)
+
++#ifndef OF
++#define OF(x) x
++#endif
++
+ #define ZLIB_FILEFUNC_MODE_READ (1)
+ #define ZLIB_FILEFUNC_MODE_WRITE (2)
+ #define ZLIB_FILEFUNC_MODE_READWRITEFILTER (3)
diff --git a/dev-lang/R/files/R-2.14.1-rmath-shared.patch b/dev-lang/R/files/R-2.14.1-rmath-shared.patch
new file mode 100644
index 00000000000..c16f20e756d
--- /dev/null
+++ b/dev-lang/R/files/R-2.14.1-rmath-shared.patch
@@ -0,0 +1,24 @@
+Link with libm to fix unresolved symbols when linked with as-needed
+and add a soname to the standalone math library
+Patch by Sebastien Fabbro
+--- src/nmath/standalone/Makefile.in.orig 2010-03-17 14:43:22.000000000 +0000
++++ src/nmath/standalone/Makefile.in 2012-01-02 17:40:13.000000000 +0000
+@@ -64,7 +64,8 @@
+ Rexeclibdir_LTLIBRARIES = $(libRmath_la)
+ libRmath_la_SOURCES = $(SOURCES)
+ libRmath_la_OBJECTS = $(OBJECTS:.o=.lo)
+-libRmath_la_LDFLAGS =
++libRmath_la_LDFLAGS = -Wl,-soname=libRmath.so
++libRmath_la_LIBADD = $(LIBM)
+
+ CLEANFILES = Makedeps *.d *.o *.lo test $(SOURCES)
+ DISTCLEANFILES = Makefile $(Rexeclibdir_LIBRARIES) $(Rexeclibdir_LTLIBRARIES)
+@@ -116,7 +117,7 @@
+ $(RANLIB) $@
+
+ $(libRmath_la): $(libRmath_la_OBJECTS)
+- $(DYLIB_LINK) -o $@ $(libRmath_la_LDFLAGS) $(libRmath_la_OBJECTS)
++ $(DYLIB_LINK) $(libRmath_la_LDFLAGS) $(libRmath_la_OBJECTS) $(libRmath_la_LIBADD) -o $@
+
+ test: $(srcdir)/test.c
+ $(CC) -o $@ $(ALL_CPPFLAGS) $(ALL_CFLAGS) $(srcdir)/test.c \
diff --git a/dev-lang/R/files/R-3.0.0-rmath-shared.patch b/dev-lang/R/files/R-3.0.0-rmath-shared.patch
new file mode 100644
index 00000000000..f53fb791051
--- /dev/null
+++ b/dev-lang/R/files/R-3.0.0-rmath-shared.patch
@@ -0,0 +1,28 @@
+Link with libm to fix unresolved symbols when linked with as-needed
+and add a soname to the standalone math library
+R bug: https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14953
+
+Patch by Sebastien Fabbro
+Adapted to R-3.0.0 by Denis Dupeyron
+
+--- src/nmath/standalone/Makefile.in.orig 2013-04-04 14:39:15.777544946 -0600
++++ src/nmath/standalone/Makefile.in 2013-04-04 14:40:51.256153179 -0600
+@@ -64,7 +64,8 @@
+ Rexeclibdir_LTLIBRARIES = $(libRmath_la)
+ libRmath_la_SOURCES = $(SOURCES)
+ libRmath_la_OBJECTS = $(OBJECTS:.o=.lo)
+-libRmath_la_LDFLAGS =
++libRmath_la_LDFLAGS = -Wl,-soname=libRmath.so
++libRmath_la_LIBADD = $(LIBM)
+
+ CLEANFILES = Makedeps *.d *.o *.lo test $(SOURCES)
+ DISTCLEANFILES = Makefile $(Rexeclibdir_LIBRARIES) $(Rexeclibdir_LTLIBRARIES)
+@@ -117,7 +118,7 @@
+
+ ## under peculiar circumstances, $(LIBM) here helps.
+ $(libRmath_la): $(libRmath_la_OBJECTS)
+- $(DYLIB_LINK) -o $@ $(libRmath_la_LDFLAGS) $(libRmath_la_OBJECTS) $(LIBM)
++ $(DYLIB_LINK) $(libRmath_la_LDFLAGS) $(libRmath_la_OBJECTS) $(libRmath_la_LIBADD) -o $@
+
+ test: $(srcdir)/test.c
+ $(CC) -o $@ $(ALL_CPPFLAGS) $(ALL_CFLAGS) $(srcdir)/test.c \
diff --git a/dev-lang/R/files/R-3.2.0-omitted-extern-R_running_as_main_program.patch b/dev-lang/R/files/R-3.2.0-omitted-extern-R_running_as_main_program.patch
new file mode 100644
index 00000000000..eebe5088ff9
--- /dev/null
+++ b/dev-lang/R/files/R-3.2.0-omitted-extern-R_running_as_main_program.patch
@@ -0,0 +1,12 @@
+--- R-3.2.0-orig/src/include/Rinterface.h 2015-03-19 10:02:16.000000000 +1100
++++ R-3.2.0/src/include/Rinterface.h 2015-05-01 23:02:17.541946810 +1000
+@@ -90,7 +90,8 @@
+ void fpu_setup(Rboolean);
+
+ /* in unix/system.c */
+-int R_running_as_main_program;
++/* Gentoo bug 547478 R bug https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15899 */
++extern int R_running_as_main_program;
+
+ #ifdef CSTACK_DEFNS
+ /* duplicating Defn.h */
diff --git a/dev-lang/R/metadata.xml b/dev-lang/R/metadata.xml
new file mode 100644
index 00000000000..1deadcbddd0
--- /dev/null
+++ b/dev-lang/R/metadata.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci-mathematics</herd>
+ <maintainer>
+ <email>calchan@gentoo.org</email>
+ <name>Denis Dupeyron</name>
+ </maintainer>
+ <longdescription lang="en">
+ R is GNU S, a system for statistical computation and graphics. It
+ consists of a language plus a run-time environment with graphics, a
+ debugger, access to certain system functions, and the ability to run
+ programs stored in script files.
+
+ The core of R is an interpreted computer language which allows
+ branching and looping as well as modular programming using functions.
+ The R distribution contains functionality for a large number of
+ statistical procedures such as: linear and generalized linear
+ models, nonlinear regression models, time series analysis, classical
+ parametric and nonparametric tests, clustering, smoothing and
+ graphical data representations. Additional modules ("add-on
+ packages") are available for a variety of specific purposes but are
+ not distributed with this package.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/ats/Manifest b/dev-lang/ats/Manifest
new file mode 100644
index 00000000000..dcfc012e60b
--- /dev/null
+++ b/dev-lang/ats/Manifest
@@ -0,0 +1 @@
+DIST ats-lang-anairiats-0.2.9.tgz 2466767 SHA256 44bbf49f7bea0e411c5a24ae0ea3ecf1d771886b6bd19ea6798badb01f1512fd SHA512 fc7df7bc032ad665c9c8376245bb52f88f71ab81d36fa6f18e66886d9d19f247f54888a8ae3fa5adf17117ee6826bbbde1a177040dc2657f6da0f98d66b035e3 WHIRLPOOL 9d0f2906c87c98aca69ff0f76db19d42adc8bf5a97625b4f8c13bc751690c389e8b2f871206bad09a64ec2913b740cc38a65448c056a227ac561d832a1541e2e
diff --git a/dev-lang/ats/ats-0.2.9.ebuild b/dev-lang/ats/ats-0.2.9.ebuild
new file mode 100644
index 00000000000..4bab28a1075
--- /dev/null
+++ b/dev-lang/ats/ats-0.2.9.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+DESCRIPTION="ATS Programming Language"
+HOMEPAGE="http://www.ats-lang.org"
+SRC_URI="http://downloads.sourceforge.net/project/ats-lang/ats-lang/anairiats-${PV}/${PN}-lang-anairiats-${PV}.tgz"
+
+SLOT="0"
+LICENSE="GPL-3"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="
+ dev-libs/glib
+ x11-libs/gtk+:2
+ sys-libs/ncurses
+ dev-libs/gmp
+ dev-libs/libpcre
+ virtual/opengl
+ media-libs/libsdl
+ dev-libs/boehm-gc
+ "
+DEPEND="${RDEPEND}
+ virtual/pkgconfig
+ "
+
+S="${WORKDIR}"/ats-lang-anairiats-${PV}
+
+src_compile() {
+ emake -j1
+}
diff --git a/dev-lang/ats/metadata.xml b/dev-lang/ats/metadata.xml
new file mode 100644
index 00000000000..6719fcd2bb3
--- /dev/null
+++ b/dev-lang/ats/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>patrick@gentoo.org</email>
+ <name>Patrick Lauer</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/dev-lang/bas/Manifest b/dev-lang/bas/Manifest
new file mode 100644
index 00000000000..e794ae1b521
--- /dev/null
+++ b/dev-lang/bas/Manifest
@@ -0,0 +1 @@
+DIST bas-2.4.tar.gz 258055 SHA256 2a147dd75a80049c1e6030c97aadb03a31fdbb622d0e18bd7961d167c9b48fac SHA512 1a86805d1981a7bc920d7f6ab7827ee9f0ed9535b78b4c46718106e7abe0b1ef9298631e7e4d3d9bf206a8ca0e1239db48a9d94b0b85b71101aea0956d1454d7 WHIRLPOOL 15a1c8a7f00158e330c13998f00976ab10258d8dffb9689722cb01db7ddd62fd15b6a1cc8ad91368a578729e312088a34f29dcaf60b960e43736e3aa2ff8049d
diff --git a/dev-lang/bas/bas-2.4.ebuild b/dev-lang/bas/bas-2.4.ebuild
new file mode 100644
index 00000000000..286c97c3354
--- /dev/null
+++ b/dev-lang/bas/bas-2.4.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+inherit autotools eutils toolchain-funcs
+
+DESCRIPTION="An interpreter for the classic dialect of the programming language BASIC"
+HOMEPAGE="http://www.moria.de/~michael/bas/"
+SRC_URI="http://www.moria.de/~michael/bas/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="lr0"
+
+RDEPEND="sys-libs/ncurses
+ virtual/libintl"
+DEPEND="${RDEPEND}
+ sys-devel/gettext"
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-2.1-makefile.patch
+
+ eautoconf
+}
+
+src_configure() {
+ tc-export AR
+ econf \
+ $(use_enable lr0)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dodoc NEWS README
+ insinto /usr/share/doc/${PF}/pdf
+ doins bas.pdf
+}
diff --git a/dev-lang/bas/files/bas-2.1-makefile.patch b/dev-lang/bas/files/bas-2.1-makefile.patch
new file mode 100644
index 00000000000..3be4bb09eaf
--- /dev/null
+++ b/dev-lang/bas/files/bas-2.1-makefile.patch
@@ -0,0 +1,49 @@
+Fixes makefile.in to respect DESTDIR during install
+Fixes makefile.in to use $MAKE instead of 'make'
+Fixes makefile.in to respect AR during libbas build
+
+Patch by Kevin McCarthy <signals42@gmail.com>
+
+--- Makefile.in
++++ Makefile.in
+@@ -27,7 +27,7 @@
+ libbas.a: auto.o bas.o fs.o global.o token.o program.o \
+ str.o value.o var.o
+ rm -f $@
+- ar cq $@ auto.o bas.o fs.o global.o token.o program.o \
++ $(AR) cq $@ auto.o bas.o fs.o global.o token.o program.o \
+ str.o value.o var.o
+ @RANLIB@ libbas.a
+
+@@ -35,7 +35,7 @@
+ install-po-no:
+ install-po-yes: $(CATALOGS)
+ for cat in $(CATALOGS); do \
+- dir=$(localedir)/`basename $$cat .mo`/LC_MESSAGES; \
++ dir=$(DESTDIR)/$(localedir)/`basename $$cat .mo`/LC_MESSAGES; \
+ [ -d $$dir ] || @INSTALL@ -m 755 -d $$dir; \
+ @INSTALL@ -m 644 $$cat $$dir/bas.mo; \
+ done
+@@ -44,14 +44,14 @@
+ for i in test/test*; do ./$$i || break; done
+
+ install: all
+- @INSTALL@ -m 755 -d @bindir@
+- @INSTALL@ bas @bindir@/bas
+- @INSTALL@ -m 755 -d @libdir@
+- @INSTALL@ -m 644 libbas.a @libdir@/libbas.a
+- @RANLIB@ @libdir@/libbas.a
+- @INSTALL@ -m 755 -d @mandir@/man1
+- @INSTALL@ -m 644 bas.1 @mandir@/man1/bas.1
+- make install-po
++ @INSTALL@ -m 755 -d $(DESTDIR)/@bindir@
++ @INSTALL@ bas $(DESTDIR)/@bindir@/bas
++ @INSTALL@ -m 755 -d $(DESTDIR)/@libdir@
++ @INSTALL@ -m 644 libbas.a $(DESTDIR)/@libdir@/libbas.a
++ @RANLIB@ $(DESTDIR)/@libdir@/libbas.a
++ @INSTALL@ -m 755 -d $(DESTDIR)/@mandir@/man1
++ @INSTALL@ -m 644 bas.1 $(DESTDIR)/@mandir@/man1/bas.1
++ $(MAKE) install-po
+
+ .c.o:
+ $(CC) -c $(CPPFLAGS) $(CFLAGS) $<
diff --git a/dev-lang/bas/metadata.xml b/dev-lang/bas/metadata.xml
new file mode 100644
index 00000000000..367faed79b4
--- /dev/null
+++ b/dev-lang/bas/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>maintainer-needed@gentoo.org</email>
+ </maintainer>
+ <use>
+ <flag name='lr0'>Use the LR0 parser instead of the recursive descending parser</flag>
+ </use>
+</pkgmetadata>
diff --git a/dev-lang/bashforth/Manifest b/dev-lang/bashforth/Manifest
new file mode 100644
index 00000000000..1053fecb20a
--- /dev/null
+++ b/dev-lang/bashforth/Manifest
@@ -0,0 +1 @@
+DIST bashforth-0.58a 78391 SHA256 846eb063e49aae42c38c29c792ec71a9e0d7b0d60f04cd69c15a8cb53257d128 SHA512 55a158fc80d6108a9151537d9d222f23dbeab9b3c9c821068c15ace283b050c0630da8e1cc0a30d997d76acbcd5f7cc38662c997df0d87b7ce68bb3de446d296 WHIRLPOOL 7041a9f9a903c2850c743668eebc410002f8843bee053c341403b9933f9e8b2e1ce9c6a4c785f84bcc67bc51dc6fd6abab7f55f940bd00c642456c20e86737bf
diff --git a/dev-lang/bashforth/bashforth-0.58a.ebuild b/dev-lang/bashforth/bashforth-0.58a.ebuild
new file mode 100644
index 00000000000..6abe4a1689e
--- /dev/null
+++ b/dev-lang/bashforth/bashforth-0.58a.ebuild
@@ -0,0 +1,25 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+DESCRIPTION="String-threaded Forth interpreter in Bash"
+HOMEPAGE="http://www.forthfreak.net/index.cgi?BashForth"
+SRC_URI="http://forthfreak.net/${PN}.versions/${P}"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~mips ~ppc ~ppc64 ~x86"
+IUSE=""
+
+DEPEND=">app-shells/bash-3.0"
+
+S="${WORKDIR}"
+
+src_unpack() {
+ cp "${DISTDIR}/${P}" "${S}"
+}
+
+src_install() {
+ newbin "${P}" "${PN}"
+}
diff --git a/dev-lang/bashforth/metadata.xml b/dev-lang/bashforth/metadata.xml
new file mode 100644
index 00000000000..1e7587374fd
--- /dev/null
+++ b/dev-lang/bashforth/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>blueness@gentoo.org</email>
+ <name>Anthony G. Basile</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/dev-lang/bff/Manifest b/dev-lang/bff/Manifest
new file mode 100644
index 00000000000..a7985e55309
--- /dev/null
+++ b/dev-lang/bff/Manifest
@@ -0,0 +1,2 @@
+DIST bff-1.0.3.1.tar.gz 2617 SHA256 189438f69bf0b66728caa1afed99e83fc03cdd3bdbcfa3c10c766e7bbea50712 SHA512 0bf9e20ffff204f3092b7f02197002880a0be0f4851f4c5f29bcb0974b90e5d518588c334b4f9224ed3320191269c7b4bfe42bd0339ef5ba86bee8bf1cf2a66d WHIRLPOOL be6e7ee7cbd2da649c3d7c0c29075996a552a9d716fdd34268390e5b6a38f8a4db77c5ab9f7c17c9b5066b605aaeb7950398092be697c961a10b2300d00a6f17
+DIST mandelbrot.b 11669 SHA256 f0f048e90855450fb06f2bea21f914f0d24e6b6c15fd050c68176ff794c6229e SHA512 3a1950f8be61fd33e563fe17dbc1297deae3ec2d276a6895e4bbb7d55c5bcf33ec7e9024d9776ad5c9c29b25c55bd08dea71403a60f9478fb3b80c22303d0862 WHIRLPOOL 8dca9257c6c6e1c56a8e5b4b9dc3cd698b44d28499b1760caff7b1fe3bdf8ebafdd30fc92b0134484e91d97bf59b6b2ad8dcc5b02892f28d4bb74add97d892e0
diff --git a/dev-lang/bff/bff-1.0.3.1.ebuild b/dev-lang/bff/bff-1.0.3.1.ebuild
new file mode 100644
index 00000000000..ee86e1e1a0f
--- /dev/null
+++ b/dev-lang/bff/bff-1.0.3.1.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit toolchain-funcs
+
+DESCRIPTION="a brainfuck interpreter"
+HOMEPAGE="http://swapped.cc/bf/"
+SRC_URI="http://swapped.cc/bf/files/${P}.tar.gz
+ test? ( http://swapped.cc/bf/files/mandelbrot.b )"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="amd64 arm hppa ia64 m68k ppc ppc64 s390 sh x86"
+IUSE="test"
+
+DEPEND=""
+RDEPEND=""
+
+src_unpack() {
+ unpack ${P}.tar.gz
+ use test && cp "${DISTDIR}"/mandelbrot.b "${S}"/
+}
+
+src_compile() {
+ $(tc-getCC) -Wall ${CFLAGS} ${LDFLAGS} -o bff bff.c || die "compile failed"
+}
+
+src_test() {
+ ebegin "Running mandelbrot test"
+ ./bff mandelbrot.b > mandelbrot.out
+ eend $? || die
+ [[ $(md5sum mandelbrot.out) == "5024283fa65866ddd347b877798e84d8 "* ]] \
+ && cat mandelbrot.out \
+ || die "mandelbrot did not output correctly"
+}
+
+src_install() {
+ dobin bff || die
+ dodoc README
+}
diff --git a/dev-lang/bff/metadata.xml b/dev-lang/bff/metadata.xml
new file mode 100644
index 00000000000..9e77c1fd69b
--- /dev/null
+++ b/dev-lang/bff/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+<email>maintainer-needed@gentoo.org</email>
+</maintainer>
+<longdescription lang="en">
+bff is a slightly optimized interpreter for brainfuck, a turing-complete
+programming language.
+</longdescription>
+</pkgmetadata>
+
diff --git a/dev-lang/blassic/Manifest b/dev-lang/blassic/Manifest
new file mode 100644
index 00000000000..382955a9885
--- /dev/null
+++ b/dev-lang/blassic/Manifest
@@ -0,0 +1 @@
+DIST blassic-0.10.2.tgz 361603 SHA256 b0ef334d5c1c710643f1dd11e651ce091e7059aa5e9895b547dfa86c3638bdfa SHA512 20f7210fd42ff58e11d7238aee37c21f18b733faf11edeb1d1a3e78c8fb524e37f0c871a2ab6b6608daaf593c4b4e8da4e2f86cddb8ad5e23905b0ce081feffa WHIRLPOOL ba571518104e319c47a341654f241e0b53ece0b614f200a824440fd0e67795a375d4f1703ccaa42ac8c85572c0ee6b0d3c980379094bc836fc4d866e2678cf1a
diff --git a/dev-lang/blassic/blassic-0.10.2.ebuild b/dev-lang/blassic/blassic-0.10.2.ebuild
new file mode 100644
index 00000000000..bb82254467a
--- /dev/null
+++ b/dev-lang/blassic/blassic-0.10.2.ebuild
@@ -0,0 +1,33 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+inherit autotools eutils
+
+DESCRIPTION="classic Basic interpreter"
+HOMEPAGE="http://blassic.org"
+SRC_URI="http://blassic.org/bin/${P}.tgz"
+
+LICENSE="GPL-2"
+KEYWORDS="amd64 hppa ppc x86 ~x86-linux ~ppc-macos ~x86-macos"
+SLOT="0"
+IUSE="X"
+
+RDEPEND="sys-libs/ncurses
+ X? ( x11-libs/libICE x11-libs/libX11 x11-libs/libSM )"
+DEPEND="${RDEPEND}
+ X? ( x11-proto/xproto )"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-tinfo.patch
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --disable-svgalib \
+ $(use_with X x)
+}
+
+DOCS=( AUTHORS NEWS README THANKS TODO )
diff --git a/dev-lang/blassic/files/blassic-0.10.2-tinfo.patch b/dev-lang/blassic/files/blassic-0.10.2-tinfo.patch
new file mode 100644
index 00000000000..3253532a6bc
--- /dev/null
+++ b/dev-lang/blassic/files/blassic-0.10.2-tinfo.patch
@@ -0,0 +1,12 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -191,7 +191,8 @@
+ AC_CHECK_HEADERS([ncurses.h],,[ncurses_found=no])
+ if test "$ncurses_found" = yes
+ then
+- AC_CHECK_LIB([ncurses],[tputs],,[ncurses_found=no])
++ AC_CHECK_LIB([tinfo],[tputs],,
++ AC_CHECK_LIB([ncurses],[tputs],,[ncurses_found=no]))
+ if test "$ncurses_found" = yes
+ then
+ AC_DEFINE(BLASSIC_CONFIG_USE_NCURSES)
diff --git a/dev-lang/blassic/metadata.xml b/dev-lang/blassic/metadata.xml
new file mode 100644
index 00000000000..6e8b0800bd5
--- /dev/null
+++ b/dev-lang/blassic/metadata.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>mr_bones_@gentoo.org</email>
+ <name>Michael Sterrett</name>
+</maintainer>
+<longdescription>
+Blassic is a classic Basic interpreter. The line numbers are mandatory,
+and it has PEEK &amp; POKE. The main goal is to execute programs written in
+old interpreters, but it can be used as a scripting language. Many examples
+are included in /usr/share/blassic/examples/.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/c-intercal/Manifest b/dev-lang/c-intercal/Manifest
new file mode 100644
index 00000000000..dbf4bee2304
--- /dev/null
+++ b/dev-lang/c-intercal/Manifest
@@ -0,0 +1 @@
+DIST intercal-0.29.pax.gz 1003800 SHA256 fba1678bdd058350742fad2f3f0673bcea9f4c8add761855a67d8ada6650950b SHA512 0789278b334f65b6e2034493cf08b26a9885e7aec09072c9d9d3d2796b2c6b09f13a856afea1f77f6c6aac0f386b0a76e35ddd9c87584386f3b8a0ad30bddd31 WHIRLPOOL 9039db79d0ecfd17abdd2ba4788d5e812d4fc5db1fab3ba554567ec3d08cd7091408d054903e8a59dbf77fc78f5408dfc1608eaac0b10e1bf76c32b3a92e300d
diff --git a/dev-lang/c-intercal/c-intercal-29.0.ebuild b/dev-lang/c-intercal/c-intercal-29.0.ebuild
new file mode 100644
index 00000000000..f1dbfc2a418
--- /dev/null
+++ b/dev-lang/c-intercal/c-intercal-29.0.ebuild
@@ -0,0 +1,76 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit elisp-common eutils multilib
+
+# C-INTERCAL uses minor-major ordering of version components and
+# negative version numbers. We map version components -1, -2, ...
+# to 65535, 65534, ..., and subtract one from the next component.
+# For example, upstream version 0.28 is mapped to Gentoo version 28.0
+# and 0.-2.0.29 is mapped to 28.65535.65534.0.
+get_intercal_version() {
+ local i=.${1:-${PV}} j k c=0
+ while [[ ${i} ]]; do
+ (( k = ${i##*.} + c ))
+ (( (c = (k >= 32768)) && (k -= 65536) ))
+ i=${i%.*}
+ j=${j}.${k}
+ done
+ echo ${j#.}
+}
+
+MY_PN="${PN#c-}"
+MY_PV="$(get_intercal_version)"
+DESCRIPTION="C-INTERCAL - INTERCAL to binary (via C) compiler"
+HOMEPAGE="http://c.intercal.org.uk"
+SRC_URI="http://overload.intercal.org.uk/c/${MY_PN}-${MY_PV}.pax.gz"
+
+LICENSE="GPL-2 FDL-1.2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="emacs examples"
+
+DEPEND="emacs? ( virtual/emacs )"
+RDEPEND="${DEPEND}"
+
+MY_PV2=${MY_PV%.${MY_PV##*.}}
+S="${WORKDIR}/${MY_PN}-${MY_PV2##*.}.${MY_PV##*.}"
+SITEFILE="50${PN}-gentoo.el"
+
+src_unpack() {
+ tar xzf "${DISTDIR}/${A}" || die "tar failed"
+}
+
+src_compile() {
+ emake
+
+ if use emacs; then
+ elisp-compile etc/intercal.el || die
+ fi
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dodoc BUGS NEWS HISTORY README doc/THEORY.txt
+
+ if use emacs; then
+ elisp-install ${PN} etc/intercal.{el,elc} || die
+ elisp-site-file-install "${FILESDIR}/${SITEFILE}" || die
+ fi
+
+ if use examples; then
+ insinto /usr/share/doc/${PF}
+ doins -r pit
+ fi
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/c-intercal/files/50c-intercal-gentoo.el b/dev-lang/c-intercal/files/50c-intercal-gentoo.el
new file mode 100644
index 00000000000..c376230eb41
--- /dev/null
+++ b/dev-lang/c-intercal/files/50c-intercal-gentoo.el
@@ -0,0 +1,4 @@
+(add-to-list 'load-path "@SITELISP@")
+(autoload 'intercal-mode "intercal"
+ "A major editing mode for the language Intercal." t)
+;;(add-to-list 'auto-mode-alist '("\\.i\\'" . intercal-mode))
diff --git a/dev-lang/c-intercal/metadata.xml b/dev-lang/c-intercal/metadata.xml
new file mode 100644
index 00000000000..6c6ba5563b7
--- /dev/null
+++ b/dev-lang/c-intercal/metadata.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>ulm@gentoo.org</email>
+</maintainer>
+<maintainer>
+ <email>pchrist@gentoo.org</email>
+</maintainer>
+<longdescription>
+ An implementation of the language INTERCAL, legendary for its perversity
+ and horribleness (this version adds COME FROM for extra flavor). Comes with
+ language manual and examples including possibly the entire extant body of
+ INTERCAL code. Now supports i18n and l14n (to Ancient Roman locale only).
+ Now with fix patch by Donald Knuth.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/cfortran/Manifest b/dev-lang/cfortran/Manifest
new file mode 100644
index 00000000000..6c32e575f4b
--- /dev/null
+++ b/dev-lang/cfortran/Manifest
@@ -0,0 +1,2 @@
+DIST cfortran_4.4-14.diff.gz 23084 SHA256 b49fe76e90f4f7c37e9b9709f4efdc4eee44e781d4c1f3842eed24fac0633daa SHA512 1e0b267efc17c2ba30ca1108d59ef87d1a401e6b88bea2c7045458f8cfad6ec9a05f6bf4a08c1d6cb314c790a4969a1f0fdf0c7b6abc28bae544928aad5b0218 WHIRLPOOL 5e07597d527303c1c15d155ac259f41a4d49e3b3285cc581b044ab5a52d05f8228309eea0a27b7e1a40b255fe3330dea4bf6ab4c1ab3453998ac6500ad17e727
+DIST cfortran_4.4.orig.tar.gz 120119 SHA256 ac7182f01afd3cc14b2525850509109598683eeb1e066c4a1f18661fb0d3d926 SHA512 969d0db566ecd7ed7945cac7f8ceea1cbd94ab427734ba83882acf97022c83b1417e32515d847fee89144137f58f7041cf5164fc397f3d7526f3aa958f8b038c WHIRLPOOL a5544fb9c23b5042d7dd2b52a516115b74e12bc54751f2cd6448eecd4f70cd86854ee4b7bac1248d312155e8be9d756e06d0d4a5bbed4162509a1b2b448330de
diff --git a/dev-lang/cfortran/cfortran-4.4-r2.ebuild b/dev-lang/cfortran/cfortran-4.4-r2.ebuild
new file mode 100644
index 00000000000..b7be931d525
--- /dev/null
+++ b/dev-lang/cfortran/cfortran-4.4-r2.ebuild
@@ -0,0 +1,38 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils
+
+DEB_PR="14"
+
+DESCRIPTION="Header file allowing to call Fortran routines from C and C++"
+SRC_URI="mirror://debian/pool/main/c/${PN}/${PN}_${PV}.orig.tar.gz
+ mirror://debian/pool/main/c/${PN}/${PN}_${PV}-${DEB_PR}.diff.gz"
+HOMEPAGE="http://www-zeus.desy.de/~burow/cfortran/"
+KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86 ~amd64-linux ~x86-linux ~x86-macos"
+LICENSE="LGPL-2"
+IUSE="examples"
+SLOT="0"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${WORKDIR}"/${PN}_${PV}-${DEB_PR}.diff
+ if use examples; then
+ tar xfz cfortran.examples.tar.gz
+ mv eg examples
+ ln -sfn sz1.c examples/sz1/sz1.C
+ ln -sfn pz.c examples/pz/pz.C
+ fi
+}
+
+src_install() {
+ insinto /usr/include/cfortran
+ doins cfortran.h || die
+ dosym cfortran/cfortran.h /usr/include/cfortran.h || die
+ dodoc cfortran.doc debian/{NEWS,changelog,copyright}
+ insinto /usr/share/doc/${PF}
+ doins cfortran.html index.htm cfortest.c cfortex.f
+ use examples && doins -r examples
+}
diff --git a/dev-lang/cfortran/cfortran-4.4-r3.ebuild b/dev-lang/cfortran/cfortran-4.4-r3.ebuild
new file mode 100644
index 00000000000..fea33052e18
--- /dev/null
+++ b/dev-lang/cfortran/cfortran-4.4-r3.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit eutils
+
+DEB_PR="14"
+
+DESCRIPTION="Header file allowing to call Fortran routines from C and C++"
+HOMEPAGE="http://www-zeus.desy.de/~burow/cfortran/"
+SRC_URI="
+ mirror://debian/pool/main/c/${PN}/${PN}_${PV}.orig.tar.gz
+ mirror://debian/pool/main/c/${PN}/${PN}_${PV}-${DEB_PR}.diff.gz"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~x86-macos"
+IUSE="examples"
+
+src_unpack() {
+ default
+ if use examples; then
+ tar xvzf "${S}"/cfortran.examples.tar.gz || die
+ mv eg examples || die
+ ln -sfn sz1.c examples/sz1/sz1.C || die
+ ln -sfn pz.c examples/pz/pz.C || die
+ fi
+}
+
+src_prepare() {
+ epatch "${WORKDIR}"/${PN}_${PV}-${DEB_PR}.diff
+}
+
+src_install() {
+ insinto /usr/include/cfortran
+ doins cfortran.h
+
+ dosym cfortran/cfortran.h /usr/include/cfortran.h
+
+ dodoc cfortran.doc debian/{NEWS,changelog,copyright}
+
+ dohtml cfortran.html index.htm cfortest.c cfortex.f
+
+ if use examples; then
+ insinto /usr/share/${PN}
+ doins -r "${WORKDIR}"/examples
+ fi
+}
diff --git a/dev-lang/cfortran/metadata.xml b/dev-lang/cfortran/metadata.xml
new file mode 100644
index 00000000000..db1151c490f
--- /dev/null
+++ b/dev-lang/cfortran/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci</herd>
+ <longdescription lang="en">
+ cfortran is a header file to ease bridge between C and FORTRAN. It
+ provides an interface between C and FORTRAN routines and global
+ data, i.e. structures and COMMON blocks. This package includes
+ patches from Debian for better support on newer compilers and architectures.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/cilk/Manifest b/dev-lang/cilk/Manifest
new file mode 100644
index 00000000000..1ca7aa3bf83
--- /dev/null
+++ b/dev-lang/cilk/Manifest
@@ -0,0 +1 @@
+DIST cilk-5.4.6.tar.gz 1270768 SHA256 0bee5386fabc87c97d716331b1b492eb8f18c8a8398c566afa3663f27139c9f6 SHA512 1ad082c5e1f42a4f15130673d1d43a0b5dedd80ca0e3182765065be8dccce72b26087243ca3405460dcc90332a84c3c5b1decf5a4650505fb738e7e085998e0e WHIRLPOOL 168138300c33c99a8906ad4c4755b57b7fc360bf5042a63b029a7c58cb7572674c9e8a67fe488ac9573461ea5a0cda69cb3d796abca375a4ecd0fcd7cb9bac4b
diff --git a/dev-lang/cilk/cilk-5.4.6-r1.ebuild b/dev-lang/cilk/cilk-5.4.6-r1.ebuild
new file mode 100644
index 00000000000..7d181822116
--- /dev/null
+++ b/dev-lang/cilk/cilk-5.4.6-r1.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+inherit flag-o-matic autotools eutils
+
+DESCRIPTION="Language for multithreaded parallel programming based on ANSI C"
+HOMEPAGE="http://supertech.csail.mit.edu/cilk"
+SRC_URI="http://supertech.csail.mit.edu/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="doc examples static-libs"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-autotools.patch
+ eautoreconf
+}
+
+src_configure() {
+ append-cppflags -D_XOPEN_SOURCE=600 -D_POSIX_C_SOURCE=200809L
+ replace-flags -O[2-9] -O1
+ econf --with-perfctr=no $(use_enable static-libs static)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dodoc NEWS README THANKS
+ use doc && dodoc doc/manual.pdf
+ if use examples; then
+ insinto /usr/share/doc/${PF}
+ doins -r examples
+ fi
+}
diff --git a/dev-lang/cilk/files/cilk-5.4.6-autotools.patch b/dev-lang/cilk/files/cilk-5.4.6-autotools.patch
new file mode 100644
index 00000000000..9f2d62b9041
--- /dev/null
+++ b/dev-lang/cilk/files/cilk-5.4.6-autotools.patch
@@ -0,0 +1,81 @@
+diff -Nur cilk-5.4.6.orig/cilk2c/Makefile.am cilk-5.4.6/cilk2c/Makefile.am
+--- cilk-5.4.6.orig/cilk2c/Makefile.am 2012-11-12 21:18:50.374020109 -0800
++++ cilk-5.4.6/cilk2c/Makefile.am 2012-11-12 21:19:09.667111443 -0800
+@@ -1,4 +1,6 @@
+-pkglib_PROGRAMS = cilk2c
++pkglibexec_PROGRAMS = cilk2c
++
++BUILT_SOURCES = ANSI-C.c ANSI-C.h
+
+ cilk2c_SOURCES = analyze.c ast.c complex-types.c constexpr.c \
+ container.c conversions.c dataflow.c elide.c initializer.c list.c \
+diff -Nur cilk-5.4.6.orig/configure.ac cilk-5.4.6/configure.ac
+--- cilk-5.4.6.orig/configure.ac 2012-11-12 21:18:50.371020111 -0800
++++ cilk-5.4.6/configure.ac 2012-11-12 21:19:09.668111459 -0800
+@@ -1,8 +1,8 @@
+ dnl Process this file with autoconf to produce a configure script.
+ AC_INIT
+ AC_CONFIG_SRCDIR([config.h.in])
+-AM_CONFIG_HEADER([config.h runtime/cilk-sysdep.h])
+-AC_PREREQ(2.53)
++AC_CONFIG_HEADERS([config.h runtime/cilk-sysdep.h])
++AC_PREREQ(2.68)
+ AM_INIT_AUTOMAKE(cilk, 5.4.6)
+ AC_CANONICAL_HOST
+
+@@ -20,7 +20,7 @@
+
+ dnl Checks for required programs.
+ if test "$GCC" != "yes"; then
+- AC_ERROR("I cannot find gcc. gcc is required for Cilk to work.")
++ AC_MSG_ERROR("I cannot find gcc. gcc is required for Cilk to work.")
+ fi
+
+ dnl Checks for libraries.
+diff -Nur cilk-5.4.6.orig/examples/Makefile.am cilk-5.4.6/examples/Makefile.am
+--- cilk-5.4.6.orig/examples/Makefile.am 2012-11-12 21:18:50.370020112 -0800
++++ cilk-5.4.6/examples/Makefile.am 2012-11-12 21:20:06.347380163 -0800
+@@ -5,13 +5,13 @@
+ NPROC = 4
+ PROGFLAGS = --nproc $(NPROC) --yield
+
+-CILKFLAGS=@CFLAGS@
++CILKFLAGS=-O2
+ CILKCOMPILE = $(CILK) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CILKFLAGS) $(CILKFLAGS)
+ CILKLD = $(CILK)
+ CILKLINK = $(CILKLD) $(AM_CILKFLAGS) $(CILKFLAGS) $(PERFCTR_LIBS) $(LDFLAGS) -o $@
+ LINK=$(CILKLINK)
+
+-noinst_PROGRAMS=hello fib fib-serial testall ck magic knapsack queens \
++check_PROGRAMS=hello fib fib-serial testall ck magic knapsack queens \
+ cilksort fft test-locks bucket cholesky game nfib kalah matmul lu plu \
+ heat test-errno strassen rectmul spacemul \
+ test-void-func \
+@@ -58,7 +58,7 @@
+ EXTRA_DIST = knapsack-example1.input knapsack-example2.input \
+ knapsack-example3.input
+
+-check: hello testall fft fib lu matmul cilksort heat test-locks test-errno
++check-local: hello testall fft fib lu matmul cilksort heat test-locks test-errno
+ @echo "Runnig Cilk tests. This will take a while."
+ ./hello $(PROGFLAGS)
+ ./test-void-func $(PROGFLAGS)
+diff -Nur cilk-5.4.6.orig/runtime/Makefile.am cilk-5.4.6/runtime/Makefile.am
+--- cilk-5.4.6.orig/runtime/Makefile.am 2012-11-12 21:18:50.375020110 -0800
++++ cilk-5.4.6/runtime/Makefile.am 2012-11-12 21:19:09.668111459 -0800
+@@ -1,5 +1,5 @@
+ lib_LTLIBRARIES = libcilk.la libcilk.g.la libcilk.p.la libcilk.g.p.la
+-pkglib_LIBRARIES = libcilkrt0.a libcilkrt0g.a libcilkrt0p.a libcilkrt0gp.a
++lib_LIBRARIES = libcilkrt0.a libcilkrt0g.a libcilkrt0p.a libcilkrt0gp.a
+
+ CILK_HFILES = cilk-cilk2c.h cilk.h cilk-lib.h cilk-lib.cilkh \
+ gcc-builtin.h cilk-cilk2c-pre.h
+@@ -8,7 +8,7 @@
+ cmdline.c internal-malloc.c timing.c invoke-main.c malloc.c debug.c \
+ workers.c mutex.c
+
+-pkginclude_HEADERS = $(CILK_HFILES) cilk-conf.h cilk-sysdep.h
++include_HEADERS = $(CILK_HFILES) cilk-conf.h cilk-sysdep.h
+
+ CILK_SRC = cilk-internal.h $(CILK_CFILES) $(CILK_HFILES)
+ COMMON_LINK_FLAGS = -version-info 1:3:0 @PTHREAD_LIBS@
diff --git a/dev-lang/cilk/metadata.xml b/dev-lang/cilk/metadata.xml
new file mode 100644
index 00000000000..86b18b2b236
--- /dev/null
+++ b/dev-lang/cilk/metadata.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>sci</herd>
+<longdescription lang="en">
+ Cilk is a language for multithreaded parallel programming based on
+ ANSI C. Cilk is especially effective for exploiting dynamic, highly
+ asynchronous parallelism, which can be difficult to write in data-parallel or
+ message-passing style. Cilk provides an effective platform for
+ programming dense and sparse numerical algorithms, such as matrix
+ factorization and N-body simulations. Cilk is algorithmic, in that
+ the runtime system employs a scheduler that allows the performance
+ of programs to be estimated accurately based on abstract complexity
+ measures.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/cll1h/Manifest b/dev-lang/cll1h/Manifest
new file mode 100644
index 00000000000..70a508bafa5
--- /dev/null
+++ b/dev-lang/cll1h/Manifest
@@ -0,0 +1 @@
+DIST cll1h-0.6.tar.gz 6569 SHA256 3f3e964d7b2e2779c13e6f08f1ca9fe97b9b8a698dcf26eea9e2f16246adf6dc SHA512 19b2716519d169d6c090c64c60db318008ac807723d73420d29b75d8b5cf74d56b2b68177483a861ab659efe24cdc1b6e1f17a9fd3c373490bcb1e755ba784b2 WHIRLPOOL 851f920e221eea0dd7e9eea011646f2bdac5dcb23367c8747a075904d5ec7fb095077a287f6a8866c375f66a0194bb3d5f2cfde3a6399272f72c9ca9344448ea
diff --git a/dev-lang/cll1h/cll1h-0.6-r1.ebuild b/dev-lang/cll1h/cll1h-0.6-r1.ebuild
new file mode 100644
index 00000000000..8a86362d03d
--- /dev/null
+++ b/dev-lang/cll1h/cll1h-0.6-r1.ebuild
@@ -0,0 +1,26 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+DESCRIPTION="C<<1 programming language system"
+HOMEPAGE="http://gpl.arachne.cz/"
+SRC_URI="http://gpl.arachne.cz/download/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
+IUSE=""
+
+DEPEND=""
+RDEPEND="sys-devel/gcc"
+
+src_install() {
+ insinto /usr/include
+ doins cll1.h
+ dodoc cll1.txt
+ docinto examples
+ dodoc demos/*.c
+ docompress -x /usr/share/doc/"${PF}"/examples
+}
diff --git a/dev-lang/cll1h/metadata.xml b/dev-lang/cll1h/metadata.xml
new file mode 100644
index 00000000000..d9cd2cad66c
--- /dev/null
+++ b/dev-lang/cll1h/metadata.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+<email>maintainer-needed@gentoo.org</email>
+</maintainer>
+</pkgmetadata>
diff --git a/dev-lang/clojure/Manifest b/dev-lang/clojure/Manifest
new file mode 100644
index 00000000000..334ac5de3b4
--- /dev/null
+++ b/dev-lang/clojure/Manifest
@@ -0,0 +1,2 @@
+DIST clojure-1.5.1.tar.gz 540021 SHA256 ee6cc9360e3545a35cdd6a9ae48b5f4034ef2eb2aaa19721df976078952a805b SHA512 8bc4b7098ec11a3cd4d077f32607c5d23118d5f84b88af69b2051c4dd5b17f28f092b77206fba87e23f1163d2d0f7a2c37b1b1ffa1bcfef3ad4c8f74695d71cd WHIRLPOOL e77d13a771903100a3fe6b0ade84375217c5b150498e727a7cef2d856a4004e640e0c95717fb67be6cae1fbab7611189a1f3999726f7bbec43968eef646dcb32
+DIST clojure-1.6.0.tar.gz 579154 SHA256 70b664b24bd8cc7bf0b5519cfa5fa98424eb3e23303fec04b24a03b8bc4f0b4a SHA512 52bf54d157dae77e71e53bac421daa1bca7ef55b837600c8b04751a545cbed0f04d3718543031d1e5b8ca43e2518d356082b9f8c029c2e318996450cfaee9c81 WHIRLPOOL b79b008773ad678e6418a719183c5b240ad0629d3a32384ec6e5979f0377ba2bd39768f27b71da815342bffbd8bdfa5b66cb24e90cf4f489273b33515f591509
diff --git a/dev-lang/clojure/clojure-1.5.1.ebuild b/dev-lang/clojure/clojure-1.5.1.ebuild
new file mode 100644
index 00000000000..0b432548557
--- /dev/null
+++ b/dev-lang/clojure/clojure-1.5.1.ebuild
@@ -0,0 +1,33 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+JAVA_PKG_IUSE="source test"
+
+inherit java-pkg-2 java-ant-2
+
+DESCRIPTION="Clojure is a dynamic programming language that targets the Java Virtual Machine"
+HOMEPAGE="http://clojure.org/"
+SRC_URI="https://github.com/clojure/clojure/tarball/${P} -> ${P}.tar.gz"
+
+LICENSE="EPL-1.0"
+SLOT="1.5"
+KEYWORDS="amd64 x86 ~x86-linux"
+IUSE=""
+RESTRICT="test" # patches welcome to fix the test
+
+RDEPEND=">=virtual/jre-1.5"
+DEPEND=">=virtual/jdk-1.5"
+
+S=${WORKDIR}/clojure-clojure-22c7e75
+
+src_test() {
+ java-pkg-2_src_test
+}
+
+src_install() {
+ java-pkg_newjar ${P/_/-}.jar
+ java-pkg_dolauncher ${PN}-${SLOT} --main clojure.main
+ dodoc changes.md readme.txt
+}
diff --git a/dev-lang/clojure/clojure-1.6.0.ebuild b/dev-lang/clojure/clojure-1.6.0.ebuild
new file mode 100644
index 00000000000..d7acc4b6b26
--- /dev/null
+++ b/dev-lang/clojure/clojure-1.6.0.ebuild
@@ -0,0 +1,33 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+JAVA_PKG_IUSE="source test"
+
+inherit java-pkg-2 java-ant-2
+
+DESCRIPTION="Clojure is a dynamic programming language that targets the Java Virtual Machine"
+HOMEPAGE="http://clojure.org/"
+SRC_URI="https://github.com/clojure/clojure/tarball/${P} -> ${P}.tar.gz"
+
+LICENSE="EPL-1.0 Apache-2.0 BSD"
+SLOT="1.6"
+KEYWORDS="amd64 x86 ~x86-linux"
+IUSE=""
+RESTRICT="test" # patches welcome to fix the test
+
+RDEPEND=">=virtual/jre-1.6"
+DEPEND=">=virtual/jdk-1.6"
+
+S=${WORKDIR}/clojure-clojure-42ce994
+
+src_test() {
+ java-pkg-2_src_test
+}
+
+src_install() {
+ java-pkg_newjar ${P/_/-}.jar
+ java-pkg_dolauncher ${PN}-${SLOT} --main clojure.main
+ dodoc changes.md readme.txt
+}
diff --git a/dev-lang/clojure/metadata.xml b/dev-lang/clojure/metadata.xml
new file mode 100644
index 00000000000..761b85fc517
--- /dev/null
+++ b/dev-lang/clojure/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>mr_bones_@gentoo.org</email>
+ <name>Michael Sterrett</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">clojure/clojure</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/closure-compiler-bin/Manifest b/dev-lang/closure-compiler-bin/Manifest
new file mode 100644
index 00000000000..737c089f310
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/Manifest
@@ -0,0 +1,5 @@
+DIST closure-compiler-bin-20120305.tar.gz 4905502 SHA256 593037f0f4e8df99293384559d64c3f89f50cecbd36f9a8755b3d4ddeeea89f2 SHA512 53c10a2731e4da8e49c46154c5a997a8b68f2d2e6a86baf4268425b3be416be1e4e9bc64809098484536af980e1192d649a95bd1088bb4da7ba83d4b7dad054f WHIRLPOOL 6e140b19282c1564a715aedd1ccee264ee5ea85e7da94f47fe9d59a3b3c9733cd0797b49238b49e68e25a7ce6957b9b3e26214b23ed41547378f45020d6d3490
+DIST closure-compiler-bin-20121212.tar.gz 5436614 SHA256 a78280bfe585be69648c0777d97bd33d9374d035463125521ca532d203974f60 SHA512 bb7bf694ff8aa9b932a6b248414884fc0d9cef6ab44d88cfad256ebd707ca299b21d2ee313a3b024032fc5eec0ffc4b7080182882af3c2311a2ad1f4ca85d1f9 WHIRLPOOL 5935f6ca1aada268a7d0fca28765c0ad4fc775891cf8f44148b81898838d5a3521a911b13efcb7a97e541f346ddb5fdeb6c998fddf6ed638c0d1fb4c52e87469
+DIST closure-compiler-bin-20130227.tar.gz 5694074 SHA256 c8ac4796e61919a4112ed616cc1734caf69b5aa5e777d5b0428defb21c253537 SHA512 f9ea62e994e1989643e3fe3db8fbe8c66eda34196b30bb31cdccbcbb4c209231bc35e705d5ac8cbcc73aecca8325e41ca48879eb624090b595a05413a56eb243 WHIRLPOOL ec4adc79e51fe5365a3087fc5d92fa1da15939a31f80c36faeda5aff3820cb58a7d77f52883f125c80c74cfa57aa3e830d98dd0975391186658339a66a457b93
+DIST closure-compiler-bin-20130411.tar.gz 5719640 SHA256 8487ab0b22f3c3e1d96ab518d42da057b113a41a685c1e68088c73fa9addcc3c SHA512 19cda8997828f58954ad94b63777aaf3157ce557af16090b6fc7dfc6333d57f901b630b75443a1b0ce961baec3989aae47061e92f97742be051f4451d8ae4023 WHIRLPOOL 3ee276d2f377be03f8bc33ba910770aa2631cc20392855d9dafc25fccc7ea0b393ecb98c20da9932eb6732e68bffc4218b87455260c4ac67d8bf7481aeef7e08
+DIST closure-compiler-bin-20150126.tar.gz 5654460 SHA256 9b8eb3ada77a440f09b32807be492f7b71429e6677d2227866fb2b50d9c7574a SHA512 fe302299aa9f5e21c6db4ebb628b63b83a84faea57a533c52d5f1590617d7df1ab484a1f32a4f666ed23de12860e30cd2f43da33fa5ec7dbb27048d2905d537c WHIRLPOOL 5e4f532ddf90577a84613af18e9a81561090a3518dd994f0f3407fa0bc16c3d94f2934c4437519e14394353e43147b5a9677ee5d413b5f08c00136ef6e9f9471
diff --git a/dev-lang/closure-compiler-bin/closure-compiler-bin-20120305.ebuild b/dev-lang/closure-compiler-bin/closure-compiler-bin-20120305.ebuild
new file mode 100644
index 00000000000..8d86d9cc484
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/closure-compiler-bin-20120305.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit java-pkg-2
+
+DESCRIPTION="JavaScript optimizing compiler"
+HOMEPAGE="http://code.google.com/p/closure-compiler/"
+SRC_URI="http://closure-compiler.googlecode.com/files/compiler-${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=virtual/jre-1.6"
+
+S=${WORKDIR}
+
+src_install() {
+ java-pkg_jarinto /opt/${PN}-${SLOT}/lib
+ java-pkg_newjar compiler.jar ${PN}.jar
+ java-pkg_dolauncher \
+ ${PN%-bin} \
+ --jar /opt/${PN}-${SLOT}/lib/${PN}.jar \
+ -into /opt
+ dodoc README
+}
diff --git a/dev-lang/closure-compiler-bin/closure-compiler-bin-20121212.ebuild b/dev-lang/closure-compiler-bin/closure-compiler-bin-20121212.ebuild
new file mode 100644
index 00000000000..5f49369896c
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/closure-compiler-bin-20121212.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit java-pkg-2
+
+DESCRIPTION="JavaScript optimizing compiler"
+HOMEPAGE="http://code.google.com/p/closure-compiler/"
+SRC_URI="http://closure-compiler.googlecode.com/files/compiler-${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=virtual/jre-1.6"
+
+S=${WORKDIR}
+
+src_install() {
+ java-pkg_jarinto /opt/${PN}-${SLOT}/lib
+ java-pkg_newjar compiler.jar ${PN}.jar
+ java-pkg_dolauncher \
+ ${PN%-bin} \
+ --jar /opt/${PN}-${SLOT}/lib/${PN}.jar \
+ -into /opt
+ dodoc README
+}
diff --git a/dev-lang/closure-compiler-bin/closure-compiler-bin-20130227.ebuild b/dev-lang/closure-compiler-bin/closure-compiler-bin-20130227.ebuild
new file mode 100644
index 00000000000..5f49369896c
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/closure-compiler-bin-20130227.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit java-pkg-2
+
+DESCRIPTION="JavaScript optimizing compiler"
+HOMEPAGE="http://code.google.com/p/closure-compiler/"
+SRC_URI="http://closure-compiler.googlecode.com/files/compiler-${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=virtual/jre-1.6"
+
+S=${WORKDIR}
+
+src_install() {
+ java-pkg_jarinto /opt/${PN}-${SLOT}/lib
+ java-pkg_newjar compiler.jar ${PN}.jar
+ java-pkg_dolauncher \
+ ${PN%-bin} \
+ --jar /opt/${PN}-${SLOT}/lib/${PN}.jar \
+ -into /opt
+ dodoc README
+}
diff --git a/dev-lang/closure-compiler-bin/closure-compiler-bin-20130411.ebuild b/dev-lang/closure-compiler-bin/closure-compiler-bin-20130411.ebuild
new file mode 100644
index 00000000000..5f49369896c
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/closure-compiler-bin-20130411.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit java-pkg-2
+
+DESCRIPTION="JavaScript optimizing compiler"
+HOMEPAGE="http://code.google.com/p/closure-compiler/"
+SRC_URI="http://closure-compiler.googlecode.com/files/compiler-${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=virtual/jre-1.6"
+
+S=${WORKDIR}
+
+src_install() {
+ java-pkg_jarinto /opt/${PN}-${SLOT}/lib
+ java-pkg_newjar compiler.jar ${PN}.jar
+ java-pkg_dolauncher \
+ ${PN%-bin} \
+ --jar /opt/${PN}-${SLOT}/lib/${PN}.jar \
+ -into /opt
+ dodoc README
+}
diff --git a/dev-lang/closure-compiler-bin/closure-compiler-bin-20150126.ebuild b/dev-lang/closure-compiler-bin/closure-compiler-bin-20150126.ebuild
new file mode 100644
index 00000000000..81c9ee43b7c
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/closure-compiler-bin-20150126.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit java-pkg-2
+
+DESCRIPTION="JavaScript optimizing compiler"
+HOMEPAGE="https://github.com/google/closure-compiler"
+SRC_URI="http://dl.google.com/closure-compiler/compiler-${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=virtual/jre-1.6"
+
+S=${WORKDIR}
+
+src_install() {
+ java-pkg_jarinto /opt/${PN}-${SLOT}/lib
+ java-pkg_newjar compiler.jar ${PN}.jar
+ java-pkg_dolauncher \
+ ${PN%-bin} \
+ --jar /opt/${PN}-${SLOT}/lib/${PN}.jar \
+ -into /opt
+ dodoc README.md
+}
diff --git a/dev-lang/closure-compiler-bin/metadata.xml b/dev-lang/closure-compiler-bin/metadata.xml
new file mode 100644
index 00000000000..42d57aedbec
--- /dev/null
+++ b/dev-lang/closure-compiler-bin/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>vapier@gentoo.org</email>
+ <description>make whatever changes you want except for removal -- i need a compiler that avoids installing a jdk</description>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">google/closure-compiler</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/coffee-script/Manifest b/dev-lang/coffee-script/Manifest
new file mode 100644
index 00000000000..9567d32cc94
--- /dev/null
+++ b/dev-lang/coffee-script/Manifest
@@ -0,0 +1 @@
+DIST coffee-script-1.9.3.tar.gz 810246 SHA256 8c8faeeee21ed3cdde727fcc08ed6062d9d0233679317f026160aee8bfa85060 SHA512 660826e27f842ed67ec6ef59f734087c95585e03b6b8c6d25c8ecfc567f3161f59034e730b61e5f806edaaa7ec6c805ad6d14902857aaf09cf6193b0fe14f506 WHIRLPOOL c99eab68344609b5352ee7b7f59ebb4e6c90d1454c3cf37ac8cb00b1add0637e2e56084864ae54cdeb494a6966a97e896bf95760e1e8dbe1b26c0fc75abd5a41
diff --git a/dev-lang/coffee-script/coffee-script-1.9.3-r1.ebuild b/dev-lang/coffee-script/coffee-script-1.9.3-r1.ebuild
new file mode 100644
index 00000000000..98497739ed4
--- /dev/null
+++ b/dev-lang/coffee-script/coffee-script-1.9.3-r1.ebuild
@@ -0,0 +1,48 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+MY_PN="coffeescript"
+
+DESCRIPTION="A little language that compiles into javascript"
+HOMEPAGE="http://coffeescript.org/"
+
+# The tests are missing from the npm registry package, so use Github
+# instead.
+SRC_URI="https://github.com/jashkenas/${MY_PN}/archive/${PV}.tar.gz
+ -> ${P}.tar.gz"
+S="${WORKDIR}/${MY_PN}-${PV}"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+# This package has a test suite (that works), but it requires a number
+# of packages not in the tree. See thread "NPM / NodeJS project" on the
+# gentoo-dev archives for more info.
+IUSE="doc examples"
+
+RDEPEND="net-libs/nodejs"
+
+src_install(){
+ local npm_module_dir="/usr/$(get_libdir)/node/${PN}"
+ insinto "${npm_module_dir}"
+ doins *.js package.json
+ doins -r lib
+ dodoc CONTRIBUTING.md README.md
+
+ use doc && dodoc -r documentation
+ use examples && dodoc -r examples
+
+ # The coffee and cake "binaries" use a relative path to find the lib
+ # directory, so we have to symlink them rather than use dobin().
+ exeinto "${npm_module_dir}/bin"
+ doexe bin/cake
+ doexe bin/coffee
+ dosym "${npm_module_dir}/bin/cake" "/usr/bin/cake"
+ dosym "${npm_module_dir}/bin/coffee" "/usr/bin/coffee"
+}
diff --git a/dev-lang/coffee-script/metadata.xml b/dev-lang/coffee-script/metadata.xml
new file mode 100644
index 00000000000..fd269876d51
--- /dev/null
+++ b/dev-lang/coffee-script/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>mjo@gentoo.org</email>
+ <name>Michael Orlitzky</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">jashkenas/coffeescript</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/confluence/Manifest b/dev-lang/confluence/Manifest
new file mode 100644
index 00000000000..e51da980b9f
--- /dev/null
+++ b/dev-lang/confluence/Manifest
@@ -0,0 +1 @@
+DIST confluence-0.10.6.tar.gz 118762 SHA256 7ab76a4183dae9f2429df5cb07b0df293c50cd947e3c051a6784561e8d3b3273 SHA512 904ea553a917ac2aafc33464fe4175bca76c53c51c50819ea92326dd5a1451e98eca6a56db28b7041814e5e4cea61da618012087a79fa9ec670ca67fc0014d25 WHIRLPOOL 74ad34b66a5f38185b00ac955d10da9b81fdba6b6f9422182550eb039d82782bf168e82a8df738a2fa3f2d615fe36bf605feb5c0b0b3b92c9c67132c4d63fc4d
diff --git a/dev-lang/confluence/confluence-0.10.6.ebuild b/dev-lang/confluence/confluence-0.10.6.ebuild
new file mode 100644
index 00000000000..85c0c915bb7
--- /dev/null
+++ b/dev-lang/confluence/confluence-0.10.6.ebuild
@@ -0,0 +1,47 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="2"
+
+inherit eutils
+
+DESCRIPTION="Functional programming language for reactive system design (digital logic, hard-real-time software)"
+HOMEPAGE="http://www.funhdl.org/wiki/doku.php?id=confluence"
+SRC_URI="http://www.funhdl.org/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="alpha ~amd64 ia64 ~ppc ~sparc x86"
+IUSE="+ocamlopt"
+
+# min version so we are sure we always have ocamlopt in IUSE
+RDEPEND=">=dev-lang/ocaml-3.10[ocamlopt?]"
+DEPEND="${RDEPEND}
+ sys-apps/sed"
+
+src_prepare() {
+ # Install non binary stuff in share...
+ sed -i -e "s:lib/confluence:share/confluence:" Makefile || die "failed to sed the makefile"
+ sed -i -e "s:lib/confluence:share/confluence:" src/cfeval/cf.ml || die "failed to sed ml files"
+ sed -i -e "s:lib/confluence:share/confluence:" src/cfeval/cfParserUtil.ml || die "failed to sed ml files"
+ if ! use ocamlopt; then
+ sed -i -e "s:cmxa:cma:" src/Makefile || die "failed to disable ocamlopt support"
+ sed -i -e "s:cmx:cmo:" src/Makefile || die "failed to disable ocamlopt support"
+ fi
+}
+
+src_compile() {
+ if use ocamlopt; then
+ emake -j1 PREFIX="${D}/usr" OCAMLLIB=`ocamlc -where` || die "failed to build"
+ else
+ emake -j1 OCAMLOPT="ocamlc" OCAMLC="ocamlc" PREFIX="${D}/usr" OCAMLLIB=`ocamlc -where` || die "failed to build"
+ fi
+}
+
+src_install() {
+ emake -j1 PREFIX="${D}/usr" OCAMLLIB=`ocamlc -where` install || die "install failed"
+ echo "CF_LIB=/usr/share/confluence" > "${T}/99${PN}"
+ doenvd "${T}/99${PN}"
+ dodoc NEWS || die
+}
diff --git a/dev-lang/confluence/metadata.xml b/dev-lang/confluence/metadata.xml
new file mode 100644
index 00000000000..2193d772e35
--- /dev/null
+++ b/dev-lang/confluence/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>ml</herd>
+</pkgmetadata>
diff --git a/dev-lang/dmd-bin/Manifest b/dev-lang/dmd-bin/Manifest
new file mode 100644
index 00000000000..85904b4c011
--- /dev/null
+++ b/dev-lang/dmd-bin/Manifest
@@ -0,0 +1,2 @@
+DIST dmd.1.016.zip 4813864 SHA256 839c0d0288560989e16271e842c368347ff392c648b8fe5e4daa9853dfd6684d SHA512 d7d801904c706b2a1fbecadc51a49f2549a4a8b2da6027195d56c9ff2a271ad2f90eb091b80066a0a4608d38905de988a7320c9c720df876bad79dd4f5c14674 WHIRLPOOL 619d0d5a5baf849fff96433b332b99fc868bb30f6cfeab1221f217c953d546312c0ebc088f782edbfcd1630d4541f998167493df20bf90288c718fb51fc6f993
+DIST dmd.2.008.zip 5325757 SHA256 8d8a0b4399ebf1ecc7e88ee68852db5e944ec7b88607d7c02a150bfcdfaf2b64 SHA512 a66aa0141147f2c6a46938c235bc2f7747f493fd09c5265b7d6bb77242075f5e262efb2b03425f2e2ed1e6b7c2bef4ab4c0e935e1ce8167738abb86f4967db96 WHIRLPOOL 356f307353a57fa75a32866d7c21b95f92da308bd6d2afc8bb7bc559a6f18138c6f17975b2b4ea7e332130bbb5e37d1b0ec96ac28d63331a8b13b972e959d8de
diff --git a/dev-lang/dmd-bin/dmd-bin-1.016.ebuild b/dev-lang/dmd-bin/dmd-bin-1.016.ebuild
new file mode 100644
index 00000000000..31876f81e6d
--- /dev/null
+++ b/dev-lang/dmd-bin/dmd-bin-1.016.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils
+
+MY_P=${P/-bin/}
+MY_P=${MY_P/-/.}
+
+DESCRIPTION="Digital Mars D Compiler"
+HOMEPAGE="http://www.digitalmars.com/d/"
+SRC_URI="http://ftp.digitalmars.com/${MY_P}.zip"
+
+LICENSE="DMD"
+SLOT="0"
+KEYWORDS="~x86"
+RESTRICT="mirror strip"
+
+LOC="/opt/dmd"
+S="${WORKDIR}"
+
+DEPEND="sys-apps/findutils
+ app-arch/unzip"
+RDEPEND="~virtual/libstdc++-3.3"
+
+src_unpack() {
+ unpack ${A}
+
+ # Remove unneccessary files
+ mv "${S}"/dmd/lib/libphobos.a "${S}"/dmd
+ rm -r "${S}"/dmd/lib
+ mkdir "${S}"/dmd/lib
+ mv "${S}"/dmd/libphobos.a "${S}"/dmd/lib
+
+ rm -r "${S}"/dm
+ rm "${S}"/dmd/bin/*.dll "${S}"/dmd/bin/*.exe "${S}"/dmd/bin/readme.txt
+ rm "${S}"/dmd/bin/sc.ini "${S}"/dmd/bin/windbg.hlp
+
+ # Cleanup line endings
+ cd "${S}"/dmd
+ edos2unix `find . -name '*.c' -type f`
+ edos2unix `find . -name '*.d' -type f`
+ edos2unix `find . -name '*.ddoc' -type f`
+ edos2unix `find . -name '*.h' -type f`
+ edos2unix `find . -name '*.mak' -type f`
+ edos2unix `find . -name '*.txt' -type f`
+ edos2unix `find samples -name '*.html' -type f`
+
+ # Fix permissions
+ fperms guo=r `find . -type f`
+ fperms guo=rx `find . -type d`
+ fperms guo=rx bin/dmd bin/dumpobj bin/obj2asm bin/rdmd
+}
+
+src_compile() {
+ cd "${S}"/dmd/src/phobos
+ sed -i -e "s:DMD=.*:DMD=${S}/dmd/bin/dmd -I${S}/dmd/src/phobos -L${S}/dmd/lib/libphobos.a:" linux.mak internal/gc/linux.mak
+ edos2unix linux.mak internal/gc/linux.mak
+ make -f linux.mak
+ cp libphobos.a "${S}"/dmd/lib
+
+ # Clean up
+ make -f linux.mak clean
+ rm internal/gc/*.o
+}
+
+src_install() {
+ cd "${S}"/dmd
+
+ # Broken dmd.conf
+ # http://d.puremagic.com/issues/show_bug.cgi?id=278
+ mv bin/dmd bin/dmd.bin
+ cat <<END > "bin/dmd"
+#!/bin/sh
+${LOC}/bin/dmd.bin -I${LOC}/src/phobos -L${LOC}/lib/libphobos.a \$*
+END
+ fperms guo=rx bin/dmd bin/dmd.bin
+
+ # Man pages
+ doman man/man1/dmd.1
+ doman man/man1/dumpobj.1
+ doman man/man1/obj2asm.1
+ rm -r man
+
+ # Install
+ mkdir "${D}/opt"
+ mv "${S}/dmd" "${D}/opt/dmd"
+
+ # Set PATH
+ doenvd "${FILESDIR}/25dmd"
+}
+
+pkg_postinst () {
+ ewarn "The DMD Configuration file has been disabled, "
+ ewarn "and will be re-enabled when: "
+ ewarn " "
+ ewarn "http://d.puremagic.com/issues/show_bug.cgi?id=278"
+ ewarn " "
+ ewarn "has been fixed. Meanwhile, please supply all your"
+ ewarn "configuration options in the /opt/dmd/bin/dmd "
+ ewarn "shell script. "
+ ewarn " "
+ ewarn "You may need to run: "
+ ewarn " "
+ ewarn "env-update && source /etc/profile "
+ ewarn " "
+ ewarn "to be able to use the compiler immediately. "
+ ewarn " "
+}
diff --git a/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild b/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild
new file mode 100644
index 00000000000..cbe2bdb2ee5
--- /dev/null
+++ b/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild
@@ -0,0 +1,105 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils
+
+MY_P=${P/-bin/}
+MY_P=${MY_P/-/.}
+
+DESCRIPTION="Digital Mars D Compiler"
+HOMEPAGE="http://www.digitalmars.com/d/"
+SRC_URI="http://ftp.digitalmars.com/${MY_P}.zip"
+
+LICENSE="DMD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+RESTRICT="mirror strip"
+
+LOC="/opt/dmd"
+S="${WORKDIR}"
+
+DEPEND="sys-apps/findutils
+ app-arch/unzip"
+RDEPEND=""
+
+src_unpack() {
+ unpack ${A}
+
+ # Cleanup line endings
+ cd "${S}/dmd"
+ edos2unix `find . -name '*.c' -type f`
+ edos2unix `find . -name '*.d' -type f`
+ edos2unix `find . -name '*.ddoc' -type f`
+ edos2unix `find . -name '*.h' -type f`
+ edos2unix `find . -name '*.mak' -type f`
+ edos2unix `find . -name '*.txt' -type f`
+ edos2unix `find samples -name '*.html' -type f`
+ edos2unix src/phobos/linux.mak src/phobos/internal/gc/linux.mak
+
+ # Fix permissions and clean up
+ fperms guo=r `find . -type f`
+ fperms guo=rx `find . -type d`
+ fperms guo=rx bin/dmd bin/dumpobj bin/obj2asm bin/rdmd
+}
+
+src_compile() {
+ # Don't use teh bundled library since on gentoo we do teh compile
+ cd "${S}/dmd/src/phobos"
+ sed -i -e "s:DMD=.*:DMD=${S}/dmd/bin/dmd:" linux.mak internal/gc/linux.mak
+ # Can't use emake, customized build system
+ make -f linux.mak
+ cp obj/release/libphobos2.a "${S}/dmd/lib"
+
+ # Clean up
+ make -f linux.mak clean
+}
+
+src_install() {
+ cd "${S}/dmd"
+
+ # Setup dmd.conf
+ cat <<END > "bin/dmd.conf"
+[Environment]
+DFLAGS=-I/opt/dmd/src/phobos -L-L/opt/dmd/lib
+END
+ insinto /etc
+ doins bin/dmd.conf
+
+ # Man pages
+ doman man/man1/dmd.1
+ doman man/man1/dumpobj.1
+ doman man/man1/obj2asm.1
+
+ # Documentation
+ dohtml "html/d/*" "html/d/phobos/*"
+
+ # Install
+ exeinto /opt/dmd/bin
+ doexe bin/dmd
+ doexe bin/dumpobj
+ doexe bin/obj2asm
+ doexe bin/rdmd
+
+ insinto /opt/dmd/lib
+ doins lib/libphobos2.a
+
+ insinto /opt/dmd/samples
+ doins "samples/d/*"
+
+ # Phobos and DMD source
+ mv src "${D}/opt/dmd/"
+
+ # Set PATH
+ doenvd "${FILESDIR}/25dmd"
+}
+
+pkg_postinst () {
+ ewarn "You may need to run: "
+ ewarn "env-update && source /etc/profile "
+ ewarn "to be able to use the compiler immediately. "
+ einfo " "
+ einfo "The bundled samples and sources may be found in "
+ einfo "/opt/dmd/samples and /opt/dmd/src respectively. "
+ einfo " "
+}
diff --git a/dev-lang/dmd-bin/files/25dmd b/dev-lang/dmd-bin/files/25dmd
new file mode 100644
index 00000000000..ab7699d90d7
--- /dev/null
+++ b/dev-lang/dmd-bin/files/25dmd
@@ -0,0 +1,2 @@
+PATH=/opt/dmd/bin
+ROOTPATH=/opt/dmd/bin
diff --git a/dev-lang/dmd-bin/metadata.xml b/dev-lang/dmd-bin/metadata.xml
new file mode 100644
index 00000000000..8160b30f53e
--- /dev/null
+++ b/dev-lang/dmd-bin/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>lang-misc</herd>
+<longdescription>
+ This package provides a binary version of
+ the D language compiler from Digital Mars
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/ekopath/Manifest b/dev-lang/ekopath/Manifest
new file mode 100644
index 00000000000..6fb3ce59791
--- /dev/null
+++ b/dev-lang/ekopath/Manifest
@@ -0,0 +1,3 @@
+DIST ekopath-2015-06-29-installer.run 61567050 SHA256 b98b2b686a7a9624b81838a37b64d8bbfc450b40c7fdfd9957c8a1690a68d4a8 SHA512 e56a9436f837df8d7acd3b9789d50316002ff42b0139b9aa7025f63ad27d98c586715277f3818a10a443d28653a1afd52f69b7101b36afd40beb4594ecbd8f91 WHIRLPOOL 42fe5fc00e83990bcf7c05a76e861d86626d54249da58608d6925323a522f7f2dc5806807aa56deceacce701386163eb34d96344fda4c49bd9b71bedc029ae3b
+DIST ekopath-2015-07-07-installer.run 59012713 SHA256 7e0026405b38f46932fc5b11ebef4c828bc9c0cf05e85f365d314949a091bdd0 SHA512 c68a4b986e9f48ae70c891535a71238a43ba5afa5dcf36c900798292096abf245cc434b03dee8c9ad87e35d7ac1f27c361edcec41dae9989fee6092dd98f5fd3 WHIRLPOOL d32c2564d0c5240fa9c112224c52b38ec2a96062c69d6e4264e610e531258fc3bf8205c4c338890ece3cecf857ffa32cced2d20339f69f098e064bf96306c51e
+DIST ekopath-2015-08-03-installer.run 59079587 SHA256 21e2f3339321e0de09a3e5df250c2dc52aa2ad9c95534a19539c342817f14c2b SHA512 1628f9bfbbce19d666a7ea6158c0abf6a159ef7680854456cfa811fe2a55b9228b34105ce97894af6d714fe23d2d3f0b3f0829c6dec67dd1318b52b3bc541b09 WHIRLPOOL 0978ecb39a8ef3291f05730b17c4df86538a540d5b8f01da699ed821f2aab8da8578a7a0b19a5af74fa560b1ae7c4d6ac06d178aff49aa1fd4b3440b8aa5d0e5
diff --git a/dev-lang/ekopath/ekopath-6.0.430_p20150629.ebuild b/dev-lang/ekopath/ekopath-6.0.430_p20150629.ebuild
new file mode 100644
index 00000000000..ab16a2fc622
--- /dev/null
+++ b/dev-lang/ekopath/ekopath-6.0.430_p20150629.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator multilib pax-utils
+
+MY_PV=$(get_version_component_range 1-3)
+DATE=$(get_version_component_range 4)
+DATE=${DATE#p}
+DATE=${DATE:0:4}-${DATE:4:2}-${DATE:6}
+INSTALLER=${PN}-${DATE}-installer.run
+
+DESCRIPTION="PathScale EKOPath Compiler Suite"
+HOMEPAGE="http://www.pathscale.com/ekopath-compiler-suite"
+SRC_URI="http://c591116.r16.cf2.rackcdn.com/${PN}/nightly/Linux/${INSTALLER}"
+
+LICENSE="all-rights-reserved"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND="!!app-arch/rpm"
+RDEPEND=""
+
+RESTRICT="bindist mirror"
+
+QA_PREBUILT="
+ opt/${PN}/lib/${MY_PV}/x8664/*
+ opt/${PN}/bin/*"
+
+S="${WORKDIR}"
+
+src_unpack() {
+ cp "${DISTDIR}/${INSTALLER}" "${S}/" || die
+ chmod +x "${S}/${INSTALLER}" || die
+}
+
+src_prepare() {
+ cat > 99${PN} <<-EOF
+ PATH=${EROOT%/}/opt/${PN}/bin
+ ROOTPATH=${EROOT%/}/opt/${PN}/bin
+ LDPATH=${EROOT%/}/opt/${PN}/lib:${EROOT%/}/opt/${PN}/lib/${MY_PV}/x8664/64
+ MANPATH=${EROOT%/}/opt/${PN}/docs/man
+ EOF
+}
+
+src_install() {
+ # EI_PAX marking is obsolete and PT_PAX breaks the binary.
+ # We must use XT_PAX to run the installer.
+ if [[ ${PAX_MARKINGS} == "XT" ]]; then
+ pax-mark m "${INSTALLER}"
+ fi
+
+ ./"${INSTALLER}" \
+ --prefix "${ED%/}/opt/${PN}" \
+ --mode unattended || die
+
+ if [[ ! -d ${ED%/}/opt/${PN}/lib/${MY_PV} ]]; then
+ local guess
+ cd "${ED%/}/opt/${PN}/lib" && guess=( * )
+
+ if [[ ${guess[@]} ]]; then
+ die "Incorrect release version in PV, guessing it should be: ${guess[*]}"
+ else
+ die "No libdir installed"
+ fi
+ fi
+ [[ -x ${ED%}/opt/${PN}/bin/pathcc ]] || die "No pathcc executable was installed, your hardware is unsupported most likely"
+
+ rm -r "${ED}/opt/${PN}"/uninstall* || die
+ doenvd 99${PN}
+}
diff --git a/dev-lang/ekopath/ekopath-6.0.439_p20150707.ebuild b/dev-lang/ekopath/ekopath-6.0.439_p20150707.ebuild
new file mode 100644
index 00000000000..ab16a2fc622
--- /dev/null
+++ b/dev-lang/ekopath/ekopath-6.0.439_p20150707.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator multilib pax-utils
+
+MY_PV=$(get_version_component_range 1-3)
+DATE=$(get_version_component_range 4)
+DATE=${DATE#p}
+DATE=${DATE:0:4}-${DATE:4:2}-${DATE:6}
+INSTALLER=${PN}-${DATE}-installer.run
+
+DESCRIPTION="PathScale EKOPath Compiler Suite"
+HOMEPAGE="http://www.pathscale.com/ekopath-compiler-suite"
+SRC_URI="http://c591116.r16.cf2.rackcdn.com/${PN}/nightly/Linux/${INSTALLER}"
+
+LICENSE="all-rights-reserved"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND="!!app-arch/rpm"
+RDEPEND=""
+
+RESTRICT="bindist mirror"
+
+QA_PREBUILT="
+ opt/${PN}/lib/${MY_PV}/x8664/*
+ opt/${PN}/bin/*"
+
+S="${WORKDIR}"
+
+src_unpack() {
+ cp "${DISTDIR}/${INSTALLER}" "${S}/" || die
+ chmod +x "${S}/${INSTALLER}" || die
+}
+
+src_prepare() {
+ cat > 99${PN} <<-EOF
+ PATH=${EROOT%/}/opt/${PN}/bin
+ ROOTPATH=${EROOT%/}/opt/${PN}/bin
+ LDPATH=${EROOT%/}/opt/${PN}/lib:${EROOT%/}/opt/${PN}/lib/${MY_PV}/x8664/64
+ MANPATH=${EROOT%/}/opt/${PN}/docs/man
+ EOF
+}
+
+src_install() {
+ # EI_PAX marking is obsolete and PT_PAX breaks the binary.
+ # We must use XT_PAX to run the installer.
+ if [[ ${PAX_MARKINGS} == "XT" ]]; then
+ pax-mark m "${INSTALLER}"
+ fi
+
+ ./"${INSTALLER}" \
+ --prefix "${ED%/}/opt/${PN}" \
+ --mode unattended || die
+
+ if [[ ! -d ${ED%/}/opt/${PN}/lib/${MY_PV} ]]; then
+ local guess
+ cd "${ED%/}/opt/${PN}/lib" && guess=( * )
+
+ if [[ ${guess[@]} ]]; then
+ die "Incorrect release version in PV, guessing it should be: ${guess[*]}"
+ else
+ die "No libdir installed"
+ fi
+ fi
+ [[ -x ${ED%}/opt/${PN}/bin/pathcc ]] || die "No pathcc executable was installed, your hardware is unsupported most likely"
+
+ rm -r "${ED}/opt/${PN}"/uninstall* || die
+ doenvd 99${PN}
+}
diff --git a/dev-lang/ekopath/ekopath-6.0.468_p20150803.ebuild b/dev-lang/ekopath/ekopath-6.0.468_p20150803.ebuild
new file mode 100644
index 00000000000..ab16a2fc622
--- /dev/null
+++ b/dev-lang/ekopath/ekopath-6.0.468_p20150803.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator multilib pax-utils
+
+MY_PV=$(get_version_component_range 1-3)
+DATE=$(get_version_component_range 4)
+DATE=${DATE#p}
+DATE=${DATE:0:4}-${DATE:4:2}-${DATE:6}
+INSTALLER=${PN}-${DATE}-installer.run
+
+DESCRIPTION="PathScale EKOPath Compiler Suite"
+HOMEPAGE="http://www.pathscale.com/ekopath-compiler-suite"
+SRC_URI="http://c591116.r16.cf2.rackcdn.com/${PN}/nightly/Linux/${INSTALLER}"
+
+LICENSE="all-rights-reserved"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND="!!app-arch/rpm"
+RDEPEND=""
+
+RESTRICT="bindist mirror"
+
+QA_PREBUILT="
+ opt/${PN}/lib/${MY_PV}/x8664/*
+ opt/${PN}/bin/*"
+
+S="${WORKDIR}"
+
+src_unpack() {
+ cp "${DISTDIR}/${INSTALLER}" "${S}/" || die
+ chmod +x "${S}/${INSTALLER}" || die
+}
+
+src_prepare() {
+ cat > 99${PN} <<-EOF
+ PATH=${EROOT%/}/opt/${PN}/bin
+ ROOTPATH=${EROOT%/}/opt/${PN}/bin
+ LDPATH=${EROOT%/}/opt/${PN}/lib:${EROOT%/}/opt/${PN}/lib/${MY_PV}/x8664/64
+ MANPATH=${EROOT%/}/opt/${PN}/docs/man
+ EOF
+}
+
+src_install() {
+ # EI_PAX marking is obsolete and PT_PAX breaks the binary.
+ # We must use XT_PAX to run the installer.
+ if [[ ${PAX_MARKINGS} == "XT" ]]; then
+ pax-mark m "${INSTALLER}"
+ fi
+
+ ./"${INSTALLER}" \
+ --prefix "${ED%/}/opt/${PN}" \
+ --mode unattended || die
+
+ if [[ ! -d ${ED%/}/opt/${PN}/lib/${MY_PV} ]]; then
+ local guess
+ cd "${ED%/}/opt/${PN}/lib" && guess=( * )
+
+ if [[ ${guess[@]} ]]; then
+ die "Incorrect release version in PV, guessing it should be: ${guess[*]}"
+ else
+ die "No libdir installed"
+ fi
+ fi
+ [[ -x ${ED%}/opt/${PN}/bin/pathcc ]] || die "No pathcc executable was installed, your hardware is unsupported most likely"
+
+ rm -r "${ED}/opt/${PN}"/uninstall* || die
+ doenvd 99${PN}
+}
diff --git a/dev-lang/ekopath/metadata.xml b/dev-lang/ekopath/metadata.xml
new file mode 100644
index 00000000000..b78884b8579
--- /dev/null
+++ b/dev-lang/ekopath/metadata.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>sci</herd>
+<maintainer>
+ <email>mgorny@gentoo.org</email>
+ <name>Michał Górny</name>
+ <description>Co-maintainer</description>
+</maintainer>
+<longdescription>
+ The PathScale EKOPath Compiler Suite offers programmers a rich set of tools and
+ one of the world's most sophisticated optimization infrastructures to maximize
+ program performance on any Intel 64 or AMD64 platform supporting Intel MMX,
+ SSE, SSE2, SSE3, SSSE3, SSE4.1, SSE4.2, AMD SSE4A and AVX.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/elixir/Manifest b/dev-lang/elixir/Manifest
new file mode 100644
index 00000000000..190d49144f7
--- /dev/null
+++ b/dev-lang/elixir/Manifest
@@ -0,0 +1,11 @@
+DIST elixir-0.11.2.tar.gz 848108 SHA256 bd3099af3f8b2796e88559b78e1474638ff6ef4894342ea5f0858d00f018fd65 SHA512 2800dfa3d152dd67634c35f31fe1f0a2c59d2db128b80ae6ad07253b1215e181a25c215c5865089adbc122026458ed2d7db4b031823326ee206bd5bcb8f77477 WHIRLPOOL 3fe2cde17708ffe9ece58be18a24d26985c33db54a8b85a55da5809628d499f0a13849cf0b0acd50adb8d4bce9b2492b96a5b609802a4d19fbaa780c98f3e8f2
+DIST elixir-0.12.5.tar.gz 876886 SHA256 8b6ad20decb0a71240d00005daca2e2145a721552455896e091477f53d26a47c SHA512 63e436938deec9916c11598af24897d80a3c3dcda983e5ff281a595b2ef02d4605fb13f9cbef442653fd4e461db77e6588589c280f9425ee9163970ca8752532 WHIRLPOOL 9e59cc1a4e683882d78e16cf266422b193e95f58cf3cc705ba41af20b9cc376e432bfc45b69a98a15cd0494dee72ea1eba443e69d4ca2bf5a250bb42cdf786fb
+DIST elixir-0.13.3.tar.gz 936934 SHA256 2e2349dc42350b0ef23220f9cc89ea0194f0017e8282d08579c730e91d46cb9e SHA512 cca45b6c9165ef428d22474d803ddd769e3eb1fd80b56dce874fb0ae1ab35f75210742b7dd543316cf8b6379ebd4b4f2265ad04780f6abe6db6cf708ec2d4203 WHIRLPOOL 998e32e45be96126500318224adfc99ea443e91b34362907962c648e62a5a9b708c0a6efa9da69fb0ede5248c6a10634f119b5446ec12f6d460b950de1f72929
+DIST elixir-0.14.3.tar.gz 989493 SHA256 7fb49733c1fad8129183d1dd00f7433d56fbc7d9980cc9fdd54f0e472f7d89ee SHA512 4e099beb3877802e47a79e59eddd7a19c00ffb80c6242e24cf0f989688d6d0b3ec8db5a889914b0c2e9ba861ccc2ceda3c913d099aefe24a16fa0aa6ec0fef1b WHIRLPOOL a85d649c14bee7313e71f1b660f36d9828ac947baf600ea85f5fff348a1f4d6357b37b7c7a4e20f2c9800ed54da92d1224d88b5686744e9bf9fc1c9af318f16c
+DIST elixir-0.15.1.tar.gz 1017067 SHA256 8e608abf90a6e9a25ef5fb7e45dfd04e2cb7e1fecb4ac260bf6652885a7f0c50 SHA512 6e10400e15f34e962485ffeefe7a728a688c3b6b31d32ae0d1f990a369810e73cb85bcb3645054b3fb6b3bfaf50249fb074d2894cb58581d71c4d2155225588a WHIRLPOOL 15e8303cc5c1dc3f426331bd1d524505691ee6f072f7eae90d3d25bdd3ec15bee36e42b2f3527457fba3e86828e89380228a02bb7b4ebdb28626d570e6264599
+DIST elixir-1.0.0.tar.gz 1032066 SHA256 527774b05bcaacb0347299b42035b606107e88665fcdd415b0b62704ad7928b2 SHA512 96978fc0df8bd59d22801f376a31d3d5802f5c16e76299a5c7fcfe50c733596b02b9092a92a16edb571fac1bda63a1dbaf38daf586675079d2d21e0f595a5d5d WHIRLPOOL 80ce9826b4288d050e3539643bfe54965ca3162123fa1d1326bf98de72baf3eb87ecfd81ee6b9937845af50d52029a35514bcb48c4700494ac0392f6427f354e
+DIST elixir-1.0.1.tar.gz 1033936 SHA256 87ecbe8aa8eecfed5033a80b0f1ad2fe95ef835fa909fde65fbc622a5aa3431b SHA512 88743b578bdd0f70356d6adfa0793ebe13a77b0022692b7329be9f192dd61ebf14e802b331e79e40460dd7b6937bf5fe12cb82bb5672db14f320385cadf5ba72 WHIRLPOOL a80ff718431163714a68ccf807c2b5db3f40bbd1307d28d03d7c661e72204a697e89b76491c0b288edcba1a598fcbf5442f14dee432e4aa1d88f6f43268511c7
+DIST elixir-1.0.2.tar.gz 1033260 SHA256 6156ee396e85045358d11a6839e157e8fa9573b7414bddbd2c91843ed2b4b962 SHA512 3768bdfeab7478df5e8e7208f5f6e5fad584d3beef78784a322e346851a39c0da5657cb0f88632246377d0795ac735bd80e7a68ca879c08b9e21283a807b4511 WHIRLPOOL 6b766c6cff9f95e95b218ff830ae1d0655e52197c817f9f0b484e7a4f94c37da931ffe48e6caa5430a00fc4807ac0a870bf175b2e20a0c016748de606d106369
+DIST elixir-1.0.3.tar.gz 1039041 SHA256 ec6c4eaffcb771d91bdea9fb274600c624fd16b1891d194b3fcb2b521f52cc75 SHA512 d48636c355181a633dfc5d256f9a1718d74137686080c965d2d568e3d9b0f5cc1352f2ed4d12e50bd89c4cfc9cd59e7a1112ae22979012845df0556124151d1e WHIRLPOOL e76b92272598aba72e9b067eef20492b692f9d4aeeff796a35dc9ea2ee27eed40a5eea369bb92c3a58e23001cf5ea627eb72bf7b7b8b13827f8601479f104135
+DIST elixir-1.0.4.tar.gz 1040843 SHA256 79341fde3b01217aa252b8996d1b1b27cd1006cb89fe43446d5241e3dcb84bad SHA512 c25bc101fd3d1bc8bfb8c793b5da95ac544d0b921538dc24fcd92ff87d1f6248f3c760f714dd7fe061827c5495004d4f7d6d4788c28daf9d519694e49afd5e0f WHIRLPOOL 3ede94b8151319198be053c8e432d801cbbd3386c8c931d5f075696e21668272d3fc058a6f7f9726fd4f6989a70e16d99850d8852703bf23c115ce2cd44a539b
+DIST elixir-1.0.5.tar.gz 1043275 SHA256 5ce5c226b3d11d751b41ad79b915b86f13f8a1b89ef3e733321d3f46ff4d81b8 SHA512 1f621e1a3939433dc91a0e2f7e62512b074ce2e8dc7190535570056875f82eda2001a333a51627e39b0f710e104409c8d17aea9635235b0963265d39b32c9f6c WHIRLPOOL eea70416f08132654e9cc4b65342971cdd7793b45d97fbe5cb1b8e6739a3befb16d72ce15b485a8c2a3204462c8b54afc9c2d934c924863e3a6342e8067644fe
diff --git a/dev-lang/elixir/elixir-0.11.2.ebuild b/dev-lang/elixir/elixir-0.11.2.ebuild
new file mode 100644
index 00000000000..00d92e3def2
--- /dev/null
+++ b/dev-lang/elixir/elixir-0.11.2.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-16"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-0.12.5.ebuild b/dev-lang/elixir/elixir-0.12.5.ebuild
new file mode 100644
index 00000000000..fb0c4b1ffc9
--- /dev/null
+++ b/dev-lang/elixir/elixir-0.12.5.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-16"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-0.13.3.ebuild b/dev-lang/elixir/elixir-0.13.3.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-0.13.3.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-0.14.3.ebuild b/dev-lang/elixir/elixir-0.14.3.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-0.14.3.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-0.15.1.ebuild b/dev-lang/elixir/elixir-0.15.1.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-0.15.1.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.0.ebuild b/dev-lang/elixir/elixir-1.0.0.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.0.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.1.ebuild b/dev-lang/elixir/elixir-1.0.1.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.1.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.2.ebuild b/dev-lang/elixir/elixir-1.0.2.ebuild
new file mode 100644
index 00000000000..0a9e1387f09
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.2.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.3.ebuild b/dev-lang/elixir/elixir-1.0.3.ebuild
new file mode 100644
index 00000000000..77a909a3db8
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.3.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.4.ebuild b/dev-lang/elixir/elixir-1.0.4.ebuild
new file mode 100644
index 00000000000..77a909a3db8
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.4.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/elixir-1.0.5.ebuild b/dev-lang/elixir/elixir-1.0.5.ebuild
new file mode 100644
index 00000000000..77a909a3db8
--- /dev/null
+++ b/dev-lang/elixir/elixir-1.0.5.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="Elixir programming language"
+HOMEPAGE="http://elixir-lang.org"
+SRC_URI="https://github.com/elixir-lang/elixir/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-lang/erlang-17"
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ emake Q=""
+}
+
+src_install() {
+ emake DESTDIR="${D}" LIBDIR="$(get_libdir)" PREFIX="/usr" install
+ dodoc README.md CHANGELOG.md CONTRIBUTING.md
+}
diff --git a/dev-lang/elixir/metadata.xml b/dev-lang/elixir/metadata.xml
new file mode 100644
index 00000000000..d553c3568b7
--- /dev/null
+++ b/dev-lang/elixir/metadata.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>hasufell@gentoo.org</email>
+ <name>Julian Ospald</name>
+ </maintainer>
+ <maintainer>
+ <email>styx.mp@gmail.com</email>
+ <name>Mikhail</name>
+ </maintainer>
+ <upstream>
+ <bugs-to>
+ https://github.com/elixir-lang/elixir/issues
+ </bugs-to>
+ <changelog>
+ https://github.com/elixir-lang/elixir/blob/master/CHANGELOG.md
+ </changelog>
+ <doc lang='en'>
+ http://elixir-lang.org/docs.html
+ </doc>
+ <remote-id type='github'>
+ elixir-lang/elixir
+ </remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/epic/Manifest b/dev-lang/epic/Manifest
new file mode 100644
index 00000000000..5b4e80be0bf
--- /dev/null
+++ b/dev-lang/epic/Manifest
@@ -0,0 +1,4 @@
+DIST epic-0.9.2.tar.gz 65607 SHA256 dca5fb553e383ff1984fb4de9e734a6c4a1390290aafa7bf5b4718d7d1743bc7 SHA512 f9ec3011e8e54d061180a1b3f945158741b35f91ee75ea065df2871d2a872ab8117bb5d34912e4ef84fd39c681eff10fb070a2fdfb23342bfc23aed5bd61534e WHIRLPOOL 85e9982abffd84eea89436912fbccf8e1aa131c9eebcf0354fdea20d321f6f9b3c40eccd6e9044c6c9fa76967180f761fc10928eda501ee17c1c2164e08fa3b5
+DIST epic-0.9.3.2.tar.gz 87050 SHA256 30f5fc0fcd67461c9b19a7ab8d50ef9ddc44430e4fb699171091116df552e3d0 SHA512 de265363ef57500ff544d8fcba5cae95bdd8f5562dff3191595f75a1e37658c1906ffa36b1252e21be06143e0f9096e606f1c59bcaff1026972d70595c76c342 WHIRLPOOL 859308b1ed4b3868cf03b9b68c9de67267f4de5971a81a61e19f65b79e27ca587d40a771285007fb9f730803756b8c5cf521b1c38a71472113524dd8cfa6a3b1
+DIST epic-0.9.3.3.tar.gz 87163 SHA256 559844322f0f3c6d511d70e1a3166175f4aea084ea0e109b161b4d1d4296e82a SHA512 f957eb5402eebad9d52f0d38cf552c00ff5df9caffce97961e761e7c91ed33dee520cb0255f6547db1c05ed6dda7a3e4833d375a5fc0ebe7e94502736a49c566 WHIRLPOOL be19a826d292f490c618659ba8c482cc74cf2239c1585a1d26b62265623858daeb79bdb65b14ede58d0d695a9a0c7f5397d6c3b94c0e5c9326e3b9cc0533096d
+DIST epic-0.9.3.tar.gz 86632 SHA256 6708a21cdf226f0a9344afaf1ee25900b74462d94ed681f815252305251d1ef5 SHA512 2db308f62561f6b4dbada2064754e9e9cbac21ebc3148e04dd102c8eeb6e122f1361374a8900a5daadcb1dac823c21cc5f7164b2ca902183e8647e936991ce08 WHIRLPOOL cbd4e03ff0d1db4551224c884517be1dc4f44521434ca32a52df1743eb691ccd9c4157ca01e64258668473984ec44fff215e43647c0eef9aea015f6fe601de37
diff --git a/dev-lang/epic/epic-0.9.2.ebuild b/dev-lang/epic/epic-0.9.2.ebuild
new file mode 100644
index 00000000000..6d6ab69f020
--- /dev/null
+++ b/dev-lang/epic/epic-0.9.2.ebuild
@@ -0,0 +1,27 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+# ebuild generated by hackport 0.2.14
+
+EAPI="4"
+
+CABAL_FEATURES="bin lib profile haddock hoogle hscolour"
+inherit haskell-cabal
+
+DESCRIPTION="Compiler for a simple functional language"
+HOMEPAGE="http://www.dcs.st-and.ac.uk/~eb/epic.php"
+SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="dev-haskell/cabal
+ dev-haskell/mtl[profile?]
+ >=dev-libs/boehm-gc-7.0[threads]
+ >=dev-lang/ghc-6.10.1"
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.8.0.4
+ dev-haskell/happy"
diff --git a/dev-lang/epic/epic-0.9.3.2.ebuild b/dev-lang/epic/epic-0.9.3.2.ebuild
new file mode 100644
index 00000000000..7dc8a8442ce
--- /dev/null
+++ b/dev-lang/epic/epic-0.9.3.2.ebuild
@@ -0,0 +1,33 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+# ebuild generated by hackport 0.4.4.9999
+
+CABAL_FEATURES="bin lib profile haddock hoogle hscolour"
+inherit eutils haskell-cabal
+
+DESCRIPTION="Compiler for a simple functional language"
+HOMEPAGE="http://www.dcs.st-and.ac.uk/~eb/epic.php"
+SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="dev-haskell/cabal:=[profile?]
+ dev-haskell/mtl:=[profile?]
+ >=dev-libs/boehm-gc-7.0[threads]
+ >=dev-lang/ghc-7.4.1:=
+"
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.8.0.4
+"
+
+src_prepare() {
+ # Bug #438422, upstream at https://github.com/edwinb/EpiVM/issues/5.
+ epatch "${FILESDIR}"/respect-user-cflags.patch
+}
diff --git a/dev-lang/epic/epic-0.9.3.3.ebuild b/dev-lang/epic/epic-0.9.3.3.ebuild
new file mode 100644
index 00000000000..b3201fc5325
--- /dev/null
+++ b/dev-lang/epic/epic-0.9.3.3.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+# ebuild generated by hackport 0.4.5.9999
+
+CABAL_FEATURES="bin lib profile haddock hoogle hscolour"
+inherit eutils haskell-cabal
+
+DESCRIPTION="Compiler for a simple functional language"
+HOMEPAGE="http://www.dcs.st-and.ac.uk/~eb/epic.php"
+SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="dev-haskell/cabal:=[profile?]
+ dev-haskell/mtl:=[profile?]
+ >=dev-libs/boehm-gc-7.0[threads]
+ dev-libs/gmp:0
+ >=dev-lang/ghc-7.4.1:=
+"
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.8.0.4
+"
+
+src_prepare() {
+ # Bug #438422, upstream at https://github.com/edwinb/EpiVM/issues/5.
+ epatch "${FILESDIR}"/respect-user-cflags.patch
+}
diff --git a/dev-lang/epic/epic-0.9.3.ebuild b/dev-lang/epic/epic-0.9.3.ebuild
new file mode 100644
index 00000000000..6bb5318741a
--- /dev/null
+++ b/dev-lang/epic/epic-0.9.3.ebuild
@@ -0,0 +1,29 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+# ebuild generated by hackport 0.3.9999
+
+CABAL_FEATURES="bin lib profile haddock hoogle hscolour"
+inherit base haskell-cabal
+
+DESCRIPTION="Compiler for a simple functional language"
+HOMEPAGE="http://www.dcs.st-and.ac.uk/~eb/epic.php"
+SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="dev-haskell/cabal:=[profile?]
+ dev-haskell/mtl:=[profile?]
+ >=dev-libs/boehm-gc-7.0[threads]
+ >=dev-lang/ghc-6.10.4:="
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.8.0.4
+ dev-haskell/happy"
+
+PATCHES=("${FILESDIR}/${PN}-0.9.3-ghc-7.6.patch")
diff --git a/dev-lang/epic/files/epic-0.9.3-ghc-7.6.patch b/dev-lang/epic/files/epic-0.9.3-ghc-7.6.patch
new file mode 100644
index 00000000000..d168f032b92
--- /dev/null
+++ b/dev-lang/epic/files/epic-0.9.3-ghc-7.6.patch
@@ -0,0 +1,53 @@
+--- epic-0.9.3-orig/Epic/Language.lhs 2012-02-28 10:44:29.000000000 +1100
++++ epic-0.9.3/Epic/Language.lhs 2012-09-14 16:20:29.841939337 +1000
+@@ -1,9 +1,14 @@
+-> {-# LANGUAGE FlexibleInstances, MultiParamTypeClasses,
++> {-# LANGUAGE FlexibleInstances, MultiParamTypeClasses, CPP,
+ > FunctionalDependencies #-}
+
+ > module Epic.Language where
+
+ > import Control.Monad
++#if MIN_VERSION_base(4,6,0)
++> import Control.Exception.Base
++#endif
++
++
+ > import System.IO
+ > import System.Directory
+ > import System.Environment
+@@ -379,7 +384,13 @@
+ > environment :: String -> IO (Maybe String)
+ > environment x = catch (do e <- getEnv x
+ > return (Just e))
+-> (\_ -> return Nothing)
++#if MIN_VERSION_base(4,6,0)
++> (\y-> do return (y::SomeException); return Nothing)
++#endif
++>
++#if !MIN_VERSION_base(4,6,0)
++> (\_-> return Nothing)
++#endif
+
+ Some tests
+
+--- epic-0.9.3-orig/Epic/CodegenC.lhs 2012-02-28 10:44:29.000000000 +1100
++++ epic-0.9.3/Epic/CodegenC.lhs 2012-09-14 16:13:48.061329048 +1000
+@@ -1,3 +1,4 @@
++> {-#LANGUAGE FlexibleContexts#-}
+ > module Epic.CodegenC where
+
+ > import Control.Monad.State
+@@ -98,10 +99,11 @@
+ > if (x>max) then put x else return ()
+
+ > cgs [] = return ""
++
+ > cgs (x:xs) = do xc <- cg x
+ > xsc <- cgs xs
+ > return $ xc ++ "\n" ++ xsc
+-
++> cg:: (MonadState Int m) => ByteOp -> m [Char]
+ > cg (CALL t fn args) = return $ tmp t ++ " = " ++ quickcall fn ++
+ > targs "(" args ++ ");"
+ > cg (TAILCALL t fn args)
diff --git a/dev-lang/epic/files/respect-user-cflags.patch b/dev-lang/epic/files/respect-user-cflags.patch
new file mode 100644
index 00000000000..eedfd253afe
--- /dev/null
+++ b/dev-lang/epic/files/respect-user-cflags.patch
@@ -0,0 +1,13 @@
+diff --git a/evm/Makefile b/evm/Makefile
+index 7e6c5ff..f40f1a4 100644
+--- a/evm/Makefile
++++ b/evm/Makefile
+@@ -1,6 +1,7 @@
+ CC = gcc
+ #CFLAGS = -Wall -g -DUSE_BOEHM
+-CFLAGS = -Wall -O3 -DUSE_BOEHM
++CFLAGS ?= -Wall -O3
++CFLAGS += -DUSE_BOEHM
+ OBJS = closure.o stdfuns.o emalloc.o sparks.o
+ INSTALLDIR = ${PREFIX}/lib/evm
+
diff --git a/dev-lang/epic/metadata.xml b/dev-lang/epic/metadata.xml
new file mode 100644
index 00000000000..b242285af82
--- /dev/null
+++ b/dev-lang/epic/metadata.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>haskell</herd>
+ <maintainer>
+ <email>haskell@gentoo.org</email>
+ </maintainer>
+ <longdescription>
+ Epic is a simple functional language which compiles to
+ reasonably efficient C code, using the Boehm-Demers-Weiser
+ garbage collector (&lt;http://www.hpl.hp.com/personal/Hans_Boehm/gc/&gt;).
+ It is intended as a compiler back end, and is currently used
+ as a back end for Epigram (&lt;http://www.e-pig.org&gt;) and Idris
+ (&lt;http://idris-lang.org/&gt;).
+ It can be invoked either as a library or an application.
+ </longdescription>
+</pkgmetadata>
diff --git a/dev-lang/erlang/Manifest b/dev-lang/erlang/Manifest
new file mode 100644
index 00000000000..80c9fdcf169
--- /dev/null
+++ b/dev-lang/erlang/Manifest
@@ -0,0 +1,12 @@
+DIST otp_doc_html_17.3.tar.gz 33444170 SHA256 bd8278b34f610d6025549640d4e03d79d2a69d7129ea230c0d71d7e6b231f5b3 SHA512 4b1f46c4258b7189b3651af8763916d791888bbc2232c9db60cfda019f611d34d215225fadc88dcfc39539a2c00fbe13b0feba59dea334b77522d7777dc55497 WHIRLPOOL 97930374b82609e27e7ea997050efaf7e92817ec5503fa895a9db30faf1a1c293a6582c769a12ab407eb6981d53aeb58d6a1d558a3b97aa8d2b533cab5aa4c3b
+DIST otp_doc_html_17.5.tar.gz 33510258 SHA256 baba1d373c1faacf4a1a6ec1220d57d0cb2b977edb74f32cd58dc786361c6cf5 SHA512 d3e455452e6d6e241c40de6e41a7b1069f8daa45c8d2340adb62f8867948261692c8465db7e288378942ebe86fd938847756992600da93aa99cb294fadcb5211 WHIRLPOOL 9657c1fd133fa713d0f30bae0394f47f43b090149ec3457a177bd9f129c052b73f1e757762ced02c1c8bcbaec294e845859b18b0e2004429e04df8e04e36cade
+DIST otp_doc_html_18.0.tar.gz 33857396 SHA256 e5a766f68406f5025f921ec32e8959937189ed1245e24b03a74156a8898b03b2 SHA512 5fcbd1ac7fb5f646e181ede385a56adb8d754bc645fd9313c2e3a77a01cb686b1c5975695207f388a78c9599b0d4e6b52c7ea121e900c0a1e2ab20679c0bede1 WHIRLPOOL 5e9174059212b3f5023c04b19164184937b2eb4cbea29103a85813f630b733e60e600e31d3478b3ef759150421b6153a1a3e946e313706bc23e110e01dc1a945
+DIST otp_doc_html_R15B03-1.tar.gz 30436303 SHA256 d06f580f11d1303217a5c1cf8d68a98d7e01c535be934dcd430ecdc254f7572e SHA512 8a22ad702d50f40162f7d6051dbbc0226af449f7a1dcfb087e952dd7eb7213257940933441cfb68f055746450e3e5aa2c5ed8107ac67af7c3a940afb195af8c7 WHIRLPOOL ac10f9ce0ffd4cbd98617e4018e5a4729ce83f0ace6a4db219e7beef2f3a626a8c9a419c7f7772c934ca50310f55486df7eb24955ba845a9230c69c93e183d33
+DIST otp_doc_man_17.3.tar.gz 1357195 SHA256 3fabdac0b0594432fdd8186fa2c74ff49a629a9bcc4174e3bd605a3d4002dab7 SHA512 2e1c483dae85b84bb15950bb06e765ab47ec10785d1fe9b06dce0310dfd3d194b4690ed19e4b16c79a21c8fd1a701895a21af0ceb3422ceee84498d16d984715 WHIRLPOOL bd86e3ba1df1a73efdcd746e50f941620c0d16595901f8336f5180d1030cd8103c52d2f8c9f550984591ab9f439484ffa73b58fdd30de442ee08a0371119f458
+DIST otp_doc_man_17.5.tar.gz 1363320 SHA256 85b1b2a1011fc01af550f1fe9e5a599a4c5f2a35d264d2804af1d05590a857c3 SHA512 98d241aa127cfe377e5efc52284cd324713cacefc96db5992275c4f8712a9e35e43f0dbc0d2a8d58a1127fbfa3f762eb001aea1bb1c9fa82205a3d83659ad548 WHIRLPOOL b790046a449824aa02e11bef6b84a7027351edba0fffd241221e690739df30c9c692074b7354612970d8d02b3c1bccfdbd81bb988af9874d181f177ffed49e2c
+DIST otp_doc_man_18.0.tar.gz 1389178 SHA256 e44f0ec36ee0683867bc2aa9cc7fbb020d9dfd57338f37b98dcd0771f5b95673 SHA512 d3e757b15ee03b4fd89b21a456b89c847a60f4715fb8257c4d3d4f431798cb8d1ae30978608bc85db7f0e25d51072a2d32927745ff410956dca11a01ae4fa034 WHIRLPOOL 83fc8d483a5385b053f5c24e51f35d448dd5ab8e4228500a858422192da17078dbd0f776cbea6d2f77a483c97397cb7e80b5bb5184157611c49743d05fd542bd
+DIST otp_doc_man_R15B03-1.tar.gz 1305001 SHA256 07980d8014c7cf8194b7078c137353f5083992add4663ced3dcba2ff91f228d8 SHA512 eb07552c83a942c1e7f1960b45edfab97b0628a1e08c7c827a07d77797901b4b60a6719b35d0f92a49eb04ada924e9263df70968a5920efc6ccf8e4e966933c6 WHIRLPOOL 764495a8bb67e2c67493452c83ff890d959aa5cd3bd711fce75b3c756dbacb913e50f7d92aab14dc33d6839daaac5a37dc7bcc11fc6392af11dd506a8d99076c
+DIST otp_src_17.3.tar.gz 67050599 SHA256 d4be03eb346016f4ca95d53eb9437ffaa6106762f153620dd98cd7f7733b76e4 SHA512 89d005fc3fdb4dc76c191b6e6a35e03f66ce01d765ba4f58cdd812d358025c62e032443d7ae73fea5b06bf6f27c9bf4e786f8090627ecb1e1309b88b82892910 WHIRLPOOL ef73ea10df2126c129ddb85c0a2bd72c6a7885b200b4d584577beab7c90b84f81647e017f2814dc4406427d4b22f48626db983636bcd5a8648f861484bfe6eff
+DIST otp_src_17.5.tar.gz 67242289 SHA256 3c28820c981b30c50df8ac2a4a238e5813454fa3ed2ad530bc7948a282846474 SHA512 cfd082c8baee7ded370a34f15a1ba3b846b7d81e06edc36c62308c9220697925f1feda91eeecb70fc658f8987087256f51a2ebd0c526d16eeb09c72889d2390d WHIRLPOOL 3c3d987981383bf148b9788fae0574da398ff63d81eea13da0463bed303922d06fe54354de1cd3d37091eb23438939c645176ab565877f06cc1f11235c4d8d3d
+DIST otp_src_18.0.tar.gz 68124710 SHA256 a0b69da34b4f218eb7d63d9e96fc120aa7257bb6c37a0f40fb388e188b4111aa SHA512 84ec2a3834270c1babe153572d6187faa36c12128e604037d55be01719788c0dd79d46769ea7090d530b746206a25fe02346b02849abee10ee41ed4ac7567c02 WHIRLPOOL 7edc237ef906da5e086bcb7b37fe23da3293b3635f612adc9239736e17731270bf64624444c5556d9fd7a03e4e64678a3bd294d04be2aada2a88d897dad9bee0
+DIST otp_src_R15B03-1.tar.gz 76123810 SHA256 4bccac86dd76aec050252e44276a0283a0df9218e6470cf042a9b9f9dfc9476c SHA512 baa8f388bd56bbdf1d3818802d011970fb51d38d14434532b1e4f04c1b8203e5a0cd9cc870f93a993cce750cd1af6e4b7df40dffc44e455353bce9d7c46c8e34 WHIRLPOOL ce76d01dfd17e0bc70e3daa7eab218000d1e802f55b0892e2e9654d2ea262f214f3bd006c0988885e787a1cfe782e8b61d5d1ee3a1d05cbced465b5a28e2de2e
diff --git a/dev-lang/erlang/erlang-15.2.3.1.ebuild b/dev-lang/erlang/erlang-15.2.3.1.ebuild
new file mode 100644
index 00000000000..b5476abf4a6
--- /dev/null
+++ b/dev-lang/erlang/erlang-15.2.3.1.ebuild
@@ -0,0 +1,175 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=3
+WX_GTK_VER="2.8"
+
+inherit elisp-common eutils java-pkg-opt-2 multilib versionator wxwidgets
+
+# NOTE: If you need symlinks for binaries please tell maintainers or
+# open up a bug to let it be created.
+
+# erlang uses a really weird versioning scheme which caused quite a few problems
+# already. Thus we do a slight modification converting all letters to digits to
+# make it more sane (see e.g. #26420)
+
+# the next line selects the right source.
+ERL_VER=($(get_version_components))
+MY_PV="R$(get_major_version)B0${ERL_VER[2]}"
+
+# ATTN!! Take care when processing the C, etc version!
+MY_P=otp_src_${MY_PV}
+
+DESCRIPTION="Erlang programming language, runtime environment, and large collection of libraries"
+HOMEPAGE="http://www.erlang.org/"
+SRC_URI="http://www.erlang.org/download/${MY_P}-${ERL_VER[3]}.tar.gz
+ http://erlang.org/download/otp_doc_man_${MY_PV}-${ERL_VER[3]}.tar.gz
+ doc? ( http://erlang.org/download/otp_doc_html_${MY_PV}-${ERL_VER[3]}.tar.gz )"
+
+LICENSE="ErlPL-1.1"
+SLOT="0"
+KEYWORDS="alpha amd64 ~arm ~ia64 ppc ppc64 sparc x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris"
+IUSE="compat-ethread doc emacs halfword hipe java kpoll odbc smp sctp ssl tk wxwidgets"
+
+RDEPEND=">=dev-lang/perl-5.6.1
+ ssl? ( >=dev-libs/openssl-0.9.7d )
+ emacs? ( virtual/emacs )
+ java? ( >=virtual/jdk-1.2 )
+ odbc? ( dev-db/unixODBC )"
+DEPEND="${RDEPEND}
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,opengl] virtual/glu )
+ sctp? ( net-misc/lksctp-tools )
+ tk? ( dev-lang/tk )"
+
+S="${WORKDIR}/${MY_P}"
+
+SITEFILE=50${PN}-gentoo.el
+
+pkg_setup() {
+ if use halfword ; then
+ use amd64 || die "halfword support is limited to amd64"
+ fi
+}
+
+src_prepare() {
+ use odbc || sed -i 's: odbc : :' lib/Makefile
+
+ # bug 263129, don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(DED_LDFLAGS):LDFLAGS += \$(DED_LDFLAGS):' -i "${S}"/lib/megaco/src/flex/Makefile.in || die
+
+ # don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(ODBC_LIB) \$(EI_LDFLAGS):LDFLAGS += \$(ODBC_LIB) \$(EI_LDFLAGS):' -i "${S}"/lib/odbc/c_src/Makefile.in || die
+
+ if ! use wxwidgets; then
+ sed -i 's: wx : :' lib/Makefile
+ rm -rf lib/wx
+ fi
+
+ # Nasty workaround, reported upstream
+ cp "${S}"/lib/configure.in.src "${S}"/lib/configure.in || die
+
+ # bug 383697
+ sed -i '1i#define OF(x) x' erts/emulator/drivers/common/gzio.c || die
+}
+
+src_configure() {
+ use java || export JAVAC=false
+
+ econf \
+ --enable-threads \
+ --enable-shared-zlib \ \
+ $(use_enable sctp) \
+ $(use_enable halfword halfword-emulator) \
+ $(use_enable hipe) \
+ $(use_with ssl ssl "${EPREFIX}"/usr) \
+ $(use_enable ssl dynamic-ssl-lib) \
+ $(use_enable kpoll kernel-poll) \
+ $(use_enable smp smp-support) \
+ $(use compat-ethread && echo "--enable-ethread-pre-pentium4-compatibility") \
+ $(use x64-macos && echo "--enable-darwin-64bit") \
+ || die
+}
+
+src_compile() {
+ use java || export JAVAC=false
+ emake || die
+
+ if use emacs ; then
+ pushd lib/tools/emacs
+ elisp-compile *.el || die
+ popd
+ fi
+}
+
+extract_version() {
+ sed -n -e "/^$2 = \(.*\)$/s::\1:p" "${S}/$1/vsn.mk"
+}
+
+src_install() {
+ local ERL_LIBDIR=/usr/$(get_libdir)/erlang
+ local ERL_INTERFACE_VER=$(extract_version lib/erl_interface EI_VSN)
+ local ERL_ERTS_VER=$(extract_version erts VSN)
+
+ emake INSTALL_PREFIX="${D}" install || die
+ dodoc AUTHORS README.md
+
+ dosym "${ERL_LIBDIR}/bin/erl" /usr/bin/erl
+ dosym "${ERL_LIBDIR}/bin/erlc" /usr/bin/erlc
+ dosym "${ERL_LIBDIR}/bin/escript" /usr/bin/escript
+ dosym \
+ "${ERL_LIBDIR}/lib/erl_interface-${ERL_INTERFACE_VER}/bin/erl_call" \
+ /usr/bin/erl_call
+ dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam" /usr/bin/beam
+ use smp && dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam.smp" /usr/bin/beam.smp
+
+ ## Remove ${D} from the following files
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/erl" || die
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/start" || die
+ grep -rle "${D}" "${ED}/${ERL_LIBDIR}/erts-${ERL_ERTS_VER}" | xargs sed -i -e "s:${D}::g"
+
+ ## Clean up the no longer needed files
+ rm "${ED}/${ERL_LIBDIR}/Install"||die
+
+ for i in "${WORKDIR}"/man/man* ; do
+ dodir "${ERL_LIBDIR}/${i##${WORKDIR}}"
+ done
+ for file in "${WORKDIR}"/man/man*/*.[1-9]; do
+ # doman sucks so we can't use it
+ cp ${file} "${ED}/${ERL_LIBDIR}"/man/man${file##*.}/
+ done
+ # extend MANPATH, so the normal man command can find it
+ # see bug 189639
+ dodir /etc/env.d/
+ echo "MANPATH=\"${EPREFIX}${ERL_LIBDIR}/man\"" > "${ED}/etc/env.d/90erlang"
+
+ if use doc ; then
+ dohtml -A README,erl,hrl,c,h,kwc,info -r \
+ "${WORKDIR}"/doc "${WORKDIR}"/lib "${WORKDIR}"/erts-*
+ fi
+
+ if use emacs ; then
+ pushd "${S}"
+ elisp-install erlang lib/tools/emacs/*.{el,elc}
+ sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \
+ "${FILESDIR}"/${SITEFILE} > "${T}"/${SITEFILE}
+ elisp-site-file-install "${T}"/${SITEFILE}
+ popd
+ fi
+
+ newinitd "${FILESDIR}"/epmd.init epmd || die
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+ elog
+ elog "If you need a symlink to one of Erlang's binaries,"
+ elog "please open a bug on http://bugs.gentoo.org/"
+ elog
+ elog "Gentoo's versioning scheme differs from the author's, so please refer to this version as ${MY_PV}"
+ elog
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/erlang/erlang-17.3.ebuild b/dev-lang/erlang/erlang-17.3.ebuild
new file mode 100644
index 00000000000..0d9af90b383
--- /dev/null
+++ b/dev-lang/erlang/erlang-17.3.ebuild
@@ -0,0 +1,159 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+WX_GTK_VER="2.8"
+
+inherit autotools elisp-common eutils java-pkg-opt-2 multilib systemd versionator wxwidgets
+
+# NOTE: If you need symlinks for binaries please tell maintainers or
+# open up a bug to let it be created.
+
+DESCRIPTION="Erlang programming language, runtime environment, and large collection of libraries"
+HOMEPAGE="http://www.erlang.org/"
+SRC_URI="http://www.erlang.org/download/otp_src_${PV}.tar.gz
+ http://erlang.org/download/otp_doc_man_${PV}.tar.gz
+ doc? ( http://erlang.org/download/otp_doc_html_${PV}.tar.gz )"
+
+LICENSE="ErlPL-1.1"
+SLOT="0"
+KEYWORDS="alpha amd64 ~arm ~ia64 ppc ppc64 sparc x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris"
+IUSE="compat-ethread doc emacs halfword hipe java kpoll odbc smp sctp ssl systemd tk wxwidgets"
+
+RDEPEND=">=dev-lang/perl-5.6.1
+ ssl? ( >=dev-libs/openssl-0.9.7d )
+ emacs? ( virtual/emacs )
+ java? ( >=virtual/jdk-1.2 )
+ odbc? ( dev-db/unixODBC )"
+DEPEND="${RDEPEND}
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,opengl] virtual/glu )
+ sctp? ( net-misc/lksctp-tools )
+ tk? ( dev-lang/tk )"
+
+S="${WORKDIR}/otp_src_${PV}"
+
+SITEFILE=50${PN}-gentoo.el
+
+pkg_setup() {
+ if use halfword ; then
+ use amd64 || die "halfword support is limited to amd64"
+ fi
+}
+
+src_prepare() {
+ use odbc || sed -i 's: odbc : :' lib/Makefile
+
+ # bug 263129, don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(DED_LDFLAGS):LDFLAGS += \$(DED_LDFLAGS):' -i "${S}"/lib/megaco/src/flex/Makefile.in
+
+ # don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(ODBC_LIB) \$(EI_LDFLAGS):LDFLAGS += \$(ODBC_LIB) \$(EI_LDFLAGS):' -i "${S}"/lib/odbc/c_src/Makefile.in
+
+ if ! use wxwidgets; then
+ sed -i 's: wx : :' lib/Makefile
+ rm -rf lib/wx
+ fi
+
+ # Nasty workaround, reported upstream
+ cp "${S}"/lib/configure.in.src "${S}"/lib/configure.in
+
+ # bug 383697
+ sed -i '1i#define OF(x) x' erts/emulator/drivers/common/gzio.c
+ cd erts && eautoreconf
+}
+
+src_configure() {
+ use java || export JAVAC=false
+
+ econf \
+ --enable-threads \
+ $(use_enable sctp) \
+ $(use_enable systemd) \
+ $(use_enable halfword halfword-emulator) \
+ $(use_enable hipe) \
+ $(use_with ssl ssl "${EPREFIX}"/usr) \
+ $(use_enable ssl dynamic-ssl-lib) \
+ $(use_enable kpoll kernel-poll) \
+ $(use_enable smp smp-support) \
+ $(use compat-ethread && echo "--enable-ethread-pre-pentium4-compatibility") \
+ $(use x64-macos && echo "--enable-darwin-64bit")
+}
+
+src_compile() {
+ use java || export JAVAC=false
+ emake
+
+ if use emacs ; then
+ pushd lib/tools/emacs
+ elisp-compile *.el
+ popd
+ fi
+}
+
+extract_version() {
+ sed -n -e "/^$2 = \(.*\)$/s::\1:p" "${S}/$1/vsn.mk"
+}
+
+src_install() {
+ local ERL_LIBDIR=/usr/$(get_libdir)/erlang
+ local ERL_INTERFACE_VER=$(extract_version lib/erl_interface EI_VSN)
+ local ERL_ERTS_VER=$(extract_version erts VSN)
+
+ emake INSTALL_PREFIX="${D}" install
+ dodoc AUTHORS README.md
+
+ dosym "${ERL_LIBDIR}/bin/erl" /usr/bin/erl
+ dosym "${ERL_LIBDIR}/bin/erlc" /usr/bin/erlc
+ dosym "${ERL_LIBDIR}/bin/escript" /usr/bin/escript
+ dosym \
+ "${ERL_LIBDIR}/lib/erl_interface-${ERL_INTERFACE_VER}/bin/erl_call" \
+ /usr/bin/erl_call
+ dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam" /usr/bin/beam
+ use smp && dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam.smp" /usr/bin/beam.smp
+
+ ## Remove ${D} from the following files
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/erl"
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/start"
+ grep -rle "${D}" "${ED}/${ERL_LIBDIR}/erts-${ERL_ERTS_VER}" | xargs sed -i -e "s:${D}::g"
+
+ ## Clean up the no longer needed files
+ rm "${ED}/${ERL_LIBDIR}/Install"
+
+ for i in "${WORKDIR}"/man/man* ; do
+ dodir "${ERL_LIBDIR}/${i##${WORKDIR}}"
+ done
+ for file in "${WORKDIR}"/man/man*/*.[1-9]; do
+ # doman sucks so we can't use it
+ cp ${file} "${ED}/${ERL_LIBDIR}"/man/man${file##*.}/
+ done
+ # extend MANPATH, so the normal man command can find it
+ # see bug 189639
+ dodir /etc/env.d/
+ echo "MANPATH=\"${EPREFIX}${ERL_LIBDIR}/man\"" > "${ED}/etc/env.d/90erlang"
+
+ if use doc ; then
+ dohtml -A README,erl,hrl,c,h,kwc,info -r \
+ "${WORKDIR}"/doc "${WORKDIR}"/lib "${WORKDIR}"/erts-*
+ fi
+
+ if use emacs ; then
+ pushd "${S}"
+ elisp-install erlang lib/tools/emacs/*.{el,elc}
+ sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \
+ "${FILESDIR}"/${SITEFILE} > "${T}"/${SITEFILE}
+ elisp-site-file-install "${T}"/${SITEFILE}
+ popd
+ fi
+
+ newinitd "${FILESDIR}"/epmd.init epmd
+ systemd_dounit "${FILESDIR}"/epmd.service
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/erlang/erlang-17.5.ebuild b/dev-lang/erlang/erlang-17.5.ebuild
new file mode 100644
index 00000000000..069811e4666
--- /dev/null
+++ b/dev-lang/erlang/erlang-17.5.ebuild
@@ -0,0 +1,159 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+WX_GTK_VER="2.8"
+
+inherit autotools elisp-common eutils java-pkg-opt-2 multilib systemd versionator wxwidgets
+
+# NOTE: If you need symlinks for binaries please tell maintainers or
+# open up a bug to let it be created.
+
+DESCRIPTION="Erlang programming language, runtime environment, and large collection of libraries"
+HOMEPAGE="http://www.erlang.org/"
+SRC_URI="http://www.erlang.org/download/otp_src_${PV}.tar.gz
+ http://erlang.org/download/otp_doc_man_${PV}.tar.gz
+ doc? ( http://erlang.org/download/otp_doc_html_${PV}.tar.gz )"
+
+LICENSE="ErlPL-1.1"
+SLOT="0"
+KEYWORDS="alpha amd64 ~arm ~ia64 ppc ~ppc64 sparc x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris"
+IUSE="compat-ethread doc emacs halfword hipe java kpoll odbc smp sctp ssl systemd tk wxwidgets"
+
+RDEPEND=">=dev-lang/perl-5.6.1
+ ssl? ( >=dev-libs/openssl-0.9.7d )
+ emacs? ( virtual/emacs )
+ java? ( >=virtual/jdk-1.2 )
+ odbc? ( dev-db/unixODBC )"
+DEPEND="${RDEPEND}
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,opengl] virtual/glu )
+ sctp? ( net-misc/lksctp-tools )
+ tk? ( dev-lang/tk )"
+
+S="${WORKDIR}/otp_src_${PV}"
+
+SITEFILE=50${PN}-gentoo.el
+
+pkg_setup() {
+ if use halfword ; then
+ use amd64 || die "halfword support is limited to amd64"
+ fi
+}
+
+src_prepare() {
+ use odbc || sed -i 's: odbc : :' lib/Makefile
+
+ # bug 263129, don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(DED_LDFLAGS):LDFLAGS += \$(DED_LDFLAGS):' -i "${S}"/lib/megaco/src/flex/Makefile.in
+
+ # don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(ODBC_LIB) \$(EI_LDFLAGS):LDFLAGS += \$(ODBC_LIB) \$(EI_LDFLAGS):' -i "${S}"/lib/odbc/c_src/Makefile.in
+
+ if ! use wxwidgets; then
+ sed -i 's: wx : :' lib/Makefile
+ rm -rf lib/wx
+ fi
+
+ # Nasty workaround, reported upstream
+ cp "${S}"/lib/configure.in.src "${S}"/lib/configure.in
+
+ # bug 383697
+ sed -i '1i#define OF(x) x' erts/emulator/drivers/common/gzio.c
+ cd erts && eautoreconf
+}
+
+src_configure() {
+ use java || export JAVAC=false
+
+ econf \
+ --enable-threads \
+ $(use_enable sctp) \
+ $(use_enable systemd) \
+ $(use_enable halfword halfword-emulator) \
+ $(use_enable hipe) \
+ $(use_with ssl ssl "${EPREFIX}"/usr) \
+ $(use_enable ssl dynamic-ssl-lib) \
+ $(use_enable kpoll kernel-poll) \
+ $(use_enable smp smp-support) \
+ $(use compat-ethread && echo "--enable-ethread-pre-pentium4-compatibility") \
+ $(use x64-macos && echo "--enable-darwin-64bit")
+}
+
+src_compile() {
+ use java || export JAVAC=false
+ emake
+
+ if use emacs ; then
+ pushd lib/tools/emacs
+ elisp-compile *.el
+ popd
+ fi
+}
+
+extract_version() {
+ sed -n -e "/^$2 = \(.*\)$/s::\1:p" "${S}/$1/vsn.mk"
+}
+
+src_install() {
+ local ERL_LIBDIR=/usr/$(get_libdir)/erlang
+ local ERL_INTERFACE_VER=$(extract_version lib/erl_interface EI_VSN)
+ local ERL_ERTS_VER=$(extract_version erts VSN)
+
+ emake INSTALL_PREFIX="${D}" install
+ dodoc AUTHORS README.md
+
+ dosym "${ERL_LIBDIR}/bin/erl" /usr/bin/erl
+ dosym "${ERL_LIBDIR}/bin/erlc" /usr/bin/erlc
+ dosym "${ERL_LIBDIR}/bin/escript" /usr/bin/escript
+ dosym \
+ "${ERL_LIBDIR}/lib/erl_interface-${ERL_INTERFACE_VER}/bin/erl_call" \
+ /usr/bin/erl_call
+ dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam" /usr/bin/beam
+ use smp && dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam.smp" /usr/bin/beam.smp
+
+ ## Remove ${D} from the following files
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/erl"
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/start"
+ grep -rle "${D}" "${ED}/${ERL_LIBDIR}/erts-${ERL_ERTS_VER}" | xargs sed -i -e "s:${D}::g"
+
+ ## Clean up the no longer needed files
+ rm "${ED}/${ERL_LIBDIR}/Install"
+
+ for i in "${WORKDIR}"/man/man* ; do
+ dodir "${ERL_LIBDIR}/${i##${WORKDIR}}"
+ done
+ for file in "${WORKDIR}"/man/man*/*.[1-9]; do
+ # doman sucks so we can't use it
+ cp ${file} "${ED}/${ERL_LIBDIR}"/man/man${file##*.}/
+ done
+ # extend MANPATH, so the normal man command can find it
+ # see bug 189639
+ dodir /etc/env.d/
+ echo "MANPATH=\"${EPREFIX}${ERL_LIBDIR}/man\"" > "${ED}/etc/env.d/90erlang"
+
+ if use doc ; then
+ dohtml -A README,erl,hrl,c,h,kwc,info -r \
+ "${WORKDIR}"/doc "${WORKDIR}"/lib "${WORKDIR}"/erts-*
+ fi
+
+ if use emacs ; then
+ pushd "${S}"
+ elisp-install erlang lib/tools/emacs/*.{el,elc}
+ sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \
+ "${FILESDIR}"/${SITEFILE} > "${T}"/${SITEFILE}
+ elisp-site-file-install "${T}"/${SITEFILE}
+ popd
+ fi
+
+ newinitd "${FILESDIR}"/epmd.init epmd
+ systemd_dounit "${FILESDIR}"/epmd.service
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/erlang/erlang-18.0.ebuild b/dev-lang/erlang/erlang-18.0.ebuild
new file mode 100644
index 00000000000..547d0a5aa6d
--- /dev/null
+++ b/dev-lang/erlang/erlang-18.0.ebuild
@@ -0,0 +1,158 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+WX_GTK_VER="2.8"
+
+inherit autotools elisp-common eutils java-pkg-opt-2 multilib systemd versionator wxwidgets
+
+# NOTE: If you need symlinks for binaries please tell maintainers or
+# open up a bug to let it be created.
+
+DESCRIPTION="Erlang programming language, runtime environment, and large collection of libraries"
+HOMEPAGE="http://www.erlang.org/"
+SRC_URI="http://www.erlang.org/download/otp_src_${PV}.tar.gz
+ http://erlang.org/download/otp_doc_man_${PV}.tar.gz
+ doc? ( http://erlang.org/download/otp_doc_html_${PV}.tar.gz )"
+
+LICENSE="ErlPL-1.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris"
+IUSE="compat-ethread doc emacs halfword hipe java kpoll odbc smp sctp ssl systemd tk wxwidgets"
+
+RDEPEND="ssl? ( >=dev-libs/openssl-0.9.7d )
+ emacs? ( virtual/emacs )
+ java? ( >=virtual/jdk-1.2 )
+ odbc? ( dev-db/unixODBC )"
+DEPEND="${RDEPEND}
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,opengl] virtual/glu )
+ sctp? ( net-misc/lksctp-tools )
+ tk? ( dev-lang/tk )"
+
+S="${WORKDIR}/otp_src_${PV}"
+
+SITEFILE=50${PN}-gentoo.el
+
+pkg_setup() {
+ if use halfword ; then
+ use amd64 || die "halfword support is limited to amd64"
+ fi
+}
+
+src_prepare() {
+ use odbc || sed -i 's: odbc : :' lib/Makefile
+
+ # bug 263129, don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(DED_LDFLAGS):LDFLAGS += \$(DED_LDFLAGS):' -i "${S}"/lib/megaco/src/flex/Makefile.in
+
+ # don't ignore LDFLAGS, reported upstream
+ sed -e 's:LDFLAGS = \$(ODBC_LIB) \$(EI_LDFLAGS):LDFLAGS += \$(ODBC_LIB) \$(EI_LDFLAGS):' -i "${S}"/lib/odbc/c_src/Makefile.in
+
+ if ! use wxwidgets; then
+ sed -i 's: wx : :' lib/Makefile
+ rm -rf lib/wx
+ fi
+
+ # Nasty workaround, reported upstream
+ cp "${S}"/lib/configure.in.src "${S}"/lib/configure.in
+
+ # bug 383697
+ sed -i '1i#define OF(x) x' erts/emulator/drivers/common/gzio.c
+ cd erts && eautoreconf
+}
+
+src_configure() {
+ use java || export JAVAC=false
+
+ econf \
+ --enable-threads \
+ $(use_enable sctp) \
+ $(use_enable systemd) \
+ $(use_enable halfword halfword-emulator) \
+ $(use_enable hipe) \
+ $(use_with ssl ssl "${EPREFIX}"/usr) \
+ $(use_enable ssl dynamic-ssl-lib) \
+ $(use_enable kpoll kernel-poll) \
+ $(use_enable smp smp-support) \
+ $(use compat-ethread && echo "--enable-ethread-pre-pentium4-compatibility") \
+ $(use x64-macos && echo "--enable-darwin-64bit")
+}
+
+src_compile() {
+ use java || export JAVAC=false
+ emake
+
+ if use emacs ; then
+ pushd lib/tools/emacs
+ elisp-compile *.el
+ popd
+ fi
+}
+
+extract_version() {
+ sed -n -e "/^$2 = \(.*\)$/s::\1:p" "${S}/$1/vsn.mk"
+}
+
+src_install() {
+ local ERL_LIBDIR=/usr/$(get_libdir)/erlang
+ local ERL_INTERFACE_VER=$(extract_version lib/erl_interface EI_VSN)
+ local ERL_ERTS_VER=$(extract_version erts VSN)
+
+ emake INSTALL_PREFIX="${D}" install
+ dodoc AUTHORS README.md
+
+ dosym "${ERL_LIBDIR}/bin/erl" /usr/bin/erl
+ dosym "${ERL_LIBDIR}/bin/erlc" /usr/bin/erlc
+ dosym "${ERL_LIBDIR}/bin/escript" /usr/bin/escript
+ dosym \
+ "${ERL_LIBDIR}/lib/erl_interface-${ERL_INTERFACE_VER}/bin/erl_call" \
+ /usr/bin/erl_call
+ dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam" /usr/bin/beam
+ use smp && dosym "${ERL_LIBDIR}/erts-${ERL_ERTS_VER}/bin/beam.smp" /usr/bin/beam.smp
+
+ ## Remove ${D} from the following files
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/erl"
+ sed -e "s:${D}::g" -i "${ED}${ERL_LIBDIR}/bin/start"
+ grep -rle "${D}" "${ED}/${ERL_LIBDIR}/erts-${ERL_ERTS_VER}" | xargs sed -i -e "s:${D}::g"
+
+ ## Clean up the no longer needed files
+ rm "${ED}/${ERL_LIBDIR}/Install"
+
+ for i in "${WORKDIR}"/man/man* ; do
+ dodir "${ERL_LIBDIR}/${i##${WORKDIR}}"
+ done
+ for file in "${WORKDIR}"/man/man*/*.[1-9]; do
+ # doman sucks so we can't use it
+ cp ${file} "${ED}/${ERL_LIBDIR}"/man/man${file##*.}/
+ done
+ # extend MANPATH, so the normal man command can find it
+ # see bug 189639
+ dodir /etc/env.d/
+ echo "MANPATH=\"${EPREFIX}${ERL_LIBDIR}/man\"" > "${ED}/etc/env.d/90erlang"
+
+ if use doc ; then
+ dohtml -A README,erl,hrl,c,h,kwc,info -r \
+ "${WORKDIR}"/doc "${WORKDIR}"/lib "${WORKDIR}"/erts-*
+ fi
+
+ if use emacs ; then
+ pushd "${S}"
+ elisp-install erlang lib/tools/emacs/*.{el,elc}
+ sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \
+ "${FILESDIR}"/${SITEFILE} > "${T}"/${SITEFILE}
+ elisp-site-file-install "${T}"/${SITEFILE}
+ popd
+ fi
+
+ newinitd "${FILESDIR}"/epmd.init epmd
+ systemd_dounit "${FILESDIR}"/epmd.service
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/erlang/files/16.2-tinfo.patch b/dev-lang/erlang/files/16.2-tinfo.patch
new file mode 100644
index 00000000000..f51ba582d8c
--- /dev/null
+++ b/dev-lang/erlang/files/16.2-tinfo.patch
@@ -0,0 +1,11 @@
+--- erts/configure.in.bak 2013-11-04 14:47:47.838188678 +0100
++++ erts/configure.in 2013-11-04 14:46:54.352439671 +0100
+@@ -1322,7 +1322,7 @@
+ if test "x$with_termcap" != "xno" &&
+ test "X$host" != "Xwin32"; then
+ # try these libs
+- termcap_libs="ncurses curses termcap termlib"
++ termcap_libs="tinfo ncurses curses termcap termlib"
+
+ for termcap_lib in $termcap_libs; do
+ AC_CHECK_LIB($termcap_lib, tgetent, TERMCAP_LIB="-l$termcap_lib")
diff --git a/dev-lang/erlang/files/17.0-systemd.patch b/dev-lang/erlang/files/17.0-systemd.patch
new file mode 100644
index 00000000000..2dba8c897fe
--- /dev/null
+++ b/dev-lang/erlang/files/17.0-systemd.patch
@@ -0,0 +1,85 @@
+--- erts/configure.in 2014-05-08 10:07:18.691087332 +0200
++++ erts/configure.in 2014-05-08 10:12:56.579375822 +0200
+@@ -366,6 +366,11 @@
+ $with_assumed_cache_line_size,
+ [Assumed cache-line size (in bytes)])
+
++AC_ARG_ENABLE(systemd,
++AS_HELP_STRING([--enable-systemd], [enable systemd support in epmd]),
++[],
++[enable_systemd=no])
++
+ dnl Magic test for clearcase.
+ OTP_RELEASE=
+ if test "${ERLANG_COMMERCIAL_BUILD}" != ""; then
+@@ -1042,8 +1047,6 @@
+ AC_CHECK_LIB(inet, main)
+ AC_CHECK_LIB(util, openpty)
+
+-AC_CHECK_LIB(systemd-daemon, sd_listen_fds)
+-
+ dnl Try to find a thread library.
+ dnl
+ dnl ETHR_LIB_NAME, ETHR_LIBS, ETHR_X_LIBS, ETHR_THR_LIB_BASE and ETHR_DEFS
+@@ -1679,7 +1682,29 @@
+ #endif
+ ])
+
+-AC_CHECK_HEADERS(systemd/sd-daemon.h)
++dnl ----------------------------------------------------------------------
++dnl Check the availability of systemd
++dnl ----------------------------------------------------------------------
++if test x"$enable_systemd" != x"no"; then
++
++systemd_daemon_save_LIBS=$LIBS
++LIBS=
++AC_SEARCH_LIBS(sd_listen_fds,[systemd systemd-daemon],
++ [have_sd_listen_fds=yes],[have_sd_listen_fds=no],$systemd_daemon_save_LIBS)
++AC_CHECK_HEADERS(systemd/sd-daemon.h,
++ [have_systemd_sd_daemon_h=yes],[have_systemd_sd_daemon_h=no])
++
++if test x"$have_sd_listen_fds" = x"yes" && \
++ test x"$have_systemd_sd_daemon_h" = x"yes"; then
++ AC_DEFINE([HAVE_SYSTEMD_DAEMON],[1],[Define if you have systemd daemon])
++ SYSTEMD_DAEMON_LIBS=$LIBS
++elif test x"$enable_systemd" = x"yes"; then
++ AC_MSG_FAILURE([--enable-systemd was given, but test for systemd failed])
++fi
++LIBS=$systemd_daemon_save_LIBS
++fi
++AC_SUBST(SYSTEMD_DAEMON_LIBS)
++
+
+ dnl ----------------------------------------------------------------------
+ dnl Check the availability for libdlpi
+--- erts/epmd/src/Makefile.in 2014-05-08 10:07:58.344182314 +0200
++++ erts/epmd/src/Makefile.in 2014-05-08 10:12:56.580375784 +0200
+@@ -84,7 +84,7 @@
+ ifeq ($(findstring ose,$(TARGET)),ose)
+ LIBS = $(ERTS_INTERNAL_LIBS) @LIBS@
+ else
+-LIBS = @LIBS@ $(ERTS_INTERNAL_LIBS)
++LIBS = @LIBS@ @SYSTEMD_DAEMON_LIBS@ $(ERTS_INTERNAL_LIBS)
+ endif
+ LDFLAGS = @LDFLAGS@
+
+--- erts/epmd/src/epmd_srv.c 2014-05-08 10:07:49.137392770 +0200
++++ erts/epmd/src/epmd_srv.c 2014-05-08 10:12:39.777759407 +0200
+@@ -213,7 +213,7 @@
+ node_init(g);
+ g->conn = conn_init(g);
+
+-#ifdef HAVE_SYSTEMD_SD_DAEMON_H
++#ifdef HAVE_SYSTEMD_DAEMON
+ if (g->is_systemd)
+ {
+ int n;
+@@ -310,7 +310,7 @@
+ SET_ADDR(iserv_addr[0],EPMD_ADDR_ANY,sport);
+ num_sockets = 1;
+ }
+-#ifdef HAVE_SYSTEMD_SD_DAEMON_H
++#ifdef HAVE_SYSTEMD_DAEMON
+ }
+ #endif
+
diff --git a/dev-lang/erlang/files/50erlang-gentoo.el b/dev-lang/erlang/files/50erlang-gentoo.el
new file mode 100644
index 00000000000..db1ae7636f1
--- /dev/null
+++ b/dev-lang/erlang/files/50erlang-gentoo.el
@@ -0,0 +1,5 @@
+;;; erlang site-lisp configuration
+
+(add-to-list 'load-path "@SITELISP@")
+(require 'erlang-start)
+(setq erlang-root-dir "/usr/share")
diff --git a/dev-lang/erlang/files/epmd.init b/dev-lang/erlang/files/epmd.init
new file mode 100644
index 00000000000..8bcc2d9675d
--- /dev/null
+++ b/dev-lang/erlang/files/epmd.init
@@ -0,0 +1,20 @@
+#!/sbin/runscript
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the Erlang Public License 1.1
+# $Id$
+
+depend() {
+ need net
+}
+
+start() {
+ ebegin "Starting Erlang Port Mapper Daemon"
+ start-stop-daemon --start --quiet --user nobody --group nobody --exec /usr/bin/epmd -- -daemon
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping Erlang Port Mapper Daemon"
+ /usr/bin/epmd -kill >/dev/null
+ eend $?
+}
diff --git a/dev-lang/erlang/files/epmd.service b/dev-lang/erlang/files/epmd.service
new file mode 100644
index 00000000000..57382ff36a4
--- /dev/null
+++ b/dev-lang/erlang/files/epmd.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Erlang Portmapper Daemon
+Wants=network.target
+
+[Service]
+ExecStart=/usr/bin/epmd
+
+[Install]
+WantedBy=multi-user.target
diff --git a/dev-lang/erlang/metadata.xml b/dev-lang/erlang/metadata.xml
new file mode 100644
index 00000000000..b78c5d38c90
--- /dev/null
+++ b/dev-lang/erlang/metadata.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>lang-misc</herd>
+<maintainer>
+<email>djc@gentoo.org</email>
+<name>Dirkjan Ochtman</name>
+</maintainer>
+ <use>
+ <flag name="hipe">HIgh Performance Erlang extension</flag>
+ <flag name="halfword">Enable halfword emulator</flag>
+ <flag name="kpoll">Enable kernel polling support</flag>
+ <flag name="sctp">Support for Stream Control Transmission Protocol</flag>
+ <flag name="compat-ethread">Enable compatibility with pre-pentium 4 CPUs in the ethread library.</flag>
+ </use>
+<longdescription>
+Erlang is a programming language designed at the Ericsson
+Computer Science Laboratory. Open-source Erlang is being
+released to help encourage the spread of Erlang outside
+Ericsson.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/esco/Manifest b/dev-lang/esco/Manifest
new file mode 100644
index 00000000000..b36d0e17720
--- /dev/null
+++ b/dev-lang/esco/Manifest
@@ -0,0 +1 @@
+DIST esco-src-0.512.tar.gz 382056 SHA256 646e88b3ff16346e41061c6cd33c37cb5e2e7d3b2b2b8604f6931fe1723935d1 SHA512 4d02af7097abbd6770a891065ea9d7d3f9acdd9c7c9164f726dba2385db48993e7fe9baa4fc57aac2d998544788416700933d473f1e9467c9f94e240f80ccf97 WHIRLPOOL 91cfdfe44756bf3b5328b8dc42d746dc33487c3565f6e172396d27e9ea5377f6e4f8fb2b6e8b28d89da8343fd437c39174c7d92daeb0157c815da64e101042c7
diff --git a/dev-lang/esco/esco-0.512.ebuild b/dev-lang/esco/esco-0.512.ebuild
new file mode 100644
index 00000000000..2e7858ef662
--- /dev/null
+++ b/dev-lang/esco/esco-0.512.ebuild
@@ -0,0 +1,32 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+MY_PN="${PN}-src"
+MY_P="${MY_PN}-${PV}"
+
+DESCRIPTION="Combine interpreter of esoteric languages"
+HOMEPAGE="http://esco.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+IUSE="gmp linguas_ru"
+
+DEPEND="gmp? ( dev-libs/gmp )"
+RDEPEND="${DEPEND}"
+
+DOCS=( AUTHORS ChangeLog README TODO docs/basics.txt )
+
+src_configure() {
+ econf $(use_with gmp)
+}
+
+src_install() {
+ default
+ use linguas_ru && dodoc docs/README_RU.utf8
+}
diff --git a/dev-lang/esco/metadata.xml b/dev-lang/esco/metadata.xml
new file mode 100644
index 00000000000..852bb704e58
--- /dev/null
+++ b/dev-lang/esco/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>pinkbyte@gentoo.org</email>
+ <name>Sergey Popov</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">esco</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/execline/Manifest b/dev-lang/execline/Manifest
new file mode 100644
index 00000000000..d0ed12e70c3
--- /dev/null
+++ b/dev-lang/execline/Manifest
@@ -0,0 +1 @@
+DIST execline-2.1.1.0.tar.gz 75967 SHA256 9e1a9b95772b64bd623c1ddea6200909cca0eb659893ac47857848928eaff7dc SHA512 250fe449b39a198193f1431b249b342f3c6c499fea12779a55d0e27aec2095285bbf9dc2a48d84eebdf9f540ecf5e67ef39393243ca0fadfc764d2cc95ac0b6b WHIRLPOOL ce92f6d7786e5f1efcfb5298b1fa8a561957c6b9f542ace49b815e69f98da4f88adcd339f7210d61d7ae1298573cd9bc31c22c6f7b3c8ac30f44986c88241f32
diff --git a/dev-lang/execline/execline-2.1.1.0.ebuild b/dev-lang/execline/execline-2.1.1.0.ebuild
new file mode 100644
index 00000000000..d6208474946
--- /dev/null
+++ b/dev-lang/execline/execline-2.1.1.0.ebuild
@@ -0,0 +1,55 @@
+# Copyright 2013-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib
+
+DESCRIPTION="a non-interactive scripting language similar to SH"
+HOMEPAGE="http://www.skarnet.org/software/execline/"
+SRC_URI="http://www.skarnet.org/software/${PN}/${P}.tar.gz"
+
+LICENSE="ISC"
+SLOT="0"
+KEYWORDS="amd64 ~x86"
+IUSE="static static-libs"
+
+DEPEND=">=sys-devel/make-4.0
+ static? ( >=dev-libs/skalibs-2.3.1.0[static-libs] )
+ !static? ( >=dev-libs/skalibs-2.3.1.0 )
+"
+RDEPEND="!static? ( >=dev-libs/skalibs-2.3.1.0 )"
+
+src_prepare() {
+ # Remove QA warning about LDFLAGS addition
+ sed -i "s~tryldflag LDFLAGS_AUTO -Wl,--hash-style=both~:~" "${S}/configure" || die
+}
+
+src_configure()
+{
+ econf \
+ $(use_enable static-libs static) \
+ $(use_enable static allstatic) \
+ $(use_enable !static shared) \
+ --bindir=/bin \
+ --sbindir=/sbin \
+ --dynlibdir=/$(get_libdir) \
+ --libdir=/usr/$(get_libdir)/${PN} \
+ --datadir=/etc \
+ --sysdepdir=/usr/$(get_libdir)/${PN} \
+ --with-dynlib=/$(get_libdir) \
+ --with-lib=/usr/$(get_libdir)/skalibs \
+ --with-sysdeps=/usr/$(get_libdir)/skalibs
+}
+
+src_compile()
+{
+ emake DESTDIR="${D}"
+}
+
+src_install()
+{
+ default
+ dohtml -r doc/*
+}
diff --git a/dev-lang/execline/metadata.xml b/dev-lang/execline/metadata.xml
new file mode 100644
index 00000000000..8004498b8ba
--- /dev/null
+++ b/dev-lang/execline/metadata.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>williamh@gentoo.org</email>
+ <name>William Hubbs</name>
+ </maintainer>
+ <longdescription lang="en">
+ Execline is a non-interactive scripting language similar to sh.
+ According to the home page, the syntax is far mor logical and
+ predictable than sh, and has no security issues.
+ </longdescription>
+</pkgmetadata>
diff --git a/dev-lang/f2c/Manifest b/dev-lang/f2c/Manifest
new file mode 100644
index 00000000000..38008a9806c
--- /dev/null
+++ b/dev-lang/f2c/Manifest
@@ -0,0 +1,3 @@
+DIST f2c-20060507.tar.bz2 186677 SHA256 5d1f7579139bc474bdc5455a0d1726cab30f09f2c13c9110bdf3813066b10e2a SHA512 d0c9019b65a8ad2fd769ada596646a1cd9b682dcc8afa2cd99081376d967fbe959186a38d74570ab4bcce7622c58c8c10042948fa56e0a7080b12111c2b99b1e WHIRLPOOL a88b3e4aec80a064168ac640b6370fa5afc3d1584d6507abf53aefc471ef438aa4fded4e0cbe30d64c68324c93e97ec1f10097851f4850c55a3266bdd3ee34fc
+DIST f2c_20100827-1.debian.tar.gz 15659 SHA256 1597878d24b4261094f67853b681db1be53dce5a320052d52e5203de765bd2dd SHA512 784d3f1a74311a933b54103d36dd18eb879bef1816ea82e8d93ef5a0eb7582d4ddde3a2b764d15b78194bab4cdf940480089e8b920002134af66cdf095708535 WHIRLPOOL e71139315c318c160bddd2c76486d88b0429a7e8b8f67dd2e9d6f259e2b83ce6351a95b683d7caa95d31ca64c8421d07ff90d69ec7f974d62013653f8c6beb09
+DIST f2c_20100827.orig.tar.gz 417930 SHA256 d3d1bbf814e3f6d7adf4fb86d092997dbb4994899e85b9f436920b79f0ea55b9 SHA512 2c28d8c06e53b569816e7982725133d46e9b145a84ec51771f4cca2409098f894648ebe5b8089a1ddd8468be62394b0edb5985e50baeea8129e4f507236d6c0d WHIRLPOOL c19022a3b9d269d69e3e4f507a6675f632fc2ef29da825099083aaa71f6b547a61f1ff229c1ecf5b201a98d697f8226719a305c0bdb3684db10e19b3e8c6339d
diff --git a/dev-lang/f2c/f2c-20060507.ebuild b/dev-lang/f2c/f2c-20060507.ebuild
new file mode 100644
index 00000000000..09be3136a74
--- /dev/null
+++ b/dev-lang/f2c/f2c-20060507.ebuild
@@ -0,0 +1,37 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils toolchain-funcs
+
+DESCRIPTION="Fortran to C converter"
+HOMEPAGE="http://www.netlib.org/f2c"
+#SRC_URI="ftp://netlib.bell-labs.com/netlib/f2c/src.tar"
+# To create, download src.tar, ungzip everything inside, then tar.bz2 the whole
+# thing.
+SRC_URI="mirror://gentoo/${P}.tar.bz2"
+
+LICENSE="HPND"
+SLOT="0"
+KEYWORDS="amd64 ppc ppc64 x86 ~x86-fbsd"
+IUSE=""
+
+RDEPEND="dev-libs/libf2c"
+DEPEND="${RDEPEND}"
+
+S="${WORKDIR}/src"
+
+src_compile() {
+ emake \
+ -f makefile.u \
+ CC=$(tc-getCC) \
+ CFLAGS="${CFLAGS}" \
+ || die "make failed"
+}
+
+src_install() {
+ mv -f f2c.1t f2c.1
+ doman f2c.1
+ dobin f2c
+ dodoc README Notice
+}
diff --git a/dev-lang/f2c/f2c-20100827.ebuild b/dev-lang/f2c/f2c-20100827.ebuild
new file mode 100644
index 00000000000..107d53bd289
--- /dev/null
+++ b/dev-lang/f2c/f2c-20100827.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit eutils toolchain-funcs
+
+DEB_PV=20100827
+DEB_PR=1
+DEB_P=${PN}_${DEB_PV}
+
+DESCRIPTION="Fortran to C converter"
+HOMEPAGE="http://www.netlib.org/f2c"
+SRC_URI="
+ mirror://debian/pool/main/${PN:0:1}/${PN}/${DEB_P}.orig.tar.gz
+ mirror://debian/pool/main/${PN:0:1}/${PN}/${DEB_P}-${DEB_PR}.debian.tar.gz"
+
+LICENSE="HPND"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86 ~x86-fbsd ~amd64-linux ~x86-linux"
+IUSE="doc"
+
+RDEPEND="dev-libs/libf2c"
+DEPEND=""
+
+S="${WORKDIR}/${PN}"
+
+src_prepare() {
+ # selective list of patches from debian
+ epatch \
+ "${WORKDIR}"/debian/patches/0000-prequilt-tweaks.patch \
+ "${WORKDIR}"/debian/patches/0002-prototype-rmdir.patch \
+ "${WORKDIR}"/debian/patches/0003-struct-init-braces.patch \
+ "${WORKDIR}"/debian/patches/0004-man-dash-hyphen-slash.patch
+ sed -i -e '/^CC/d' -e '/^CFLAGS/d' src/makefile.u || die
+ tc-export CC
+}
+
+src_compile() {
+ emake -C src -f makefile.u
+}
+
+src_install() {
+ doman f2c.1
+ use doc && dodoc f2c.pdf
+ newdoc "${WORKDIR}"/debian/changelog debian.changelog
+ cd src
+ dobin f2c
+ dodoc README Notice
+}
diff --git a/dev-lang/f2c/metadata.xml b/dev-lang/f2c/metadata.xml
new file mode 100644
index 00000000000..adca89fcd3f
--- /dev/null
+++ b/dev-lang/f2c/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci</herd>
+ <longdescription lang="en">
+ F2C compiles FORTRAN 77 sources by converting to C/C++ sources and
+ compiling the later with gcc. The resulting binaries depend on the
+ libf2c runtime library.
+</longdescription>
+ <longdescription lang="de">
+ F2C kompiliert FORTRAN 77 Quellcode durch Konvertierung in C/C++
+ Quellcode und deren anschließendes Kompilieren mit Hilfe von gcc. Die
+ produzierten Binärdateien benötigen die Laufzeitbibliothek libf2c.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-lang/falcon/Manifest b/dev-lang/falcon/Manifest
new file mode 100644
index 00000000000..e76bd45cf2d
--- /dev/null
+++ b/dev-lang/falcon/Manifest
@@ -0,0 +1 @@
+DIST Falcon-0.9.6.4.tar.gz 1782796 SHA256 24f4294f93c192f21d3590795a9fdd864c3f2d376cb0baac9c1e11e893cfaf81 SHA512 244fc0cc6811d9c918a1983d93e380982584016d84752b00d3adc17e46d7a7cbf9d20f09b7562316b1c9ea6eaaa91c1cb931f4469f7d510d9084f1daaca732a5 WHIRLPOOL 2178d6307fcd516f490fada540af649a60ca39f8640215b926f153316ab349ed9b46e47c7849270a20632e9639ca65d635f88ed4d0a2fccf718967ce83106a8b
diff --git a/dev-lang/falcon/falcon-0.9.6.4.ebuild b/dev-lang/falcon/falcon-0.9.6.4.ebuild
new file mode 100644
index 00000000000..89e124c350e
--- /dev/null
+++ b/dev-lang/falcon/falcon-0.9.6.4.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="2"
+
+inherit cmake-utils multilib
+
+MY_P=${P/f/F}
+
+DESCRIPTION="An open source general purpose untyped language written in C++"
+HOMEPAGE="http://falconpl.org/"
+SRC_URI="http://falconpl.org/project_dl/_official_rel/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="debug readline"
+
+DEPEND="
+ dev-libs/libpcre
+ sys-libs/zlib
+ readline? ( sys-libs/readline )
+"
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}/${MY_P}
+
+DOCS="AUTHORS ChangeLog README RELNOTES"
+
+src_configure() {
+ mycmakeargs=(
+ -DFALCON_DISABLE_RPATH=ON
+ -DFALCON_LIB_DIR=$(get_libdir)
+ -DFALCON_SKIP_BISON=ON
+ -DFALCON_WITH_MANPAGES=ON
+ -DFALCON_WITH_INTERNAL_PCRE=OFF
+ -DFALCON_WITH_INTERNAL_ZLIB=OFF
+ -DFALCON_WITH_GPL_READLINE=ON
+ $(cmake-utils_use readline FALCON_WITH_EDITLINE)
+ )
+ cmake-utils_src_configure
+}
+
+src_test() {
+ FALCON_LOAD_PATH=".;${CMAKE_BUILD_DIR}/core/clt"
+ for testsuite in "${S}/core/tests/testsuite" "${S}/modules/feathers/tests/testsuite"; do
+ "${CMAKE_BUILD_DIR}/core/clt/faltest/faltest" \
+ -d "${testsuite}" || die "faltest in ${testsuite} failed"
+ done
+}
diff --git a/dev-lang/falcon/metadata.xml b/dev-lang/falcon/metadata.xml
new file mode 100644
index 00000000000..6318a491915
--- /dev/null
+++ b/dev-lang/falcon/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>lang-misc</herd>
+</pkgmetadata>
diff --git a/dev-lang/ferite/Manifest b/dev-lang/ferite/Manifest
new file mode 100644
index 00000000000..f5d5339288d
--- /dev/null
+++ b/dev-lang/ferite/Manifest
@@ -0,0 +1 @@
+DIST ferite-1.1.17.tar.gz 2174774 SHA256 d407f3db45482e17f41820fb029cf8b06e6104699b8d7340f3946f57d3f4e690 SHA512 475983b865fba492661e59b7470b7e46889f29ed8ba829b112354963fafcbed6ab4d4677579337c1c4ed730c6fe02897743f56edae335ceda6277da975d1098f WHIRLPOOL d563849e7b1ebe19657f319ecf970ad4987d10c28c29729da2868b10b7466159f5210e8bb7c065b8fccb7314ebc764dc8dbe97484c138c70ec066ecd12ebb005
diff --git a/dev-lang/ferite/ferite-1.1.17-r1.ebuild b/dev-lang/ferite/ferite-1.1.17-r1.ebuild
new file mode 100644
index 00000000000..1bd7daee9cc
--- /dev/null
+++ b/dev-lang/ferite/ferite-1.1.17-r1.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit autotools eutils multilib
+
+DESCRIPTION="A clean, lightweight, object oriented scripting language"
+HOMEPAGE="http://www.ferite.org/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="1"
+KEYWORDS="~alpha amd64 ppc -sparc x86 ~amd64-linux ~x86-linux ~ppc-macos"
+IUSE=""
+
+DEPEND="
+ >=dev-libs/libpcre-5
+ dev-libs/libxml2"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch ${FILESDIR}/ferite-pcre.patch || die
+
+ # use docsdir variable, install to DESTDIR
+ sed \
+ -e '/docsdir =/!s:$(prefix)/share/doc/ferite:$(DESTDIR)$(docsdir):' \
+ -i docs/Makefile.am || die
+
+ # Install docs to /usr/share/doc/${PF}, not .../${PN}
+ sed \
+ -e "s:doc/ferite:doc/${PF}:" \
+ -i Makefile.am \
+ docs/Makefile.am \
+ scripts/test/Makefile.am \
+ scripts/test/rmi/Makefile.am || die
+
+ # Don't override the user's LDFLAGS
+ sed \
+ -e 's:_LDFLAGS = :&$(AM_LDFLAGS) :' \
+ -e '/^LDFLAGS/s:^:AM_:' \
+ -i modules/*/Makefile.am \
+ libs/{aphex,triton}/src/Makefile.am \
+ src/Makefile.am || die
+
+ # Only build/install shared libs for modules (can't use static anyway)
+ sed -i -e '/_LDFLAGS/s:-module:& -shared:' modules/*/Makefile.am || die
+
+ # use LIBADD to ensure proper deps (fix parallel build)
+ sed \
+ -e '/^stream_la_LDFLAGS/s:-L\. -lferitestream::' \
+ -e '/^stream_la_LIBADD/s:$:libferitestream.la:' \
+ -i modules/stream/Makefile.am || die
+
+ # Make sure we install in $(get_libdir), not lib
+ sed -i -e "s|\$prefix/lib|\$prefix/$(get_libdir)|g" configure.ac || die
+
+ # We copy feritedoc to ${T} in src_install, then patch it in-situ
+ # note that this doesn't actually work right, currently - it still tries
+ # to pull from / instead of ${D}, and I can't figure out how to fix that
+ sed -i -e 's:$(prefix)/bin/:${T}/:' docs/Makefile.am || die
+
+ eautoreconf
+}
+
+src_configure() {
+ econf --libdir="${EPREFIX}/usr/$(get_libdir)"
+}
+
+src_install() {
+ cp tools/doc/feritedoc "${T}" || die
+ sed -i -e '/^prefix/s:prefix:${T}:g' "${T}"/feritedoc || die
+ sed -i -e '/^$prefix/s:$prefix/bin/ferite:'"${ED}"'usr/bin/ferite:' "${T}"/feritedoc || die
+ sed -i -e 's:$library_path $library_path:${S}/tools/doc ${S}/tools/doc:' "${T}"/feritedoc || die
+ export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}${LD_LIBRARY_PATH:+:}${ED}usr/lib"
+ emake DESTDIR="${D}" LIBDIR="${EPREFIX}"/usr/$(get_libdir) install
+ prune_libtool_files
+}
diff --git a/dev-lang/ferite/files/ferite-pcre.patch b/dev-lang/ferite/files/ferite-pcre.patch
new file mode 100644
index 00000000000..1e2e19ce481
--- /dev/null
+++ b/dev-lang/ferite/files/ferite-pcre.patch
@@ -0,0 +1,26 @@
+diff -pruN ferite-1.1.17.orig/modules/regexp/regexp.fec ferite-1.1.17/modules/regexp/regexp.fec
+--- ferite-1.1.17.orig/modules/regexp/regexp.fec 2009-07-15 19:21:34.000000000 +0200
++++ ferite-1.1.17/modules/regexp/regexp.fec 2013-02-01 02:33:40.438849775 +0100
+@@ -427,7 +427,8 @@ class Regexp {
+ }
+
+ /* get the number of subparts */
+- captured_str_cnt = pcre_info( rgx->compiled_re, NULL, NULL ) + 1;
++ pcre_fullinfo( rgx->compiled_re, NULL, PCRE_INFO_CAPTURECOUNT, &captured_str_cnt );
++ captured_str_cnt++;
+ /* create an offset array */
+ size_offsets = (int)(captured_str_cnt * 3);
+ offsets = (int *)fmalloc(size_offsets * sizeof(int));
+diff -pruN ferite-1.1.17.orig/modules/regexp/regexp_Regexp.c ferite-1.1.17/modules/regexp/regexp_Regexp.c
+--- ferite-1.1.17.orig/modules/regexp/regexp_Regexp.c 2009-07-17 08:59:19.000000000 +0200
++++ ferite-1.1.17/modules/regexp/regexp_Regexp.c 2013-02-01 02:33:16.647875845 +0100
+@@ -88,7 +88,8 @@ FE_NATIVE_FUNCTION( ferite_regexp_Regexp
+ }
+
+ /* get the number of subparts */
+- captured_str_cnt = pcre_info( rgx->compiled_re, NULL, NULL ) + 1;
++ pcre_fullinfo( rgx->compiled_re, NULL, PCRE_INFO_CAPTURECOUNT, &captured_str_cnt );
++ captured_str_cnt++;
+ /* create an offset array */
+ size_offsets = (int)(captured_str_cnt * 3);
+ offsets = (int *)fmalloc(size_offsets * sizeof(int));
diff --git a/dev-lang/ferite/metadata.xml b/dev-lang/ferite/metadata.xml
new file mode 100644
index 00000000000..c5d9211b3c1
--- /dev/null
+++ b/dev-lang/ferite/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>maintainer-needed@gentoo.org</email>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">ferite</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/fpc/Manifest b/dev-lang/fpc/Manifest
new file mode 100644
index 00000000000..c99167a7d14
--- /dev/null
+++ b/dev-lang/fpc/Manifest
@@ -0,0 +1,18 @@
+DIST fpc-2.6.2-doc-html.tar.gz 4716648 SHA256 2f30db4ad0687cfeb990bff1933aea6c644c8c49460051bafb1645863fd14005 SHA512 abefed1ac92e49d3ef18599c6d0e44c6963bda214a599f2d9c1df64c88f3bd43fc31baf1b7a032b626f4caedca225b55f99a06f1828b2da143cd07d8cd242999 WHIRLPOOL 4f4b13eb5e55aaf271be9ee93ec7ec425169940cd85d65b796c63e0b09b111ec381ae9274dcd8b671e9ff0b81f6b2abebbc99628e6791aa1682feb11d9aadf89
+DIST fpc-2.6.2-fpctoc.htx.bz2 124078 SHA256 de9b948c4d3d3f41f7a4c1eb1d0a022d6a0cd2cd3860d738dc8c0183c3207e78 SHA512 98f53ec7a2ddd6403696c5b0feb8c05797b1c267593adce0e3a50132238c0b5abd2f00886f0e68f73b449e0376ef7ebbf666ba3eb9362cffbb1f0fffd6886591 WHIRLPOOL 3dc2d0d633962635a9fa74e5c6f984d658ae5a7c5254b1ff0317d94820525262d3f741dec05a8af35844e2471cfa4939bed98a7fa3fb492cb9075fb6ebbbdf50
+DIST fpc-2.6.2.arm-linux.tar 32501760 SHA256 c961ea868ac2c7ea9a724a8ed5f5d4c3965e0ada61e97735e75252a50067e68e SHA512 c7f5a5b1938608cf3195549a3272c0932c08ee6601ffc516bab2cd7efd52145fbd6e03ad6664d1c876de02e89de63674cdc064dc23d228b73a621a5cd1e23220 WHIRLPOOL b0c8eacdac44615891a1fed574098a95e8616caaad4472c933b44e054d6f2237c79f66cc7e6a8f17d1d263d762ba723b94f41652b0ec0aaa0abaf9ae828dbeec
+DIST fpc-2.6.2.i386-linux.tar 45905920 SHA256 d625a3dfdb248d1975a580ee01c43db3bfe05610248b2196bafddbb74579eac9 SHA512 741b01821cbc4eb1e2602bd69ccce58fac48640e06868ba29896a24376f77afe07a27ebd26a7936cc4bb813685b7151e7d64806ebe1bfce8988254a921015280 WHIRLPOOL 88ab9381c1f84f511770602f00148418e71daf6d107fbd6f341b61981809987b710f70761e0e840b40811b487389072ba53f3493f1fae7844afafd674c5b000a
+DIST fpc-2.6.2.powerpc-linux.tar 44462080 SHA256 c2e7847c0a6d41820e3eb2da50122ac8fe5eade02157551f5857933d5a4e13c6 SHA512 a0894e56143115e35a00da48eb7cb11d90907b4474065b5092d2084cf5733c8d0ece74ec90f654dcf8b92e0cf016a7f5c6f48c8d02a2f85950f37a609583966a WHIRLPOOL db7b91f267d1321a49743ce682b4ed4f42699cb4b85bb15a3efbd1447e00e70fac1157ff21756bdf547528a6055221cf2296941efdb8bbdee6db6905730fcdc2
+DIST fpc-2.6.2.powerpc64-linux.tar 49336320 SHA256 b4870ad23405324dd3549f03fe6d8662b9dff17eafe681046b28d63be542989e SHA512 e5a8e75302b6281ac14a1b299ee208ffa3f447e87ed3e74113f82b0e99175ebc71a4431bcef26a0fb99ca8566748c743dc69f8d7bc756889f17a7b1e1cfd267b WHIRLPOOL b4725180d5de66ccb64408552a3449a88c7a6ba47213e81411dcef4a1fc14f756d4e73ec6f10082d7572183229fd1da3f7e802b3681cfa2f1b3280ee7c914bcc
+DIST fpc-2.6.2.sparc-linux.tar 33843200 SHA256 3a1918c7076e4984f8c085d0dde672907f730940214c5abca2d9513051d1cd79 SHA512 9f6ba30680bd51ccb6b627935ce2cc10dfa8671f621d5ef7d7e047b036c48934829e165c3f9bbac61bbccda8b679ee132fc26e41c4f9b66cf30966481eb81f09 WHIRLPOOL c754e925761d99bc0ad5185d19ee2f0db83a5c5bafca26051efccfeef4db5f3f29464542127d27b950a0cef6463f5333eec7dea260fd386fab74ec5ef26facf6
+DIST fpc-2.6.2.x86_64-linux.tar 48332800 SHA256 e05aed29318c250ce3c494c3938c905c7853620da8cbc4d66ba584160690e558 SHA512 3ac22bff975197b3ecc40bd76bb66093f71253290d6eb095e1bf014cb1cdf0354cf05212516bca008d9b525f906c173c1bf2067eda9015cb3db64a42b576a512 WHIRLPOOL b52d8ba4b97c83bba051a771d1b952839440828bfabd18004ca9b03ba3f1f3763b73396940c965aeeb4944ef05f7f968658629214c0ab777b9b3841286d7d40a
+DIST fpc-2.6.4-doc-html.tar.gz 4864530 SHA256 bdfa09ff5d362bc39262fa33f8f4365a4767871df17095b3cbf83582c60d0e3b SHA512 c76b15c3c9c47d687bb4760753f605a169c7e76b8b8478dc4e557d0a172f9e7ce7abb24fc1512f7eaa305807a1f4cb0a1305bb02e983f932b02aa9683026e54d WHIRLPOOL a24a99cc5a0450f377a3235b5d9d697a431e93a9825263869ee5d861dd91a3f3f18ca899beec01a8180e60da24769fb2e85c52c8be307e8fd5497dc3fc01aac9
+DIST fpc-2.6.4-fpctoc.htx.bz2 125626 SHA256 2718b88921370cadee365849224b0edbb3a2a0d4e3f2c9767f4631d246ce5050 SHA512 12fdc2755adfabbda74257b058e00072e5e11925b8e62cf7959b2acab90b3e226b8f51544a127f88fc3cd473ba9794e6c9da4e73c04ced2a0d41994b520cd33d WHIRLPOOL 73279b563c683fdb8c25546b9c3f8438a464ca6499f38e30bab2ab452c943802035753bd8c442fd17f12b02cffe79d29c2d242b38d37ab33e46553376a791331
+DIST fpc-2.6.4.arm-linux.tar 38440960 SHA256 cf0aa330a60327865125e74063ef9e62648f26ce8431fba548204e94c9da3fdc SHA512 3a11ebed39f37021201cac8a7e435d7ef3b1110d6893de7faf33651ff9b5a9aa13b6b529b0011132850386048483a55754ed8b1dba7de2e7ba9b2e881e7f0203 WHIRLPOOL 67e19376a6d5a1a5d374397e2af4d311cde5e2a06e9de31302a5c0f87ae9647c1510ab73216b4e9ab2cab0fd93050662154254cf89cc6a5c365dfad45a67ba04
+DIST fpc-2.6.4.i386-linux.tar 47718400 SHA256 3ca6271d18f9b4f48b4bd6e9500045cd18964aea62abede9cf9f130f3c72e602 SHA512 2c1c33c80553d8a331f4fb35e1b136ab195de9fa03ab566b218a265a64cc75447a697a34472fa9cceeedf1e3acd664fada2cd36d60b319ea43eed7e1f9e57615 WHIRLPOOL 4f2fa5b569907dcec030e4501670b7b2d4b13da429c9ef0900de64cda95820d05a03b290b4487ee86751264647d4218fa3d583f1054f8fb7fc9f39993c740ddb
+DIST fpc-2.6.4.powerpc-linux.tar 48220160 SHA256 c1af7e353b7ac40fdd542fbcb6fbfb0cc8f8c68bc0c89e14d3aeeac4c86ed752 SHA512 a78b416a6dd59a10ad50c3549956f15fae5962b64d43be1f1d605befd035732cf860146970dcb410080f9ceb2af1a4f798434fceb11be550cb87d41c72be1810 WHIRLPOOL 4a1d285c682b31f8cdd4cd6c317bd3ad26f88894117c9de71bb982e7ba6aab5fe21075687d4b141d01ef0362c00ea7b3b665d2fd2913e5bafdb6331f049588c3
+DIST fpc-2.6.4.powerpc64-linux.tar 53975040 SHA256 20a0b4ef0810afe826c4dbf7003f72f5968c3b7caa581e3202f29e38c075fa29 SHA512 0e978f68e339f12e2c53c8641c4f0918604b6b970949159dd20c49d65dabb5253d338d180da144eea3c6102a0110c401d03efbd634885220a320fce5fc686b16 WHIRLPOOL 65c3c496a32f86372db1eb7dc81dd413b0c813313fc6acf3d09c90d37c7c923b4c03420c9043b25dc054072bcbec4b8cb1255bd2e95ad1b966001d09d7031982
+DIST fpc-2.6.4.source.tar.gz 29904088 SHA256 c16f2e6e0274c7afc0f1d2dded22d0fec98fe329b1d5b2f011af1655f3a1cc29 SHA512 653968786b40c69c3703f67cddfe7c501686cc8b3524a045498c247dc36b66a6619e9cdb5bb5ca002fb700ddc0b653f2a4298e92527df46fc09c8a69e8e9c3a5 WHIRLPOOL 73fa37e002c1674dee097955b6e199df4bd2a25e0149121810593378b9083660bf1e3eda7398b07d9e97a5a6bdbffe41018d2e40d4b86915076f097422dae417
+DIST fpc-2.6.4.x86_64-linux.tar 50350080 SHA256 196c386f927d772c447fb4c84f61b29133891d14261f0ed3aa773c2f9dda3b39 SHA512 3a993d1f978353a1d68d8ce2cd62748a875b0d0589ed8daf71ebba545b51879b09173e26245e02ac327b5d64932153a7695975c02f3f266642b4ef68e8ff48dc WHIRLPOOL eba5dde2fa6614ebc1e3969a7a8524c779cdb7a3ebdb8855872669387488d5606f0c482cc8e9f8ac9db33203edbb5e0fc01c26c61d3179cd67479167705ecc2a
+DIST fpcbuild-2.6.2.tar.gz 55198144 SHA256 75ad700ccc772b07304c286b0aae95f48a504b15fe890a36361d17dc8e92d83c SHA512 ecc28e8c63fd6bdd6a1b02b0aca4b7ac861bd4c0e815146ab34181fff63f3f60102c227e17317efdc30d6e97b6003b708ed9853f1d21f9e5faabcc89c85a91fe WHIRLPOOL 8614adf51cb71072dc1a4ed9b79acb1943b58decfcadbefd260dfbf20b07f9cba1b5c91c3b57ea78cf89ceb4de102e7cc4d0d93c54e7101bbfa3151b80c0af26
+DIST fpcbuild-2.6.4.tar.gz 55604643 SHA256 8d9c3bcfa469d9b37c05663e2775d179809e4b3443604fac7d21aa64c9a56daa SHA512 7c48fb48a3742ffe533a8a172758071c0a1129ffac09231e6969aa1d31bac346dc764598b6ae78dc9d25585a788f6ed4f2b4c39502774d4d3620f09185b807de WHIRLPOOL d2cb72917031f6ffaeb66c2e1e4f0bc18050da2437241da9e6655af4f62aa3e05c7f7c89ba88ba3f96ee20571c3e0d733bebab7a9c2e3f04aa2f0208bb1dc7f9
diff --git a/dev-lang/fpc/fpc-2.6.2.ebuild b/dev-lang/fpc/fpc-2.6.2.ebuild
new file mode 100644
index 00000000000..aece8d6df85
--- /dev/null
+++ b/dev-lang/fpc/fpc-2.6.2.ebuild
@@ -0,0 +1,174 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit toolchain-funcs
+
+HOMEPAGE="http://www.freepascal.org/"
+DESCRIPTION="Free Pascal Compiler"
+SRC_URI="mirror://sourceforge/freepascal/fpcbuild-${PV}.tar.gz
+ amd64? ( mirror://sourceforge/freepascal/${P}.x86_64-linux.tar )
+ arm? ( mirror://sourceforge/freepascal/${P}.arm-linux.tar )
+ ppc? ( mirror://sourceforge/freepascal/${P}.powerpc-linux.tar )
+ ppc64? ( mirror://sourceforge/freepascal/${P}.powerpc64-linux.tar )
+ sparc? ( mirror://sourceforge/freepascal/${P}.sparc-linux.tar )
+ x86? ( mirror://sourceforge/freepascal/${P}.i386-linux.tar )
+ doc? ( mirror://sourceforge/freepascal/Documentation/${PV}/doc-html.tar.gz -> ${P}-doc-html.tar.gz
+ http://dev.gentoo.org/~radhermit/distfiles/${P}-fpctoc.htx.bz2 )"
+
+SLOT="0"
+LICENSE="GPL-2 LGPL-2.1-with-linking-exception"
+KEYWORDS="amd64 ~arm ppc x86"
+IUSE="doc ide source"
+
+RDEPEND="ide? ( !dev-lang/fpc-ide )"
+
+RESTRICT="strip" #269221
+
+S=${WORKDIR}/fpcbuild-${PV}/fpcsrc
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != binary ]]; then
+ # Bug 475210
+ if $(tc-getLD) --version | grep -q "GNU gold"; then
+ eerror "fpc does not function correctly when built with the gold linker."
+ eerror "Please select the bfd linker with binutils-config."
+ die "GNU gold detected"
+ fi
+ fi
+}
+
+src_unpack() {
+ case ${ARCH} in
+ amd64) FPC_ARCH="x86_64" PV_BIN=${PV} ;;
+ arm) FPC_ARCH="arm" PV_BIN=${PV} ;;
+ ppc) FPC_ARCH="powerpc" PV_BIN=${PV} ;;
+ ppc64) FPC_ARCH="powerpc64" PV_BIN=${PV} ;;
+ sparc) FPC_ARCH="sparc" PV_BIN=${PV} ;;
+ x86) FPC_ARCH="i386" PV_BIN=${PV} ;;
+ *) die "This ebuild doesn't support ${ARCH}." ;;
+ esac
+
+ unpack ${A}
+
+ tar -xf ${P}.${FPC_ARCH}-linux/binary.${FPC_ARCH}-linux.tar || die "Unpacking binary.${FPC_ARCH}-linux.tar failed!"
+ tar -xzf base.${FPC_ARCH}-linux.tar.gz || die "Unpacking base.${FPC_ARCH}-linux.tar.gz failed!"
+}
+
+src_prepare() {
+ find "${WORKDIR}" -name Makefile -exec sed -i -e 's/ -Xs / /g' {} + || die
+
+ # let the pkg manager compress man files
+ sed -i '/find man.* gzip /d' "${WORKDIR}"/fpcbuild-${PV}/install/man/Makefile || die
+}
+
+set_pp() {
+ case ${ARCH} in
+ amd64) FPC_ARCH="x64" ;;
+ arm) FPC_ARCH="arm" ;;
+ ppc) FPC_ARCH="ppc" ;;
+ ppc64) FPC_ARCH="ppc64" ;;
+ sparc) FPC_ARCH="sparc" ;;
+ x86) FPC_ARCH="386" ;;
+ *) die "This ebuild doesn't support ${ARCH}." ;;
+ esac
+
+ case ${1} in
+ bootstrap) pp="${WORKDIR}"/lib/fpc/${PV_BIN}/ppc${FPC_ARCH} ;;
+ new) pp="${S}"/compiler/ppc${FPC_ARCH} ;;
+ *) die "set_pp: unknown argument: ${1}" ;;
+ esac
+}
+
+src_compile() {
+ local pp
+
+ # Using the bootstrap compiler.
+ set_pp bootstrap
+
+ emake -j1 PP="${pp}" compiler_cycle AS="$(tc-getAS)"
+
+ # Save new compiler from cleaning...
+ cp "${S}"/compiler/ppc${FPC_ARCH} "${S}"/ppc${FPC_ARCH}.new || die
+
+ # ...rebuild with current version...
+ emake -j1 PP="${S}"/ppc${FPC_ARCH}.new AS="$(tc-getAS)" compiler_cycle
+
+ # ..and clean up afterwards
+ rm "${S}"/ppc${FPC_ARCH}.new || die
+
+ # Using the new compiler.
+ set_pp new
+
+ emake -j1 PP="${pp}" AS="$(tc-getAS)" rtl_clean
+
+ emake -j1 PP="${pp}" AS="$(tc-getAS)" rtl packages_all utils
+
+ if use ide ; then
+ cd "${S}"/ide || die
+ emake -j1 PP="${pp}" AS="$(tc-getAS)"
+ fi
+}
+
+src_install() {
+ local pp
+ set_pp new
+
+ set -- PP="${pp}" FPCMAKE="${S}/utils/fpcm/fpcmake" \
+ INSTALL_PREFIX="${D}"/usr \
+ INSTALL_DOCDIR="${D}"/usr/share/doc/${PF} \
+ INSTALL_MANDIR="${D}"/usr/share/man \
+ INSTALL_SOURCEDIR="${D}"/usr/lib/fpc/${PV}/source
+
+ emake -j1 "$@" compiler_install rtl_install packages_install utils_install
+
+ dosym ../lib/fpc/${PV}/ppc${FPC_ARCH} /usr/bin/ppc${FPC_ARCH}
+
+ cd "${S}"/../install/doc || die
+ emake -j1 "$@" installdoc
+
+ cd "${S}"/../install/man || die
+ emake -j1 "$@" installman
+
+ if use doc ; then
+ cd "${S}"/../../doc || die
+ dodoc -r *
+ newdoc "${WORKDIR}"/${P}-fpctoc.htx fpctoc.htx
+ docompress -x /usr/share/doc/${PF}/fpctoc.htx
+ fi
+
+ if use ide ; then
+ cd "${S}"/ide
+ emake -j1 "$@" install
+ fi
+
+ if use source ; then
+ cd "${S}" || die
+ shift
+ emake -j1 PP="${D}"/usr/bin/ppc${FPC_ARCH} "$@" sourceinstall
+ find "${D}"/usr/lib/fpc/${PV}/source -name '*.o' -exec rm {} \;
+ fi
+
+ "${D}"/usr/lib/fpc/${PV}/samplecfg "${D}"/usr/lib/fpc/${PV} "${D}"/etc || die
+
+ sed -i "s:${D}::g" "${D}"/etc/fpc.cfg || die
+
+ if use ide ; then
+ sed -e "s:${D}::g" \
+ -i "${D}"/etc/fppkg.cfg \
+ -i "${D}"/etc/fppkg/* \
+ -i "${D}"/usr/lib/fpc/${PV}/ide/text/fp*.cfg \
+ || die
+ fi
+
+ rm -r "${D}"/usr/lib/fpc/lexyacc || die
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] && use ide; then
+ einfo "To read the documentation in the fpc IDE, enable the doc USE flag"
+ einfo "and add /usr/share/doc/${PF}/fpctoc.htx to the Help Files list."
+ fi
+}
diff --git a/dev-lang/fpc/fpc-2.6.4.ebuild b/dev-lang/fpc/fpc-2.6.4.ebuild
new file mode 100644
index 00000000000..2d8f16c8d7d
--- /dev/null
+++ b/dev-lang/fpc/fpc-2.6.4.ebuild
@@ -0,0 +1,175 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit toolchain-funcs
+
+HOMEPAGE="http://www.freepascal.org/"
+DESCRIPTION="Free Pascal Compiler"
+SRC_URI="mirror://sourceforge/freepascal/fpcbuild-${PV}.tar.gz
+ mirror://sourceforge/freepascal/fpc-${PV}.source.tar.gz
+ amd64? ( mirror://sourceforge/freepascal/${P}.x86_64-linux.tar )
+ arm? ( mirror://sourceforge/freepascal/${P}.arm-linux.tar )
+ ppc? ( mirror://sourceforge/freepascal/${P}.powerpc-linux.tar )
+ ppc64? ( mirror://sourceforge/freepascal/${P}.powerpc64-linux.tar )
+ sparc? ( mirror://sourceforge/freepascal/${PN}-2.6.2.sparc-linux.tar )
+ x86? ( mirror://sourceforge/freepascal/${P}.i386-linux.tar )
+ doc? ( mirror://sourceforge/freepascal/Documentation/${PV}/doc-html.tar.gz -> ${P}-doc-html.tar.gz
+ http://dev.gentoo.org/~radhermit/distfiles/${P}-fpctoc.htx.bz2 )"
+
+SLOT="0"
+LICENSE="GPL-2 LGPL-2.1-with-linking-exception"
+KEYWORDS="amd64 ~arm ppc x86"
+IUSE="doc ide source"
+
+RDEPEND="ide? ( !dev-lang/fpc-ide )"
+
+RESTRICT="strip" #269221
+
+S=${WORKDIR}/fpcbuild-${PV}/fpcsrc
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != binary ]]; then
+ # Bug 475210
+ if $(tc-getLD) --version | grep -q "GNU gold"; then
+ eerror "fpc does not function correctly when built with the gold linker."
+ eerror "Please select the bfd linker with binutils-config."
+ die "GNU gold detected"
+ fi
+ fi
+}
+
+src_unpack() {
+ case ${ARCH} in
+ amd64) FPC_ARCH="x86_64" PV_BIN=${PV} ;;
+ arm) FPC_ARCH="arm" PV_BIN=${PV} ;;
+ ppc) FPC_ARCH="powerpc" PV_BIN=${PV} ;;
+ ppc64) FPC_ARCH="powerpc64" PV_BIN=${PV} ;;
+ sparc) FPC_ARCH="sparc" PV_BIN=2.6.2 ;;
+ x86) FPC_ARCH="i386" PV_BIN=${PV} ;;
+ *) die "This ebuild doesn't support ${ARCH}." ;;
+ esac
+
+ unpack ${A}
+
+ tar -xf ${PN}-${PV_BIN}.${FPC_ARCH}-linux/binary.${FPC_ARCH}-linux.tar || die "Unpacking binary.${FPC_ARCH}-linux.tar failed!"
+ tar -xzf base.${FPC_ARCH}-linux.tar.gz || die "Unpacking base.${FPC_ARCH}-linux.tar.gz failed!"
+}
+
+src_prepare() {
+ find "${WORKDIR}" -name Makefile -exec sed -i -e 's/ -Xs / /g' {} + || die
+
+ # let the pkg manager compress man files
+ sed -i '/find man.* gzip /d' "${WORKDIR}"/fpcbuild-${PV}/install/man/Makefile || die
+}
+
+set_pp() {
+ case ${ARCH} in
+ amd64) FPC_ARCH="x64" ;;
+ arm) FPC_ARCH="arm" ;;
+ ppc) FPC_ARCH="ppc" ;;
+ ppc64) FPC_ARCH="ppc64" ;;
+ sparc) FPC_ARCH="sparc" ;;
+ x86) FPC_ARCH="386" ;;
+ *) die "This ebuild doesn't support ${ARCH}." ;;
+ esac
+
+ case ${1} in
+ bootstrap) pp="${WORKDIR}"/lib/fpc/${PV_BIN}/ppc${FPC_ARCH} ;;
+ new) pp="${S}"/compiler/ppc${FPC_ARCH} ;;
+ *) die "set_pp: unknown argument: ${1}" ;;
+ esac
+}
+
+src_compile() {
+ local pp
+
+ # Using the bootstrap compiler.
+ set_pp bootstrap
+
+ emake -j1 PP="${pp}" compiler_cycle AS="$(tc-getAS)"
+
+ # Save new compiler from cleaning...
+ cp "${S}"/compiler/ppc${FPC_ARCH} "${S}"/ppc${FPC_ARCH}.new || die
+
+ # ...rebuild with current version...
+ emake -j1 PP="${S}"/ppc${FPC_ARCH}.new AS="$(tc-getAS)" compiler_cycle
+
+ # ..and clean up afterwards
+ rm "${S}"/ppc${FPC_ARCH}.new || die
+
+ # Using the new compiler.
+ set_pp new
+
+ emake -j1 PP="${pp}" AS="$(tc-getAS)" rtl_clean
+
+ emake -j1 PP="${pp}" AS="$(tc-getAS)" rtl packages_all utils
+
+ if use ide ; then
+ cd "${S}"/ide || die
+ emake -j1 PP="${pp}" AS="$(tc-getAS)"
+ fi
+}
+
+src_install() {
+ local pp
+ set_pp new
+
+ set -- PP="${pp}" FPCMAKE="${S}/utils/fpcm/fpcmake" \
+ INSTALL_PREFIX="${D}"/usr \
+ INSTALL_DOCDIR="${D}"/usr/share/doc/${PF} \
+ INSTALL_MANDIR="${D}"/usr/share/man \
+ INSTALL_SOURCEDIR="${D}"/usr/lib/fpc/${PV}/source
+
+ emake -j1 "$@" compiler_install rtl_install packages_install utils_install
+
+ dosym ../lib/fpc/${PV}/ppc${FPC_ARCH} /usr/bin/ppc${FPC_ARCH}
+
+ cd "${S}"/../install/doc || die
+ emake -j1 "$@" installdoc
+
+ cd "${S}"/../install/man || die
+ emake -j1 "$@" installman
+
+ if use doc ; then
+ cd "${S}"/../../doc || die
+ dodoc -r *
+ newdoc "${WORKDIR}"/${P}-fpctoc.htx fpctoc.htx
+ docompress -x /usr/share/doc/${PF}/fpctoc.htx
+ fi
+
+ if use ide ; then
+ cd "${S}"/ide
+ emake -j1 "$@" install
+ fi
+
+ if use source ; then
+ cd "${S}" || die
+ shift
+ emake -j1 PP="${D}"/usr/bin/ppc${FPC_ARCH} "$@" sourceinstall
+ find "${D}"/usr/lib/fpc/${PV}/source -name '*.o' -exec rm {} \;
+ fi
+
+ "${D}"/usr/lib/fpc/${PV}/samplecfg "${D}"/usr/lib/fpc/${PV} "${D}"/etc || die
+
+ sed -i "s:${D}::g" "${D}"/etc/fpc.cfg || die
+
+ if use ide ; then
+ sed -e "s:${D}::g" \
+ -i "${D}"/etc/fppkg.cfg \
+ -i "${D}"/etc/fppkg/* \
+ -i "${D}"/usr/lib/fpc/${PV}/ide/text/fp*.cfg \
+ || die
+ fi
+
+ rm -r "${D}"/usr/lib/fpc/lexyacc || die
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] && use ide; then
+ einfo "To read the documentation in the fpc IDE, enable the doc USE flag"
+ einfo "and add /usr/share/doc/${PF}/fpctoc.htx to the Help Files list."
+ fi
+}
diff --git a/dev-lang/fpc/metadata.xml b/dev-lang/fpc/metadata.xml
new file mode 100644
index 00000000000..b2e0e1884e3
--- /dev/null
+++ b/dev-lang/fpc/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>lang-misc</herd>
+ <use>
+ <flag name="ide">Build and install the Free Pascal Compiler IDE</flag>
+ </use>
+ <upstream>
+ <remote-id type="sourceforge">freepascal</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/fsharp/Manifest b/dev-lang/fsharp/Manifest
new file mode 100644
index 00000000000..c06d4304080
--- /dev/null
+++ b/dev-lang/fsharp/Manifest
@@ -0,0 +1 @@
+DIST fsharp-3.1.1.31.tar.gz 31369171 SHA256 9b39c3f4625475c2553668ddbca337ec52fa3a637a05ae14a61a41abe39568b0 SHA512 fcbdad5780a5dd6ab55c380d70b8d0a38f25088e2bb49078468a2cd723b604a14bee6ba2d1005094b1f777a894208654b3f8d3876c5f72126ddc24f96e1eb049 WHIRLPOOL e9060e1e8ccfd3b0efcfeb1148cb5182390e738e8b462746e87d52acaacf5561b53cde50c920a1e4f6929ddf9f3ad0ca6a7d1e9eb8fd3b10af37a375675df019
diff --git a/dev-lang/fsharp/fsharp-3.1.1.31.ebuild b/dev-lang/fsharp/fsharp-3.1.1.31.ebuild
new file mode 100644
index 00000000000..ef9be8c1c83
--- /dev/null
+++ b/dev-lang/fsharp/fsharp-3.1.1.31.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+AUTOTOOLS_AUTORECONF=1
+
+inherit autotools-utils mono-env
+
+DESCRIPTION="The F# Compiler"
+HOMEPAGE="https://github.com/fsharp/fsharp"
+SRC_URI="https://github.com/fsharp/fsharp/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~x86 ~amd64"
+IUSE=""
+
+MAKEOPTS+=" -j1" #nowarn
+DEPEND="dev-lang/mono"
+RDEPEND="${DEPEND}"
+
+AUTOTOOLS_IN_SOURCE_BUILD=1
+
+src_install() {
+ autotools-utils_src_install
+}
diff --git a/dev-lang/fsharp/metadata.xml b/dev-lang/fsharp/metadata.xml
new file mode 100644
index 00000000000..1740437050d
--- /dev/null
+++ b/dev-lang/fsharp/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>dotnet</herd>
+ <longdescription>
+ Mono/.NET open-source, strongly typed, multi-paradigm programming language encompassing functional, imperative and object-oriented programming techniques. Most often used as a cross-platform CLI language.
+ </longdescription>
+ <upstream>
+ <remote-id type="github">fsharp/fsharp</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/gdl/Manifest b/dev-lang/gdl/Manifest
new file mode 100644
index 00000000000..4a390d7fcd9
--- /dev/null
+++ b/dev-lang/gdl/Manifest
@@ -0,0 +1,2 @@
+DIST gdl-0.9.4.tar.gz 2191342 SHA256 e18010cd874cad7b1fd8c752e9386571156e1fb066f2d27ecbcc15bbfc9514fa SHA512 46921eb3333a6b890187a6c75f71758e5e234b76d61a194e17de81ace10760659a4a676060490a5ef7374fd1acadf47c7f565133c19ea165e04c54a577b3c723 WHIRLPOOL a760fcf37e47235e3d21c8c852b65560894e29cfe3684bfee6e83f2d1d060dcaa41a2f9e60e41cbae55d9e5a2036518a5aad22cfd6f07b951a978e1ba2446eae
+DIST gdl-0.9.5.tar.gz 2341992 SHA256 cc9635e836b5ea456cad93f8a07d589aed8649668fbd14c4aad22091991137e2 SHA512 10f004956fedc1ae5a99a9398f82e64982267a59637fc8823591b9573df9ce136b303a0fcebd774475b9bea266a640e2b66cd590c85b57b6cf505f40448e0d3a WHIRLPOOL 6ef59fc574ce26e798d30e9b4fdec9f49b82933b500901c8013c60de884ed6601d99c58ecd17221191cea121914dffce4c59211ce86b2c43fb40d43ce7ce033b
diff --git a/dev-lang/gdl/files/0.9.2-antlr.patch b/dev-lang/gdl/files/0.9.2-antlr.patch
new file mode 100644
index 00000000000..9c8e6abb235
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.2-antlr.patch
@@ -0,0 +1,76 @@
+diff -Nur gdl-0.9.2.orig/CMakeLists.txt gdl-0.9.2/CMakeLists.txt
+--- gdl-0.9.2.orig/CMakeLists.txt 2011-12-22 20:18:17.000000000 +0000
++++ gdl-0.9.2/CMakeLists.txt 2011-12-22 20:32:20.000000000 +0000
+@@ -94,6 +94,8 @@
+
+ set(GDL_DATA_DIR "/share/gnudatalanguage" CACHE PATH "Choose data install directory relative to CMAKE_INSTALL_PREFIX")
+
++set(BUNDLED_ANTLR OFF CACHE BOOL "Use bundled ANTLR grammar ?")
++set(ANTLRDIR "" CACHE PATH "Specify the system ANTLR directory tree")
+
+ # check for 64-bit OS
+ if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
+@@ -143,9 +145,15 @@
+ # mpi
+ check_include_file(mpi.h HAVE_MPI_H)
+
+-# SA: whithout it compilation of antlr fails if there's a conflicting
+-# version of antlr in system-wide directories
+-include_directories(src)
++if(BUNDLED_ANTLR)
++ # SA: whithout it compilation of antlr fails if there's a conflicting
++ # version of antlr in system-wide directories
++ include_directories(src)
++else(BUNDLED_ANTLR)
++ find_package(ANTLR QUIET)
++ set(LIBRARIES ${LIBRARIES} ${ANTLR_LIBRARIES})
++ include_directories(${ANTLR_INCLUDE_DIR})
++endif(BUNDLED_ANTLR)
+
+ # Ncurses MANDATORY
+ # -DNCURSESDIR=DIR
+diff -Nur gdl-0.9.2.orig/CMakeModules/FindANTLR.cmake gdl-0.9.2/CMakeModules/FindANTLR.cmake
+--- gdl-0.9.2.orig/CMakeModules/FindANTLR.cmake 1970-01-01 01:00:00.000000000 +0100
++++ gdl-0.9.2/CMakeModules/FindANTLR.cmake 2011-12-22 21:03:34.000000000 +0000
+@@ -0,0 +1,11 @@
++
++
++find_library(ANTLR_LIBRARIES NAMES antlr)
++find_path(ANTLR_INCLUDE_DIR NAMES antlr/ANTLRUtil.hpp)
++include(FindPackageHandleStandardArgs)
++find_package_handle_standard_args(ANTLR DEFAULT_MSG ANTLR_LIBRARIES ANTLR_INCLUDE_DIR)
++
++mark_as_advanced(
++ANTLR_LIBRARIES
++ANTLR_INCLUDE_DIR
++)
+diff -Nur gdl-0.9.2.orig/src/CMakeLists.txt gdl-0.9.2/src/CMakeLists.txt
+--- gdl-0.9.2.orig/src/CMakeLists.txt 2011-12-22 20:18:17.000000000 +0000
++++ gdl-0.9.2/src/CMakeLists.txt 2011-12-22 20:31:27.000000000 +0000
+@@ -224,9 +224,8 @@
+ widget.cpp
+ )
+
+-add_subdirectory(antlr)
+
+-include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_SOURCE_DIR}/src/antlr ${CMAKE_BINARY_DIR})
++include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_BINARY_DIR})
+ link_directories(${LINK_DIRECTORIES})
+
+ if(PYTHON_MODULE) #libgdl
+@@ -237,8 +236,13 @@
+ add_executable(gdl ${SOURCES})
+ endif(PYTHON_MODULE)
+
+-add_dependencies(gdl antlr) # be sure that antlr is built before gdl
+-target_link_libraries(gdl antlr) # link antlr against gdl
++if(BUNDLED_ANTLR)
++ add_subdirectory(antlr)
++ include_directories(${CMAKE_SOURCE_DIR}/src/antlr)
++ add_dependencies(gdl antlr) # be sure that antlr is built before gdl
++ target_link_libraries(gdl antlr) # link antlr against gdl
++endif(BUNDLED_ANTLR)
++
+ target_link_libraries(gdl ${LIBRARIES})
+ add_definitions(-DHAVE_CONFIG_H)
+
diff --git a/dev-lang/gdl/files/0.9.2-include.patch b/dev-lang/gdl/files/0.9.2-include.patch
new file mode 100644
index 00000000000..49613da16e2
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.2-include.patch
@@ -0,0 +1,10 @@
+--- gdl-0.9.2.orig/src/cformat.g 2010-07-25 17:59:19.000000000 +0100
++++ gdl-0.9.2/src/cformat.g 2012-06-21 16:34:12.000000000 +0100
+@@ -16,6 +16,7 @@
+ ***************************************************************************/
+
+ header "pre_include_cpp" {
++#include <cstdlib>
+ #include "includefirst.hpp"
+ }
+
diff --git a/dev-lang/gdl/files/0.9.2-proj4.patch b/dev-lang/gdl/files/0.9.2-proj4.patch
new file mode 100644
index 00000000000..594b6d5cbae
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.2-proj4.patch
@@ -0,0 +1,27 @@
+--- gdl-0.9.2.orig/CMakeLists.txt 2011-12-22 20:18:17.000000000 +0000
++++ gdl-0.9.2/CMakeLists.txt 2011-12-24 06:12:08.000000000 +0000
+@@ -412,17 +420,17 @@
+ find_package(Libproj4 QUIET)
+ if(LIBPROJ4_FOUND)
+ set(CMAKE_REQUIRED_LIBRARIES ${LIBPROJ4_LIBRARIES} ${GSL_LIBRARIES} m)
+- check_library_exists("${LIBPROJ4_LIBRARIES}" proj_init "" USE_LIBPROJ4_NEW)
+- if(USE_LIBPROJ4_NEW)
++ check_library_exists("${LIBPROJ4_LIBRARIES}" proj_init "" USE_LIBPROJ4)
++ if(USE_LIBPROJ4)
+ set(USE_LIBPROJ4 1)
+- else(USE_LIBPROJ4_NEW)
+- check_library_exists("${LIBPROJ4_LIBRARIES}" pj_init "" USE_LIBPROJ4)
+- if(NOT USE_LIBPROJ4)
++ else(USE_LIBPROJ4)
++ check_library_exists("${LIBPROJ4_LIBRARIES}" pj_init "" USE_LIBPROJ4_NEW)
++ if(NOT USE_LIBPROJ4_NEW)
+ message(FATAL_ERROR "Libproj4 is required but was not found.\n"
+ "Use -DLIBPROJ4DIR=DIR to specify the Libproj4 directory tree.\n"
+ "Use -DLIBPRJ4=OFF to not use it.")
+- endif(NOT USE_LIBPROJ4)
+- endif(USE_LIBPROJ4_NEW)
++ endif(NOT USE_LIBPROJ4_NEW)
++ endif(USE_LIBPROJ4)
+ include_directories(${LIBPROJ4_INCLUDE_DIR})
+ set(LIBRARIES ${LIBRARIES} ${LIBPROJ4_LIBRARIES})
+ set(CMAKE_REQUIRED_LIBRARIES)
diff --git a/dev-lang/gdl/files/0.9.2-semaphore.patch b/dev-lang/gdl/files/0.9.2-semaphore.patch
new file mode 100644
index 00000000000..f2a28042f8d
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.2-semaphore.patch
@@ -0,0 +1,22 @@
+--- gdl-0.9.2/CMakeLists.txt 2011-11-06 22:39:45.000000000 +0000
++++ gdl-0.9.2/CMakeLists.txt.new 2012-06-21 00:02:42.000000000 +0100
+@@ -217,6 +217,19 @@
+ add_definitions(${OpenMP_CXX_FLAGS})
+ set(LIBRARIES ${LIBRARIES} ${OpenMP_CXX_FLAGS})
+ endif(OPENMP_FOUND)
++else(OPENMP)
++ # we need to define those semaphore posix symbols, do it with threads libs
++ find_package(Threads)
++ if(THREADS_FOUND)
++ set(LIBRARIES ${LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
++ else(THREADS_FOUND)
++ check_library_exists(rt sem_unlink "" HAVE_RT)
++ if(HAVE_RT)
++ set(LIBRARIES ${LIBRARIES} rt)
++ else(HAVE_RT)
++ message(FATAL_ERROR "Missing a POSIX semaphore symbols (rt or threads).\n")
++ endif(HAVE_RT)
++ endif(THREADS_FOUND)
+ endif(OPENMP)
+
+ # GSL MANDATORY
diff --git a/dev-lang/gdl/files/0.9.3-plwidth.patch b/dev-lang/gdl/files/0.9.3-plwidth.patch
new file mode 100644
index 00000000000..b09e1a88f5d
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.3-plwidth.patch
@@ -0,0 +1,158 @@
+diff -up gdl-0.9.3/CMakeLists.txt.plwidth gdl-0.9.3/CMakeLists.txt
+--- gdl-0.9.3/CMakeLists.txt.plwidth 2013-08-27 16:55:33.806600443 -0600
++++ gdl-0.9.3/CMakeLists.txt 2013-08-27 16:55:36.589590528 -0600
+@@ -23,6 +23,7 @@ include(CheckLibraryExists)
+ include(CheckFunctionExists)
+ include(CheckSymbolExists)
+ include(CheckCSourceRuns)
++include(CheckCXXSourceCompiles)
+ include(FindPkgConfig)
+ include(FindPackageHandleStandardArgs)
+
+@@ -302,6 +303,18 @@ if(PLPLOT_FOUND)
+ message(STATUS "warning, due to old plplot library, [XYZ]TICKFORMAT option for plot axis will not be supported.\n"
+ "you should upgrade to plplot version > 5.9.6")
+ endif(HAVE_PLPLOT_SLABELFUNC)
++ set(CMAKE_REQUIRED_INCLUDES "${PLPLOT_INCLUDE_DIR}")
++ set(CMAKE_REQUIRED_LIBRARIES "${PLPLOT_LIBRARIES}")
++ check_cxx_source_compiles("
++#include <plplot/plstream.h>
++int main(int argc, char **argv) {
++ plstream *p = new plstream();
++ PLFLT w = 0.5;
++ p->width(w);
++}" HAVE_PLPLOT_WIDTH)
++ if(HAVE_PLPLOT_WIDTH)
++ set(HAVE_PLPLOT_WIDTH 1)
++ endif(HAVE_PLPLOT_WIDTH)
+ check_library_exists("${PLPLOT_LIBRARIES}" plstrl "" PLPLOT_PRIVATE_NOT_HIDDEN)
+ if(PLPLOT_PRIVATE_NOT_HIDDEN)
+ set(PLPLOT_PRIVATE_NOT_HIDDEN 1)
+diff -up gdl-0.9.3/config.h.cmake.plwidth gdl-0.9.3/config.h.cmake
+--- gdl-0.9.3/config.h.cmake.plwidth 2013-08-27 16:55:33.808600436 -0600
++++ gdl-0.9.3/config.h.cmake 2013-08-27 16:55:36.589590528 -0600
+@@ -28,6 +28,7 @@
+ #cmakedefine HAVE_NEXTTOWARD 1
+ #cmakedefine HAVE_OLDPLPLOT 1
+ #cmakedefine HAVE_PLPLOT_SLABELFUNC 1
++#cmakedefine HAVE_PLPLOT_WIDTH 1
+ #cmakedefine PLPLOT_PRIVATE_NOT_HIDDEN 1
+ #cmakedefine PLPLOT_HAS_LEGEND
+ #ifndef HAVE_STDINT_H
+diff -up gdl-0.9.3/src/plotting_contour.cpp.plwidth gdl-0.9.3/src/plotting_contour.cpp
+--- gdl-0.9.3/src/plotting_contour.cpp.plwidth 2013-08-27 16:55:33.883600169 -0600
++++ gdl-0.9.3/src/plotting_contour.cpp 2013-08-27 16:55:36.590590524 -0600
+@@ -705,7 +705,11 @@ namespace lib
+ actStream->pat(1,&ori,&spa);
+
+ if (docolors) actStream->Color ( ( *colors )[i%colors->N_Elements ( )], decomposed, (PLINT)colorindex_table_0_color );
++#if (HAVE_PLPLOT_WIDTH)
++ if (dothick) actStream->width ( static_cast<PLFLT>(( *thick )[i%thick->N_Elements ( )]));
++#else
+ if (dothick) actStream->wid ( ( *thick )[i%thick->N_Elements ( )]);
++#endif
+ if (dostyle) gdlLineStyle(actStream, ( *style )[i%style->N_Elements ( )]);
+ actStream->shade( map, xEl, yEl, isLog?doIt:NULL, xStart, xEnd, yStart, yEnd,
+ clevel[i], clevel[i+1],
+@@ -788,7 +792,11 @@ namespace lib
+ actStream->stransform(gdl3dTo2dTransformContour, &Data3d);
+ }
+ if (docolors) actStream->Color ( ( *colors )[i%colors->N_Elements ( )], decomposed, 2);
++#if (HAVE_PLPLOT_WIDTH)
++ if (dothick) actStream->width ( static_cast<PLFLT>(( *thick )[i%thick->N_Elements ( )]));
++#else
+ if (dothick) actStream->wid ( ( *thick )[i%thick->N_Elements ( )]);
++#endif
+ if (dostyle) gdlLineStyle(actStream, ( *style )[i%style->N_Elements ( )]);
+ if (dolabels) actStream->setcontlabelparam ( LABELOFFSET, (PLFLT) label_size, LABELSPACING,
+ (PLINT)(*labels)[i%labels->N_Elements()] );
+diff -up gdl-0.9.3/src/plotting.cpp.plwidth gdl-0.9.3/src/plotting.cpp
+--- gdl-0.9.3/src/plotting.cpp.plwidth 2013-08-27 16:55:33.886600158 -0600
++++ gdl-0.9.3/src/plotting.cpp 2013-08-27 16:58:33.707952697 -0600
+@@ -1891,7 +1891,11 @@ namespace lib
+ DFloatGDL* charthickVect=e->GetKWAs<DFloatGDL>( charthickIx );
+ charthick=(*charthickVect)[0];
+ }
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(static_cast<PLFLT>(charthick));
++#else
+ a->wid(charthick);
++#endif
+ }
+
+ void gdlSetAxisCharsize(EnvT *e, GDLGStream *a, string axis)
+@@ -1919,7 +1923,11 @@ namespace lib
+
+ e->AssureFloatScalarKWIfPresent("THICK", thick);
+ if ( thick<=0.0 ) thick=1.0;
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(static_cast<PLFLT>(thick));
++#else
+ a->wid(static_cast<PLINT>(floor(thick-0.5)));
++#endif
+ }
+
+ //LINESTYLE
+@@ -2932,7 +2940,11 @@ namespace lib
+ a->smaj((PLFLT)OtherAxisSizeInMm, 1.0); //set base ticks to default 0.02 viewport converted to mm.
+ a->smin((PLFLT)OtherAxisSizeInMm/2.0,1.0); //idem min (plplt defaults)
+ //thick for box and ticks.
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(static_cast<PLFLT>(Thick));
++#else
+ a->wid(Thick);
++#endif
+ //ticks or grid eventually with style and length:
+ if (abs(TickLen)<1e-6) Opt=""; else Opt="st"; //remove ticks if ticklen=0
+ if (TickLen<0) {Opt+="i"; TickLen=-TickLen;}
+@@ -2977,7 +2989,11 @@ namespace lib
+ else if (axis=="Y") a->box("", 0.0, 0 , Opt.c_str(), 0.0, 0);
+ }
+ //reset charsize & thick
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(1.0);
++#else
+ a->wid(1);
++#endif
+ a->sizeChar(1.0);
+ }
+ return 0;
+@@ -3120,7 +3136,11 @@ namespace lib
+ a->smaj((PLFLT)OtherAxisSizeInMm, 1.0); //set base ticks to default 0.02 viewport converted to mm.
+ a->smin((PLFLT)OtherAxisSizeInMm/2.0,1.0); //idem min (plplt defaults)
+ //thick for box and ticks.
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(static_cast<PLFLT>(Thick));
++#else
+ a->wid(Thick);
++#endif
+ //ticks or grid eventually with style and length:
+ if (abs(TickLen)<1e-6) Opt=""; else Opt="st"; //remove ticks if ticklen=0
+ if (TickLen<0) {Opt+="i"; TickLen=-TickLen;}
+@@ -3145,7 +3165,11 @@ namespace lib
+ else if (axis=="Z") a->box3("","",0,0,"","",0,0, Opt.c_str(), "", TickInterval, Minor);
+ }
+ //reset charsize & thick
++#if (HAVE_PLPLOT_WIDTH)
++ a->width(1.0);
++#else
+ a->wid(1);
++#endif
+ a->sizeChar(1.0);
+ }
+ return 0;
+diff -up gdl-0.9.3/src/plotting_xyouts.cpp.plwidth gdl-0.9.3/src/plotting_xyouts.cpp
+--- gdl-0.9.3/src/plotting_xyouts.cpp.plwidth 2013-08-27 16:55:33.892600137 -0600
++++ gdl-0.9.3/src/plotting_xyouts.cpp 2013-08-27 16:55:36.591590521 -0600
+@@ -339,7 +339,11 @@ namespace lib
+ //plot!
+ if (docharsize) actStream->sizeChar(( *size )[i%size->N_Elements ( )]);
+ if (docolor) actStream->Color ( ( *color )[i%color->N_Elements ( )], decomposed, 2);
++#if (HAVE_PLPLOT_WIDTH)
++ if (docharthick) actStream->width ( static_cast<PLFLT>(( *charthick )[i%charthick->N_Elements ( )]));
++#else
+ if (docharthick) actStream->wid ( ( *charthick )[i%charthick->N_Elements ( )]);
++#endif
+ //orientation word is not orientation page depending on axes increment direction [0..1] vs. [1..0]
+ PLFLT oriD=(( *orientation )[i%orientation->N_Elements ( )]); //ori DEVICE
+ PLFLT oriW=oriD; //ori WORLD
diff --git a/dev-lang/gdl/files/0.9.4-gsl.patch b/dev-lang/gdl/files/0.9.4-gsl.patch
new file mode 100644
index 00000000000..3a96a41adcd
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.4-gsl.patch
@@ -0,0 +1,62 @@
+diff -up gdl-0.9.4/src/gsl_matrix.cpp.gsl gdl-0.9.4/src/gsl_matrix.cpp
+--- gdl-0.9.4/src/gsl_matrix.cpp.gsl 2013-09-20 10:10:02.000000000 -0600
++++ gdl-0.9.4/src/gsl_matrix.cpp 2013-10-03 13:50:41.089660703 -0600
+@@ -41,10 +41,11 @@ namespace lib {
+ const int szdbl=sizeof(DDouble);
+ const int szflt=sizeof(DFloat);
+ const int szlng=sizeof(DLong);
++ const int szlng64=sizeof(DLong64);
+
+ void ludc_pro( EnvT* e)
+ {
+- // cout << szdbl << " " <<szflt << " " << szlng << endl;
++ // cout << szdbl << " " <<szflt << " " << szlng << " " szlng64 << endl;
+
+ SizeT nParam=e->NParam(1);
+ // if( nParam == 0)
+@@ -120,9 +121,15 @@ namespace lib {
+ dimension dim1(&n, (SizeT) 1);
+ BaseGDL** p1D = &e->GetPar( 1);
+ GDLDelete((*p1D));
+- *p1D = new DLongGDL(dim1, BaseGDL::NOZERO);
+- memcpy(&(*(DLongGDL*) *p1D)[0], p->data,
+- p0->Dim(0)*szlng);
++ if (sizeof(size_t) == szlng) {
++ *p1D = new DLongGDL(dim1, BaseGDL::NOZERO);
++ memcpy(&(*(DLongGDL*) *p1D)[0], p->data,
++ p0->Dim(0)*szlng);
++ } else {
++ *p1D = new DLong64GDL(dim1, BaseGDL::NOZERO);
++ memcpy(&(*(DLong64GDL*) *p1D)[0], p->data,
++ p0->Dim(0)*szlng64);
++ }
+
+ // gsl_matrix_free(mat);
+ // gsl_permutation_free(p);
+@@ -189,10 +196,15 @@ namespace lib {
+ GDLGuard<gsl_matrix> g1(mat,gsl_matrix_free);
+ memcpy(mat->data, &(*p0D)[0], nEl*szdbl);
+
+- DLongGDL* p1L =e->GetParAs<DLongGDL>(1);
+ gsl_permutation *p = gsl_permutation_alloc (nEl1);
+ GDLGuard<gsl_permutation> g2(p,gsl_permutation_free);
+- memcpy(p->data, &(*p1L)[0], nEl1*szlng);
++ if (sizeof(size_t) == szlng) {
++ DLongGDL* p1L =e->GetParAs<DLongGDL>(1);
++ memcpy(p->data, &(*p1L)[0], nEl1*szlng);
++ } else {
++ DLong64GDL* p1L =e->GetParAs<DLong64GDL>(1);
++ memcpy(p->data, &(*p1L)[0], nEl1*szlng64);
++ }
+
+ DDoubleGDL *p2D = e->GetParAs<DDoubleGDL>(2);
+ gsl_vector *b = gsl_vector_alloc(nEl2);
+@@ -222,7 +234,7 @@ namespace lib {
+ DDoubleGDL* res = new DDoubleGDL( p2->Dim(), BaseGDL::NOZERO);
+ memcpy(&(*res)[0], x->data, nEl1*szdbl);
+
+-// gsl_matrix_free(mat);
++// gsl_matrix_free(mat);Parameter
+ // gsl_vector_free(x);
+ // gsl_permutation_free(p);
+ // b ???
diff --git a/dev-lang/gdl/files/0.9.4-plplot.patch b/dev-lang/gdl/files/0.9.4-plplot.patch
new file mode 100644
index 00000000000..fac18ec5e69
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.4-plplot.patch
@@ -0,0 +1,18 @@
+ CMakeModules/FindPlplot.cmake | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeModules/FindPlplot.cmake b/CMakeModules/FindPlplot.cmake
+index a503f8c..cdaeb24 100644
+--- a/CMakeModules/FindPlplot.cmake
++++ b/CMakeModules/FindPlplot.cmake
+@@ -9,8 +9,8 @@
+ #
+
+
+-find_library(PLPLOT_LIBRARY NAMES plplotd)
+-find_library(PLPLOTCXX_LIBRARY NAMES plplotcxxd)
++find_library(PLPLOT_LIBRARY NAMES plplotd plplot)
++find_library(PLPLOTCXX_LIBRARY NAMES plplotcxxd plplotcxx)
+ set(PLPLOT_LIBRARIES ${PLPLOT_LIBRARY} ${PLPLOTCXX_LIBRARY})
+ find_path(PLPLOT_INCLUDE_DIR NAMES plplot/plplot.h)
+ include(FindPackageHandleStandardArgs)
diff --git a/dev-lang/gdl/files/0.9.4-python.patch b/dev-lang/gdl/files/0.9.4-python.patch
new file mode 100644
index 00000000000..709f8c140cd
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.4-python.patch
@@ -0,0 +1,12 @@
+diff -up gdl-0.9.4/src/pythongdl.cpp.python gdl-0.9.4/src/pythongdl.cpp
+--- gdl-0.9.4/src/pythongdl.cpp.python 2013-07-26 03:30:32.000000000 -0600
++++ gdl-0.9.4/src/pythongdl.cpp 2013-09-30 10:24:27.092666180 -0600
+@@ -373,7 +373,7 @@ PyObject *GDLSub( PyObject *self, PyObje
+ if( libCall)
+ e = new EnvT( NULL, sub);
+ else
+- e = new EnvUDT( NULL, sub);
++ e = new EnvUDT( NULL, static_cast<DSubUD*>(sub));
+
+ Guard< EnvBaseT> e_guard( e);
+
diff --git a/dev-lang/gdl/files/0.9.4-python2.patch b/dev-lang/gdl/files/0.9.4-python2.patch
new file mode 100644
index 00000000000..8dc92324a58
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.4-python2.patch
@@ -0,0 +1,17 @@
+ CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 1fda8ee..e2170b2 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -615,8 +615,8 @@ if(PYTHON OR PYTHON_MODULE)
+ else()
+ set(PythonLibs_FIND_VERSION 2)
+ endif()
+- find_package(PythonLibs)
+ include(FindPythonInterp)
++ find_package(PythonLibs)
+ endif()
+ set(USE_PYTHON ${PYTHONLIBS_FOUND})
+ if(PYTHONLIBS_FOUND)
diff --git a/dev-lang/gdl/files/0.9.4-reorder.patch b/dev-lang/gdl/files/0.9.4-reorder.patch
new file mode 100644
index 00000000000..d871757a29d
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.4-reorder.patch
@@ -0,0 +1,380 @@
+diff -up gdl-0.9.4/src/allix.hpp.reorder gdl-0.9.4/src/allix.hpp
+--- gdl-0.9.4/src/allix.hpp.reorder 2012-12-11 10:39:35.000000000 -0700
++++ gdl-0.9.4/src/allix.hpp 2013-10-04 10:59:22.666594845 -0600
+@@ -344,9 +344,9 @@ private:
+ public:
+ AllIxAllIndexedT( ArrayIndexVectorT* ixList_, SizeT acRank_, SizeT nIx_, const SizeT* varStride_)
+ : ixList( ixList_)
++ , varStride( varStride_)
+ , acRank( acRank_)
+ , nIx( nIx_)
+- , varStride( varStride_)
+ {}
+ ~AllIxAllIndexedT() {}
+
+@@ -384,11 +384,11 @@ private:
+ public:
+ AllIxNewMultiT( ArrayIndexVectorT* ixList_, SizeT acRank_, SizeT nIx_, const SizeT* varStride_, SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , acRank( acRank_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , acRank( acRank_)
++ , nIx( nIx_)
+ {
+ add = 0;
+ assert( varStride[0] == 1);
+@@ -440,10 +440,10 @@ private:
+ public:
+ AllIxNewMulti2DT( ArrayIndexVectorT* ixList_, SizeT nIx_, const SizeT* varStride_, SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , nIx( nIx_)
+ {
+ add = 0;
+ if( !(*ixList)[0]->Indexed())
+@@ -499,11 +499,11 @@ private:
+ public:
+ AllIxNewMultiNoneIndexedT( ArrayIndexVectorT* ixList_, SizeT acRank_, SizeT nIx_, const SizeT* varStride_, SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , acRank( acRank_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , acRank( acRank_)
++ , nIx( nIx_)
+ {
+ assert( varStride[0] == 1);
+ add = 0;
+@@ -548,10 +548,10 @@ private:
+ public:
+ AllIxNewMultiNoneIndexed2DT( ArrayIndexVectorT* ixList_, SizeT nIx_, const SizeT* varStride_, SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , nIx( nIx_)
+ {
+ assert( varStride[0] == 1);
+ ixListStride[0] = (*ixList)[0]->GetStride();
+@@ -593,11 +593,11 @@ public:
+ AllIxNewMultiOneVariableIndexNoIndexT( RankT gt1Rank, SizeT add_,
+ ArrayIndexVectorT* ixList_, SizeT acRank_, SizeT nIx_, const SizeT* varStride_, SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , acRank( acRank_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , acRank( acRank_)
++ , nIx( nIx_)
+ , add( add_)
+ , variableIndex( gt1Rank)
+ {
+@@ -642,11 +642,11 @@ public:
+ SizeT acRank_, SizeT nIx_, const SizeT* varStride_,
+ SizeT* nIterLimit_, SizeT* stride_)
+ : ixList( ixList_)
+- , acRank( acRank_)
+- , nIx( nIx_)
+ , varStride( varStride_)
+ , nIterLimit( nIterLimit_)
+ , stride( stride_)
++ , acRank( acRank_)
++ , nIx( nIx_)
+ , add( add_)
+ , variableIndex( gt1Rank)
+ {
+diff -up gdl-0.9.4/src/arrayindex.hpp.reorder gdl-0.9.4/src/arrayindex.hpp
+--- gdl-0.9.4/src/arrayindex.hpp.reorder 2013-09-17 10:46:19.000000000 -0600
++++ gdl-0.9.4/src/arrayindex.hpp 2013-10-04 11:00:58.849879562 -0600
+@@ -303,7 +303,7 @@ private:
+ RangeT s;
+ BaseGDL* rawData; // for overloaded object indexing
+
+- CArrayIndexScalar( const CArrayIndexScalar& c): s( c.s), sInit( c.sInit)
++ CArrayIndexScalar( const CArrayIndexScalar& c): sInit( c.sInit), s( c.s)
+ {
+ assert( c.rawData != NULL);
+ rawData = c.rawData->Dup();
+diff -up gdl-0.9.4/src/arrayindexlistnoassoct.hpp.reorder gdl-0.9.4/src/arrayindexlistnoassoct.hpp
+--- gdl-0.9.4/src/arrayindexlistnoassoct.hpp.reorder 2013-07-04 17:24:44.000000000 -0600
++++ gdl-0.9.4/src/arrayindexlistnoassoct.hpp 2013-10-04 11:24:02.893867004 -0600
+@@ -59,8 +59,8 @@ public:
+ { nParam = 0;}
+
+ ArrayIndexListOneNoAssocT( const ArrayIndexListOneNoAssocT& cp):
+- cleanupIx(),
+ ArrayIndexListT( cp),
++ cleanupIx(),
+ ix( cp.ix->Dup()),
+ allIx( NULL)
+ {
+diff -up gdl-0.9.4/src/arrayindexlistt.hpp.reorder gdl-0.9.4/src/arrayindexlistt.hpp
+--- gdl-0.9.4/src/arrayindexlistt.hpp.reorder 2013-09-17 10:46:19.000000000 -0600
++++ gdl-0.9.4/src/arrayindexlistt.hpp 2013-10-04 11:23:35.607069888 -0600
+@@ -130,8 +130,8 @@ public:
+ { nParam = 0;}
+
+ ArrayIndexListOneT( const ArrayIndexListOneT& cp):
+- cleanupIx(),
+ ArrayIndexListT( cp),
++ cleanupIx(),
+ ix( cp.ix->Dup()),
+ allIx( NULL)
+ {
+diff -up gdl-0.9.4/src/deviceps.hpp.reorder gdl-0.9.4/src/deviceps.hpp
+--- gdl-0.9.4/src/deviceps.hpp.reorder 2013-07-03 15:48:06.000000000 -0600
++++ gdl-0.9.4/src/deviceps.hpp 2013-10-04 13:14:48.283746779 -0600
+@@ -441,9 +441,9 @@ private:
+ }
+
+ public:
+- DevicePS(): Graphics(), fileName( "gdl.ps"), actStream( NULL), color(0),
+- decomposed( 0), encapsulated(false), scale(1.), XPageSize(17.78), YPageSize(12.7),
+- XOffset(0.0),YOffset(0.0)
++ DevicePS(): Graphics(), fileName( "gdl.ps"), actStream( NULL),
++ XPageSize(17.78), YPageSize(12.7), XOffset(0.0),YOffset(0.0),
++ color(0), decomposed( 0), encapsulated(false), scale(1.)
+ {
+ name = "PS";
+
+diff -up gdl-0.9.4/src/dnode.cpp.reorder gdl-0.9.4/src/dnode.cpp
+--- gdl-0.9.4/src/dnode.cpp.reorder 2012-09-18 08:19:18.000000000 -0600
++++ gdl-0.9.4/src/dnode.cpp 2013-10-04 12:02:48.601416601 -0600
+@@ -55,9 +55,10 @@ DNode::DNode( const DNode& cp):
+ // keepRight( false),
+ CommonAST( cp), //down(), right(),
+ lineNumber( cp.getLine()), cData(NULL),
+- var(cp.var), arrIxList(NULL),arrIxListNoAssoc(NULL),
++ var(cp.var),
+ libFun( cp.libFun),
+ libPro( cp.libPro),
++ arrIxList(NULL),arrIxListNoAssoc(NULL),
+ labelStart( cp.labelStart), labelEnd( cp.labelEnd)
+ {
+ if( cp.cData != NULL) cData = cp.cData->Dup();
+diff -up gdl-0.9.4/src/dnode.hpp.reorder gdl-0.9.4/src/dnode.hpp
+diff -up gdl-0.9.4/src/dpro.cpp.reorder gdl-0.9.4/src/dpro.cpp
+--- gdl-0.9.4/src/dpro.cpp.reorder 2013-09-17 03:03:25.000000000 -0600
++++ gdl-0.9.4/src/dpro.cpp 2013-10-04 13:05:23.169223727 -0600
+@@ -200,8 +200,8 @@ DSubUD::~DSubUD()
+ DSubUD::DSubUD(const string& n,const string& o,const string& f) :
+ DSub(n,o), file(f),
+ tree( NULL),
+- labelList(),
+ compileOpt(GDLParser::NONE),
++ labelList(),
+ nForLoops( 0)
+ {
+ if( o != "")
+diff -up gdl-0.9.4/src/envt.cpp.reorder gdl-0.9.4/src/envt.cpp
+--- gdl-0.9.4/src/envt.cpp.reorder 2013-09-25 05:55:21.000000000 -0600
++++ gdl-0.9.4/src/envt.cpp 2013-10-04 13:08:17.081114086 -0600
+@@ -107,15 +107,15 @@ void EnvUDT::operator delete( void *ptr)
+
+
+ EnvBaseT::EnvBaseT( ProgNodeP cN, DSub* pro_):
+- env(),
+ toDestroy(),
++ env(),
+ pro(pro_),
+- extra(NULL),
+- newEnv(NULL),
+ callingNode( cN),
+ lineNumber( 0),
+- obj(false)
+- ,ptrToReturnValue(NULL)
++ obj(false),
++ extra(NULL),
++ newEnv(NULL),
++ ptrToReturnValue(NULL)
+ //, toDestroyInitialIndex( toDestroy.size())
+ {}
+
+diff -up gdl-0.9.4/src/envt.hpp.reorder gdl-0.9.4/src/envt.hpp
+--- gdl-0.9.4/src/envt.hpp.reorder 2013-09-26 04:47:48.000000000 -0600
++++ gdl-0.9.4/src/envt.hpp 2013-10-04 10:55:21.892428311 -0600
+@@ -863,7 +863,7 @@ public:
+ typedef SizeT size_type;
+ typedef EnvUDT* pointer_type;
+
+- EnvStackT(): sz(defaultStackDepth), top(0)
++ EnvStackT(): top(0), sz(defaultStackDepth)
+ {
+ envStackFrame = new EnvUDT* [ sz+1];
+ envStack = envStackFrame + 1;
+diff -up gdl-0.9.4/src/gdlexception.cpp.reorder gdl-0.9.4/src/gdlexception.cpp
+--- gdl-0.9.4/src/gdlexception.cpp.reorder 2013-06-23 17:07:32.000000000 -0600
++++ gdl-0.9.4/src/gdlexception.cpp 2013-10-04 14:00:32.102348401 -0600
+@@ -43,9 +43,9 @@ GDLException::GDLException(DLong eC, con
+ errorNodeP( NULL),
+ errorCode(eC),
+ line( 0), col( 0), prefix( pre),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if(decorate && interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -97,9 +97,9 @@ GDLException::GDLException(const RefDNod
+ errorNodeP( NULL),
+ errorCode(-1),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if(interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -122,9 +122,9 @@ GDLException::GDLException(DLong eC, con
+ errorNodeP( NULL),
+ errorCode(eC),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if(interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -148,9 +148,9 @@ GDLException::GDLException(const ProgNod
+ errorNodeP( eN),
+ errorCode(-1),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if( overWriteNode && interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -177,9 +177,9 @@ GDLException::GDLException(DLong eC, con
+ errorNodeP( eN),
+ errorCode(eC),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if( overWriteNode && interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -207,9 +207,9 @@ GDLException::GDLException(SizeT l, Size
+ errorNodeP( NULL),
+ errorCode(-1),
+ line( l), col( c), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {
+ if(interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+@@ -232,8 +232,8 @@ GDLException::GDLException(DLong eC, Siz
+ errorNodeP( NULL),
+ errorCode(eC),
+ line( l), col( c), prefix( true),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ arrayexprIndexeeFailed(false),
++ targetEnv( NULL)
+ {
+ if(interpreter!=NULL && interpreter->CallStack().size()>0)
+ {
+diff -up gdl-0.9.4/src/gdlexception.hpp.reorder gdl-0.9.4/src/gdlexception.hpp
+--- gdl-0.9.4/src/gdlexception.hpp.reorder 2013-06-23 17:07:32.000000000 -0600
++++ gdl-0.9.4/src/gdlexception.hpp 2013-10-04 11:12:58.332125288 -0600
+@@ -66,18 +66,18 @@ public:
+ errorNodeP( NULL),
+ errorCode(-1),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {}
+ GDLException( DLong eC): ANTLRException(),
+ errorNode(static_cast<RefDNode>(antlr::nullAST)),
+ errorNodeP( NULL),
+ errorCode(eC),
+ line( 0), col( 0), prefix( true),
++ arrayexprIndexeeFailed(false),
+ ioException( false),
+- targetEnv( NULL),
+- arrayexprIndexeeFailed(false)
++ targetEnv( NULL)
+ {}
+ GDLException(const std::string& s, bool pre = true, bool decorate=true);
+ GDLException(const RefDNode eN, const std::string& s);
+diff -up gdl-0.9.4/src/prognode.cpp.reorder gdl-0.9.4/src/prognode.cpp
+--- gdl-0.9.4/src/prognode.cpp.reorder 2013-09-27 18:47:49.000000000 -0600
++++ gdl-0.9.4/src/prognode.cpp 2013-10-04 14:01:11.490342867 -0600
+@@ -54,19 +54,19 @@ return nonCopyNodeLookupArray;
+
+ // tanslation RefDNode -> ProgNode
+ ProgNode::ProgNode( const RefDNode& refNode):
++ ttype( refNode->getType()),
++ text( refNode->getText()),
+ keepRight( false),
+ keepDown( false),
+ breakTarget( NULL),
+- ttype( refNode->getType()),
+- text( refNode->getText()),
+ down( NULL),
+ right( NULL),
+- lineNumber( refNode->getLine()),
+ cData( refNode->StealCData()), // stealing is crucial here because references might exist
++ var( refNode->var),
+ // as arrayindices
+- libPro( refNode->libPro),
+ libFun( refNode->libFun),
+- var( refNode->var),
++ libPro( refNode->libPro),
++ lineNumber( refNode->getLine()),
+ arrIxList( refNode->StealArrIxList()),
+ arrIxListNoAssoc( refNode->StealArrIxNoAssocList()),
+ // arrIxList( refNode->CloneArrIxList()),
+diff -up gdl-0.9.4/src/prognodeexpr.cpp.reorder gdl-0.9.4/src/prognodeexpr.cpp
+--- gdl-0.9.4/src/prognodeexpr.cpp.reorder 2013-09-26 05:08:39.000000000 -0600
++++ gdl-0.9.4/src/prognodeexpr.cpp 2013-10-04 13:20:36.660155916 -0600
+@@ -49,18 +49,18 @@ BinaryExprNC::BinaryExprNC( const RefDNo
+ }
+
+ ProgNode::ProgNode(): // for NULLProgNode
++ ttype( antlr::Token::NULL_TREE_LOOKAHEAD),
++ text( "NULLProgNode"),
+ keepRight( false),
+ keepDown( false),
+ breakTarget( NULL),
+- ttype( antlr::Token::NULL_TREE_LOOKAHEAD),
+- text( "NULLProgNode"),
+ down( NULL),
+ right( NULL),
+- lineNumber( 0),
+ cData( NULL),
+- libPro( NULL),
+- libFun( NULL),
+ var( NULL),
++ libFun( NULL),
++ libPro( NULL),
++ lineNumber( 0),
+ labelStart( 0),
+ labelEnd( 0)
+ {}
diff --git a/dev-lang/gdl/files/0.9.5-antlr.patch b/dev-lang/gdl/files/0.9.5-antlr.patch
new file mode 100644
index 00000000000..f5b627ab444
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.5-antlr.patch
@@ -0,0 +1,91 @@
+ CMakeLists.txt | 14 +++++++++++---
+ CMakeModules/FindANTLR.cmake | 11 +++++++++++
+ src/CMakeLists.txt | 18 +++++++++++-------
+ 3 files changed, 33 insertions(+), 10 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 407e39a..c4b3278 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -111,6 +111,8 @@ set(SZIPDIR "" CACHE PATH "GDL: Specify the SZip directory tree")
+
+ set(GDL_DATA_DIR "/share/gnudatalanguage" CACHE PATH "GDL: data directory relative to CMAKE_INSTALL_PREFIX")
+
++set(BUNDLED_ANTLR OFF CACHE BOOL "Use bundled ANTLR grammar ?")
++set(ANTLRDIR "" CACHE PATH "Specify the system ANTLR directory tree")
+
+ # check for 64-bit OS
+ if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
+@@ -174,9 +176,15 @@ check_library_exists(m nexttoward "" HAVE_NEXTTOWARD)
+ # mpi
+ check_include_file(mpi.h HAVE_MPI_H)
+
+-# SA: whithout it compilation of antlr fails if there's a conflicting
+-# version of antlr in system-wide directories
+-include_directories(src)
++if(BUNDLED_ANTLR)
++ # SA: whithout it compilation of antlr fails if there's a conflicting
++ # version of antlr in system-wide directories
++ include_directories(src)
++else(BUNDLED_ANTLR)
++ find_package(ANTLR QUIET)
++ set(LIBRARIES ${LIBRARIES} ${ANTLR_LIBRARIES})
++ include_directories(${ANTLR_INCLUDE_DIR})
++endif(BUNDLED_ANTLR)
+
+ if(WIN32 AND NOT CYGWIN)
+ # For Win32 find Pdcureses instead of (N)Curses
+diff --git a/CMakeModules/FindANTLR.cmake b/CMakeModules/FindANTLR.cmake
+new file mode 100644
+index 0000000..b61cc5b
+--- /dev/null
++++ b/CMakeModules/FindANTLR.cmake
+@@ -0,0 +1,11 @@
++
++
++find_library(ANTLR_LIBRARIES NAMES antlr)
++find_path(ANTLR_INCLUDE_DIR NAMES antlr/ANTLRUtil.hpp)
++include(FindPackageHandleStandardArgs)
++find_package_handle_standard_args(ANTLR DEFAULT_MSG ANTLR_LIBRARIES ANTLR_INCLUDE_DIR)
++
++mark_as_advanced(
++ANTLR_LIBRARIES
++ANTLR_INCLUDE_DIR
++)
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 1f7ffec..776a1fd 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -262,9 +262,8 @@ widget.cpp
+ widget.hpp
+ )
+
+-add_subdirectory(antlr)
+
+-include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_SOURCE_DIR}/src/antlr ${CMAKE_BINARY_DIR})
++include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_BINARY_DIR})
+ link_directories(${LINK_DIRECTORIES})
+
+ if(PYTHON_MODULE) #libgdl
+@@ -275,11 +274,16 @@ else(PYTHON_MODULE) #gdl
+ add_executable(gdl ${SOURCES})
+ endif(PYTHON_MODULE)
+
+-add_dependencies(gdl antlr) # be sure that antlr is built before gdl
+-target_link_libraries(gdl antlr) # link antlr against gdl
+-if (MINGW)
+-target_link_libraries(gdl ws2_32)
+-endif (MINGW)
++if(BUNDLED_ANTLR)
++ add_subdirectory(antlr)
++ include_directories(${CMAKE_SOURCE_DIR}/src/antlr)
++ add_dependencies(gdl antlr) # be sure that antlr is built before gdl
++ target_link_libraries(gdl antlr) # link antlr against gdl
++ if (MINGW)
++ target_link_libraries(gdl ws2_32)
++ endif (MINGW)
++endif(BUNDLED_ANTLR)
++
+ target_link_libraries(gdl ${LIBRARIES})
+ add_definitions(-DHAVE_CONFIG_H)
+
diff --git a/dev-lang/gdl/files/0.9.5-plplot.patch b/dev-lang/gdl/files/0.9.5-plplot.patch
new file mode 100644
index 00000000000..70ad1bd14ca
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.5-plplot.patch
@@ -0,0 +1,134 @@
+diff -up gdl-0.9.5/CMakeLists.txt.plplot gdl-0.9.5/CMakeLists.txt
+--- gdl-0.9.5/CMakeLists.txt.plplot 2014-10-07 07:21:14.000000000 -0600
++++ gdl-0.9.5/CMakeLists.txt 2015-04-24 14:29:15.588067694 -0600
+@@ -386,7 +386,7 @@ if(PLPLOT_FOUND)
+ #}" HAVE_PLPLOT_WIDTH)
+
+ #give it a 2nd try...
+- check_library_exists("${PLPLOT_LIBRARIES}" c_plwidth "" HAVE_PLPLOT_WIDTH)
++ check_library_exists("${PLPLOT_LIBRARIES}" c_plwidth "" HAVE_PLPLOT_WIDTH)
+ if(HAVE_PLPLOT_WIDTH)
+ set(HAVE_PLPLOT_WIDTH 1)
+ endif(HAVE_PLPLOT_WIDTH)
+@@ -402,6 +402,11 @@ if(PLPLOT_FOUND)
+ else(PLPLOT_HAS_LEGEND)
+ message(STATUS "Your plplot lib is too old for some gdl functions, please upgrade.")
+ endif(PLPLOT_HAS_LEGEND)
++ check_cxx_source_compiles("#include <plplot/plstream.h>
++ main(){PLINT n; PLFLT x,y;plcallback::fill(n,&x,&y);}" PLPLOT_HAS_PLCALLBACK)
++ if(PLPLOT_HAS_PLCALLBACK)
++ set(PLPLOT_HAS_PLCALLBACK 1)
++ endif(PLPLOT_HAS_PLCALLBACK)
+ endif(PLPLOT_FOUND)
+
+ # GRAPHICSMAGICK is an alternative to the classical ImageMagick Lib.
+diff -up gdl-0.9.5/CMakeModules/FindPlplot.cmake.plplot gdl-0.9.5/CMakeModules/FindPlplot.cmake
+--- gdl-0.9.5/CMakeModules/FindPlplot.cmake.plplot 2011-08-19 04:18:51.000000000 -0600
++++ gdl-0.9.5/CMakeModules/FindPlplot.cmake 2015-04-24 13:54:56.915632230 -0600
+@@ -9,8 +9,12 @@
+ #
+
+
+-find_library(PLPLOT_LIBRARY NAMES plplotd)
+-find_library(PLPLOTCXX_LIBRARY NAMES plplotcxxd)
++find_library(PLPLOT_LIBRARY NAMES plplot)
++find_library(PLPLOTCXX_LIBRARY NAMES plplotcxx)
++if(NOT PLPLOT_LIBRARY)
++ find_library(PLPLOT_LIBRARY NAMES plplotd)
++ find_library(PLPLOTCXX_LIBRARY NAMES plplotcxxd)
++endif(NOT PLPLOT_LIBRARY)
+ set(PLPLOT_LIBRARIES ${PLPLOT_LIBRARY} ${PLPLOTCXX_LIBRARY})
+ find_path(PLPLOT_INCLUDE_DIR NAMES plplot/plplot.h)
+ include(FindPackageHandleStandardArgs)
+diff -up gdl-0.9.5/config.h.cmake.plplot gdl-0.9.5/config.h.cmake
+--- gdl-0.9.5/config.h.cmake.plplot 2014-08-30 14:13:43.000000000 -0600
++++ gdl-0.9.5/config.h.cmake 2015-04-24 13:39:22.259704608 -0600
+@@ -31,6 +31,12 @@
+ #cmakedefine HAVE_PLPLOT_WIDTH 1
+ #cmakedefine PLPLOT_PRIVATE_NOT_HIDDEN 1
+ #cmakedefine PLPLOT_HAS_LEGEND
++#cmakedefine PLPLOT_HAS_PLCALLBACK
++#ifdef PLPLOT_HAS_PLCALLBACK
++#define PLCALLBACK plcallback
++#else
++#define PLCALLBACK plstream
++#endif
+ #ifndef HAVE_STDINT_H
+ #cmakedefine HAVE_STDINT_H 1
+ #endif
+diff -up gdl-0.9.5/src/plotting_contour.cpp.plplot gdl-0.9.5/src/plotting_contour.cpp
+--- gdl-0.9.5/src/plotting_contour.cpp.plplot 2014-09-29 11:03:12.000000000 -0600
++++ gdl-0.9.5/src/plotting_contour.cpp 2015-04-24 13:39:22.267705191 -0600
+@@ -789,8 +789,8 @@ namespace lib
+ 1, value,
+ static_cast<PLFLT>(( *thick )[i%thick->N_Elements()]),
+ 0,0,0,0,
+- (plstream::fill), (oneDim),
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ (PLCALLBACK::fill), (oneDim),
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ }
+ actStream->psty(0);
+ // if (docolors) gdlSetGraphicsForegroundColorFromKw( e, actStream );
+@@ -808,8 +808,8 @@ namespace lib
+ clevel[i], maxmax,
+ 1,value,
+ 0,0,0,0,0,
+- plstream::fill, (oneDim), //Onedim is accelerator since rectangles are kept rectangles see plplot doc
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ PLCALLBACK::fill, (oneDim), //Onedim is accelerator since rectangles are kept rectangles see plplot doc
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ }
+ } else { //every other case of fill
+ // note that plshades is not protected against 1 level (color formula is
+@@ -818,8 +818,8 @@ namespace lib
+ if (nlevel>2 && !(docolors)) { //acceleration with shades when no c_colors are given. use continuous table1, decomposed or not.
+ //acceleration is most sensible when a (x,y) transform (rotate, stretch) is in place since plplot does not recompute the map.
+ actStream->shades( map, xEl, yEl, isLog?doIt:NULL, xStart, xEnd, yStart, yEnd,
+- clevel, nlevel, 1, 0, 0, plstream::fill, (oneDim),
+- (oneDim)?(plstream::tr1):(plstream::tr2),
++ clevel, nlevel, 1, 0, 0, PLCALLBACK::fill, (oneDim),
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2),
+ (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ }
+ else { //fill with colors defined with c_colors or n<=2
+@@ -832,8 +832,8 @@ namespace lib
+ clevel[i], maxmax,
+ 1,value,
+ 0,0,0,0,0,
+- plstream::fill, (oneDim), //Onedim is accelerator since rectangles are kept rectangles see plplot doc
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ PLCALLBACK::fill, (oneDim), //Onedim is accelerator since rectangles are kept rectangles see plplot doc
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ } else
+ printf(" Problem, sorry! plplot doesn't like to FILL with a single level!");
+ }
+@@ -854,7 +854,7 @@ namespace lib
+ if (doT3d) { //no label in T3D , bug in plplot...
+ actStream->setcontlabelparam ( LABELOFFSET, (PLFLT) label_size, LABELSPACING, 0 );
+ actStream->cont ( map, xEl, yEl, 1, xEl, 1, yEl, &( clevel[i] ), 1,
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ } else {
+ if (dolabels && i<labels->N_Elements())
+ {
+@@ -862,16 +862,16 @@ namespace lib
+ //else (lables thicker than contours) impossible with plplot...
+ actStream->setcontlabelparam ( LABELOFFSET, (PLFLT) label_size, LABELSPACING, 0 );
+ actStream->cont ( map, xEl, yEl, 1, xEl, 1, yEl, &( clevel[i] ), 1,
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2); //thick contours, no label
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2); //thick contours, no label
+ actStream->Thick(label_thick);
+ }
+ actStream->setcontlabelparam ( LABELOFFSET, (PLFLT) label_size, LABELSPACING*sqrt(label_size),(PLINT)(*labels)[i] );
+ actStream->cont ( map, xEl, yEl, 1, xEl, 1, yEl, &( clevel[i] ), 1,
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ if (!dothick) gdlSetPenThickness(e, actStream);
+ } else {
+ actStream->cont ( map, xEl, yEl, 1, xEl, 1, yEl, &( clevel[i] ), 1,
+- (oneDim)?(plstream::tr1):(plstream::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
++ (oneDim)?(PLCALLBACK::tr1):(PLCALLBACK::tr2), (oneDim)?(void *)&cgrid1:(void *)&cgrid2);
+ }
+ }
+ }
diff --git a/dev-lang/gdl/files/0.9.5-png.patch b/dev-lang/gdl/files/0.9.5-png.patch
new file mode 100644
index 00000000000..1140fcc9ac7
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.5-png.patch
@@ -0,0 +1,15 @@
+ CMakeLists.txt | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 407e39a..f24a087 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -270,7 +270,6 @@ if(PNGLIB)
+ set(USE_PNGLIB ${PNG_FOUND})
+ if(PNG_FOUND)
+ set(LIBRARIES ${LIBRARIES} ${PNG_LIBRARIES})
+- set(LINK_DIRECTORIES ${LINK_DIRECTORIES} ${PNG_LIBRARY_DIRS})
+ include_directories(${PNG_INCLUDE_DIRS})
+ else(PNG_FOUND)
+ message(FATAL_ERROR "libpng is required but was not found.\n"
diff --git a/dev-lang/gdl/files/0.9.5-proj4.patch b/dev-lang/gdl/files/0.9.5-proj4.patch
new file mode 100644
index 00000000000..4b2ebcca0a0
--- /dev/null
+++ b/dev-lang/gdl/files/0.9.5-proj4.patch
@@ -0,0 +1,41 @@
+ CMakeLists.txt | 14 +++++++-------
+ 1 file changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index c4b3278..f9ed49d 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -637,17 +637,17 @@ if(LIBPROJ4)
+ if(LIBPROJ4_FOUND)
+ set(CMAKE_REQUIRED_LIBRARIES ${LIBPROJ4_LIBRARIES} ${GSL_LIBRARIES} m)
+
+- check_library_exists("${LIBPROJ4_LIBRARIES}" pj_init "" USE_LIBPROJ4_NEW)
+- if(USE_LIBPROJ4_NEW)
++ check_library_exists("${LIBPROJ4_LIBRARIES}" pj_init "" USE_LIBPROJ4)
++ if(USE_LIBPROJ4)
+ # check_library_exists("${LIBPROJ4_LIBRARIES}" proj_init "" USE_LIBPROJ4)
+ # if(USE_LIBPROJ4)
+
+ # define USE_LIB_PROJ4 in any case
+ set(USE_LIBPROJ4 1)
+
+- else(USE_LIBPROJ4_NEW)
+- check_library_exists("${LIBPROJ4_LIBRARIES}" proj_init "" USE_LIBPROJ4)
+- if(NOT USE_LIBPROJ4)
++ else(USE_LIBPROJ4)
++ check_library_exists("${LIBPROJ4_LIBRARIES}" proj_init "" USE_LIBPROJ4_NEW)
++ if(NOT USE_LIBPROJ4_NEW)
+ # else(USE_LIBPROJ4)
+ # check_library_exists("${LIBPROJ4_LIBRARIES}" pj_init "" USE_LIBPROJ4_NEW)
+ # if(NOT USE_LIBPROJ4_NEW)
+@@ -656,8 +656,8 @@ if(LIBPROJ4)
+ "Use -DLIBPROJ4DIR=DIR to specify the Libproj4 directory tree.\n"
+ "Use -DLIBPRJ4=OFF to not use it.")
+
+- endif(NOT USE_LIBPROJ4)
+- endif(USE_LIBPROJ4_NEW)
++ endif(NOT USE_LIBPROJ4_NEW)
++ endif(USE_LIBPROJ4)
+ # endif(NOT USE_LIBPROJ4_NEW)
+ # endif(USE_LIBPROJ4)
+
diff --git a/dev-lang/gdl/gdl-0.9.4.ebuild b/dev-lang/gdl/gdl-0.9.4.ebuild
new file mode 100644
index 00000000000..05382dcb70e
--- /dev/null
+++ b/dev-lang/gdl/gdl-0.9.4.ebuild
@@ -0,0 +1,161 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+WX_GTK_VER="2.8"
+PYTHON_COMPAT=( python2_7 )
+
+inherit cmake-utils eutils python-r1 wxwidgets toolchain-funcs virtualx
+
+DESCRIPTION="GNU Data Language"
+HOMEPAGE="http://gnudatalanguage.sourceforge.net/"
+SRC_URI="mirror://sourceforge/gnudatalanguage/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="+eigen fftw grib gshhs hdf hdf5 imagemagick netcdf openmp
+ proj postscript python static-libs udunits wxwidgets"
+
+RDEPEND="
+ sci-libs/gsl:0=
+ sci-libs/plplot:0=[-dynamic]
+ sys-libs/ncurses:5=
+ sys-libs/readline:0=
+ sys-libs/zlib:0=
+ x11-libs/libX11:0=
+ fftw? ( sci-libs/fftw:3.0= )
+ grib? ( sci-libs/grib_api:0= )
+ gshhs? ( sci-geosciences/gshhs-data sci-geosciences/gshhs:0= )
+ hdf? ( sci-libs/hdf:0= )
+ hdf5? ( sci-libs/hdf5:0= )
+ imagemagick? (
+ || (
+ media-gfx/graphicsmagick[cxx]
+ media-gfx/imagemagick[cxx]
+ )
+ )
+ netcdf? ( sci-libs/netcdf )
+ proj? ( sci-libs/proj )
+ postscript? ( dev-libs/pslib )
+ python? (
+ ${PYTHON_DEPS}
+ dev-python/numpy[${PYTHON_USEDEP}]
+ )
+ udunits? ( sci-libs/udunits )
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,-odbc] )"
+
+DEPEND="${RDEPEND}
+ >=dev-java/antlr-2.7.7-r5:0[cxx,java,script]
+ virtual/pkgconfig
+ eigen? ( dev-cpp/eigen:3 )"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+PATCHES=(
+ "${FILESDIR}"/0.9.2-antlr.patch
+ "${FILESDIR}"/0.9.2-include.patch
+ "${FILESDIR}"/0.9.2-proj4.patch
+ "${FILESDIR}"/0.9.2-semaphore.patch
+ "${FILESDIR}"/0.9.3-plwidth.patch
+ "${FILESDIR}"/0.9.4-gsl.patch
+ "${FILESDIR}"/0.9.4-python.patch
+ "${FILESDIR}"/0.9.4-reorder.patch
+ "${FILESDIR}"/0.9.4-plplot.patch
+ "${FILESDIR}"/0.9.4-python2.patch
+)
+
+pkg_setup() {
+ use openmp && [[ $(tc-getCXX)$ == *g++* ]] && ! tc-has-openmp && \
+ die "You have openmp enabled but your current g++ does not support it"
+}
+
+src_prepare() {
+ cmake-utils_src_prepare
+
+ use hdf5 && has_version sci-libs/hdf5[mpi] && export CXX=mpicxx
+
+ # make sure antlr includes are from system and rebuild the sources with it
+ # https://sourceforge.net/tracker/?func=detail&atid=618685&aid=3465878&group_id=97659
+ rm -r src/antlr || die
+ einfo "Regenerating grammar"
+ pushd src > /dev/null
+ local i
+ for i in *.g; do antlr ${i} || die ; done
+ popd > /dev/null
+
+ # gentoo: use proj instead of libproj4 (libproj4 last update: 2004)
+ sed -i \
+ -e 's:proj4:proj:' \
+ -e 's:lib_proj\.h:proj_api\.h:g' \
+ CMakeModules/FindLibproj4.cmake src/math_utl.hpp || die
+
+ # gentoo: avoid install files in datadir directory
+ sed -i \
+ -e '/AUTHORS/d' \
+ CMakeLists.txt || die
+}
+
+src_configure() {
+ # MPI is still very buggy
+ # x11=off does not compile
+ local mycmakeargs=(
+ -DMPICH=OFF
+ -DBUNDLED_ANTLR=OFF
+ -DX11=ON
+ $(cmake-utils_use fftw)
+ $(cmake-utils_use eigen EIGEN3)
+ $(cmake-utils_use grib)
+ $(cmake-utils_use gshhs)
+ $(cmake-utils_use hdf)
+ $(cmake-utils_use hdf5)
+ $(cmake-utils_use netcdf)
+ $(cmake-utils_use openmp)
+ $(cmake-utils_use proj LIBPROJ4)
+ $(cmake-utils_use postscript PSLIB)
+ $(cmake-utils_use udunits)
+ $(cmake-utils_use wxwidgets)
+ )
+ if use imagemagick; then
+ if has_version media-gfx/graphicsmagick[cxx]; then
+ mycmakeargs+=( -DGRAPHICSMAGICK=ON -DMAGICK=OFF )
+ else
+ mycmakeargs+=( -DGRAPHICSMAGICK=OFF -DMAGICK=ON )
+ fi
+ else
+ mycmakeargs+=( -DGRAPHICSMAGICK=OFF -DMAGICK=OFF )
+ fi
+ configuration() {
+ mycmakeargs+=( $@ )
+ cmake-utils_src_configure
+ }
+ configuration -DPYTHON_MODULE=OFF -DPYTHON=OFF
+ use python && python_foreach_impl configuration -DPYTHON_MODULE=ON -DPYTHON=ON
+}
+
+src_compile() {
+ cmake-utils_src_compile
+ use python && python_foreach_impl cmake-utils_src_make
+}
+
+src_test() {
+ # there is check target instead of the ctest to define some LDPATH
+ Xemake -C "${BUILD_DIR}" check
+}
+
+src_install() {
+ cmake-utils_src_install
+ if use python; then
+ installation() {
+ mv src/libgdl.so GDL.so || die
+ python_domodule GDL.so
+ }
+ python_foreach_impl run_in_build_dir installation
+ dodoc PYTHON.txt
+ fi
+
+ echo "GDL_PATH=\"+${EROOT%/}/usr/share/gnudatalanguage\"" > 50gdl
+ doenvd 50gdl
+}
diff --git a/dev-lang/gdl/gdl-0.9.5.ebuild b/dev-lang/gdl/gdl-0.9.5.ebuild
new file mode 100644
index 00000000000..1f195bab8ec
--- /dev/null
+++ b/dev-lang/gdl/gdl-0.9.5.ebuild
@@ -0,0 +1,156 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+WX_GTK_VER="2.8"
+PYTHON_COMPAT=( python2_7 )
+
+inherit cmake-utils eutils python-r1 wxwidgets toolchain-funcs virtualx
+
+DESCRIPTION="GNU Data Language"
+HOMEPAGE="http://gnudatalanguage.sourceforge.net/"
+SRC_URI="mirror://sourceforge/gnudatalanguage/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="+eigen fftw grib gshhs hdf hdf5 imagemagick netcdf openmp
+ png proj postscript python static-libs udunits wxwidgets"
+
+RDEPEND="
+ sci-libs/gsl:0=
+ sci-libs/plplot:0=[-dynamic]
+ sys-libs/ncurses:5=
+ sys-libs/readline:0=
+ sys-libs/zlib:0=
+ x11-libs/libX11:0=
+ fftw? ( sci-libs/fftw:3.0= )
+ grib? ( sci-libs/grib_api:0= )
+ gshhs? ( sci-geosciences/gshhs-data sci-geosciences/gshhs:0= )
+ hdf? ( sci-libs/hdf:0= )
+ hdf5? ( sci-libs/hdf5:0= )
+ imagemagick? (
+ || (
+ media-gfx/graphicsmagick[cxx]
+ media-gfx/imagemagick[cxx]
+ )
+ )
+ netcdf? ( sci-libs/netcdf )
+ proj? ( sci-libs/proj )
+ postscript? ( dev-libs/pslib )
+ python? (
+ ${PYTHON_DEPS}
+ dev-python/numpy[${PYTHON_USEDEP}]
+ )
+ udunits? ( sci-libs/udunits )
+ wxwidgets? ( x11-libs/wxGTK:2.8[X,-odbc] )"
+
+DEPEND="${RDEPEND}
+ >=dev-java/antlr-2.7.7-r5:0[cxx,java,script]
+ virtual/pkgconfig
+ eigen? ( dev-cpp/eigen:3 )"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+PATCHES=(
+ "${FILESDIR}"/0.9.5-antlr.patch
+ "${FILESDIR}"/0.9.2-include.patch
+ "${FILESDIR}"/0.9.5-plplot.patch
+ "${FILESDIR}"/0.9.5-png.patch
+)
+
+pkg_setup() {
+ use openmp && [[ $(tc-getCXX)$ == *g++* ]] && ! tc-has-openmp && \
+ die "You have openmp enabled but your current g++ does not support it"
+}
+
+src_prepare() {
+ cmake-utils_src_prepare
+
+ use hdf5 && has_version sci-libs/hdf5[mpi] && export CXX=mpicxx
+
+ # make sure antlr includes are from system and rebuild the sources with it
+ # https://sourceforge.net/tracker/?func=detail&atid=618685&aid=3465878&group_id=97659
+ rm -r src/antlr || die
+ einfo "Regenerating grammar"
+ pushd src > /dev/null
+ local i
+ for i in *.g; do antlr ${i} || die ; done
+ popd > /dev/null
+
+ # gentoo: use proj instead of libproj4 (libproj4 last update: 2004)
+ sed -i \
+ -e 's:proj4:proj:' \
+ -e 's:lib_proj\.h:proj_api\.h:g' \
+ CMakeModules/FindLibproj4.cmake src/math_utl.hpp || die
+
+ # gentoo: avoid install files in datadir directory
+ sed -i \
+ -e '/AUTHORS/d' \
+ CMakeLists.txt || die
+}
+
+src_configure() {
+ # MPI is still very buggy
+ # x11=off does not compile
+ local mycmakeargs=(
+ -DMPICH=OFF
+ -DBUNDLED_ANTLR=OFF
+ -DX11=ON
+ $(cmake-utils_use fftw)
+ $(cmake-utils_use eigen EIGEN3)
+ $(cmake-utils_use grib)
+ $(cmake-utils_use gshhs)
+ $(cmake-utils_use hdf)
+ $(cmake-utils_use hdf5)
+ $(cmake-utils_use netcdf)
+ $(cmake-utils_use openmp)
+ $(cmake-utils_use png PNGLIB)
+ $(cmake-utils_use proj LIBPROJ4)
+ $(cmake-utils_use postscript PSLIB)
+ $(cmake-utils_use udunits)
+ $(cmake-utils_use wxwidgets)
+ )
+ if use imagemagick; then
+ if has_version media-gfx/graphicsmagick[cxx]; then
+ mycmakeargs+=( -DGRAPHICSMAGICK=ON -DMAGICK=OFF )
+ else
+ mycmakeargs+=( -DGRAPHICSMAGICK=OFF -DMAGICK=ON )
+ fi
+ else
+ mycmakeargs+=( -DGRAPHICSMAGICK=OFF -DMAGICK=OFF )
+ fi
+ configuration() {
+ mycmakeargs+=( $@ )
+ cmake-utils_src_configure
+ }
+ configuration -DPYTHON_MODULE=OFF -DPYTHON=OFF
+ use python && python_foreach_impl configuration -DPYTHON_MODULE=ON -DPYTHON=ON
+}
+
+src_compile() {
+ cmake-utils_src_compile
+ use python && python_foreach_impl cmake-utils_src_make
+}
+
+src_test() {
+ # there is check target instead of the ctest to define some LDPATH
+ Xemake -C "${BUILD_DIR}" check
+}
+
+src_install() {
+ cmake-utils_src_install
+ if use python; then
+ installation() {
+ mv src/libgdl.so GDL.so || die
+ python_domodule GDL.so
+ }
+ python_foreach_impl run_in_build_dir installation
+ dodoc PYTHON.txt
+ fi
+
+ echo "GDL_PATH=\"+${EROOT%/}/usr/share/gnudatalanguage\"" > 50gdl
+ doenvd 50gdl
+}
diff --git a/dev-lang/gdl/metadata.xml b/dev-lang/gdl/metadata.xml
new file mode 100644
index 00000000000..8b80e5e849d
--- /dev/null
+++ b/dev-lang/gdl/metadata.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci</herd>
+ <longdescription lang="en">
+ A free IDL (Interactive Data Language) compatible incremental compiler
+ (ie. runs IDL programs). IDL is a registered trademark of ITT Visual
+ Information Solutions.
+</longdescription>
+ <use>
+ <flag name="eigen">Build matrix manipulation with <pkg>dev-cpp/eigen</pkg></flag>
+ <flag name="hdf">Add support for the Hierarchical Data Format v.4</flag>
+ <flag name="gshhs">Add support for projection adn continent maps with <pkg>sci-geosciences/gshhs-data</pkg></flag>
+ <flag name="grib">Add support for the meteorological GRIB format with <pkg>sci-libs/grib_api</pkg></flag>
+ <flag name="proj">Add support for <pkg>sci-libs/proj</pkg> (geographic projections)</flag>
+ <flag name="udunits">Add support for manipulating units of physical quantities</flag>
+ </use>
+ <upstream>
+ <remote-id type="sourceforge">gnudatalanguage</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-lang/gforth/Manifest b/dev-lang/gforth/Manifest
new file mode 100644
index 00000000000..c0c5e507f63
--- /dev/null
+++ b/dev-lang/gforth/Manifest
@@ -0,0 +1 @@
+DIST gforth-0.7.3.tar.gz 2523433 SHA256 2f62f2233bf022c23d01c920b1556aa13eab168e3236b13352ac5e9f18542bb0 SHA512 f034234acfb0fc727f28b564432219a100b916c6df4b847794a55b2fc3b8ed8714eca6de0df67c7c427b7c2bb4dd00f65cfd34e6eb60181e41ab84fea30304e4 WHIRLPOOL e16e1dfcccc1f02855da9f53407feaeca66fbe64586373aa4e8916c6b9f1dbbd023e4cd7908c8e943d0700c094dbd5e387f6c0b92492bf4e1ecc23692cc63932
diff --git a/dev-lang/gforth/files/0.6.2-c-to-forth-to-c.patch b/dev-lang/gforth/files/0.6.2-c-to-forth-to-c.patch
new file mode 100644
index 00000000000..28ab2e5f572
--- /dev/null
+++ b/dev-lang/gforth/files/0.6.2-c-to-forth-to-c.patch
@@ -0,0 +1,30 @@
+Index: engine/main.c
+===================================================================
+RCS file: /usr/local/lib/cvs-repository/src-master/gforth/engine/main.c,v
+retrieving revision 1.139
+retrieving revision 1.140
+diff -u -r1.139 -r1.140
+--- engine/main.c.old 2004/01/20 19:07:41 1.139
++++ engine/main.c 2004/04/10 00:16:55 1.140
+@@ -70,8 +70,21 @@
+
+ void engine_callback(Xt* fcall, void * alist)
+ {
++ /* save global valiables */
++ Cell *rp = RP;
++ Cell *sp = SP;
++ Float *fp = FP;
++ Address lp = LP;
++
+ clist = (va_alist)alist;
+- engine(fcall, SP, RP, FP, LP);
++
++ engine(fcall, sp, rp, fp, lp);
++
++ /* restore global variables */
++ RP = rp;
++ SP = sp;
++ FP = fp;
++ LP = lp;
+ }
+ #endif \ No newline at end of file
diff --git a/dev-lang/gforth/files/0.6.2-ppc-configure-gentoo.patch b/dev-lang/gforth/files/0.6.2-ppc-configure-gentoo.patch
new file mode 100644
index 00000000000..30061aa702f
--- /dev/null
+++ b/dev-lang/gforth/files/0.6.2-ppc-configure-gentoo.patch
@@ -0,0 +1,13 @@
+diff -ur gforth-0.6.2.orig/configure gforth-0.6.2/configure
+--- gforth-0.6.2.orig/configure 2003-08-25 03:03:42.000000000 -0500
++++ gforth-0.6.2/configure 2006-05-12 15:10:52.000000000 -0500
+@@ -3586,7 +3586,8 @@
+ fi
+
+ #long long is broken on (at least) gcc-2.95.* for PPC
+- test x$ac_cv_sizeof_long_long = x && ac_cv_sizeof_long_long=0
++ # XXX this was fixed long ago
++# test x$ac_cv_sizeof_long_long = x && ac_cv_sizeof_long_long=0
+ ;;
+ *)
+ { echo "$as_me:$LINENO: WARNING: Using a generic machine description" >&5
diff --git a/dev-lang/gforth/files/50gforth-gentoo.el b/dev-lang/gforth/files/50gforth-gentoo.el
new file mode 100644
index 00000000000..b2be92698bb
--- /dev/null
+++ b/dev-lang/gforth/files/50gforth-gentoo.el
@@ -0,0 +1,7 @@
+
+;;; gforth site-lisp configuration
+
+(add-to-list 'load-path "@SITELISP@")
+
+(autoload 'forth-mode "gforth" "Autoload for `forth-mode'." t)
+(autoload 'run-forth "gforth" "Autoload for `run-forth'." t)
diff --git a/dev-lang/gforth/files/gforth-0.7.0-make-elc.patch b/dev-lang/gforth/files/gforth-0.7.0-make-elc.patch
new file mode 100644
index 00000000000..fa558407c25
--- /dev/null
+++ b/dev-lang/gforth/files/gforth-0.7.0-make-elc.patch
@@ -0,0 +1,14 @@
+--- gforth-0.7.0-orig/Makefile.in
++++ gforth-0.7.0/Makefile.in
+@@ -430,7 +430,10 @@
+
+ ENGINES_FAST = gforth-fast$(OPT)$(EC)$(EXE) #gforth-native$(OPT)$(EC)$(EXE)
+
+-GEN = $(ENGINES) $(ENGINES_FAST) gforth.elc
++GEN = $(ENGINES) $(ENGINES_FAST)
++ifneq ($(emacssitelispdir), no)
++GEN += gforth.elc
++endif
+
+ # things that need a working forth system to be generated
+ FORTH_GEN_ENGINE=engine/prim.i engine/prim_lab.i engine/prim_names.i \
diff --git a/dev-lang/gforth/files/gforth.el-gentoo.patch b/dev-lang/gforth/files/gforth.el-gentoo.patch
new file mode 100644
index 00000000000..cc98537e766
--- /dev/null
+++ b/dev-lang/gforth/files/gforth.el-gentoo.patch
@@ -0,0 +1,37 @@
+--- gforth-0.6.2-orig/gforth.el 2003-08-05 11:12:47.000000000 +0200
++++ gforth-0.6.2/gforth.el 2008-09-06 08:29:44.000000000 +0200
+@@ -61,9 +61,10 @@
+ (progn (string-match "^[0-9]+" emacs-version)
+ (string-to-int (match-string 0 emacs-version)))))
+
+-(defun forth-emacs-older (major minor)
+- (or (< emacs-major-version major)
+- (and (= emacs-major-version major) (< emacs-minor-version minor))))
++(eval-when-compile
++ (defun forth-emacs-older (major minor)
++ (or (< emacs-major-version major)
++ (and (= emacs-major-version major) (< emacs-minor-version minor)))))
+
+ ;; Code ripped from `subr.el' for compatability with Emacs versions
+ ;; prior to 20.1
+@@ -79,8 +80,9 @@
+
+ ;; `no-error' argument of require not supported in Emacs versions
+ ;; prior to 20.4 :-(
+-(defun forth-require (feature)
+- (condition-case err (require feature) (error nil)))
++(eval-and-compile
++ (defun forth-require (feature)
++ (condition-case err (require feature) (error nil))))
+
+ (require 'font-lock)
+
+@@ -1702,6 +1704,6 @@
+ (error "No current process. See variable `forth-process-buffer'"))))
+ ) ; (memq 'comint features)
+
+-(provide 'forth-mode)
++(provide 'gforth)
+
+ ;;; gforth.el ends here
+
diff --git a/dev-lang/gforth/gforth-0.7.3.ebuild b/dev-lang/gforth/gforth-0.7.3.ebuild
new file mode 100644
index 00000000000..9b5acae069e
--- /dev/null
+++ b/dev-lang/gforth/gforth-0.7.3.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit elisp-common eutils
+
+DESCRIPTION="GNU Forth is a fast and portable implementation of the ANSI Forth language"
+HOMEPAGE="http://www.gnu.org/software/gforth"
+SRC_URI="mirror://gnu/gforth/${P}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd ~x86-freebsd ~x86-linux ~ppc-macos ~sparc-solaris"
+IUSE="emacs"
+
+DEPEND="dev-libs/ffcall
+ emacs? ( virtual/emacs )"
+RDEPEND="${DEPEND}"
+
+SITEFILE="50${PN}-gentoo.el"
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-0.7.0-make-elc.patch"
+ epatch_user
+}
+
+src_configure() {
+ # May want to add a USE flag for --enable-force-cdiv, if necessary
+ # At this point I do not know when that is appropriate, and I don't
+ # want to add an ebuild-specific USE flag without understanding.
+ econf \
+ --without-check \
+ $(use emacs || echo "--without-lispdir")
+}
+
+src_compile() {
+ # Parallel make breaks here
+ emake -j1 || die "emake failed"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+
+ dodoc AUTHORS BUGS ChangeLog NEWS* README* ToDo doc/glossaries.doc doc/*.ps
+
+ if use emacs; then
+ elisp-install ${PN} gforth.el gforth.elc
+ elisp-site-file-install "${FILESDIR}/${SITEFILE}"
+ fi
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
diff --git a/dev-lang/gforth/metadata.xml b/dev-lang/gforth/metadata.xml
new file mode 100644
index 00000000000..e0c579bfd1d
--- /dev/null
+++ b/dev-lang/gforth/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>proxy-maintainers</herd>
+ <maintainer>
+ <email>carsten@strotmann.de</email>
+ <name>Carsten Strotmann</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/dev-lang/ghc/Manifest b/dev-lang/ghc/Manifest
new file mode 100644
index 00000000000..7406de315e9
--- /dev/null
+++ b/dev-lang/ghc/Manifest
@@ -0,0 +1,34 @@
+DIST binary-0.7.5.0.tar.gz 45764 SHA256 4709c5aa7cc99cb4a465a68de1648968208d0c60c368e2fece476d977530ef19 SHA512 232e7c3da1c0055f3e9f211a86e81c76bc44ab1b70cabd23c93634dbaa42eed8bd9314fbedc16b9703d3ca92b0bbf232e6c30bb1384687dad0e6e85c9abb8947 WHIRLPOOL 1d8dcf9d5125ff398375f4024c0e43fa168004811db7824e2739ec5c0451b38dae9ad74f757c7708427deed0044580b182e35d1c7ecffec25f7b10c70bd32075
+DIST ghc-7.10.2-src.tar.bz2 12651156 SHA256 908a01ca86238318f4e880fda400ea399d0a0008d699c912b85d0e0f746e5689 SHA512 e3f99a9e848c12b728212da24bf9029ec8cde88cdfa7eeb4ee2ea223ad8bcaae3e7c27456d09d60a3d21efa8f907ccd2490caf5630ca5fe3ce87f04901275a66 WHIRLPOOL dee757e79de8ac6bcf127212703985282ce96d050be50e78c3f249f13dc0212c9fd96899502748ceb26b9fc3a804379a456e19a9bedfef72f6890992b00492da
+DIST ghc-7.4.2-src.tar.bz2 25836446 SHA256 f2ee1289a33cc70539287129841acc7eaf16112bb60c59b5a6ee91887bfd836d SHA512 5a3d06a36702fa7e337b482c9de92ce1f84a68f18d8560bcc11f3617d6d46f93167fee27e786de6483a9ef0eab3b1ac6909a71dd53908d36156df4e465075050 WHIRLPOOL 61865eed2bf92728e7c4c4a0c48be44081bf728cfd824760d643e2fad838d96c19e173052d3aac073e0795b5efa3720ba5ddf13cca1ec7952b7524bbe1f204bc
+DIST ghc-7.6.3-src.tar.bz2 110763823 SHA256 bd43823d31f6b5d0b2ca7b74151a8f98336ab0800be85f45bb591c9c26aac998 SHA512 ac86f18b4feeb0bdc9e867261600b210caf62740d73ae657259bbe8149b8c2c4f5a73d09d74d944d4e50f85cc87503485365f0a0ae65befe8d2b6844e5e1253a WHIRLPOOL 0fe1f5f2987699067494559e6a679d28f027eee8fb2a00c683161dbce5443b1faeebfb51572209b75231cee24c7f0c929cabbc82a93f70e16d05e351fdfe2eaf
+DIST ghc-7.8.3-src.tar.xz 9160092 SHA256 b0cd96a549ba3b5e512847a4a8cd1a3174e4b2b75dadfc41c568fb812887b958 SHA512 2cc8c2aa6f18ba565c1e2aa637045e246f1214c2a77e95c2a97dfb97203b8983e4ad3cc13178b4b51aff70c58d59a1f68f94cd813d043745cb02411bad04bb00 WHIRLPOOL 3a2e8eea0db7a150e4732efed488a3a5eb56da00a9a90a3379afcb4090323925a2a7485fec6676e784139f112d7c825e8d18a576c34c760af4a7f3adb22c021a
+DIST ghc-7.8.4-ia64-CLOSUREs-regenerated.patch.gz 13268 SHA256 3bdff22e654aee6f942d43edf1bf6cf70404c0152c4fcf89276f10d2c4c5b4b9 SHA512 a655713e06324b56f0041edf70837487e296d28e6f3ee35fe116b9938765aaf3469d25e92645e0940655ed3607dff27d3826fe0f995c84e81b51bfc956816e7d WHIRLPOOL d2cb53bdc6debc0278d554168ea3ab22b0fd8314adac81444637278a92d21b766280fedfb4b7d1b4540c7381c7962dec6b13a799ab2fee4d456fe2875d5c6a5b
+DIST ghc-7.8.4-src.tar.bz2 10600755 SHA256 59e3bd514a1820cc1c03e1808282205c0b8518369acae12645ceaf839e6f114b SHA512 079a53891d8ebd8d9b88da96170e60981608a619f8282e4b7948f35244e99bd87277649ac7fcebc227a61a4d21960db8d5e5b9e92f2c69c82d8d68d7fd0a41d3 WHIRLPOOL a9be7641adbd237ed6e0f644c312e655e98be9566097aee5e2c0022e8756d5b2236e42dd86d76c638a001b5ca3f67307e89ec0cd003a92cd112a5d6d3e3d8467
+DIST ghc-bin-7.10.2-amd64.tbz2 112028560 SHA256 536297ac402da44ec1aafb1a937960883d12d192db16715ca34ab6469773a4c7 SHA512 207d8032c99d52bf4215ddeea2dbcd5816bb8d4caf2c3c31190e3ca92b49667d98a4f97aaf4cd6b40090f150854d520f75b5420dfe1ade7f036cf35d3dcb5100 WHIRLPOOL 8e43956a61c2c0fead242e3b179cde4918c04f3db7dbb27cc986f00f981261d98028ead82548b87d183d8da928635d5db4aa62ff1161f4077e5370483530a316
+DIST ghc-bin-7.10.2-x86.tbz2 113900477 SHA256 eefb7a3002e3dcdd6d936b2b2826eadf3cd100352babad4c9a355b944064240a SHA512 61dae4b9c80bfef6b1e0550c77b70f25d11f4a9fbe3b57d6c4ad451b4b584884432405d39dc32b9f85f3a5ad9d02657356ae0ebd99518848f3d330314c74b595 WHIRLPOOL da0d7eb62d2ee2aeb80a3f495da2ff123e29151b7517fbcd212f83ab3722638f10019511f4f237e8e001c68dd957ed2817fb0f1a2b42c2710239343f1d801496
+DIST ghc-bin-7.4.2-alpha.tbz2 130483507 SHA256 cd8e72e569574f137bf10fcdb4337bb0dc320deb2a2c4d72529a821735c53ae6 SHA512 6fb99dea706965afa60f4aeb68da3da1c69dda477f5fcfb4e67b73d75b78583193148ce9f623a356679a57f1a740f8010f28a22f08e56ace50f3fcd42142f83f WHIRLPOOL e5ec69ab24dc963ac709f13928c0e35931d5d50ca6b21dfb0aa79f9088c0ce1196b64bb4d9668e35d73dcdf9e2df9c3da59c95eaf3db8b793a6bb65b1f4ba6c0
+DIST ghc-bin-7.4.2-amd64-stable-glibc.tbz2 93139900 SHA256 f06dff00585cc1a8ecc8ac29aeca7fdc601d272eed29d7613f7a2f2924cad585 SHA512 9b725f2613dd9013851a16eaea4000ea424c51cbafa97d3860f120fdb9936247f8c65208775a80a2f49b74946ddda2e843a54dec00b78c521197374aa3dd2d50 WHIRLPOOL 9e2630b1de40a059c324be38a1fe68b16ea484bc7afc2a397ea05192263d1964aed1d29fde543622ceab12ed2df111204576fdc72b7e35b2bbf9c6b9519901d1
+DIST ghc-bin-7.4.2-ia64.tbz2 155787636 SHA256 a1d89221645832cc5d11cde4937cce75d564e6a79eba334b92a4c465eb3f161f SHA512 c7138ed8eaf40ee7e7559b6063096351b64fc35cbd1adb4c734b2f2c6b77fb98368b1296fcb67c1a0b21b0faf053a82f8f98c3656b89c593e677ce78165d0c74 WHIRLPOOL 7ff2db2932a6d56961dcca386c9ec8f8eb1ee12e1b84230fbb089ff137eeb216117eecaa37b33b4c037ebee0063a07cd380077b754e64ef0219759b54a4f7fe2
+DIST ghc-bin-7.4.2-ppc.tbz2 89396808 SHA256 ebf6083a1f3256a978a9408cffa2562e837b641136e5d6ad41a8ab5c2f50e804 SHA512 d7abd4a2612f26b6937dd20c11d2081b2c846178347a8e09f4ef5d8b1ef2ad3eabb9d5429fd0c214f6c5bd53eb194ccf199745904d6b861650c9eef681a48bc1 WHIRLPOOL e2f8a4c8e3209432a744fd8587be39591d7b4fb026dca36755933f49e6f650e1b34e6087d9260aee65206a700f9d70e2fb6cbe42d29645b52f060729845a347e
+DIST ghc-bin-7.4.2-ppc64.tbz2 105431655 SHA256 d0aecf47749a9862085aec6403f25197465d99a02a3c721dffd5314bf81d74eb SHA512 f220fb91b1856da37f72166fe050d4908049845eec03626d09c5b6e88701b0002835c3343c3584baf9f9d9efb5c7cbc210eb64c6eb711a58764d0fea92e8ac9f WHIRLPOOL e27022a72c254fd189995fd1b39629d5328927b83237ae4e61e97ab5efb5c451c92fe77f944c724bf9d14130d5a6cd2e0896a7cd6052de1ef7091531aa39fa0f
+DIST ghc-bin-7.4.2-sparc.tbz2 121224130 SHA256 e5eaf1f31ddc4790e0226f0075236af340ec9674d98701452d5c51455ca1cb52 SHA512 a3647d82bbb36fe0ca55185ebc9479a264e785eb5a8a33be6c37b8a6cbcf8c55373374801c685eef004de78db5aa1c96760b2bedb2ca0ac9097d39fe286984e9 WHIRLPOOL d2d5f8c5abb001fb5425e68d3d26d941569b832c373e40b5a96aaa11f589db9e2b72eb1cbcf8df7b8d4473e2cc1c61498b284d8b006cc20822c3a203fd0fe2cd
+DIST ghc-bin-7.4.2-x86-stable-glibc.tbz2 92394017 SHA256 2c42257a60aec03ae622c1a600cd210a6094f26ac310fbd307006e7f2260e2a4 SHA512 9e8ef72d2aeb5681e6bb71e2eb875587ddd51089cfc3443c33c69f93274a29e5680de4bf4884af05cd84f0e9cea13d66d20f1e89994460137910cbc987b64359 WHIRLPOOL 5722824af91f1191e6a38a8eb4696e765468e3bf54ad411b1d387ae4bcc7cd4cb772bdf2054d7013a3cff41feaaf5607f051b3c0d9f609ca19f1a1f92dd02586
+DIST ghc-bin-7.6.3-amd64.tbz2 94441516 SHA256 3ef747e96a40c9d5021e88b8afee0a97838c27b00619d9187783d95279c31779 SHA512 89f6c693d83d6309a0e44fcc68e30279c858adb0a0ea9317dd168b2e632c22a8507da78ed953523f5d7156db98e06c6df56d6edc19c0c50b3941ea578263dc64 WHIRLPOOL 891dfbfc9d88fa579b6a837651f7cc6d9aecef8b8752ec7bcebbdfef2a6d8929d0edaceff27ec61d6160d36d1b0e8406b7829a04a858ed64210b5c57b9c98940
+DIST ghc-bin-7.6.3-r1-alpha.tbz2 123486983 SHA256 fb6828d9dff7b90563cc7b3277ed38801907930aebd6042a7e5ba61e5f50db73 SHA512 7821bdf7490283dc062be090d224138dd34641e014cc6742edaa51dcc9cb1de9724d575955b596c9273b878dfe79023daf172b132b124f67567132649cf9a30d WHIRLPOOL 4e51a7e7f54fcb4aeb7a4ade4140533413348f9aacf04f683fe7cc5e20843dc6a95bdd6d79a995e5e1085747be9e584df6ada61430662f06eb600abae0c7eabd
+DIST ghc-bin-7.6.3-r1-ia64.tbz2 154480728 SHA256 9a176312f796a189c0354deab9a7c446db274f75f40554963c2f86597a5951fb SHA512 2aa945cebcd3d0c26af5ddb53cf2002ec6d263d071173495905dd52898bd2ab6605370b0025554c1f6afbd28e276abc708708e4add9a9b8cb08b4bb39f8f50a1 WHIRLPOOL 6371531141e707618577e924c01102481a12d91e2c85e24694ba64f9b2545869c248999138146f63ca379a4243ccd0dfa322ea01a23d222b9757584787c5a899
+DIST ghc-bin-7.6.3-r1-ppc.tbz2 91800558 SHA256 c9b2262957585c9f02136014aa05423e1b7674c8eb0731a6d991e400e053e33a SHA512 2a101a30a4324780f1a614e044ba614f9094cd57d026c56f2b3ba514ae049c26ce8e4acbc89e93229da451b6fbe05ba0980b500cdd785bb2bce968a60434403a WHIRLPOOL 3a3b7e1eb945be01ab195880c7709514d2d11d25bab12fc15c2257207da48a37e6d6d7699c9ed5c1cc32d01057240a4d795e43cdf9d9d2748a1d94b93fb283ed
+DIST ghc-bin-7.6.3-r1-ppc64.tbz2 121213680 SHA256 7d820988a762dc56ec471c9fcb5510f2e0bb47560181aa7dea8a934e73952477 SHA512 17fb269a2eae326db927b8734cd8326061b059ecd50a377c51c37cd657380be1ae61964df299009259de6e4e00aa71a525a9224f8fa607d6cc7994c221848358 WHIRLPOOL 76e9664a535e6be54c5288be683959ab6aadafb04d03c5d2f08f8ee663868b3ed390e2a0c8e6d233a532af694709e03dc0f78d16dfe51b87e201655219da4704
+DIST ghc-bin-7.6.3-r1-sparc.tbz2 121641337 SHA256 0fb31b9584c1c6caafb44a51158bfd3d85c28d2313f8201855f58c019a1692c0 SHA512 d71efc47769efb091f93cb288b54a1fadfd4184053149b1cd7c219a0c9c95ed97c32b101c712e20643fea12546357b70a11f2852bebeac2141e961a3e4bf8764 WHIRLPOOL 37d320e01d8e43ecba6e90f8d0a9c440d30ea31ff79d9094a8205d9ce892570f81b8641080034215fdddf71131de1acc364e2a485383af8346190c36201c1e91
+DIST ghc-bin-7.6.3-x86.tbz2 93718672 SHA256 a55024f66a048437fcd6ef0f33cdb994a43628998a2f0fe4d094cc9ba83d1615 SHA512 624f2a3238dee15853018d45632d1363e42d34099a77e5e9ce5c8da976cb4c33578144f7c39dbf25ee68c17d8d42910db2347186849eeeda6bc20053ce2be990 WHIRLPOOL bc646fc19906b59416358fb7558b6e2c3f7ad069c2fcf443be36b621894cfcecb0844acf5b5f9c383e034dfff3e24d312a7da0d7a629836134ec5dc1ecd6f139
+DIST ghc-bin-7.8.3-amd64.tbz2 100786052 SHA256 af49f547336a4f9f13cd625155d5a6a998e52ae7da8bbbddc856f88b00b6aff4 SHA512 b1826095b67fa2028678057f70909bff4e082b82f3b70f1aedbc91073efad54334fa1864bc8248c9249eec6edab3671dc38ac1650be86f1245e2fecf92528952 WHIRLPOOL 5b44fff77a0d79c6f7c5c8ca792eb6b36987d1de58d5ebc0a9b05da9c19a2c312eca6b9d40e7e63437742b7f9c28c925feb3bea7f9803dda95fac7acaa7a3132
+DIST ghc-bin-7.8.3-x86.tbz2 102583755 SHA256 c67f0d2471e594b4fdfc5b219bb6b61e57e6ba75132aa3f63d171550af8cbe3c SHA512 badabbba2f46b5ab3a2601e53997ce6533162afeec7dc36eeb877a62680a9f599aeb05dd3682f45d3e273d71d28b8bd01eee37dcad3c7354e8f83b7be4e58536 WHIRLPOOL 7b99b6bbeb4ad6d203f270d8446285825ad0857a8ab058d8c126155b49e8819e0efc2f6c42b5ff775dc0ece5488e97fcc7ae2459fe87fdceef43d63a75443430
+DIST ghc-bin-7.8.4-alpha.tbz2 210691009 SHA256 23c9e5ef97b444fa87d3b9509a7b2b7b68c526ca4139739dd60c08fb1279d48a SHA512 f08230de82f0c4112da9d0b48227ca74d5d0b4a84046d746b023557b7aeeb9678f5ac037fe89a863178df4b9036e5c5c63182d14dfbb42c772011de883e3966f WHIRLPOOL d624b4d5eac8aa68f389b81e68d7fa2ea960c9b9c5fabb27ddf4da5140c18fd0ee9080725fb645e2c532bb0a01ade32da2cf6aac08707f9d89a94ea9752b8e72
+DIST ghc-bin-7.8.4-amd64.tbz2 100573133 SHA256 bd9d144c08caa0ff345ada8d7eed7592531b8f8b9ef2f94d0b9a42fd747440aa SHA512 e4416d6dae3c644f74bafb3aecf1a123f985427aba32d0e0c43143a137d64a9220fc5947cd9bde8a3bc44555ae71184fc06a3f7df7976aadd065ad5681b90954 WHIRLPOOL ab0bd6219d68e08cb473cf2f3f15538d65940f28e84f026361032c3a6bc09f7820faf67629e915f27c2afda7de41fa9c6010a1b5cd487df0936d968c7e58a3a4
+DIST ghc-bin-7.8.4-ia64.tbz2 222789275 SHA256 8bbbc11ba64d08bad691593afafc4c6a7cf078b10cf33cb8508bf0a0b3ccf523 SHA512 2d8b89e399cbe9bfeae29cf3ceea736bfaa65ea21483fa2ee95d9814e122fcfbb67ce22ad8175493fab088e9a9d0139610c67e9d5c8b4f797b5e14846df32b6e WHIRLPOOL 181d48bbb53d181c8febf63ddae620bec1a6c212a5b5bf938228689df2ff45ba68d7d4a99ebb1b68aa516d5633be41125321e3f8fdef6e5f0cd1e4a7f9b8774c
+DIST ghc-bin-7.8.4-ppc.tbz2 112803496 SHA256 a47e0fb17137878af1e7b5a166046bee20d456d49da6ba8cde990173f4b3be8d SHA512 9581f55a088e53edcc969960e45c9ad7227d71198ce2d241a4a066a138450a879287e55e7d2210e86143670539711387e36c7f60660c4422dc1b4122278fe4a0 WHIRLPOOL 4904414cbfafdb48f0539b071fe80568da74beb174948ee426da5c22acf1d0c35ade89d2e160ddd109d2fbc0a508459a8e249f3b732b88735070b9522b417108
+DIST ghc-bin-7.8.4-ppc64.tbz2 129284515 SHA256 1e8a350af39d1db1e58a74c9bc4a4c57765eceb33e5b32751fb31340b9ff02ff SHA512 53974e15c26cf6b62d8f838607abd209ec57cf0f45fcc48b90ad62736f5e4e7ff263dcd326ae03d8d5557a22eb9730e5eb8ae4eda55e52dd3d973bc73c84935e WHIRLPOOL adaaa92323d319f6576423ac41678f7d263f36e0e30d89fc14ee89104b006772c26d7b408be7f85225d1bddaf5f15ebdcbb7136f5c8bf7bda4bb0938eefbe6c2
+DIST ghc-bin-7.8.4-sparc.tbz2 147340595 SHA256 1cde749ce3c47016c5c7a7179423d0aa2b174ddae4af0392ae3b7f57b098ec0c SHA512 ee5f0b2f1cf2693a0f2be9df71ef61b52bc2327225d40b8be955c1584b9901ffc6aaab63c1e46bf9bb352633b605c98378f8fd3e6cd71aef1c089007e4110217 WHIRLPOOL 27d55a016ffb49852553f920c29929c3bdf383e28b4b806ceb9ffc8b46a59b438801101402e498b069aa6eb56870b70a00ba7b1f4098f3fd8d8ddf1b20caa626
+DIST ghc-bin-7.8.4-x86.tbz2 102312459 SHA256 4c53148836e5a1ba55b8db5bb7c3eb915103e0955fb503b2facdc5a72f12a974 SHA512 cabc5bd6d8760ce4120e7053f6c1dffca7d161ba454b6201087760096c037c932e3ff8c82e53346c8278855bf0cff1c2f5fb8046242ca4d8307355b060a9556e WHIRLPOOL 0171d67dc1b63381a491e1577a783eb0e8f53cb579ba96a9b4fdf6685d494d78eb2be780f77ff33422d3b7c320ed102d9b48f6e954f8fee5532982575001a4a5
+DIST hoopl-3.10.1.0.tar.gz 241582 SHA256 7af615dfd4051670dccf31e5a7e1e71a9ae5f301e6a0668557fd84f61f6bc2d4 SHA512 943fe7034c89f4f914617cf1bccf7f66c3e660328fbbd9ae40f78a3f78a4a5b6fdd86c2afd40c11d4c4c4a34bc8fd47ab7e6227cdf9f3f4887b5cc796720e7aa WHIRLPOOL 3a410081f70c4ebbb563a48d71ec6f1e226a13b965ea12d01ca521b32041308394c7da6d3b3e36e75d1322c188b81fc08f4b2bf6037df5d8ac4998a944326be2
+DIST transformers-0.4.3.0.tar.gz 28632 SHA256 b3d0a797e815ca50d411e20c02f781efe7751308007d880af7f0b5c4365c3a9d SHA512 c3ec0893ebba4fbd6087c3202e919552c4a9bff3350b5c0589e7ebb18751a515d98b8cac15b0a3252906ea72b5a0eb09b7fe88c8da88b09d6ce4fbf0f50b2780 WHIRLPOOL 89591781926b1d025056dedcfc5de61705056c1e3a8eba72f2e89789e78d2ed4d8909f84d6560dfc66bc0b360f98cb3dc3835f3a05c2325f747498373c88aa4b
diff --git a/dev-lang/ghc/files/ghc-7.0.4-CHOST-prefix.patch b/dev-lang/ghc/files/ghc-7.0.4-CHOST-prefix.patch
new file mode 100644
index 00000000000..682c573c90a
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.0.4-CHOST-prefix.patch
@@ -0,0 +1,17 @@
+Strip versioning components from *HOST for Darwin and Solaris
+
+--- aclocal.m4
++++ aclocal.m4
+@@ -1358,6 +1358,12 @@
+ freebsd*)
+ $2="freebsd"
+ ;;
++ darwin*)
++ $2="darwin"
++ ;;
++ solaris2.*)
++ $2="solaris2"
++ ;;
+ *)
+ echo "Unknown OS $1"
+ exit 1
diff --git a/dev-lang/ghc/files/ghc-7.0.4-darwin8.patch b/dev-lang/ghc/files/ghc-7.0.4-darwin8.patch
new file mode 100644
index 00000000000..bfbee41b4f9
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.0.4-darwin8.patch
@@ -0,0 +1,18 @@
+Workaround headers problem in Darwin 8 as well.
+
+--- rts/PosixSource.h
++++ rts/PosixSource.h
+@@ -11,6 +11,13 @@
+
+ #include <ghcplatform.h>
+
++#if defined(darwin_HOST_OS)
++/* unfortunately the hack below only works for Darwin 9 and
++ * above, so as hack include sys/types early (before setting
++ * _POSIX_C_SOURCE) (this obviously obsoletes the hack below) */
++#include <sys/types.h>
++#endif
++
+ #if defined(freebsd_HOST_OS)
+ #define _POSIX_C_SOURCE 200112L
+ #define _XOPEN_SOURCE 600
diff --git a/dev-lang/ghc/files/ghc-7.10.1-T10590-dequeue.patch b/dev-lang/ghc/files/ghc-7.10.1-T10590-dequeue.patch
new file mode 100644
index 00000000000..be0f7a05b1e
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.10.1-T10590-dequeue.patch
@@ -0,0 +1,89 @@
+diff --git a/rts/RaiseAsync.c b/rts/RaiseAsync.c
+index 3b206ff..08c031c 100644
+--- a/rts/RaiseAsync.c
++++ b/rts/RaiseAsync.c
+@@ -56,7 +56,8 @@ static void throwToSendMsg (Capability *cap USED_IF_THREADS,
+
+ static void
+ throwToSingleThreaded__ (Capability *cap, StgTSO *tso, StgClosure *exception,
+- rtsBool stop_at_atomically, StgUpdateFrame *stop_here)
++ rtsBool stop_at_atomically, StgUpdateFrame *stop_here,
++ rtsBool dequeue)
+ {
+ // Thread already dead?
+ if (tso->what_next == ThreadComplete || tso->what_next == ThreadKilled) {
+@@ -64,7 +65,9 @@ throwToSingleThreaded__ (Capability *cap, StgTSO *tso, StgClosure *exception,
+ }
+
+ // Remove it from any blocking queues
+- removeFromQueues(cap,tso);
++ if (dequeue) {
++ removeFromQueues(cap,tso);
++ }
+
+ raiseAsync(cap, tso, exception, stop_at_atomically, stop_here);
+ }
+@@ -72,20 +75,26 @@ throwToSingleThreaded__ (Capability *cap, StgTSO *tso, StgClosure *exception,
+ void
+ throwToSingleThreaded (Capability *cap, StgTSO *tso, StgClosure *exception)
+ {
+- throwToSingleThreaded__(cap, tso, exception, rtsFalse, NULL);
++ throwToSingleThreaded__(cap, tso, exception, rtsFalse, NULL, rtsTrue);
++}
++
++void
++throwToSingleThreadedNoDequeue (Capability *cap, StgTSO *tso, StgClosure *exception)
++{
++ throwToSingleThreaded__(cap, tso, exception, rtsFalse, NULL, rtsFalse);
+ }
+
+ void
+ throwToSingleThreaded_ (Capability *cap, StgTSO *tso, StgClosure *exception,
+ rtsBool stop_at_atomically)
+ {
+- throwToSingleThreaded__ (cap, tso, exception, stop_at_atomically, NULL);
++ throwToSingleThreaded__ (cap, tso, exception, stop_at_atomically, NULL, rtsTrue);
+ }
+
+ void // cannot return a different TSO
+ suspendComputation (Capability *cap, StgTSO *tso, StgUpdateFrame *stop_here)
+ {
+- throwToSingleThreaded__ (cap, tso, NULL, rtsFalse, stop_here);
++ throwToSingleThreaded__ (cap, tso, NULL, rtsFalse, stop_here, rtsTrue);
+ }
+
+ /* -----------------------------------------------------------------------------
+diff --git a/rts/RaiseAsync.h b/rts/RaiseAsync.h
+index 6bfed8d..2e8a7a3 100644
+--- a/rts/RaiseAsync.h
++++ b/rts/RaiseAsync.h
+@@ -23,6 +23,10 @@ void throwToSingleThreaded (Capability *cap,
+ StgTSO *tso,
+ StgClosure *exception);
+
++void throwToSingleThreadedNoDequeue (Capability *cap,
++ StgTSO *tso,
++ StgClosure *exception);
++
+ void throwToSingleThreaded_ (Capability *cap,
+ StgTSO *tso,
+ StgClosure *exception,
+diff --git a/rts/posix/Select.c b/rts/posix/Select.c
+index 4b19235..6889499 100644
+--- a/rts/posix/Select.c
++++ b/rts/posix/Select.c
+@@ -412,8 +412,12 @@ awaitEvent(rtsBool wait)
+ IF_DEBUG(scheduler,
+ debugBelch("Killing blocked thread %lu on bad fd=%i\n",
+ (unsigned long)tso->id, fd));
+- throwToSingleThreaded(&MainCapability, tso,
+- (StgClosure *)blockedOnBadFD_closure);
++ /*
++ * We can't use throwToSingleThreaded() here
++ * as 'RTS_FD_IS_READY' breaks blocked_queue_hd list
++ */
++ throwToSingleThreadedNoDequeue(&MainCapability, tso,
++ (StgClosure *)blockedOnBadFD_closure);
+ break;
+ case RTS_FD_IS_READY:
+ IF_DEBUG(scheduler,
diff --git a/dev-lang/ghc/files/ghc-7.10.1-rc3-ghc-7.10-bootstrap.patch b/dev-lang/ghc/files/ghc-7.10.1-rc3-ghc-7.10-bootstrap.patch
new file mode 100644
index 00000000000..60db34b8b36
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.10.1-rc3-ghc-7.10-bootstrap.patch
@@ -0,0 +1,78 @@
+--- ghc-7.10.0.20150316-orig/compiler/utils/Pair.hs 2015-03-10 05:43:13.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/utils/Pair.hs 2015-03-17 09:50:48.491115080 +1100
+@@ -15,6 +15,8 @@
+ import Data.Foldable
+ import Data.Monoid
+ import Data.Traversable
++#else
++import Control.Applicative ((<$>))
+ #endif
+
+ data Pair a = Pair { pFst :: a, pSnd :: a }
+--- ghc-7.10.0.20150316-orig/compiler/types/Coercion.hs 2015-03-10 05:43:13.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/types/Coercion.hs 2015-03-17 10:11:21.636047380 +1100
+@@ -104,6 +104,8 @@
+ #if __GLASGOW_HASKELL__ < 709
+ import Control.Applicative hiding ( empty )
+ import Data.Traversable (traverse, sequenceA)
++#else
++import Control.Applicative ((<$>))
+ #endif
+ import FastString
+ import ListSetOps
+--- ghc-7.10.0.20150316-orig/compiler/typecheck/TcEvidence.hs 2015-03-14 08:48:57.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/typecheck/TcEvidence.hs 2015-03-17 10:26:03.251433371 +1100
+@@ -50,6 +50,8 @@
+ #if __GLASGOW_HASKELL__ < 709
+ import Control.Applicative
+ import Data.Traversable (traverse, sequenceA)
++#else
++import Control.Applicative ((<$>))
+ #endif
+ import qualified Data.Data as Data
+ import Outputable
+--- ghc-7.10.0.20150316-orig/compiler/hsSyn/HsBinds.hs 2015-03-10 05:43:13.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/hsSyn/HsBinds.hs 2015-03-17 10:42:21.459519033 +1100
+@@ -47,6 +47,8 @@
+ import Data.Traversable ( Traversable(..) )
+ import Data.Monoid ( mappend )
+ import Control.Applicative hiding (empty)
++#else
++import Control.Applicative ((<$>))
+ #endif
+
+ {-
+--- ghc-7.10.0.20150316-orig/compiler/parser/RdrHsSyn.hs 2015-03-10 05:43:13.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/parser/RdrHsSyn.hs 2015-03-17 11:17:48.950929542 +1100
+@@ -91,9 +91,7 @@
+ import Util
+ import ApiAnnotation
+
+-#if __GLASGOW_HASKELL__ < 709
+ import Control.Applicative ((<$>))
+-#endif
+ import Control.Monad
+
+ import Text.ParserCombinators.ReadP as ReadP
+--- ghc-7.10.0.20150316-orig/compiler/typecheck/TcGenDeriv.hs 2015-03-14 08:48:57.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/typecheck/TcGenDeriv.hs 2015-03-17 11:30:39.106508173 +1100
+@@ -59,6 +59,8 @@
+ import Var
+ #if __GLASGOW_HASKELL__ < 709
+ import MonadUtils
++#else
++import Control.Applicative ((<$>))
+ #endif
+ import Outputable
+ import Lexeme
+--- ghc-7.10.0.20150316-orig/compiler/vectorise/Vectorise/Exp.hs 2015-03-10 05:43:13.000000000 +1100
++++ ghc-7.10.0.20150316/compiler/vectorise/Vectorise/Exp.hs 2015-03-17 11:46:41.829481669 +1100
+@@ -46,6 +46,8 @@
+ import Util
+ #if __GLASGOW_HASKELL__ < 709
+ import MonadUtils
++#else
++import Control.Applicative ((<$>))
+ #endif
+
+ import Control.Monad
diff --git a/dev-lang/ghc/files/ghc-7.2.1-freebsd-CHOST.patch b/dev-lang/ghc/files/ghc-7.2.1-freebsd-CHOST.patch
new file mode 100644
index 00000000000..da59cd789f9
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.2.1-freebsd-CHOST.patch
@@ -0,0 +1,13 @@
+diff --git a/aclocal.m4 b/aclocal.m4
+index 11bb003..52df243 100644
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -1545,7 +1545,7 @@ case "$1" in
+ freebsd|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku)
+ $2="$1"
+ ;;
+- freebsd8) # like i686-gentoo-freebsd8
++ freebsd*) # like i686-gentoo-freebsd8 or i686-gentoo-freebsd8.2
+ $2="freebsd"
+ ;;
+ darwin*)
diff --git a/dev-lang/ghc/files/ghc-7.4-rc2-macos-prefix-respect-gcc.patch b/dev-lang/ghc/files/ghc-7.4-rc2-macos-prefix-respect-gcc.patch
new file mode 100644
index 00000000000..770fd650606
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.4-rc2-macos-prefix-respect-gcc.patch
@@ -0,0 +1,23 @@
+diff --git a/aclocal.m4 b/aclocal.m4
+index a377cb9..4f8fd69 100644
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -1950,17 +1950,7 @@ AC_DEFUN([XCODE_VERSION],[
+ # --------------------------------
+ # Finds where gcc is
+ AC_DEFUN([FIND_GCC],[
+- if test "$TargetOS_CPP" = "darwin" &&
+- test "$XCodeVersion1" -eq 4 &&
+- test "$XCodeVersion2" -lt 2
+- then
+- # In Xcode 4.1, 'gcc-4.2' is the gcc legacy backend (rather
+- # than the LLVM backend). We prefer the legacy gcc, but in
+- # Xcode 4.2 'gcc-4.2' was removed.
+- FP_ARG_WITH_PATH_GNU_PROG([CC], [gcc-4.2])
+- else
+- FP_ARG_WITH_PATH_GNU_PROG([CC], [gcc])
+- fi
++ FP_ARG_WITH_PATH_GNU_PROG([CC], [gcc])
+ export CC
+ WhatGccIsCalled="$CC"
+ AC_SUBST(WhatGccIsCalled)
diff --git a/dev-lang/ghc/files/ghc-7.4.1-darwin-CHOST.patch b/dev-lang/ghc/files/ghc-7.4.1-darwin-CHOST.patch
new file mode 100644
index 00000000000..348158882aa
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.4.1-darwin-CHOST.patch
@@ -0,0 +1,18 @@
+like the other CHOST patches, but this one catches another case where
+$host is used (instead of the cannonicalised variables)
+
+--- aclocal.m4
++++ aclocal.m4
+@@ -93,10 +93,10 @@
+ exeext='.exe'
+ soext='.dll'
+ ;;
+- i386-apple-darwin|powerpc-apple-darwin)
++ i386-apple-darwin*|powerpc-apple-darwin*)
+ soext='.dylib'
+ ;;
+- x86_64-apple-darwin)
++ x86_64-apple-darwin*)
+ soext='.dylib'
+ ;;
+ esac
diff --git a/dev-lang/ghc/files/ghc-7.4.1-ticket-7339-fix-unaligned-unreg.patch b/dev-lang/ghc/files/ghc-7.4.1-ticket-7339-fix-unaligned-unreg.patch
new file mode 100644
index 00000000000..f2f19f1bbab
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.4.1-ticket-7339-fix-unaligned-unreg.patch
@@ -0,0 +1,28 @@
+From 26f8466507bd9383e0a7d1e62e397eca4a13822a Mon Sep 17 00:00:00 2001
+From: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Tue, 13 Nov 2012 01:39:14 +0300
+Subject: [PATCH] Fix unaligned access on alpha and friends (ticket #7339)
+
+Assume unknown arch (alpha and mips) an alignment sensitive target.
+Otherwise on alpha it causes ghc-7.4.1 to generate invalud lexers.
+
+Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+---
+ compiler/cmm/PprC.hs | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/compiler/cmm/PprC.hs b/compiler/cmm/PprC.hs
+index 21826f8..8cdcde6 100644
+--- a/compiler/cmm/PprC.hs
++++ b/compiler/cmm/PprC.hs
+@@ -963,6 +963,7 @@ cLoad platform expr rep
+ | otherwise
+ = char '*' <> parens (cCast platform (machRepPtrCType rep) expr)
+ where -- On these platforms, unaligned loads are known to cause problems
++ bewareLoadStoreAlignment ArchUnknown = True -- like alpha or mips
+ bewareLoadStoreAlignment (ArchARM {}) = True
+ bewareLoadStoreAlignment _ = False
+
+--
+1.8.0
+
diff --git a/dev-lang/ghc/files/ghc-7.4.2-system-libffi.patch b/dev-lang/ghc/files/ghc-7.4.2-system-libffi.patch
new file mode 100644
index 00000000000..73c4aa278dd
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.4.2-system-libffi.patch
@@ -0,0 +1,119 @@
+Make ghc use the libffi installed on the system instead of the bundled one.
+
+This patch is based on the one used by Debian and Fedora, but was
+augmented by additional lines to identify the libffi include directory
+using pkg-config, as libffi on Gentoo installs into a subdirectory of
+the system include directory.
+
+2012-04-24 Martin von Gagern
+
+References:
+https://bugs.gentoo.org/411925
+http://hackage.haskell.org/trac/ghc/ticket/5743
+
+Index: ghc-7.4.1/ghc.mk
+===================================================================
+--- ghc-7.4.1.orig/ghc.mk
++++ ghc-7.4.1/ghc.mk
+@@ -579,7 +579,6 @@ BUILD_DIRS += \
+ driver/ghci \
+ driver/ghc \
+ driver/haddock \
+- libffi \
+ includes \
+ rts
+
+Index: ghc-7.4.1/rts/ghc.mk
+===================================================================
+--- ghc-7.4.1.orig/rts/ghc.mk
++++ ghc-7.4.1/rts/ghc.mk
+@@ -86,8 +86,7 @@
+ ALL_RTS_DEF_LIBNAMES = base ghc-prim
+ ALL_RTS_DEF_LIBS = \
+ rts/dist/build/win32/libHSbase.dll.a \
+- rts/dist/build/win32/libHSghc-prim.dll.a \
+- libffi/build/inst/lib/libffi.dll.a
++ rts/dist/build/win32/libHSghc-prim.dll.a
+
+ # -- import libs for the regular Haskell libraries
+ define make-importlib-def # args $1 = lib name
+@@ -172,12 +171,12 @@
+ # Making a shared library for the RTS.
+ ifneq "$$(findstring dyn, $1)" ""
+ ifeq "$$(HOSTPLATFORM)" "i386-unknown-mingw32"
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) rts/libs.depend rts/dist/build/libffi-5.dll
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) rts/libs.depend
+ "$$(RM)" $$(RM_OPTS) $$@
+ "$$(rts_dist_HC)" -package-name rts -shared -dynamic -dynload deploy \
+ -no-auto-link-packages -Lrts/dist/build -lffi-5 `cat rts/libs.depend` $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) -o $$@
+ else
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) rts/libs.depend rts/dist/build/libffi$$(soext)
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) rts/libs.depend
+ "$$(RM)" $$(RM_OPTS) $$@
+ "$$(rts_dist_HC)" -package-name rts -shared -dynamic -dynload deploy \
+ -no-auto-link-packages -Lrts/dist/build -lffi `cat rts/libs.depend` $$(rts_$1_OBJS) \
+@@ -188,9 +187,9 @@
+ endif
+ endif
+ else
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) $$(rts_ffi_objs_stamp)
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS)
+ "$$(RM)" $$(RM_OPTS) $$@
+- echo $$(rts_ffi_objs) $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) | "$$(XARGS)" $$(XARGS_OPTS) "$$(AR_STAGE1)" \
++ echo $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) | "$$(XARGS)" $$(XARGS_OPTS) "$$(AR_STAGE1)" \
+ $$(AR_OPTS_STAGE1) $$(EXTRA_AR_ARGS_STAGE1) $$@
+ endif
+
+@@ -403,6 +402,12 @@
+ rts/dist/build/sm/Evac_thr_CC_OPTS += -DPARALLEL_GC -Irts/sm
+ rts/dist/build/sm/Scav_thr_CC_OPTS += -DPARALLEL_GC -Irts/sm
+
++# Use system libffi
++libffi_include_flags:=$(shell pkg-config --cflags-only-I libffi)
++rts/Adjustor_CC_OPTS += $(libffi_include_flags)
++rts/Interpreter_CC_OPTS += $(libffi_include_flags)
++rts/sm/Storage_CC_OPTS += $(libffi_include_flags)
++
+ #-----------------------------------------------------------------------------
+ # Add PAPI library if needed
+
+@@ -504,10 +509,8 @@
+ # installing
+
+ INSTALL_LIBS += $(ALL_RTS_LIBS)
+-INSTALL_LIBS += $(wildcard rts/dist/build/libffi$(soext)*)
+-INSTALL_LIBS += $(wildcard rts/dist/build/libffi-5.dll)
+
+-install: install_libffi_headers
++install:
+
+ .PHONY: install_libffi_headers
+ install_libffi_headers :
+Index: ghc-7.4.1/rts/package.conf.in
+===================================================================
+--- ghc-7.4.1.orig/rts/package.conf.in
++++ ghc-7.4.1/rts/package.conf.in
+@@ -24,8 +24,9 @@
+ hs-libraries: "HSrts"
+
+ extra-libraries:
++ "ffi"
+ #ifdef HAVE_LIBM
+- "m" /* for ldexp() */
++ , "m" /* for ldexp() */
+ #endif
+ #ifdef HAVE_LIBRT
+ , "rt"
+Index: ghc-7.4.1/compiler/ghc.mk
+===================================================================
+--- ghc-7.4.1.orig/compiler/ghc.mk
++++ ghc-7.4.1/compiler/ghc.mk
+@@ -260,6 +260,8 @@
+
+ compiler_CPP_OPTS += -I$(GHC_INCLUDE_DIR)
+ compiler_CPP_OPTS += ${GhcCppOpts}
++libffi_include_flags := $(shell pkg-config --cflags-only-I libffi)
++compiler/ghci/LibFFI_HSC2HS_OPTS += $(addprefix --cflag=,$(libffi_include_flags))
+
+ $(PRIMOPS_TXT) compiler/parser/Parser.y: %: %.pp compiler/stage1/$(PLATFORM_H)
+ $(CPP) $(RAWCPP_FLAGS) -P $(compiler_CPP_OPTS) -x c $< | grep -v '^#pragma GCC' > $@
diff --git a/dev-lang/ghc/files/ghc-7.5.20120505-system-libffi.patch b/dev-lang/ghc/files/ghc-7.5.20120505-system-libffi.patch
new file mode 100644
index 00000000000..f3b0c71c545
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.5.20120505-system-libffi.patch
@@ -0,0 +1,88 @@
+--- ghc-7.5.20120505-orig/ghc.mk 2012-05-06 03:01:29.000000000 +1000
++++ ghc-7.5.20120505/ghc.mk 2012-05-06 17:22:01.023416003 +1000
+@@ -584,7 +584,6 @@
+ $(MAYBE_GHCI) \
+ driver/ghc \
+ driver/haddock \
+- libffi \
+ includes \
+ rts
+
+--- ghc-7.5.20120505-orig/rts/ghc.mk 2012-05-06 03:01:30.000000000 +1000
++++ ghc-7.5.20120505/rts/ghc.mk 2012-05-06 17:28:31.925897226 +1000
+@@ -171,12 +171,12 @@
+ # Making a shared library for the RTS.
+ ifneq "$$(findstring dyn, $1)" ""
+ ifeq "$$(HostOS_CPP)" "mingw32"
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) rts/libs.depend rts/dist/build/$$(LIBFFI_DLL)
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) rts/libs.depend
+ "$$(RM)" $$(RM_OPTS) $$@
+ "$$(rts_dist_HC)" -package-name rts -shared -dynamic -dynload deploy \
+ -no-auto-link-packages -Lrts/dist/build -l$(LIBFFI_WINDOWS_LIB) `cat rts/libs.depend` $$(rts_$1_OBJS) $$(ALL_RTS_DEF_LIBS) -o $$@
+ else
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) rts/libs.depend rts/dist/build/libffi$$(soext)
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) rts/libs.depend
+ "$$(RM)" $$(RM_OPTS) $$@
+ "$$(rts_dist_HC)" -package-name rts -shared -dynamic -dynload deploy \
+ -no-auto-link-packages -Lrts/dist/build -lffi `cat rts/libs.depend` $$(rts_$1_OBJS) \
+@@ -187,9 +187,9 @@
+ endif
+ endif
+ else
+-$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) $$(rts_ffi_objs_stamp)
++$$(rts_$1_LIB) : $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS)
+ "$$(RM)" $$(RM_OPTS) $$@
+- echo $$(rts_ffi_objs) $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) | "$$(XARGS)" $$(XARGS_OPTS) "$$(AR_STAGE1)" \
++ echo $$(rts_$1_OBJS) $$(rts_$1_DTRACE_OBJS) | "$$(XARGS)" $$(XARGS_OPTS) "$$(AR_STAGE1)" \
+ $$(AR_OPTS_STAGE1) $$(EXTRA_AR_ARGS_STAGE1) $$@
+ endif
+
+@@ -407,6 +407,12 @@
+ rts/dist/build/sm/Evac_thr_CC_OPTS += -DPARALLEL_GC -Irts/sm
+ rts/dist/build/sm/Scav_thr_CC_OPTS += -DPARALLEL_GC -Irts/sm
+
++# Use system libffi
++libffi_include_flags:=$(shell pkg-config --cflags-only-I libffi)
++rts/Adjustor_CC_OPTS += $(libffi_include_flags)
++rts/Interpreter_CC_OPTS += $(libffi_include_flags)
++rts/sm/Storage_CC_OPTS += $(libffi_include_flags)
++
+ #-----------------------------------------------------------------------------
+ # Add PAPI library if needed
+
+@@ -508,10 +514,8 @@
+ # installing
+
+ INSTALL_LIBS += $(ALL_RTS_LIBS)
+-INSTALL_LIBS += $(wildcard rts/dist/build/libffi$(soext)*)
+-INSTALL_LIBS += $(wildcard rts/dist/build/$(LIBFFI_DLL))
+
+-install: install_libffi_headers
++install:
+
+ .PHONY: install_libffi_headers
+ install_libffi_headers :
+--- ghc-7.5.20120505-orig/rts/package.conf.in 2012-05-06 03:01:30.000000000 +1000
++++ ghc-7.5.20120505/rts/package.conf.in 2012-05-06 17:22:01.025416056 +1000
+@@ -24,8 +24,9 @@
+ hs-libraries: "HSrts"
+
+ extra-libraries:
++ "ffi"
+ #ifdef HAVE_LIBM
+- "m" /* for ldexp() */
++ , "m" /* for ldexp() */
+ #endif
+ #ifdef HAVE_LIBRT
+ , "rt"
+--- ghc-7.5.20120505-orig/compiler/ghc.mk 2012-05-06 03:01:29.000000000 +1000
++++ ghc-7.5.20120505/compiler/ghc.mk 2012-05-06 17:22:01.026416083 +1000
+@@ -260,6 +260,8 @@
+
+ compiler_CPP_OPTS += $(addprefix -I,$(GHC_INCLUDE_DIRS))
+ compiler_CPP_OPTS += ${GhcCppOpts}
++libffi_include_flags := $(shell pkg-config --cflags-only-I libffi)
++compiler/ghci/LibFFI_HSC2HS_OPTS += $(addprefix --cflag=,$(libffi_include_flags))
+
+ $(PRIMOPS_TXT) compiler/parser/Parser.y: %: %.pp compiler/stage1/$(PLATFORM_H)
+ $(CPP) $(RAWCPP_FLAGS) -P $(compiler_CPP_OPTS) -x c $< | grep -v '^#pragma GCC' > $@
diff --git a/dev-lang/ghc/files/ghc-7.6.2-integer-simple-div-mod.patch b/dev-lang/ghc/files/ghc-7.6.2-integer-simple-div-mod.patch
new file mode 100644
index 00000000000..0dc5391678f
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.6.2-integer-simple-div-mod.patch
@@ -0,0 +1,57 @@
+commit de13417726b90b0945aaaf0b9cfbaf8ab975d8b5
+Author: Gabor Greif <ggreif@gmail.com>
+Date: Tue Jul 24 14:31:36 2012 +0200
+
+ track integer-gmp and add 'divInteger', 'modInteger'
+
+diff --git a/libraries/integer-simple/GHC/Integer.hs b/libraries/integer-simple/GHC/Integer.hs
+index c9b50a7..4122d38 100644
+--- a/libraries/integer-simple/GHC/Integer.hs
++++ b/libraries/integer-simple/GHC/Integer.hs
+@@ -4,7 +4,7 @@
+ -----------------------------------------------------------------------------
+ -- |
+ -- Module : GHC.Integer
+--- Copyright : (c) Ian Lynagh 2007-2008
++-- Copyright : (c) Ian Lynagh 2007-2012
+ -- License : BSD3
+ --
+ -- Maintainer : igloo@earth.li
+@@ -27,6 +27,7 @@ module GHC.Integer (
+ plusInteger, minusInteger, timesInteger, negateInteger,
+ eqInteger, neqInteger, absInteger, signumInteger,
+ leInteger, gtInteger, ltInteger, geInteger, compareInteger,
++ divInteger, modInteger,
+ divModInteger, quotRemInteger, quotInteger, remInteger,
+ encodeFloatInteger, decodeFloatInteger, floatFromInteger,
+ encodeDoubleInteger, decodeDoubleInteger, doubleFromInteger,
+diff --git a/libraries/integer-simple/GHC/Integer/Type.hs b/libraries/integer-simple/GHC/Integer/Type.hs
+index c3d812c..67ed19c 100644
+--- a/libraries/integer-simple/GHC/Integer/Type.hs
++++ b/libraries/integer-simple/GHC/Integer/Type.hs
+@@ -7,7 +7,7 @@
+ -----------------------------------------------------------------------------
+ -- |
+ -- Module : GHC.Integer.Type
+--- Copyright : (c) Ian Lynagh 2007-2008
++-- Copyright : (c) Ian Lynagh 2007-2012
+ -- License : BSD3
+ --
+ -- Maintainer : igloo@earth.li
+@@ -370,6 +370,16 @@ n `divModInteger` d =
+ then (# q `minusInteger` oneInteger, r `plusInteger` d #)
+ else (# q, r #)
+
++{-# NOINLINE divInteger #-}
++divInteger :: Integer -> Integer -> Integer
++n `divInteger` d = quotient
++ where (# quotient, _ #) = n `divModInteger` d
++
++{-# NOINLINE modInteger #-}
++modInteger :: Integer -> Integer -> Integer
++n `modInteger` d = modulus
++ where (# _, modulus #) = n `divModInteger` d
++
+ {-# NOINLINE quotRemInteger #-}
+ quotRemInteger :: Integer -> Integer -> (# Integer, Integer #)
+ Naught `quotRemInteger` (!_) = (# Naught, Naught #)
diff --git a/dev-lang/ghc/files/ghc-7.6.3-preserve-inplace-xattr.patch b/dev-lang/ghc/files/ghc-7.6.3-preserve-inplace-xattr.patch
new file mode 100644
index 00000000000..08410fa0cd9
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.6.3-preserve-inplace-xattr.patch
@@ -0,0 +1,14 @@
+On hardened 'cp' drops out XT-pax parking.
+perfinion suggested using 'install', where portage
+might have a chance to save our marking.
+
+Reported-by: Jay Yang
+Gentoo-bug: https://bugs.gentoo.org/518734
+diff --git a/rules/build-prog.mk b/rules/build-prog.mk
+index 399369e..2ee9cd5 100644
+--- a/rules/build-prog.mk
++++ b/rules/build-prog.mk
+@@ -288,3 +288,3 @@ endif
+ $$($1_$2_INPLACE) : $1/$2/build/tmp/$$($1_$2_PROG_INPLACE) | $$$$(dir $$$$@)/.
+- "$$(CP)" -p $$< $$@
++ $$(INSTALL) -m 755 $$< $$@
diff --git a/dev-lang/ghc/files/ghc-7.6.3-trac-3333-weak-syms.patch b/dev-lang/ghc/files/ghc-7.6.3-trac-3333-weak-syms.patch
new file mode 100644
index 00000000000..c3184a68c1e
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.6.3-trac-3333-weak-syms.patch
@@ -0,0 +1,387 @@
+The patch set adds support for weak symbols to ghci.
+
+For gentoo it fixes nonworking ghci / template haskell
+for package base.
+
+Steps to reproduce:
+ 1. CFLAGS=-Os emerge ghc
+ 2. ghci -package base
+ Loading package base ... linking ... ghc: /usr/lib64/ghc-7.6.3/base-4.6.0.1/HSbase-4.6.0.1.o: unknown symbol `stat'
+
+When built with -O2 weak 'stat' resolved to '__xstat' and we don't see any errors.
+But on olwer optimization levels 'stat' remains.
+
+Patches-by: akio
+Gentoo-bug: http://bugs.gentoo.org/452442
+Upstream-bug: http://ghc.haskell.org/trac/ghc/ticket/3333
+
+From 500d57d3a18412c78cab5abc4d91f1564edc964d Mon Sep 17 00:00:00 2001
+From: Takano Akio <aljee@hyper.cx>
+Date: Sat, 29 Dec 2012 11:47:22 +0900
+Subject: [PATCH 1/3] Linker.c: remove stablehash, which is no longer used
+
+---
+ includes/rts/Linker.h | 3 ---
+ rts/Linker.c | 31 ++-----------------------------
+ 2 files changed, 2 insertions(+), 32 deletions(-)
+
+diff --git a/includes/rts/Linker.h b/includes/rts/Linker.h
+index e900e85..d20ebc2 100644
+--- a/includes/rts/Linker.h
++++ b/includes/rts/Linker.h
+@@ -23,9 +23,6 @@ typedef char pathchar;
+ /* initialize the object linker */
+ void initLinker( void );
+
+-/* insert a stable symbol in the hash table */
+-void insertStableSymbol(pathchar* obj_name, char* key, StgPtr data);
+-
+ /* insert a symbol in the hash table */
+ void insertSymbol(pathchar* obj_name, char* key, void* data);
+
+diff --git a/rts/Linker.c b/rts/Linker.c
+index fa1de89..513fe3f 100644
+--- a/rts/Linker.c
++++ b/rts/Linker.c
+@@ -30,1 +30,0 @@
+-#include "Stable.h"
+@@ -150,9 +149,6 @@ int dynamicByDefault = 0;
+ /* Hash table mapping symbol names to Symbol */
+ static /*Str*/HashTable *symhash;
+
+-/* Hash table mapping symbol names to StgStablePtr */
+-static /*Str*/HashTable *stablehash;
+-
+ /* List of currently loaded objects */
+ ObjectCode *objects = NULL; /* initially empty */
+
+@@ -1126,1 +1126,0 @@ typedef struct _RtsSymbolVal {
+- SymI_HasProto(insertStableSymbol) \
+@@ -1488,7 +1483,6 @@ initLinker( void )
+ #if defined(THREADED_RTS) && (defined(OBJFORMAT_ELF) || defined(OBJFORMAT_MACHO))
+ initMutex(&dl_mutex);
+ #endif
+- stablehash = allocStrHashTable();
+ symhash = allocStrHashTable();
+
+ /* populate the symbol table with stuff from the RTS */
+@@ -1817,17 +1811,6 @@ error:
+ }
+
+ /* -----------------------------------------------------------------------------
+- * insert a stable symbol in the hash table
+- */
+-
+-void
+-insertStableSymbol(pathchar* obj_name, char* key, StgPtr p)
+-{
+- ghciInsertStrHashTable(obj_name, stablehash, key, getStablePtr(p));
+-}
+-
+-
+-/* -----------------------------------------------------------------------------
+ * insert a symbol in the hash table
+ */
+ void
+@@ -4749,8 +4732,6 @@ do_Elf_Rel_relocations ( ObjectCode* oc, char* ehdrC,
+ #ifdef i386_HOST_ARCH
+ Elf_Addr value;
+ #endif
+- StgStablePtr stablePtr;
+- StgPtr stableVal;
+ #ifdef arm_HOST_ARCH
+ int is_target_thm=0, T=0;
+ #endif
+@@ -4773,16 +4754,8 @@ do_Elf_Rel_relocations ( ObjectCode* oc, char* ehdrC,
+
+ } else {
+ symbol = strtab + sym.st_name;
+- stablePtr = (StgStablePtr)lookupHashTable(stablehash, (StgWord)symbol);
+- if (NULL == stablePtr) {
+- /* No, so look up the name in our global table. */
+- S_tmp = lookupSymbol( symbol );
+- S = (Elf_Addr)S_tmp;
+- } else {
+- stableVal = deRefStablePtr( stablePtr );
+- S_tmp = stableVal;
+- S = (Elf_Addr)S_tmp;
+- }
++ S_tmp = lookupSymbol( symbol );
++ S = (Elf_Addr)S_tmp;
+ }
+ if (!S) {
+ errorBelch("%s: unknown symbol `%s'", oc->fileName, symbol);
+--
+1.7.9.5
+
+From 2e5e0f7a90dd390adc5ae5fb2a3bc6e879aa42d6 Mon Sep 17 00:00:00 2001
+From: Takano Akio <aljee@hyper.cx>
+Date: Sat, 29 Dec 2012 11:59:34 +0900
+Subject: [PATCH 2/3] ghci: add support for ELF weak symbols
+
+---
+ rts/Linker.c | 102 ++++++++++++++++++++++++++++++++++++++++++++--------------
+ 1 file changed, 78 insertions(+), 24 deletions(-)
+
+diff --git a/rts/Linker.c b/rts/Linker.c
+index 513fe3f..5105085 100644
+--- a/rts/Linker.c
++++ b/rts/Linker.c
+@@ -146,7 +146,13 @@ int dynamicByDefault = 1;
+ int dynamicByDefault = 0;
+ #endif
+
+-/* Hash table mapping symbol names to Symbol */
++typedef struct _RtsSymbolInfo {
++ void *value;
++ const ObjectCode *owner;
++ HsBool weak;
++} RtsSymbolInfo;
++
++/* Hash table mapping symbol names to RtsSymbolInfo */
+ static /*Str*/HashTable *symhash;
+
+ /* List of currently loaded objects */
+@@ -1415,15 +1421,31 @@ static RtsSymbolVal rtsSyms[] = {
+ * Insert symbols into hash tables, checking for duplicates.
+ */
+
+-static void ghciInsertStrHashTable ( pathchar* obj_name,
+- HashTable *table,
+- char* key,
+- void *data
+- )
++static void ghciInsertSymbolTable(
++ pathchar* obj_name,
++ HashTable *table,
++ char* key,
++ void *data,
++ HsBool weak,
++ ObjectCode *owner)
+ {
+- if (lookupHashTable(table, (StgWord)key) == NULL)
++ RtsSymbolInfo *pinfo = lookupStrHashTable(table, key);
++ if (!pinfo) /* new entry */
++ {
++ pinfo = stgMallocBytes(sizeof (*pinfo), "ghciInsertToSymbolTable");
++ pinfo->value = data;
++ pinfo->owner = owner;
++ pinfo->weak = weak;
++ insertStrHashTable(table, key, pinfo);
++ return;
++ } else if ((!pinfo->weak || pinfo->value) && weak) {
++ return; /* duplicate weak symbol, throw it away */
++ } else if (pinfo->weak) /* weak symbol is in the table */
+ {
+- insertStrHashTable(table, (StgWord)key, data);
++ /* override the weak definition with the non-weak one */
++ pinfo->value = data;
++ pinfo->owner = owner;
++ pinfo->weak = HS_BOOL_FALSE;
+ return;
+ }
+ debugBelch(
+@@ -1444,6 +1466,32 @@ static void ghciInsertStrHashTable ( pathchar* obj_name,
+ );
+ stg_exit(1);
+ }
++
++static HsBool ghciLookupSymbolTable(HashTable *table,
++ const char *key, void **result)
++{
++ RtsSymbolInfo *pinfo = lookupStrHashTable(table, key);
++ if (!pinfo) {
++ *result = NULL;
++ return HS_BOOL_FALSE;
++ }
++ if (pinfo->weak)
++ IF_DEBUG(linker, debugBelch("lookup: promoting %s\n", key));
++ /* Once it's looked up, it can no longer be overridden */
++ pinfo->weak = HS_BOOL_FALSE;
++
++ *result = pinfo->value;
++ return HS_BOOL_TRUE;
++}
++
++static void ghciRemoveSymbolTable(HashTable *table, const char *key,
++ ObjectCode *owner)
++{
++ RtsSymbolInfo *pinfo = lookupStrHashTable(table, key);
++ if (!pinfo || owner != pinfo->owner) return;
++ removeStrHashTable(table, key, NULL);
++ stgFree(pinfo);
++}
+ /* -----------------------------------------------------------------------------
+ * initialize the object linker
+ */
+@@ -1487,8 +1535,8 @@ initLinker( void )
+
+ /* populate the symbol table with stuff from the RTS */
+ for (sym = rtsSyms; sym->lbl != NULL; sym++) {
+- ghciInsertStrHashTable(WSTR("(GHCi built-in symbols)"),
+- symhash, sym->lbl, sym->addr);
++ ghciInsertSymbolTable(WSTR("(GHCi built-in symbols)"),
++ symhash, sym->lbl, sym->addr, HS_BOOL_FALSE, NULL);
+ IF_DEBUG(linker, debugBelch("initLinker: inserting rts symbol %s, %p\n", sym->lbl, sym->addr));
+ }
+ # if defined(OBJFORMAT_MACHO) && defined(powerpc_HOST_ARCH)
+@@ -1816,7 +1864,7 @@ error:
+ void
+ insertSymbol(pathchar* obj_name, char* key, void* data)
+ {
+- ghciInsertStrHashTable(obj_name, symhash, key, data);
++ ghciInsertSymbolTable(obj_name, symhash, key, data, HS_BOOL_FALSE, NULL);
+ }
+
+ /* -----------------------------------------------------------------------------
+@@ -1829,9 +1877,8 @@ lookupSymbol( char *lbl )
+ IF_DEBUG(linker, debugBelch("lookupSymbol: looking up %s\n", lbl));
+ initLinker() ;
+ ASSERT(symhash != NULL);
+- val = lookupStrHashTable(symhash, lbl);
+
+- if (val == NULL) {
++ if (!ghciLookupSymbolTable(symhash, lbl, &val)) {
+ IF_DEBUG(linker, debugBelch("lookupSymbol: symbol not found\n"));
+ # if defined(OBJFORMAT_ELF)
+ return internal_dlsym(dl_prog_handle, lbl);
+@@ -1903,7 +1950,7 @@ void ghci_enquire ( char* addr )
+ if (sym == NULL) continue;
+ a = NULL;
+ if (a == NULL) {
+- a = lookupStrHashTable(symhash, sym);
++ ghciLookupSymbolTable(symhash, sym, (void **)&a);
+ }
+ if (a == NULL) {
+ // debugBelch("ghci_enquire: can't find %s\n", sym);
+@@ -2715,7 +2762,7 @@ unloadObj( pathchar *path )
+ int i;
+ for (i = 0; i < oc->n_symbols; i++) {
+ if (oc->symbols[i] != NULL) {
+- removeStrHashTable(symhash, oc->symbols[i], NULL);
++ ghciRemoveSymbolTable(symhash, oc->symbols[i], oc);
+ }
+ }
+ }
+@@ -3802,7 +3849,8 @@ ocGetNames_PEi386 ( ObjectCode* oc )
+ ASSERT(i >= 0 && i < oc->n_symbols);
+ /* cstring_from_COFF_symbol_name always succeeds. */
+ oc->symbols[i] = (char*)sname;
+- ghciInsertStrHashTable(oc->fileName, symhash, (char*)sname, addr);
++ ghciInsertSymbolTable(oc->fileName, symhash, (char*)sname, addr,
++ HS_BOOL_FALSE, oc);
+ } else {
+ # if 0
+ debugBelch(
+@@ -4595,6 +4643,7 @@ ocGetNames_ELF ( ObjectCode* oc )
+ for (j = 0; j < nent; j++) {
+
+ char isLocal = FALSE; /* avoids uninit-var warning */
++ HsBool isWeak = HS_BOOL_FALSE;
+ char* ad = NULL;
+ char* nm = strtab + stab[j].st_name;
+ int secno = stab[j].st_shndx;
+@@ -4615,6 +4664,7 @@ ocGetNames_ELF ( ObjectCode* oc )
+ else
+ if ( ( ELF_ST_BIND(stab[j].st_info)==STB_GLOBAL
+ || ELF_ST_BIND(stab[j].st_info)==STB_LOCAL
++ || ELF_ST_BIND(stab[j].st_info)==STB_WEAK
+ )
+ /* and not an undefined symbol */
+ && stab[j].st_shndx != SHN_UNDEF
+@@ -4638,7 +4688,8 @@ ocGetNames_ELF ( ObjectCode* oc )
+ ad = ehdrC + shdr[ secno ].sh_offset + stab[j].st_value;
+ if (ELF_ST_BIND(stab[j].st_info)==STB_LOCAL) {
+ isLocal = TRUE;
+- } else {
++ isWeak = FALSE;
++ } else { /* STB_GLOBAL or STB_WEAK */
+ #ifdef ELF_FUNCTION_DESC
+ /* dlsym() and the initialisation table both give us function
+ * descriptors, so to be consistent we store function descriptors
+@@ -4649,6 +4700,7 @@ ocGetNames_ELF ( ObjectCode* oc )
+ IF_DEBUG(linker,debugBelch( "addOTabName(GLOB): %10p %s %s\n",
+ ad, oc->fileName, nm ));
+ isLocal = FALSE;
++ isWeak = (ELF_ST_BIND(stab[j].st_info)==STB_WEAK);
+ }
+ }
+
+@@ -4661,7 +4713,7 @@ ocGetNames_ELF ( ObjectCode* oc )
+ if (isLocal) {
+ /* Ignore entirely. */
+ } else {
+- ghciInsertStrHashTable(oc->fileName, symhash, nm, ad);
++ ghciInsertSymbolTable(oc->fileName, symhash, nm, ad, isWeak, oc);
+ }
+ } else {
+ /* Skip. */
+@@ -6306,11 +6358,13 @@ ocGetNames_MachO(ObjectCode* oc)
+ else
+ {
+ IF_DEBUG(linker, debugBelch("ocGetNames_MachO: inserting %s\n", nm));
+- ghciInsertStrHashTable(oc->fileName, symhash, nm,
++ ghciInsertSymbolTable(oc->fileName, symhash, nm,
+ image
+ + sections[nlist[i].n_sect-1].offset
+ - sections[nlist[i].n_sect-1].addr
+- + nlist[i].n_value);
++ + nlist[i].n_value,
++ HS_BOOL_FALSE,
++ oc);
+ oc->symbols[curSymbol++] = nm;
+ }
+ }
+@@ -6341,8 +6395,8 @@ ocGetNames_MachO(ObjectCode* oc)
+ nlist[i].n_value = commonCounter;
+
+ IF_DEBUG(linker, debugBelch("ocGetNames_MachO: inserting common symbol: %s\n", nm));
+- ghciInsertStrHashTable(oc->fileName, symhash, nm,
+- (void*)commonCounter);
++ ghciInsertSymbolTable(oc->fileName, symhash, nm,
++ (void*)commonCounter, HS_BOOL_FALSE, oc);
+ oc->symbols[curSymbol++] = nm;
+
+ commonCounter += sz;
+@@ -6466,7 +6520,7 @@ machoInitSymbolsWithoutUnderscore(void)
+
+ #undef SymI_NeedsProto
+ #define SymI_NeedsProto(x) \
+- ghciInsertStrHashTable("(GHCi built-in symbols)", symhash, #x, *p++);
++ ghciInsertSymbolTable("(GHCi built-in symbols)", symhash, #x, *p++, HS_BOOL_FALSE, NULL);
+
+ RTS_MACHO_NOUNDERLINE_SYMBOLS
+
+--
+1.7.9.5
+
+From 916d7713b34b529ae7ec24eaa836a4eaca7724fc Mon Sep 17 00:00:00 2001
+From: Takano Akio <aljee@hyper.cx>
+Date: Sun, 6 Jan 2013 17:51:19 +0900
+Subject: [PATCH 3/3] Linker.c: add dso_handle to the symbol table
+
+---
+ rts/Linker.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/rts/Linker.c b/rts/Linker.c
+index 5105085..0b2bf63 100644
+--- a/rts/Linker.c
++++ b/rts/Linker.c
+@@ -1542,6 +1542,13 @@ initLinker( void )
+ # if defined(OBJFORMAT_MACHO) && defined(powerpc_HOST_ARCH)
+ machoInitSymbolsWithoutUnderscore();
+ # endif
++ /* GCC defines a special symbol __dso_handle which is resolved to NULL if
++ referenced from a statically linked module. We need to mimic this, but
++ we cannot use NULL because we use it to mean nonexistent symbols. So we
++ use an arbitrary (hopefully unique) address here.
++ */
++ ghciInsertSymbolTable(WSTR("(GHCi special symbols)"),
++ symhash, "__dso_handle", (void *)0x12345687, HS_BOOL_FALSE, NULL);
+
+ # if defined(OBJFORMAT_ELF) || defined(OBJFORMAT_MACHO)
+ # if defined(RTLD_DEFAULT)
+--
+1.7.9.5
+
diff --git a/dev-lang/ghc/files/ghc-7.8.1_rc1-libbfd.patch b/dev-lang/ghc/files/ghc-7.8.1_rc1-libbfd.patch
new file mode 100644
index 00000000000..d01cb49affb
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.1_rc1-libbfd.patch
@@ -0,0 +1,81 @@
+commit bb5953484579968c984d074ca1af5d21e1c9e7a0
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Mon Feb 10 12:45:58 2014 +0300
+
+ rts: unrust 'libbfd' debug symbols parser
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+diff --git a/configure.ac b/configure.ac
+index e7fbc7f..e47979c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -801,7 +801,8 @@ fi
+ dnl ** check whether this machine has BFD and libiberty installed (used for debugging)
+ dnl the order of these tests matters: bfd needs libiberty
+ AC_CHECK_LIB(iberty, xmalloc)
+-AC_CHECK_LIB(bfd, bfd_uncompress_section_contents)
++dnl 'bfd_init' is a rare non-macro in libbfd
++AC_CHECK_LIB(bfd, bfd_init)
+
+ dnl ################################################################
+ dnl Check for libraries
+diff --git a/rts/Printer.c b/rts/Printer.c
+index ca9ca49..ce02b02 100644
+--- a/rts/Printer.c
++++ b/rts/Printer.c
+@@ -48,6 +48,9 @@ void printPtr( StgPtr p )
+ raw = lookupGHCName(p);
+ if (raw != NULL) {
+ printZcoded(raw);
++ /* it can be just a C symbol, like 'stg_returnToStackTop' */
++ debugBelch("<%s>", raw);
++ debugBelch("[%p]", p);
+ } else {
+ debugBelch("%p", p);
+ }
+@@ -794,7 +797,7 @@ static void printZcoded( const char *raw )
+ disabling this for now.
+ */
+ #ifdef USING_LIBBFD
+-
++#include "../mk/config.h" /* silly BFD's requirement */
+ #include <bfd.h>
+
+ /* Fairly ad-hoc piece of code that seems to filter out a lot of
+@@ -863,7 +866,10 @@ extern void DEBUG_LoadSymbols( char *name )
+ for( i = 0; i != number_of_symbols; ++i ) {
+ symbol_info info;
+ bfd_get_symbol_info(abfd,symbol_table[i],&info);
+- /*debugBelch("\t%c\t0x%x \t%s\n",info.type,(nat)info.value,info.name); */
++ if (0)
++ {
++ debugBelch("\t%c\t0x%x \t%s\n",info.type,(nat)info.value,info.name);
++ }
+ if (isReal(info.type, info.name)) {
+ num_real_syms += 1;
+ }
+diff --git a/rts/RtsStartup.c b/rts/RtsStartup.c
+index aa7306f..5bdef94 100644
+--- a/rts/RtsStartup.c
++++ b/rts/RtsStartup.c
+@@ -19,6 +19,7 @@
+ #include "RtsFlags.h"
+ #include "RtsUtils.h"
+ #include "Prelude.h"
++#include "Printer.h" /* DEBUG_LoadSymbols */
+ #include "Schedule.h" /* initScheduler */
+ #include "Stats.h" /* initStats */
+ #include "STM.h" /* initSTM */
+@@ -162,6 +163,11 @@ hs_init_ghc(int *argc, char **argv[], RtsConfig rts_config)
+ rts_config.rts_opts_enabled, rts_config.rts_opts, rts_config.rts_hs_main);
+ }
+
++#ifdef DEBUG
++ /* load debugging symbols */
++ DEBUG_LoadSymbols((*argv)[0]);
++#endif /* DEBUG */
++
+ /* Initialise the stats department, phase 1 */
+ initStats1();
+
diff --git a/dev-lang/ghc/files/ghc-7.8.2-cgen-constify.patch b/dev-lang/ghc/files/ghc-7.8.2-cgen-constify.patch
new file mode 100644
index 00000000000..efdd54fbf3f
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.2-cgen-constify.patch
@@ -0,0 +1,34 @@
+commit b0cf3ab7a69b878a4335d21a347b56e4b0ca0b7b
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Mon Apr 14 19:06:24 2014 +0300
+
+ compiler/cmm/PprC.hs: constify local string literals
+
+ Consider one-line module
+ module B (v) where v = "hello"
+ in -fvia-C mode it generates code like
+ static char gibberish_str[] = "hello";
+
+ It uselessly eats data section (precious resource on ia64!).
+ The patch switches genrator to emit:
+ static const char gibberish_str[] = "hello";
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+diff --git a/compiler/cmm/PprC.hs b/compiler/cmm/PprC.hs
+index 2398981..fdb578d 100644
+--- a/compiler/cmm/PprC.hs
++++ b/compiler/cmm/PprC.hs
+@@ -112,6 +112,12 @@ pprTop (CmmProc infos clbl _ graph) =
+
+ -- We only handle (a) arrays of word-sized things and (b) strings.
+
++pprTop (CmmData ReadOnlyData (Statics lbl [CmmString str])) =
++ hcat [
++ pprLocalness lbl, ptext (sLit "const char "), ppr lbl,
++ ptext (sLit "[] = "), pprStringInCStyle str, semi
++ ]
++
+ pprTop (CmmData _section (Statics lbl [CmmString str])) =
+ hcat [
+ pprLocalness lbl, ptext (sLit "char "), ppr lbl,
diff --git a/dev-lang/ghc/files/ghc-7.8.3-cc-lang.patch b/dev-lang/ghc/files/ghc-7.8.3-cc-lang.patch
new file mode 100644
index 00000000000..032dc9a6762
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-cc-lang.patch
@@ -0,0 +1,129 @@
+commit 4d4d07704ee78221607a18b8118294b0aea1bac4
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Tue Sep 2 00:06:56 2014 +0300
+
+ systools: fix gcc version detecton on non-english locale
+
+ Summary:
+ ghc runs 'gcc -v' to check if we run under vanilla gcc
+ or disaguised clang by checking for string
+
+ "gcc version <something>"
+
+ But this check does not always work as gcc has that string
+ localized via gettext mechanism:
+
+ (some gcc's locale strings)
+ be.po-msgstr "версія gcc %s\n"
+ da.po-msgstr "GCC version %s\n"
+ de.po-msgstr "gcc-Version %s %s\n"
+ el.po-msgstr "έκδοση gcc %s\n"
+ ...
+
+ To ping gcc to English locale we now override environment
+ variable with 'LANGUAGE=en' value.
+
+ Fixes Issue #8825
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+ Test Plan: validate
+
+ Reviewers: austin
+
+ Reviewed By: austin
+
+ Subscribers: simonmar, ezyang, carter
+
+ Differential Revision: https://phabricator.haskell.org/D185
+
+ GHC Trac Issues: #8825
+
+diff --git a/compiler/main/SysTools.lhs b/compiler/main/SysTools.lhs
+index 72fa19b..67926f5 100644
+--- a/compiler/main/SysTools.lhs
++++ b/compiler/main/SysTools.lhs
+@@ -492,6 +492,51 @@ readCreateProcess proc = do
+
+ return (ex, output)
+
++readProcessEnvWithExitCode
++ :: String -- ^ program path
++ -> [String] -- ^ program args
++ -> [(String, String)] -- ^ environment to override
++ -> IO (ExitCode, String, String) -- ^ (exit_code, stdout, stderr)
++readProcessEnvWithExitCode prog args env_update = do
++ current_env <- getEnvironment
++ let new_env = env_update ++ [ (k, v)
++ | let overriden_keys = map fst env_update
++ , (k, v) <- current_env
++ , k `notElem` overriden_keys
++ ]
++ p = proc prog args
++
++ (_stdin, Just stdoh, Just stdeh, pid) <-
++ createProcess p{ std_out = CreatePipe
++ , std_err = CreatePipe
++ , env = Just new_env
++ }
++
++ outMVar <- newEmptyMVar
++ errMVar <- newEmptyMVar
++
++ _ <- forkIO $ do
++ stdo <- hGetContents stdoh
++ _ <- evaluate (length stdo)
++ putMVar outMVar stdo
++
++ _ <- forkIO $ do
++ stde <- hGetContents stdeh
++ _ <- evaluate (length stde)
++ putMVar errMVar stde
++
++ out <- takeMVar outMVar
++ hClose stdoh
++ err <- takeMVar errMVar
++ hClose stdeh
++
++ ex <- waitForProcess pid
++
++ return (ex, out, err)
++
++-- Don't let gcc localize version info string, #8825
++en_locale_env :: [(String, String)]
++en_locale_env = [("LANGUAGE", "en")]
+
+ -- If the -B<dir> option is set, add <dir> to PATH. This works around
+ -- a bug in gcc on Windows Vista where it can't find its auxiliary
+@@ -746,8 +791,9 @@ getLinkerInfo' dflags = do
+ _ -> do
+ -- In practice, we use the compiler as the linker here. Pass
+ -- -Wl,--version to get linker version info.
+- (exitc, stdo, stde) <- readProcessWithExitCode pgm
+- ["-Wl,--version"] ""
++ (exitc, stdo, stde) <- readProcessEnvWithExitCode pgm
++ ["-Wl,--version"]
++ en_locale_env
+ -- Split the output by lines to make certain kinds
+ -- of processing easier. In particular, 'clang' and 'gcc'
+ -- have slightly different outputs for '-Wl,--version', but
+@@ -802,7 +848,8 @@ getCompilerInfo' dflags = do
+
+ -- Process the executable call
+ info <- catchIO (do
+- (exitc, stdo, stde) <- readProcessWithExitCode pgm ["-v"] ""
++ (exitc, stdo, stde) <-
++ readProcessEnvWithExitCode pgm ["-v"] en_locale_env
+ -- Split the output by lines to make certain kinds
+ -- of processing easier.
+ parseCompilerInfo (lines stdo) (lines stde) exitc
+@@ -952,7 +999,8 @@ readElfSection _dflags section exe = do
+ prog = "readelf"
+ args = [Option "-p", Option section, FileOption "" exe]
+ --
+- r <- readProcessWithExitCode prog (filter notNull (map showOpt args)) ""
++ r <- readProcessEnvWithExitCode prog (filter notNull (map showOpt args))
++ en_locale_env
+ case r of
+ (ExitSuccess, out, _err) -> return (doFilter (lines out))
+ _ -> return Nothing
diff --git a/dev-lang/ghc/files/ghc-7.8.3-deRefStablePtr.patch b/dev-lang/ghc/files/ghc-7.8.3-deRefStablePtr.patch
new file mode 100644
index 00000000000..8deec21edc5
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-deRefStablePtr.patch
@@ -0,0 +1,38 @@
+commit 104a66a461f4f89b8e5ad9c829923bb7ca8ceddb
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Sat Aug 23 13:11:23 2014 +0300
+
+ rts/Linker.c: declare 'deRefStablePtr' as an exported 'rts' symbol
+
+ $ inplace/bin/ghc-stage2 -fforce-recomp -dcore-lint -dcmm-lint -dno-debug-output -no-user-package-db -rtsopts -optc-fno-builtin -fno-ghci-history \
+ testsuite/tests/ffi/should_run/T4038.hs --interactive -v0 -ignore-dot-ghci +RTS -I0.1 -RTS
+
+ *Main> main
+ <interactive>: /tmp/ghc16668_0/ghc16668_5.o: unknown symbol `deRefStablePtr'
+
+ The reference to 'deRefStablePtr' is generated by 'compiler/deSugar/DsForeign.lhs':
+ the_cfun
+ = case maybe_target of
+ Nothing -> text "(StgClosure*)deRefStablePtr(the_stableptr)"
+ Just hs_fn -> char '&' <> ppr hs_fn <> text "_closure"
+
+ Patch fixes all broken tests using 'import wrapper':
+ TEST="ffi013 ffi010 ffi011 ffi005 ffi020 ffi006 ffi019 fed001 T1679 T4038"
+
+ Tests manifested as broken only in DYNAMIC_GHC_PROGRAMS=NO builds,
+ where GHCi's custom linker is used instead of system's linker.
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+diff --git a/rts/Linker.c b/rts/Linker.c
+index e97580d..b24be58 100644
+--- a/rts/Linker.c
++++ b/rts/Linker.c
+@@ -1092,6 +1092,7 @@ typedef struct _RtsSymbolVal {
+ SymI_HasProto(__word_encodeFloat) \
+ SymI_HasProto(stg_atomicallyzh) \
+ SymI_HasProto(barf) \
++ SymI_HasProto(deRefStablePtr) \
+ SymI_HasProto(debugBelch) \
+ SymI_HasProto(errorBelch) \
+ SymI_HasProto(sysErrorBelch) \
diff --git a/dev-lang/ghc/files/ghc-7.8.3-ia64-prim.patch b/dev-lang/ghc/files/ghc-7.8.3-ia64-prim.patch
new file mode 100644
index 00000000000..9026ecfdf4b
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-ia64-prim.patch
@@ -0,0 +1,69 @@
+commit e2a8801b9779949010f30db6f6ef66f3c3a70776
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Thu Sep 4 17:50:45 2014 +0300
+
+ pprC: declare extern cmm primitives as functions, not data
+
+ Summary:
+ The commit fixes incorrect code generation of
+ integer-gmp package on ia64 due to C prototype mismatch.
+ Before patch prototype was
+ StgWord poizh[];
+ After patch it became
+ StgFunPtr poizh();
+
+ Long story:
+
+ Consider the following simple example:
+
+ {-# LANGUAGE MagicHash, GHCForeignImportPrim, UnliftedFFITypes #-}
+ module M where
+ import GHC.Prim -- Int#
+ foreign import prim "poizh" poi# :: Int# -> Int#
+
+ Before the patch Unregisterised build generated the
+ following 'poizh' reference:
+ EI_(poizh); /* StgWord poizh[]; */
+ FN_(M_poizh_entry) {
+ // ...
+ JMP_((W_)&poizh);
+ }
+
+ After the patch it looks this way:
+ EF_(poizh); /* StgFunPtr poizh(); */
+ FN_(M_poizh_entry) {
+ // ...
+ JMP_((W_)&poizh);
+ }
+
+ On ia64 it leads to different relocation types being generated:
+ incorrect one:
+ addl r14 = @ltoffx(poizh#)
+ ld8.mov r14 = [r14], poizh#
+ correct one:
+ addl r14 = @ltoff(@fptr(poizh#)), gp
+ ld8 r14 = [r14]
+
+ '@fptr(poizh#)' basically instructs assembler to creates
+ another obect consisting of real address to 'poizh' instructions
+ and module address. That '@fptr' object is used as a function "address".
+ This object is different for every module referencing 'poizh' symbol.
+
+ All indirect function calls expect '@fptr' object. That way
+ call site can read real destination address and set destination
+ module address in 'gp' register.
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+diff --git a/compiler/cmm/CLabel.hs b/compiler/cmm/CLabel.hs
+index 02ad026..0f2c0ae 100644
+--- a/compiler/cmm/CLabel.hs
++++ b/compiler/cmm/CLabel.hs
+@@ -813,6 +813,7 @@ labelType (CmmLabel _ _ CmmClosure) = GcPtrLabel
+ labelType (CmmLabel _ _ CmmCode) = CodeLabel
+ labelType (CmmLabel _ _ CmmInfo) = DataLabel
+ labelType (CmmLabel _ _ CmmEntry) = CodeLabel
++labelType (CmmLabel _ _ CmmPrimCall) = CodeLabel
+ labelType (CmmLabel _ _ CmmRetInfo) = DataLabel
+ labelType (CmmLabel _ _ CmmRet) = CodeLabel
+ labelType (RtsLabel (RtsSelectorInfoTable _ _)) = DataLabel
diff --git a/dev-lang/ghc/files/ghc-7.8.3-linker-warn.patch b/dev-lang/ghc/files/ghc-7.8.3-linker-warn.patch
new file mode 100644
index 00000000000..c8570c06940
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-linker-warn.patch
@@ -0,0 +1,35 @@
+commit 326046739801a380c5457ef4c87bce8fb95497ba
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Sun Aug 10 22:12:28 2014 +0300
+
+ systools info: fix warning about C compiler (message said about linker)
+
+ Summary: Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+ Test Plan: build-tested
+
+ Reviewers: austin
+
+ Reviewed By: austin
+
+ Subscribers: phaskell, simonmar, relrod, ezyang, carter
+
+ Differential Revision: https://phabricator.haskell.org/D132
+
+diff --git a/compiler/main/SysTools.lhs b/compiler/main/SysTools.lhs
+index 1c1c52c..72fa19b 100644
+--- a/compiler/main/SysTools.lhs
++++ b/compiler/main/SysTools.lhs
+@@ -809,10 +809,10 @@ getCompilerInfo' dflags = do
+ )
+ (\err -> do
+ debugTraceMsg dflags 2
+- (text "Error (figuring out compiler information):" <+>
++ (text "Error (figuring out C compiler information):" <+>
+ text (show err))
+ errorMsg dflags $ hang (text "Warning:") 9 $
+- text "Couldn't figure out linker information!" $$
++ text "Couldn't figure out C compiler information!" $$
+ text "Make sure you're using GNU gcc, or clang"
+ return UnknownCC)
+ return info
diff --git a/dev-lang/ghc/files/ghc-7.8.3-pic-asm.patch b/dev-lang/ghc/files/ghc-7.8.3-pic-asm.patch
new file mode 100644
index 00000000000..10c41d5b29f
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-pic-asm.patch
@@ -0,0 +1,107 @@
+commit a93ab43ab5f40cadbedea2f6342b93c245e91434
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Wed Aug 27 22:19:52 2014 +0300
+
+ driver: pass '-fPIC' option to assembler as well
+
+ Summary:
+ Before the patch '-fPIC' was passed only to C compiler,
+ but not to assembler itself.
+
+ It led to runtime crash in GHC_DYNAMIC_PROGRAMS=YES mode
+ on sparc32.
+
+ Technical details are in 'Note [-fPIC for assembler]'.
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+ Test Plan: validate on sparc
+
+ Reviewers: simonmar, austin, kgardas
+
+ Reviewed By: austin
+
+ Subscribers: simonmar, ezyang, carter
+
+ Differential Revision: https://phabricator.haskell.org/D177
+
+diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs
+index 183f435..5a18e6e 100644
+--- a/compiler/main/DriverPipeline.hs
++++ b/compiler/main/DriverPipeline.hs
+@@ -1199,6 +1199,7 @@ runPhase (RealPhase (As with_cpp)) input_fn dflags
+
+ as_prog <- whichAsProg
+ let cmdline_include_paths = includePaths dflags
++ let pic_c_flags = picCCOpts dflags
+
+ next_phase <- maybeMergeStub
+ output_fn <- phaseOutputFilename next_phase
+@@ -1212,6 +1213,9 @@ runPhase (RealPhase (As with_cpp)) input_fn dflags
+ = liftIO $ as_prog dflags
+ ([ SysTools.Option ("-I" ++ p) | p <- cmdline_include_paths ]
+
++ -- See Note [-fPIC for assembler]
++ ++ map SysTools.Option pic_c_flags
++
+ -- We only support SparcV9 and better because V8 lacks an atomic CAS
+ -- instruction so we have to make sure that the assembler accepts the
+ -- instruction set. Note that the user can still override this
+@@ -1253,6 +1257,8 @@ runPhase (RealPhase SplitAs) _input_fn dflags
+ osuf = objectSuf dflags
+ split_odir = base_o ++ "_" ++ osuf ++ "_split"
+
++ let pic_c_flags = picCCOpts dflags
++
+ -- this also creates the hierarchy
+ liftIO $ createDirectoryIfMissing True split_odir
+
+@@ -1286,6 +1292,9 @@ runPhase (RealPhase SplitAs) _input_fn dflags
+ then [SysTools.Option "-mcpu=v9"]
+ else []) ++
+
++ -- See Note [-fPIC for assembler]
++ map SysTools.Option pic_c_flags ++
++
+ [ SysTools.Option "-c"
+ , SysTools.Option "-o"
+ , SysTools.FileOption "" (split_obj n)
+@@ -2203,3 +2212,38 @@ haveRtsOptsFlags dflags =
+ isJust (rtsOpts dflags) || case rtsOptsEnabled dflags of
+ RtsOptsSafeOnly -> False
+ _ -> True
++
++-- Note [-fPIC for assembler]
++-- When compiling .c source file GHC's driver pipeline basically
++-- does the following two things:
++-- 1. ${CC} -S 'PIC_CFLAGS' source.c
++-- 2. ${CC} -x assembler -c 'PIC_CFLAGS' source.S
++--
++-- Why do we need to pass 'PIC_CFLAGS' both to C compiler and assembler?
++-- Because on some architectures (at least sparc32) assembler also choses
++-- relocation type!
++-- Consider the following C module:
++--
++-- /* pic-sample.c */
++-- int v;
++-- void set_v (int n) { v = n; }
++-- int get_v (void) { return v; }
++--
++-- $ gcc -S -fPIC pic-sample.c
++-- $ gcc -c pic-sample.s -o pic-sample.no-pic.o # incorrect binary
++-- $ gcc -c -fPIC pic-sample.s -o pic-sample.pic.o # correct binary
++--
++-- $ objdump -r -d pic-sample.pic.o > pic-sample.pic.o.od
++-- $ objdump -r -d pic-sample.no-pic.o > pic-sample.no-pic.o.od
++-- $ diff -u pic-sample.pic.o.od pic-sample.no-pic.o.od
++--
++-- Most of architectures won't show any difference in this test, but on sparc32
++-- the following assembly snippet:
++--
++-- sethi %hi(_GLOBAL_OFFSET_TABLE_-8), %l7
++--
++-- generates two kinds or relocations, only 'R_SPARC_PC22' is correct:
++--
++-- 3c: 2f 00 00 00 sethi %hi(0), %l7
++-- - 3c: R_SPARC_PC22 _GLOBAL_OFFSET_TABLE_-0x8
++-- + 3c: R_SPARC_HI22 _GLOBAL_OFFSET_TABLE_-0x8
diff --git a/dev-lang/ghc/files/ghc-7.8.3-pic-sparc.patch b/dev-lang/ghc/files/ghc-7.8.3-pic-sparc.patch
new file mode 100644
index 00000000000..16a552fdd4b
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-pic-sparc.patch
@@ -0,0 +1,31 @@
+commit 78863edbb0751f5c9694ea10c6132a87cfd0ee10
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Wed Aug 27 22:20:33 2014 +0300
+
+ Revert "disable shared libs on sparc (linux/solaris) (fixes #8857)"
+
+ This reverts commit 623883f1ed0ee11cc925c4590fb09565403fd231.
+
+ The commit a93ab43ab5f40cadbedea2f6342b93c245e91434
+ driver: pass '-fPIC' option to assembler as well
+ fixes shared libraries on sparc at least on linux.
+
+ Properly fixes Issue #8857
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+diff --git a/mk/config.mk.in b/mk/config.mk.in
+index c210cd3..392237f 100644
+--- a/mk/config.mk.in
++++ b/mk/config.mk.in
+@@ -97,9 +97,7 @@ endif
+ # Some platforms don't support shared libraries
+ NoSharedLibsPlatformList = powerpc-unknown-linux \
+ x86_64-unknown-mingw32 \
+- i386-unknown-mingw32 \
+- sparc-sun-solaris2 \
+- sparc-unknown-linux
++ i386-unknown-mingw32
+
+ ifeq "$(SOLARIS_BROKEN_SHLD)" "YES"
+ NoSharedLibsPlatformList += i386-unknown-solaris2
diff --git a/dev-lang/ghc/files/ghc-7.8.3-ppc32-fPIC.patch b/dev-lang/ghc/files/ghc-7.8.3-ppc32-fPIC.patch
new file mode 100644
index 00000000000..434be8b1bda
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-ppc32-fPIC.patch
@@ -0,0 +1,351 @@
+commit fa31e8f4a0f853848d96549a429083941877bf8d
+Author: Sergei Trofimovich <siarheit@google.com>
+Date: Sun Dec 14 14:30:12 2014 +0000
+
+ powerpc: fix and enable shared libraries by default on linux
+
+ Summary:
+ And fix things all the way down to it. Namely:
+ - remove 'r30' from free registers, it's an .LCTOC1 register
+ for gcc. generated .plt stubs expect it to be initialised.
+ - fix PicBase computation, which originally forgot to use 'tmp'
+ reg in 'initializePicBase_ppc.fetchPC'
+ - mark 'ForeighTarget's as implicitly using 'PicBase' register
+ (see comment for details)
+ - add 64-bit MO_Sub and test on alloclimit3/4 regtests
+ - fix dynamic label offsets to match with .LCTOC1 offset
+
+ Signed-off-by: Sergei Trofimovich <siarheit@google.com>
+
+ Test Plan: validate passes equal amount of vanilla/dyn tests
+
+ Reviewers: simonmar, erikd, austin
+
+ Reviewed By: erikd, austin
+
+ Subscribers: carter, thomie
+
+ Differential Revision: https://phabricator.haskell.org/D560
+
+ GHC Trac Issues: #8024, #9831
+
+diff --git a/compiler/cmm/CLabel.hs b/compiler/cmm/CLabel.hs
+index 0f2c0ae..37b8ada 100644
+--- a/compiler/cmm/CLabel.hs
++++ b/compiler/cmm/CLabel.hs
+@@ -1170,7 +1170,8 @@ pprDynamicLinkerAsmLabel platform dllInfo lbl
+ else if osElfTarget (platformOS platform)
+ then if platformArch platform == ArchPPC
+ then case dllInfo of
+- CodeStub -> ppr lbl <> text "@plt"
++ CodeStub -> -- See Note [.LCTOC1 in PPC PIC code]
++ ppr lbl <> text "+32768@plt"
+ SymbolPtr -> text ".LC_" <> ppr lbl
+ _ -> panic "pprDynamicLinkerAsmLabel"
+ else if platformArch platform == ArchX86_64
+diff --git a/compiler/nativeGen/PIC.hs b/compiler/nativeGen/PIC.hs
+index 9b5c080..6326a8b 100644
+--- a/compiler/nativeGen/PIC.hs
++++ b/compiler/nativeGen/PIC.hs
+@@ -54,7 +54,6 @@ import qualified X86.Instr as X86
+
+ import Platform
+ import Instruction
+-import Size
+ import Reg
+ import NCGMonad
+
+@@ -468,11 +467,8 @@ pprGotDeclaration dflags ArchX86 OSDarwin
+ pprGotDeclaration _ _ OSDarwin
+ = empty
+
+--- pprGotDeclaration
++-- Emit GOT declaration
+ -- Output whatever needs to be output once per .s file.
+--- The .LCTOC1 label is defined to point 32768 bytes into the table,
+--- to make the most of the PPC's 16-bit displacements.
+--- Only needed for PIC.
+ pprGotDeclaration dflags arch os
+ | osElfTarget os
+ , arch /= ArchPPC_64
+@@ -482,6 +478,7 @@ pprGotDeclaration dflags arch os
+ | osElfTarget os
+ , arch /= ArchPPC_64
+ = vcat [
++ -- See Note [.LCTOC1 in PPC PIC code]
+ ptext (sLit ".section \".got2\",\"aw\""),
+ ptext (sLit ".LCTOC1 = .+32768") ]
+
+@@ -688,12 +685,7 @@ pprImportedSymbol _ _ _
+
+
+ -- Get a pointer to our own fake GOT, which is defined on a per-module basis.
+--- This is exactly how GCC does it, and it's quite horrible:
+--- We first fetch the address of a local label (mkPicBaseLabel).
+--- Then we add a 16-bit offset to that to get the address of a .long that we
+--- define in .text space right next to the proc. This .long literal contains
+--- the (32-bit) offset from our local label to our global offset table
+--- (.LCTOC1 aka gotOffLabel).
++-- This is exactly how GCC does it in linux.
+
+ initializePicBase_ppc
+ :: Arch -> OS -> Reg
+@@ -704,18 +696,9 @@ initializePicBase_ppc ArchPPC os picReg
+ (CmmProc info lab live (ListGraph blocks) : statics)
+ | osElfTarget os
+ = do
+- dflags <- getDynFlags
+- gotOffLabel <- getNewLabelNat
+- tmp <- getNewRegNat $ intSize (wordWidth dflags)
+ let
+- gotOffset = CmmData Text $ Statics gotOffLabel [
+- CmmStaticLit (CmmLabelDiffOff gotLabel
+- mkPicBaseLabel
+- 0)
+- ]
+- offsetToOffset
+- = PPC.ImmConstantDiff
+- (PPC.ImmCLbl gotOffLabel)
++ gotOffset = PPC.ImmConstantDiff
++ (PPC.ImmCLbl gotLabel)
+ (PPC.ImmCLbl mkPicBaseLabel)
+
+ blocks' = case blocks of
+@@ -726,15 +709,23 @@ initializePicBase_ppc ArchPPC os picReg
+ | bID `mapMember` info = fetchPC b
+ | otherwise = b
+
++ -- GCC does PIC prologs thusly:
++ -- bcl 20,31,.L1
++ -- .L1:
++ -- mflr 30
++ -- addis 30,30,.LCTOC1-.L1@ha
++ -- addi 30,30,.LCTOC1-.L1@l
++ -- TODO: below we use it over temporary register,
++ -- it can and should be optimised by picking
++ -- correct PIC reg.
+ fetchPC (BasicBlock bID insns) =
+ BasicBlock bID (PPC.FETCHPC picReg
+- : PPC.ADDIS tmp picReg (PPC.HI offsetToOffset)
+- : PPC.LD PPC.archWordSize tmp
+- (PPC.AddrRegImm tmp (PPC.LO offsetToOffset))
+- : PPC.ADD picReg picReg (PPC.RIReg picReg)
++ : PPC.ADDIS picReg picReg (PPC.HA gotOffset)
++ : PPC.ADDI picReg picReg (PPC.LO gotOffset)
++ : PPC.MR PPC.r30 picReg
+ : insns)
+
+- return (CmmProc info lab live (ListGraph blocks') : gotOffset : statics)
++ return (CmmProc info lab live (ListGraph blocks') : statics)
+
+
+ initializePicBase_ppc ArchPPC OSDarwin picReg
+diff --git a/compiler/nativeGen/PPC/CodeGen.hs b/compiler/nativeGen/PPC/CodeGen.hs
+index ddf483a..c1c4a74 100644
+--- a/compiler/nativeGen/PPC/CodeGen.hs
++++ b/compiler/nativeGen/PPC/CodeGen.hs
+@@ -54,7 +54,7 @@ import Outputable
+ import Unique
+ import DynFlags
+
+-import Control.Monad ( mapAndUnzipM )
++import Control.Monad ( mapAndUnzipM, when )
+ import Data.Bits
+ import Data.Word
+
+@@ -355,6 +355,19 @@ iselExpr64 (CmmMachOp (MO_Add _) [e1,e2]) = do
+ ADDE rhi r1hi r2hi ]
+ return (ChildCode64 code rlo)
+
++iselExpr64 (CmmMachOp (MO_Sub _) [e1,e2]) = do
++ ChildCode64 code1 r1lo <- iselExpr64 e1
++ ChildCode64 code2 r2lo <- iselExpr64 e2
++ (rlo,rhi) <- getNewRegPairNat II32
++ let
++ r1hi = getHiVRegFromLo r1lo
++ r2hi = getHiVRegFromLo r2lo
++ code = code1 `appOL`
++ code2 `appOL`
++ toOL [ SUBFC rlo r2lo r1lo,
++ SUBFE rhi r2hi r1hi ]
++ return (ChildCode64 code rlo)
++
+ iselExpr64 (CmmMachOp (MO_UU_Conv W32 W64) [expr]) = do
+ (expr_reg,expr_code) <- getSomeReg expr
+ (rlo, rhi) <- getNewRegPairNat II32
+@@ -918,8 +931,12 @@ genCCall' dflags gcp target dest_regs args0
+ (toOL []) []
+
+ (labelOrExpr, reduceToFF32) <- case target of
+- ForeignTarget (CmmLit (CmmLabel lbl)) _ -> return (Left lbl, False)
+- ForeignTarget expr _ -> return (Right expr, False)
++ ForeignTarget (CmmLit (CmmLabel lbl)) _ -> do
++ uses_pic_base_implicitly
++ return (Left lbl, False)
++ ForeignTarget expr _ -> do
++ uses_pic_base_implicitly
++ return (Right expr, False)
+ PrimTarget mop -> outOfLineMachOp mop
+
+ let codeBefore = move_sp_down finalStack `appOL` passArgumentsCode
+@@ -940,6 +957,13 @@ genCCall' dflags gcp target dest_regs args0
+ where
+ platform = targetPlatform dflags
+
++ uses_pic_base_implicitly = do
++ -- See Note [implicit register in PPC PIC code]
++ -- on why we claim to use PIC register here
++ when (gopt Opt_PIC dflags) $ do
++ _ <- getPicBaseNat archWordSize
++ return ()
++
+ initialStackOffset = case gcp of
+ GCPDarwin -> 24
+ GCPLinux -> 8
+@@ -1431,3 +1455,21 @@ coerceFP2Int _ toRep x = do
+ -- read low word of value (high word is undefined)
+ LD II32 dst (spRel dflags 3)]
+ return (Any (intSize toRep) code')
++
++-- Note [.LCTOC1 in PPC PIC code]
++-- The .LCTOC1 label is defined to point 32768 bytes into the GOT table
++-- to make the most of the PPC's 16-bit displacements.
++-- As 16-bit signed offset is used (usually via addi/lwz instructions)
++-- first element will have '-32768' offset against .LCTOC1.
++
++-- Note [implicit register in PPC PIC code]
++-- PPC generates calls by labels in assembly
++-- in form of:
++-- bl puts+32768@plt
++-- in this form it's not seen directly (by GHC NCG)
++-- that r30 (PicBaseReg) is used,
++-- but r30 is a required part of PLT code setup:
++-- puts+32768@plt:
++-- lwz r11,-30484(r30) ; offset in .LCTOC1
++-- mtctr r11
++-- bctr
+diff --git a/compiler/nativeGen/PPC/Instr.hs b/compiler/nativeGen/PPC/Instr.hs
+index f5b9506..b7081f9 100644
+--- a/compiler/nativeGen/PPC/Instr.hs
++++ b/compiler/nativeGen/PPC/Instr.hs
+@@ -205,8 +205,11 @@ data Instr
+ | ADD Reg Reg RI -- dst, src1, src2
+ | ADDC Reg Reg Reg -- (carrying) dst, src1, src2
+ | ADDE Reg Reg Reg -- (extend) dst, src1, src2
++ | ADDI Reg Reg Imm -- Add Immediate dst, src1, src2
+ | ADDIS Reg Reg Imm -- Add Immediate Shifted dst, src1, src2
+ | SUBF Reg Reg Reg -- dst, src1, src2 ; dst = src2 - src1
++ | SUBFC Reg Reg Reg -- (carrying) dst, src1, src2 ; dst = src2 - src1
++ | SUBFE Reg Reg Reg -- (extend) dst, src1, src2 ; dst = src2 - src1
+ | MULLW Reg Reg RI
+ | DIVW Reg Reg Reg
+ | DIVWU Reg Reg Reg
+@@ -284,8 +287,11 @@ ppc_regUsageOfInstr platform instr
+ ADD reg1 reg2 ri -> usage (reg2 : regRI ri, [reg1])
+ ADDC reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
+ ADDE reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
++ ADDI reg1 reg2 _ -> usage ([reg2], [reg1])
+ ADDIS reg1 reg2 _ -> usage ([reg2], [reg1])
+ SUBF reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
++ SUBFC reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
++ SUBFE reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
+ MULLW reg1 reg2 ri -> usage (reg2 : regRI ri, [reg1])
+ DIVW reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
+ DIVWU reg1 reg2 reg3 -> usage ([reg2,reg3], [reg1])
+@@ -358,8 +364,11 @@ ppc_patchRegsOfInstr instr env
+ ADD reg1 reg2 ri -> ADD (env reg1) (env reg2) (fixRI ri)
+ ADDC reg1 reg2 reg3 -> ADDC (env reg1) (env reg2) (env reg3)
+ ADDE reg1 reg2 reg3 -> ADDE (env reg1) (env reg2) (env reg3)
++ ADDI reg1 reg2 imm -> ADDI (env reg1) (env reg2) imm
+ ADDIS reg1 reg2 imm -> ADDIS (env reg1) (env reg2) imm
+ SUBF reg1 reg2 reg3 -> SUBF (env reg1) (env reg2) (env reg3)
++ SUBFC reg1 reg2 reg3 -> SUBFC (env reg1) (env reg2) (env reg3)
++ SUBFE reg1 reg2 reg3 -> SUBFE (env reg1) (env reg2) (env reg3)
+ MULLW reg1 reg2 ri -> MULLW (env reg1) (env reg2) (fixRI ri)
+ DIVW reg1 reg2 reg3 -> DIVW (env reg1) (env reg2) (env reg3)
+ DIVWU reg1 reg2 reg3 -> DIVWU (env reg1) (env reg2) (env reg3)
+diff --git a/compiler/nativeGen/PPC/Ppr.hs b/compiler/nativeGen/PPC/Ppr.hs
+index 6851769..f59d51f 100644
+--- a/compiler/nativeGen/PPC/Ppr.hs
++++ b/compiler/nativeGen/PPC/Ppr.hs
+@@ -525,6 +525,16 @@ pprInstr (BCTRL _) = hcat [
+ ptext (sLit "bctrl")
+ ]
+ pprInstr (ADD reg1 reg2 ri) = pprLogic (sLit "add") reg1 reg2 ri
++pprInstr (ADDI reg1 reg2 imm) = hcat [
++ char '\t',
++ ptext (sLit "addi"),
++ char '\t',
++ pprReg reg1,
++ ptext (sLit ", "),
++ pprReg reg2,
++ ptext (sLit ", "),
++ pprImm imm
++ ]
+ pprInstr (ADDIS reg1 reg2 imm) = hcat [
+ char '\t',
+ ptext (sLit "addis"),
+@@ -539,6 +549,8 @@ pprInstr (ADDIS reg1 reg2 imm) = hcat [
+ pprInstr (ADDC reg1 reg2 reg3) = pprLogic (sLit "addc") reg1 reg2 (RIReg reg3)
+ pprInstr (ADDE reg1 reg2 reg3) = pprLogic (sLit "adde") reg1 reg2 (RIReg reg3)
+ pprInstr (SUBF reg1 reg2 reg3) = pprLogic (sLit "subf") reg1 reg2 (RIReg reg3)
++pprInstr (SUBFC reg1 reg2 reg3) = pprLogic (sLit "subfc") reg1 reg2 (RIReg reg3)
++pprInstr (SUBFE reg1 reg2 reg3) = pprLogic (sLit "subfe") reg1 reg2 (RIReg reg3)
+ pprInstr (MULLW reg1 reg2 ri@(RIReg _)) = pprLogic (sLit "mullw") reg1 reg2 ri
+ pprInstr (MULLW reg1 reg2 ri@(RIImm _)) = pprLogic (sLit "mull") reg1 reg2 ri
+ pprInstr (DIVW reg1 reg2 reg3) = pprLogic (sLit "divw") reg1 reg2 (RIReg reg3)
+diff --git a/compiler/nativeGen/PPC/Regs.hs b/compiler/nativeGen/PPC/Regs.hs
+index 0f636bf..69e69c0 100644
+--- a/compiler/nativeGen/PPC/Regs.hs
++++ b/compiler/nativeGen/PPC/Regs.hs
+@@ -37,7 +37,8 @@ module PPC.Regs (
+ fits16Bits,
+ makeImmediate,
+ fReg,
+- sp, r3, r4, r27, r28, f1, f20, f21,
++ sp, r3, r4, r27, r28, r30,
++ f1, f20, f21,
+
+ allocatableRegs
+
+@@ -295,12 +296,13 @@ point registers.
+ fReg :: Int -> RegNo
+ fReg x = (32 + x)
+
+-sp, r3, r4, r27, r28, f1, f20, f21 :: Reg
++sp, r3, r4, r27, r28, r30, f1, f20, f21 :: Reg
+ sp = regSingle 1
+ r3 = regSingle 3
+ r4 = regSingle 4
+ r27 = regSingle 27
+ r28 = regSingle 28
++r30 = regSingle 30
+ f1 = regSingle $ fReg 1
+ f20 = regSingle $ fReg 20
+ f21 = regSingle $ fReg 21
+diff --git a/includes/CodeGen.Platform.hs b/includes/CodeGen.Platform.hs
+index 9916e0e..1d46a01 100644
+--- a/includes/CodeGen.Platform.hs
++++ b/includes/CodeGen.Platform.hs
+@@ -881,6 +881,8 @@ freeReg 1 = fastBool False -- The Stack Pointer
+ # if !MACHREGS_darwin
+ -- most non-darwin powerpc OSes use r2 as a TOC pointer or something like that
+ freeReg 2 = fastBool False
++-- at least linux in -fPIC relies on r30 in PLT stubs
++freeReg 30 = fastBool False
+ # endif
+ # ifdef REG_Base
+ freeReg REG_Base = fastBool False
+diff --git a/mk/config.mk.in b/mk/config.mk.in
+index 0f5820f..8f134bc 100644
+--- a/mk/config.mk.in
++++ b/mk/config.mk.in
+@@ -95,7 +95,7 @@ TargetElf = YES
+ endif
+
+ # Some platforms don't support shared libraries
+-NoSharedLibsPlatformList = powerpc-unknown-linux \
++NoSharedLibsPlatformList = \
+ x86_64-unknown-mingw32 \
+ i386-unknown-mingw32
+
diff --git a/dev-lang/ghc/files/ghc-7.8.3-prim-lm.patch b/dev-lang/ghc/files/ghc-7.8.3-prim-lm.patch
new file mode 100644
index 00000000000..3ef2313fcec
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-prim-lm.patch
@@ -0,0 +1,12 @@
+Fix underlinking on ghc-prim.
+Fixes ghc-stage2 crahs on hardened toolchain.
+Reported-by: aranea
+diff --git a/libraries/ghc-prim/ghc-prim.cabal b/libraries/ghc-prim/ghc-prim.cabal
+index ffb32af..0431380 100644
+--- a/libraries/ghc-prim/ghc-prim.cabal
++++ b/libraries/ghc-prim/ghc-prim.cabal
+@@ -68,0 +68,4 @@ Library
++
++ -- ghc 'sin' (and other) primops generate 'libm' calls,
++ -- but ghc itself does not add '-lm'
++ extra-libraries: m
diff --git a/dev-lang/ghc/files/ghc-7.8.3-unreg-lit.patch b/dev-lang/ghc/files/ghc-7.8.3-unreg-lit.patch
new file mode 100644
index 00000000000..632696d6fde
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.3-unreg-lit.patch
@@ -0,0 +1,84 @@
+commit a6ea05e21e175407dc9e45f18c56c1d727fd0f26
+Author: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Fri Aug 22 23:24:32 2014 +0300
+
+ UNREG: fix emission of large Integer literals in C codegen
+
+ Summary:
+ On amd64/UNREG build there is many failing tests trying
+ to deal with 'Integer' types.
+
+ Looking at 'overflow1' test I've observed invalid C code generated by
+ GHC.
+
+ Cmm code
+ CInt a = -1; (a == -1)
+ yields 'False' with optimisations enabled via the following C code:
+ StgWord64 a = (StgWord32)0xFFFFffffFFFFffffu; (a == 0xFFFFffffFFFFffffu)
+
+ The patch fixes it by shrinking emitted literals to required sizes:
+ StgWord64 a = (StgWord32)0xFFFFffffu; (a == 0xFFFFffffu)
+
+ Thanks to Reid Barton for tracking down and fixing the issue.
+
+ Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+
+ Test Plan: validate on UNREG build (amd64)
+
+ Reviewers: simonmar, rwbarton, austin
+
+ Subscribers: simonmar, ezyang, carter
+
+ Differential Revision: https://phabricator.haskell.org/D173
+
+diff --git a/compiler/cmm/PprC.hs b/compiler/cmm/PprC.hs
+index 93a5d06..8605988 100644
+--- a/compiler/cmm/PprC.hs
++++ b/compiler/cmm/PprC.hs
+@@ -1221,8 +1221,9 @@ commafy xs = hsep $ punctuate comma xs
+ pprHexVal :: Integer -> Width -> SDoc
+ pprHexVal 0 _ = ptext (sLit "0x0")
+ pprHexVal w rep
+- | w < 0 = parens (char '-' <> ptext (sLit "0x") <> go (-w) <> repsuffix rep)
+- | otherwise = ptext (sLit "0x") <> go w <> repsuffix rep
++ | w < 0 = parens (char '-' <>
++ ptext (sLit "0x") <> intToDoc (-w) <> repsuffix rep)
++ | otherwise = ptext (sLit "0x") <> intToDoc w <> repsuffix rep
+ where
+ -- type suffix for literals:
+ -- Integer literals are unsigned in Cmm/C. We explicitly cast to
+@@ -1237,10 +1238,33 @@ pprHexVal w rep
+ else panic "pprHexVal: Can't find a 64-bit type"
+ repsuffix _ = char 'U'
+
++ intToDoc :: Integer -> SDoc
++ intToDoc i = go (truncInt i)
++
++ -- We need to truncate value as Cmm backend does not drop
++ -- redundant bits to ease handling of negative values.
++ -- Thus the following Cmm code on 64-bit arch, like amd64:
++ -- CInt v;
++ -- v = {something};
++ -- if (v == %lobits32(-1)) { ...
++ -- leads to the following C code:
++ -- StgWord64 v = (StgWord32)({something});
++ -- if (v == 0xFFFFffffFFFFffffU) { ...
++ -- Such code is incorrect as it promotes both operands to StgWord64
++ -- and the whole condition is always false.
++ truncInt :: Integer -> Integer
++ truncInt i =
++ case rep of
++ W8 -> i `rem` (2^(8 :: Int))
++ W16 -> i `rem` (2^(16 :: Int))
++ W32 -> i `rem` (2^(32 :: Int))
++ W64 -> i `rem` (2^(64 :: Int))
++ _ -> panic ("pprHexVal/truncInt: C backend can't encode "
++ ++ show rep ++ " literals")
++
+ go 0 = empty
+ go w' = go q <> dig
+ where
+ (q,r) = w' `quotRem` 16
+ dig | r < 10 = char (chr (fromInteger r + ord '0'))
+ | otherwise = char (chr (fromInteger r - 10 + ord 'a'))
+-
diff --git a/dev-lang/ghc/files/ghc-7.8.4-gold.patch b/dev-lang/ghc/files/ghc-7.8.4-gold.patch
new file mode 100644
index 00000000000..a8e9b1e6c85
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.4-gold.patch
@@ -0,0 +1,27 @@
+Gentoo-bug: https://bugs.gentoo.org/536426
+Reported-by: Eric Siegel
+commit 021b7978d14799bae779907faf7490cfd21b3f46
+Author: Austin Seipp <austin@well-typed.com>
+Date: Sun Jul 20 10:13:15 2014 -0500
+
+ driver: use absolute paths in ld scripts (#7452)
+
+ Patch contributed by slowmo.
+
+ Signed-off-by: Austin Seipp <austin@well-typed.com>
+
+diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs
+index 11427e2..49126fe 100644
+--- a/compiler/main/DriverPipeline.hs
++++ b/compiler/main/DriverPipeline.hs
+@@ -2166,7 +2166,9 @@ joinObjectFiles dflags o_files output_fn = do
+ if ldIsGnuLd
+ then do
+ script <- newTempName dflags "ldscript"
+- writeFile script $ "INPUT(" ++ unwords o_files ++ ")"
++ cwd <- getCurrentDirectory
++ let o_files_abs = map (cwd </>) o_files
++ writeFile script $ "INPUT(" ++ unwords o_files_abs ++ ")"
+ ld_r [SysTools.FileOption "" script] ccInfo
+ else if sLdSupportsFilelist mySettings
+ then do
diff --git a/dev-lang/ghc/files/ghc-7.8.4-ia64-CLOSUREs.patch b/dev-lang/ghc/files/ghc-7.8.4-ia64-CLOSUREs.patch
new file mode 100644
index 00000000000..9d50792bcf4
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-7.8.4-ia64-CLOSUREs.patch
@@ -0,0 +1,66 @@
+From b677ba51cf8131a6f6ddcdfee8dd2a8c4c2b4ac7 Mon Sep 17 00:00:00 2001
+From: Sergei Trofimovich <siarheit@google.com>
+Date: Sat, 17 Jan 2015 14:27:13 +0000
+Subject: [PATCH 1/3] CMM: add a mechanism to import C data labels
+
+Fixes threaded runtime on ia64.
+sm_mutex there was not referenced correctly.
+
+Signed-off-by: Sergei Trofimovich <siarheit@google.com>
+---
+ compiler/cmm/CmmParse.y | 4 ++++
+ rts/Exception.cmm | 2 +-
+ rts/PrimOps.cmm | 6 +++---
+ 3 files changed, 8 insertions(+), 4 deletions(-)
+
+diff --git a/compiler/cmm/CmmParse.y.source b/compiler/cmm/CmmParse.y.source
+index 6b51e51..fd9489b 100644
+--- a/compiler/cmm/CmmParse.y.source
++++ b/compiler/cmm/CmmParse.y.source
+@@ -575,6 +575,10 @@ importName
+ : NAME
+ { ($1, mkForeignLabel $1 Nothing ForeignLabelInExternalPackage IsFunction) }
+
++ -- as previous 'NAME', but 'IsData'
++ | 'CLOSURE' NAME
++ { ($2, mkForeignLabel $2 Nothing ForeignLabelInExternalPackage IsData) }
++
+ -- A label imported with an explicit packageId.
+ | STRING NAME
+ { ($2, mkCmmCodeLabel (fsToPackageKey (mkFastString $1)) $2) }
+diff --git a/rts/Exception.cmm b/rts/Exception.cmm
+index 5007ef3..8d19c14 100644
+--- a/rts/Exception.cmm
++++ b/rts/Exception.cmm
+@@ -13,7 +13,7 @@
+ #include "Cmm.h"
+ #include "RaiseAsync.h"
+
+-import ghczmprim_GHCziTypes_True_closure;
++import CLOSURE ghczmprim_GHCziTypes_True_closure;
+
+ /* -----------------------------------------------------------------------------
+ Exception Primitives
+diff --git a/rts/PrimOps.cmm b/rts/PrimOps.cmm
+index 3e8612c..2e6ca46 100644
+--- a/rts/PrimOps.cmm
++++ b/rts/PrimOps.cmm
+@@ -28,12 +28,12 @@
+ import pthread_mutex_lock;
+ import pthread_mutex_unlock;
+ #endif
+-import base_ControlziExceptionziBase_nestedAtomically_closure;
++import CLOSURE base_ControlziExceptionziBase_nestedAtomically_closure;
+ import EnterCriticalSection;
+ import LeaveCriticalSection;
+-import ghczmprim_GHCziTypes_False_closure;
++import CLOSURE ghczmprim_GHCziTypes_False_closure;
+ #if defined(USE_MINIINTERPRETER) || !defined(mingw32_HOST_OS)
+-import sm_mutex;
++import CLOSURE sm_mutex;
+ #endif
+
+ /*-----------------------------------------------------------------------------
+--
+2.2.1
+
diff --git a/dev-lang/ghc/files/ghc-bash-completion b/dev-lang/ghc/files/ghc-bash-completion
new file mode 100644
index 00000000000..0ee2149cd81
--- /dev/null
+++ b/dev-lang/ghc/files/ghc-bash-completion
@@ -0,0 +1,218 @@
+# ghc-pkg command line completion for bash
+#
+# Copyright 2006-2007 Lennart Kolmodin <kolmodin@dtek.chalmers.se>
+
+_ghc-pkg-get-ghc-pkg()
+{
+ echo ghc-pkg
+}
+
+_ghc-pkg-pkg-fields()
+{
+ # usage: _ghc-pkg-pkg-fields pkg-id
+ #
+ # list all fields of the pkg-id
+
+ # same fields for all packages but different in different versions of
+ # ghc-pkg? this can probably be done better/faster
+
+ if [[ -z "$1" ]]; then
+ echo "usage: _ghc-pkg-pkg-fields pkg-id"
+ return 1
+ fi
+
+ local fields
+
+ fields="$( $(_ghc-pkg-get-ghc-pkg) describe $1 )"
+
+ #if [[ fields != *"cannot find package"* ]]; then
+ echo "$fields" | grep ".*:.*" | sed "s/^\(.*\):.*\$/\1/"
+ #fi
+}
+
+_ghc-pkg-pkg-ids()
+{
+ # usage: _ghc-pkg-pkg-ids
+ #
+ # simply lists all package ids known by ghc-pkg.
+ $(_ghc-pkg-get-ghc-pkg) list --simple-output
+}
+
+_ghc-pkg-pkgs()
+{
+ # usage: _ghc-pkg-pkgs [include-pkgs] [include-ids]
+ #
+ # with optional parameter include-pkgs it will list all packages known
+ # to ghc-pkg.
+ # with optional parameter include-ids it will list all package-ids known
+ # to ghc-pkg.
+ local pkgs
+ local result
+ pkgs=( $( _ghc-pkg-pkg-ids ) )
+ result=( )
+
+ local withPkgs="no" withIds="no"
+ while [[ -n "$1" ]]; do
+ case "$1" in
+ include-pkgs)
+ withPkgs="yes" ;;
+ include-ids)
+ withIds="yes" ;;
+ *)
+ echo "unknown parameter '$1' to _ghc-pkg-pkgs"
+ return 1 ;;
+ esac
+ shift
+ done
+
+ # user must supply either include-pkgs, include-ids or both
+ if [[ $withPkgs != "yes" && $withIds != "yes" ]]; then
+ echo "usage: _ghc-pkg-pkgs [include-pkgs] [include-ids]"
+ return 1
+ fi
+
+ # find all packages if the user requested them
+ if [[ $withPkgs == "yes" ]]; then
+ # O(n^2) algorithm to exclude duplicates
+ for p in ${pkgs[*]}; do
+ p="${p//-[0-9.]*/}"
+ for existing in ${result[*]}; do
+ if [[ "$existing" == "$p" ]]; then
+ continue 2
+ fi
+ done
+ result=( "${result[@]}" "${p}" )
+ done
+ fi
+
+ # include all pkg-ids if requested
+ if [[ $withIds == "yes" ]]; then
+ result=( "${result[@]}" "${pkgs[@]}" )
+ fi
+
+ # we are finished, echo the result
+ echo "${result[*]}"
+
+ # happy ending
+ return 0
+}
+
+_ghc-pkg()
+{
+ local cur
+ cur=${COMP_WORDS[COMP_CWORD]}
+
+ COMPREPLY=()
+
+ local actions flags
+ actions='register update unregister expose hide list latest describe field'
+ dbflags="--user \
+ --global \
+ -f --package-conf= \
+ --global-conf="
+ registerflags="--force \
+ -g --auto-ghci-libs \
+ -D --define-name="
+ listflags="--simple-output"
+ flags="$dbflags \
+ $registerflags \
+ $listflags \
+ -? --help \
+ -V --version"
+
+ # if it's the users first word; complete it and return
+ if (($COMP_CWORD == 1)); then
+ COMPREPLY=( $( compgen -W "$actions $flags" -- $cur ) )
+ return 0
+ fi
+
+ # now we know we have at least one word written
+
+ local action="unknown" \
+ prev numwords \
+ cword act
+ prev=${COMP_WORDS[COMP_CWORD-1]}
+ numwords=${#COMP_WORDS[@]}
+
+ # find the action with O(n*m) algorithm
+ # where n = ${#COMP_WORDS[*]}
+ # m = number of actions
+ for cword in ${COMP_WORDS[*]}; do
+ for act in $actions; do
+ if [[ "$cword" == "$act" ]]; then
+ action=$cword
+ fi
+ done
+ done
+
+ case $action in
+ register|update)
+ # we want to complete both flags and paths, how?
+ # we do it by checking if the user has started to write a flag
+ # or a path, and then decide what to complete.
+ # that is, to complete a flag, the user must start to write a '-'
+ if [[ "$cur" == -* ]]; then
+ # (we assume) it's the start of a flag
+ # set COMPREPLY to flags relevant to these actions
+ COMPREPLY=( $( compgen -W "$dbflags $registerflags" -- $cur ) )
+ fi
+ ;;
+ unregister|expose|hide|list|describe)
+ # all these actions can be completed with exactly one argument,
+ # a pkg-id.
+ COMPREPLY=( $( compgen -W "$dbflags" -- $cur ) )
+
+ # add special flags for some actions
+ if [[ "$action" == "list" ]]; then
+ COMPREPLY+=( $( compgen -W "$listflags" -- $cur ) )
+ fi
+
+ COMPREPLY+=( $( compgen -W "$( _ghc-pkg-pkgs include-ids )" -- $cur ) )
+ ;;
+ latest)
+ # complete only packages, not package ids
+ COMPREPLY=( $( compgen -W "$( _ghc-pkg-pkgs include-pkgs )" -- $cur ) )
+ ;;
+ field)
+ # we should always complete on the flags...
+ COMPREPLY=( $( compgen -W "$dbflags" -- $cur ) )
+
+ # then, we should either complete the package name or the field
+ # lets find out which one
+
+ # find the number of words in COMP_WORDS before COMP_CWORD that
+ # isn't flags. it should be 2 or 3 for us to complete it,
+ # exactly 2 if we should complete the package name
+ # exactly 3 if we should complete the field name
+ # otherwise, don't do any additional completion except the
+ # flags
+
+ # count the number of non flags up till the current word
+ local numnonflags=0 lastword i
+ for (( i=0 ; $i < $COMP_CWORD ; i++ )); do
+ if [[ ${COMP_WORDS[$i]} != -* ]]; then
+ lastword=${COMP_WORDS[$i]}
+ numnonflags=$(( ++numnonflags ))
+ fi
+ done
+
+ case $numnonflags in
+ 2)
+ # complete on pkg-ids
+ COMPREPLY+=( $( compgen -W "$( _ghc-pkg-pkgs include-ids )" -- $cur ) ) ;;
+ 3)
+ # complete on fields
+ COMPREPLY+=( $( compgen -W "$( _ghc-pkg-pkg-fields $lastword )" -- $cur ) ) ;;
+ esac
+ ;;
+ *)
+ # unknown action, not yet given by the user
+ # return all possible completions
+ COMPREPLY=( $( compgen -W "$actions $flags" -- $cur ) )
+ ;;
+ esac
+}
+
+complete -F _ghc-pkg -o default ghc-pkg
+
+# vim: set ft=sh tw=80 sw=4 et :
diff --git a/dev-lang/ghc/files/terminfo-0.3.2.5-tinfo.patch b/dev-lang/ghc/files/terminfo-0.3.2.5-tinfo.patch
new file mode 100644
index 00000000000..ca10da2e03a
--- /dev/null
+++ b/dev-lang/ghc/files/terminfo-0.3.2.5-tinfo.patch
@@ -0,0 +1,25 @@
+http://bugs.gentoo.org/454216
+
+Mon Jan 7 16:34:47 FET 2013 Judah Jacobson <judah.jacobson@gmail.com>
+ * Search for terminfo in libtinfo; fixes GHC #7281.
+
+ Patch from Paul Johnson.
+diff -rN -u old-terminfo/configure.ac new-terminfo/configure.ac
+--- old-terminfo/configure.ac 2013-02-14 00:16:11.816111434 +0300
++++ new-terminfo/configure.ac 2013-02-14 00:16:11.819111434 +0300
+@@ -39,10 +39,11 @@
+ TERMINFO_INCLUDES="$CursesIncludes term.h"
+ fi
+
+-AC_CHECK_LIB(ncursesw, setupterm, HaveLibCurses=YES; LibCurses=ncursesw,
+- [AC_CHECK_LIB(ncurses, setupterm, HaveLibCurses=YES; LibCurses=ncurses,
+- [AC_CHECK_LIB(curses, setupterm, HaveLibCurses=YES; LibCurses=curses,
+- HaveLibCurses=NO; LibCurses=not-installed)])])
++AC_CHECK_LIB(tinfo, setupterm, HaveLibCurses=YES; LibCurses=tinfo,
++ [AC_CHECK_LIB(ncursesw, setupterm, HaveLibCurses=YES; LibCurses=ncursesw,
++ [AC_CHECK_LIB(ncurses, setupterm, HaveLibCurses=YES; LibCurses=ncurses,
++ [AC_CHECK_LIB(curses, setupterm, HaveLibCurses=YES; LibCurses=curses,
++ HaveLibCurses=NO; LibCurses=not-installed)])])])
+
+ if test "x$HaveLibCurses" = "xNO" ; then
+ AC_MSG_FAILURE([curses library not found, so this package cannot be built])
diff --git a/dev-lang/ghc/ghc-7.10.2.ebuild b/dev-lang/ghc/ghc-7.10.2.ebuild
new file mode 100644
index 00000000000..9aab30fd6f2
--- /dev/null
+++ b/dev-lang/ghc/ghc-7.10.2.ebuild
@@ -0,0 +1,643 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+# to make make a crosscompiler use crossdev and symlink ghc tree into
+# cross overlay. result would look like 'cross-sparc-unknown-linux-gnu/ghc'
+#
+# 'CTARGET' definition and 'is_crosscompile' are taken from 'toolchain.eclass'
+export CTARGET=${CTARGET:-${CHOST}}
+if [[ ${CTARGET} = ${CHOST} ]] ; then
+ if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
+ export CTARGET=${CATEGORY/cross-}
+ fi
+fi
+
+inherit autotools bash-completion-r1 eutils flag-o-matic ghc-package
+inherit multilib pax-utils toolchain-funcs versionator
+
+DESCRIPTION="The Glasgow Haskell Compiler"
+HOMEPAGE="http://www.haskell.org/ghc/"
+
+# we don't have any binaries yet
+arch_binaries=""
+
+# sorted!
+#arch_binaries="$arch_binaries alpha? ( http://code.haskell.org/~slyfox/ghc-alpha/ghc-bin-${PV}-alpha.tbz2 )"
+#arch_binaries="$arch_binaries arm? ( http://code.haskell.org/~slyfox/ghc-arm/ghc-bin-${PV}-arm.tbz2 )"
+arch_binaries="$