/[gentoo-x86]/net-misc/mico/mico-2.3.13-r4.ebuild
Gentoo

Contents of /net-misc/mico/mico-2.3.13-r4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Wed Dec 1 09:57:46 2010 UTC (3 years, 9 months ago) by haubi
Branch: MAIN
EAPI 3 bump. Listen to CFLAGS/CXXFLAGS. Better grouping of econf options.
(Portage version: 2.1.8.3/cvs/Linux x86_64)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/mico/mico-2.3.13-r3.ebuild,v 1.6 2010/08/16 15:17:14 haubi Exp $
4
5 EAPI="3"
6
7 inherit eutils flag-o-matic toolchain-funcs
8
9 DESCRIPTION="A freely available and fully compliant implementation of the CORBA standard"
10 HOMEPAGE="http://www.mico.org/"
11 SRC_URI="http://www.mico.org/${P}.tar.gz"
12
13 PATCH_VER=0.1
14
15 LICENSE="GPL-2 LGPL-2"
16 SLOT="0"
17 KEYWORDS="~alpha ~amd64 ~ppc ~sparc ~x86 ~ppc-aix ~ia64-hpux ~amd64-linux ~x86-linux ~sparc-solaris ~x86-winnt"
18 IUSE="gtk postgres qt4 ssl tcl threads X"
19 RESTRICT="test" #298101
20
21 [[ -z ${PATCH_VER} ]] || \
22 SRC_URI="${SRC_URI} mirror://gentoo/${P}-gentoo-patches-${PATCH_VER}.tar.bz2"
23
24 # doesn't compile:
25 # bluetooth? ( net-wireless/bluez )
26
27 RDEPEND="
28 gtk? ( x11-libs/gtk+:2 )
29 postgres? ( dev-db/postgresql-base )
30 qt4? ( x11-libs/qt-gui:4[qt3support] )
31 ssl? ( dev-libs/openssl )
32 tcl? ( dev-lang/tcl )
33 X? ( x11-libs/libXt )
34 "
35 DEPEND="${RDEPEND}
36 >=sys-devel/flex-2.5.2
37 >=sys-devel/bison-1.22
38 "
39
40 S=${WORKDIR}/${PN}
41
42 src_prepare() {
43 EPATCH_SUFFIX=patch epatch "${WORKDIR}"/patches
44
45 # cannot use big TOC (AIX only), gdb doesn't like it.
46 # This assumes that the compiler (or -wrapper) uses
47 # gcc flag '-mminimal-toc' for compilation.
48 sed -i -e 's/,-bbigtoc//' "${S}"/configure
49
50 # stop struggling with '-g' and '-O*' in CFLAGS/CXXFLAGS
51 sed -i -e '/^CFLAGS=.*sed/d;/^CXXFLAGS=.*sed/d;/use_opt=/s/yes/no/' configure ||
52 die "cannot stop struggling with CFLAGS/CXXFLAGS"
53
54 if use qt4; then
55 sed -i -e "s, -lqt\", $(pkg-config --libs Qt3Support)\"," configure ||
56 die "cannot update to use Qt3Support of qt4"
57 fi
58 }
59
60 src_configure() {
61 tc-export CC CXX
62
63 if use gtk; then
64 # need gtk-1 wrapper for gtk-2
65 export PATH="${WORKDIR}"/helpers:${PATH}
66 fi
67
68 # Don't know which version of JavaCUP would suffice, but there is no
69 # configure argument to disable checking for JavaCUP.
70 # So we override the configure check to not find 'javac'.
71 export ac_cv_path_JAVAC=no
72
73 # '--without-ssl' just does not add another search path - the only way
74 # to disable openssl utilization seems to override the configure check.
75 use ssl || export ac_cv_lib_ssl_open=no
76
77 # CFLAGS aren't used when checking for <qapplication.h>, but CPPFLAGS are.
78 use qt4 && append-cppflags $(pkg-config --cflags Qt3Support)
79
80 local myconf=
81 myconf() {
82 myconf="${myconf} $*"
83 }
84
85 myconf --disable-mini-stl
86 myconf $(use_enable threads)
87
88 # '--without-*' or '--with-*=no' does not disable some features,
89 # the value needs to be empty instead.
90 # This applies to: gtk, pgsql, qt, tcl, bluetooth.
91 myconf --with-gtk=$( use gtk && echo "${EPREFIX}"/usr)
92 myconf --with-pgsql=$(use postgres && echo "${EPREFIX}"/usr)
93 myconf --with-qt=$( use qt4 && echo "${EPREFIX}"/usr)
94 myconf --with-tcl=$( use tcl && echo "${EPREFIX}"/usr)
95 # bluetooth and wireless both don't compile cleanly
96 myconf --with-bluetooth=''
97 myconf --disable-wireless
98 # But --without-x works.
99 myconf $(use_with X x "${EPREFIX}"/usr)
100
101 # http://www.mico.org/pipermail/mico-devel/2009-April/010285.html
102 [[ ${CHOST} == *-hpux* ]] && append-cppflags -D_XOPEN_SOURCE_EXTENDED
103
104 if [[ ${CHOST} == *-winnt* ]]; then
105 # disabling static libs, since ar on interix takes nearly
106 # one hour per library, thanks to mico's monster objects.
107 use threads &&
108 ewarn "disabling USE='threads', does not work on ${CHOST}"
109 myconf --disable-threads --disable-static --enable-final
110 append-flags -D__STDC__
111 fi
112
113 econf ${myconf}
114 }
115
116 src_install() {
117 emake INSTDIR="${ED}"usr SHARED_INSTDIR="${ED}"usr install LDCONFIG=: || die "install failed"
118
119 dodir /usr/share || die
120 mv "${ED}"usr/man "${ED}"usr/share || die
121 dodir /usr/share/doc/${PF} || die
122 mv "${ED}"usr/doc "${ED}"usr/share/doc/${PF} || die
123
124 dodoc BUGS CHANGES* CONVERT FAQ README* ROADMAP TODO VERSION WTODO || die
125 }

  ViewVC Help
Powered by ViewVC 1.1.20