/[gentoo-x86]/dev-libs/pwlib/pwlib-1.10.0.ebuild
Gentoo

Contents of /dev-libs/pwlib/pwlib-1.10.0.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Sat Apr 14 08:16:57 2007 UTC (7 years, 4 months ago) by genstef
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
remove old
(Portage version: 2.1.2.3)

1 # Copyright 1999-2006 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-libs/pwlib/pwlib-1.10.0.ebuild,v 1.2 2006/07/12 09:03:46 corsair Exp $
4
5 inherit eutils flag-o-matic multilib
6
7 IUSE="alsa debug ieee1394 ipv6 ldap oss sasl sdl ssl v4l v4l2 xml"
8
9 DESCRIPTION="Portable Multiplatform Class Libraries used by several VoIP applications"
10 HOMEPAGE="http://www.ekiga.org"
11 SRC_URI="http://www.ekiga.org/admin/downloads/latest/sources/sources/${P}.tar.gz"
12
13 LICENSE="MPL-1.1"
14 SLOT="0"
15 KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86"
16
17 RDEPEND="alsa? ( media-libs/alsa-lib )
18 ieee1394? ( media-libs/libdv
19 sys-libs/libavc1394
20 sys-libs/libraw1394
21 <media-libs/libdc1394-1.9.99
22 !>=media-libs/libdc1394-2.0.0_pre1 )
23 ldap? ( net-nds/openldap )
24 sasl? ( dev-libs/cyrus-sasl )
25 sdl? ( media-libs/libsdl )
26 ssl? ( dev-libs/openssl )
27 xml? ( dev-libs/expat )"
28 DEPEND="${RDEPEND}
29 >=sys-devel/bison-1.28
30 >=sys-devel/flex-2.5.4a
31 >=sys-apps/sed-4"
32
33 src_unpack() {
34 unpack ${A}
35 cd ${S}
36
37 # filter out -O3, -Os and -mcpu embedded compiler flags
38 sed -i \
39 -e "s:-mcpu=\$(CPUTYPE)::" \
40 -e "s:-O3 -DNDEBUG:-DNDEBUG:" \
41 -e "s:-Os::" \
42 make/unix.mak
43
44 # don't break make install if there are no plugins to install
45 epatch ${FILESDIR}/pwlib-1.8.7-instplugins.diff
46
47 # # fix "command not found" error during configure run
48 # epatch ${FILESDIR}/pwlib-1.9.2-ldap-configure.patch
49
50 # use sdl-config to query required libraries
51 epatch ${FILESDIR}/pwlib-1.9.3-sdl-configure.patch
52
53 autoconf || die "autoconf failed"
54 }
55
56 src_compile() {
57 # may cause ICE (bug #70638)
58 filter-flags -fstack-protector
59
60 econf \
61 --enable-plugins \
62 $(use_enable v4l2) \
63 $(use_enable v4l) \
64 $(use_enable ieee1394 dc) \
65 $(use_enable ieee1394 avc) \
66 $(use_enable oss) \
67 $(use_enable alsa) \
68 $(use_enable ipv6) \
69 $(use_enable sdl) \
70 $(use_enable ssl openssl) \
71 $(use_enable debug exceptions) \
72 $(use_enable debug memcheck) \
73 $(use_enable ldap openldap) \
74 $(use_enable sasl) \
75 $(use_enable xml expat) \
76 || die "configure failed"
77
78 # Horrible hack to strip out -L/usr/lib to allow upgrades
79 # problem is it adds -L/usr/lib before -L${S} when SSL is
80 # enabled. Same thing for -I/usr/include.
81 # sed -i -e "s:^\(LDFLAGS.*\)-L/usr/lib:\1:" \
82 # -e "s:^\(STDCCFLAGS.*\)-I/usr/include:\1:" \
83 # ${S}/make/ptbuildopts.mak
84
85 # sed -i -e "s:^\(LDFLAGS[\s]*=.*\) -L/usr/lib:\1:" \
86 # -e "s:^\(LDFLAGS[\s]*=.*\) -I/usr/include:\1:" \
87 # -e "s:^\(CCFLAGS[\s]*=.*\) -I/usr/include:\1:" \
88 # ${S}/make/ptlib-config
89
90 emake -j1 opt || die "make failed"
91 }
92
93 src_install() {
94 local libdir libname
95
96 libdir=$(get_libdir)
97
98 # makefile doesn't create ${D}/usr/bin
99 make PREFIX=/usr DESTDIR=${D} install || die "install failed"
100
101 ## vv will try to fix the mess below, requires a lot of patching though...
102
103 # update 2005/08/22:
104 #
105 # locations in *.mak files haven been fixed
106 # directories have been replaced w/ symlinks
107 # (left to not break things, doing some testing atm)
108
109 # Note: reactivating this seems to be the only easy solution to slot pwlib ebuild
110 # and keep applications happy (e.g. gnomemeeting / ekiga)
111
112 # dosym /usr/include /usr/share/pwlib/include
113 # dosym /usr/${libdir} /usr/share/pwlib/${libdir}
114 #
115 # # just in case...
116 # if [[ "${libdir}" = "lib64" ]]; then
117 # dosym /usr/share/pwlib/lib64 /usr/share/pwlib/lib
118 # fi
119
120 ## ^^ bad stuff
121
122 # fix symlink
123 libname=$(basename `ls ${D}/usr/${libdir}/libpt_*_*_r.so.${PV}`)
124 rm ${D}/usr/${libdir}/libpt.so
125 dosym ${libname} /usr/${libdir}/libpt.so
126
127 # fix makefiles to use headers from /usr/include and libs from /usr/lib
128 # instead of /usr/share/pwlib
129 # Note: change to /usr/include/pwlib-${PV} (or whereever includes will be)
130 # once pwlib ebuilds get slotted
131 sed -i -e "s:-I\$(PWLIBDIR)\(/include[a-zA-Z0-9_/-]\+\):-I/usr/include\1:g" \
132 -e "s:-I\$(PWLIBDIR)/include::g" \
133 -e "s:^\(PW_LIBDIR[ \t]\+=\).*:\1 /usr/${libdir}:" \
134 ${D}/usr/share/pwlib/make/*.mak
135
136 # dodgy configure/makefiles forget to expand this
137 # Note: change to /usr/share/pwlib/${PV} (or whatever PWLIBDIR should point to)
138 # once pwlib ebuilds get slotted
139 sed -i -e "s:\${exec_prefix}:/usr:" \
140 ${D}/usr/bin/ptlib-config \
141 ${D}/usr/share/pwlib/make/ptlib-config
142
143 # copy version.h
144 insinto /usr/share/pwlib
145 doins version.h
146
147 dodoc ReadMe.txt ReadMe_QOS.txt History.txt mpl-1.0.htm
148 }

  ViewVC Help
Powered by ViewVC 1.1.20