/[gentoo-x86]/sci-electronics/ghdl/ghdl-0.29.ebuild
Gentoo

Contents of /sci-electronics/ghdl/ghdl-0.29.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (hide annotations) (download)
Sun Aug 4 09:10:43 2013 UTC (6 years, 7 months ago) by tomjbe
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +7 -4 lines
Fix bug #477552, use <texinfo-5.1. Thanks qnikst for providing the patch

(Portage version: 2.1.13.4/cvs/Linux x86_64, signed Manifest commit with key 0x762053D5)

1 tomjbe 1.4 # Copyright 1999-2013 Gentoo Foundation
2 calchan 1.1 # Distributed under the terms of the GNU General Public License v2
3 tomjbe 1.4 # $Header: /var/cvsroot/gentoo-x86/sci-electronics/ghdl/ghdl-0.29.ebuild,v 1.3 2011/05/14 14:34:21 tomjbe Exp $
4 calchan 1.1
5 tomjbe 1.3 EAPI="3"
6 calchan 1.1
7 tomjbe 1.4 inherit eutils multilib
8 calchan 1.1
9     GCC_VERSION="4.3.4"
10     GNATGCC_SLOT="4.3"
11    
12     DESCRIPTION="Complete VHDL simulator using the GCC technology"
13     HOMEPAGE="http://ghdl.free.fr"
14     SRC_URI="http://ghdl.free.fr/${P}.tar.bz2
15     mirror://gnu/gcc/releases/gcc-${GCC_VERSION}/gcc-core-${GCC_VERSION}.tar.bz2"
16     LICENSE="GPL-2"
17     SLOT="0"
18     KEYWORDS="~amd64 ~ppc ~x86"
19     IUSE=""
20 tomjbe 1.4 DEPEND="<sys-apps/texinfo-5.1
21 calchan 1.1 dev-lang/gnat-gcc:${GNATGCC_SLOT}"
22     RDEPEND=""
23     S="${WORKDIR}/gcc-${GCC_VERSION}"
24    
25     ADA_INCLUDE_PATH="${ROOT}/usr/lib/gnat-gcc/${CHOST}/${GNATGCC_SLOT}/adainclude"
26     ADA_OBJECTS_PATH="${ROOT}/usr/lib/gnat-gcc/${CHOST}/${GNATGCC_SLOT}/adalib"
27     GNATGCC_PATH="${ROOT}/usr/${CHOST}/gnat-gcc-bin/${GNATGCC_SLOT}:${ROOT}/usr/libexec/gnat-gcc/${CHOST}/${GNATGCC_SLOT}"
28    
29     src_prepare() {
30     mv "${WORKDIR}/${P}"/vhdl gcc
31     sed -i -e 's/ADAC = \$(CC)/ADAC = gnatgcc/' gcc/vhdl/Makefile.in || die "sed failed"
32     sed -i \
33     -e 's/AGCC_CFLAGS=-g/AGCC_CFLAGS=$(CFLAGS)/' \
34     -e 's/rm -rf $(infodir)/rm -rf $(DESTDIR)$(infodir)/' \
35     gcc/vhdl/Make-lang.in || die "sed failed"
36    
37     # Fix issue similar to bug #195074, ported from vapier's fix for binutils
38     sed -i -e "s:egrep.*texinfo.*dev/null:egrep 'texinfo[^0-9]*(4\.([4-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null:" \
39     configure* || die "sed failed"
40    
41     # For multilib profile arch, see bug #203721
42     if (has_multilib_profile || use multilib ) ; then
43     for T_LINUX64 in `find "${S}/gcc/config" -name t-linux64` ;
44     do
45     einfo "sed for ${T_LINUX64} for multilib. :)"
46     sed -i \
47     -e "s:\(MULTILIB_OSDIRNAMES = \).*:\1../lib64 ../lib32:" \
48     "${T_LINUX64}" \
49     || die "sed for ${T_LINUX64} failed. :("
50     done
51     fi
52 tomjbe 1.4
53     # fix for bug #477552 backported from bug #424970
54     epatch "${FILESDIR}"/${P}-gcc.patch
55 calchan 1.1 }
56    
57     src_configure() {
58     PATH="${GNATGCC_PATH}:${PATH}" econf --enable-languages=vhdl
59     }
60    
61     src_compile() {
62     PATH="${GNATGCC_PATH}:${PATH}" emake -j1 || die "Compilation failed"
63     }
64    
65     src_install() {
66     # bug #277644
67 tomjbe 1.2 PATH="${GNATGCC_PATH}:${PATH}" emake -j1 DESTDIR="${D}" install || die "Installation failed"
68 calchan 1.1
69     cd "${D}"/usr/bin ; rm `ls --ignore=ghdl`
70     rm -rf "${D}"/usr/include
71     rm "${D}"/usr/$(get_libdir)/lib*
72     cd "${D}"/usr/$(get_libdir)/gcc/${CHOST}/${GCC_VERSION} ; rm -rf `ls --ignore=vhdl*`
73     cd "${D}"/usr/libexec/gcc/${CHOST}/${GCC_VERSION} ; rm -rf `ls --ignore=ghdl*`
74     cd "${D}"/usr/share/info ; rm `ls --ignore=ghdl*`
75     cd "${D}"/usr/share/man/man1 ; rm `ls --ignore=ghdl*`
76     rm -Rf "${D}"/usr/share/locale
77     rm -Rf "${D}"/usr/share/man/man7
78     }

  ViewVC Help
Powered by ViewVC 1.1.20