/[gentoo-x86]/kde-base/kdelibs/kdelibs-4.4.5-r2.ebuild
Gentoo

Contents of /kde-base/kdelibs/kdelibs-4.4.5-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (hide annotations) (download)
Fri Apr 8 19:39:21 2011 UTC (3 years, 5 months ago) by dilfridge
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines
FILE REMOVED
Cleanup

(Portage version: 2.1.9.45/cvs/Linux x86_64)

1 phajdan.jr 1.2 # Copyright 1999-2011 Gentoo Foundation
2 dilfridge 1.1 # Distributed under the terms of the GNU General Public License v2
3 dilfridge 1.6 # $Header: /var/cvsroot/gentoo-x86/kde-base/kdelibs/kdelibs-4.4.5-r2.ebuild,v 1.5 2011/03/26 17:19:25 dilfridge Exp $
4 dilfridge 1.1
5     EAPI="3"
6    
7     CPPUNIT_REQUIRED="optional"
8     OPENGL_REQUIRED="optional"
9     WEBKIT_REQUIRED="always"
10     inherit kde4-base fdo-mime
11    
12     DESCRIPTION="KDE libraries needed by all KDE programs."
13     HOMEPAGE="http://www.kde.org/"
14    
15 hwoarang 1.4 KEYWORDS="amd64 ~arm ~ppc ~ppc64 x86 ~x86-fbsd ~amd64-linux ~x86-linux"
16 dilfridge 1.1 LICENSE="LGPL-2.1"
17     IUSE="3dnow acl alsa altivec bindist +bzip2 debug doc fam +handbook jpeg2k kerberos
18     lzma mmx nls openexr policykit semantic-desktop spell sse sse2 ssl zeroconf"
19    
20     # needs the kate regression testsuite from svn
21     RESTRICT="test"
22    
23     COMMONDEPEND="
24     app-crypt/qca:2
25     >=app-misc/strigi-0.6.3
26     ~dev-libs/libattica-0.1.2
27     dev-libs/libpcre[unicode]
28     dev-libs/libxml2
29     dev-libs/libxslt
30     media-libs/fontconfig
31     media-libs/freetype:2
32     media-libs/giflib
33     >=media-libs/libpng-1.4
34 dilfridge 1.5 >=media-libs/phonon-4.3.80
35 dilfridge 1.1 sys-libs/zlib
36     virtual/jpeg
37     >=x11-misc/shared-mime-info-0.60
38     acl? ( virtual/acl )
39     alsa? ( media-libs/alsa-lib )
40     !aqua? (
41     x11-libs/libICE
42     x11-libs/libSM
43     x11-libs/libX11
44     x11-libs/libXau
45     x11-libs/libXcursor
46     x11-libs/libXdmcp
47     x11-libs/libXext
48     x11-libs/libXfixes
49     x11-libs/libXft
50     x11-libs/libXpm
51     x11-libs/libXrender
52     x11-libs/libXtst
53     !kernel_SunOS? ( sys-libs/libutempter )
54     )
55     bzip2? ( app-arch/bzip2 )
56     fam? ( virtual/fam )
57     jpeg2k? ( media-libs/jasper )
58     kerberos? ( virtual/krb5 )
59     lzma? ( app-arch/xz-utils )
60     openexr? (
61     media-libs/openexr
62     media-libs/ilmbase
63     )
64     policykit? ( sys-auth/polkit-qt )
65     semantic-desktop? (
66     >=dev-libs/shared-desktop-ontologies-0.2
67     >=dev-libs/soprano-2.3.73[dbus,raptor,redland]
68     )
69     spell? ( app-text/enchant )
70     ssl? ( dev-libs/openssl )
71     zeroconf? (
72     || (
73     net-dns/avahi[mdnsresponder-compat]
74     !bindist? ( net-misc/mDNSResponder )
75     )
76     )
77     "
78     DEPEND="${COMMONDEPEND}
79     doc? ( app-doc/doxygen )
80     nls? ( virtual/libintl )
81     "
82     RDEPEND="${COMMONDEPEND}
83     !dev-libs/conversion
84     !dev-libs/kunitconversion
85     !x11-libs/qt-phonon
86     !<=kde-misc/kdnssd-avahi-0.1.2:0
87     >=app-crypt/gnupg-2.0.11
88     app-misc/ca-certificates
89     $(add_kdebase_dep kde-env)
90     !aqua? (
91     x11-apps/iceauth
92     x11-apps/rgb
93     >=x11-misc/xdg-utils-1.0.2-r3
94     )
95     "
96     PDEPEND="
97     handbook? ( $(add_kdebase_dep khelpcenter) )
98     policykit? ( >=sys-auth/polkit-kde-0.95.1 )
99     semantic-desktop? ( $(add_kdebase_dep nepomuk) )
100     "
101    
102     # Blockers added due to packages from old versions, removed in the meanwhile
103     # as well as for file collisions
104     add_blocker libknotificationitem
105     add_blocker libkworkspace '<4.3.66'
106     # @since 4.4 - kpilot is gone (blocker added to help upgrades)
107     add_blocker kpilot
108     # Block some old versions of KDE-3.5 packages that don't work well with KDE-4
109     add_blocker kdebase 0 3.5.9-r4:3.5
110     add_blocker kdebase-startkde 0 3.5.10:3.5
111     add_blocker kdelibs 0 '<3.5.10:3.5'
112     # libnepomukquery moved to kdelibs from plasma-workspace between 4.3.74 -> 4.3.75
113     add_blocker plasma-workspace '<4.3.75'
114    
115     PATCHES=(
116     "${FILESDIR}/dist/01_gentoo_set_xdg_menu_prefix.patch"
117     "${FILESDIR}/dist/02_gentoo_append_xdg_config_dirs.patch"
118     "${FILESDIR}/dist/23_solid_no_double_build.patch"
119     "${FILESDIR}/${PN}-4.3.80-module-suffix.patch"
120     "${FILESDIR}/${PN}-4.4.66-macos-unbundle.patch"
121     "${FILESDIR}/${PN}-4.3.3-klauncher_kdeinit.patch"
122     "${FILESDIR}/${PN}-4.3.3-klauncher_kioslave.patch"
123     "${FILESDIR}/${PN}-4.3.3-klauncher_mac.patch"
124     "${FILESDIR}/${PN}-4.4.3-mimetypes.patch"
125     "${FILESDIR}/${PN}-4.4.90-xslt.patch"
126     "${FILESDIR}/${PN}-4.4.5-qt471.patch"
127     "${FILESDIR}/${PN}-4.4.5-formpainter.patch"
128     )
129    
130     src_prepare() {
131     kde4-base_src_prepare
132    
133     # Rename applications.menu (needs 01_gentoo_set_xdg_menu_prefix.patch to work)
134     local menu_prefix="kde-${SLOT}-"
135     sed -e "s|FILES[[:space:]]applications.menu|FILES applications.menu RENAME ${menu_prefix}applications.menu|g" \
136     -i kded/CMakeLists.txt || die "Sed on CMakeLists.txt for applications.menu failed."
137     sed -e "s|@REPLACE_MENU_PREFIX@|${menu_prefix}|g" \
138     -i kded/vfolder_menu.cpp || die "Sed on vfolder_menu.cpp failed."
139    
140     if use aqua; then
141     sed -i -e \
142     "s:BUNDLE_INSTALL_DIR \"/Applications:BUNDLE_INSTALL_DIR \"${EPREFIX}/${APP_BUNDLE_DIR}:g" \
143     cmake/modules/FindKDE4Internal.cmake || die "failed to sed FindKDE4Internal.cmake"
144    
145     #if [[ ${CHOST} == *-darwin8 ]]; then
146     sed -i -e \
147     "s:set(_add_executable_param MACOSX_BUNDLE):remove(_add_executable_param MACOSX_BUNDLE):g" \
148     cmake/modules/KDE4Macros.cmake || die "failed to sed KDE4Macros.cmake"
149     #fi
150    
151     # solid/solid/backends/iokit doesn't properly link, so disable it.
152     sed -e "s|\(APPLE\)|(FALSE)|g" -i solid/solid/CMakeLists.txt \
153     || die "disabling solid/solid/backends/iokit failed"
154     sed -e "s|m_backend = .*Backends::IOKit.*;|m_backend = 0;|g" -i solid/solid/managerbase.cpp \
155     || die "disabling solid/solid/backends/iokit failed"
156    
157     # There's no fdatasync on OSX and the check fails to detect that.
158     sed -e "/HAVE_FDATASYNC/ d" -i config.h.cmake \
159     || die "disabling fdatasync failed"
160    
161     # Fix nameser include to nameser8_compat
162     sed -e "s|nameser8_compat.h|nameser_compat.h|g" -i kio/misc/kpac/discovery.cpp \
163     || die "fixing nameser include failed"
164     append-flags -DHAVE_ARPA_NAMESER8_COMPAT_H=1
165    
166     # Try to fix kkeyserver_mac
167     epatch "${FILESDIR}"/${PN}-4.3.80-kdeui_util_kkeyserver_mac.patch
168     fi
169    
170     if [[ ${CHOST} == *-solaris* ]] ; then
171     epatch "${FILESDIR}/kdelibs-4.3.2-solaris-ksyscoca.patch"
172     # getgrouplist not in solaris libc
173     epatch "${FILESDIR}/kdelibs-4.3.2-solaris-getgrouplist.patch"
174     # solaris has no d_type element in dir_ent
175     epatch "${FILESDIR}/kdelibs-4.3.2-solaris-fileunix.patch"
176     fi
177     }
178    
179     src_configure() {
180     if use zeroconf; then
181     if has_version net-dns/avahi; then
182     mycmakeargs=(-DWITH_Avahi=ON -DWITH_DNSSD=OFF)
183     elif has_version net-misc/mDNSResponder; then
184     mycmakeargs=(-DWITH_Avahi=OFF -DWITH_DNSSD=ON)
185     else
186     die "USE=\"zeroconf\" enabled but neither net-dns/avahi nor net-misc/mDNSResponder were found."
187     fi
188     else
189     mycmakeargs=(-DWITH_Avahi=OFF -DWITH_DNSSD=OFF)
190     fi
191     if use kdeprefix; then
192     HME=".kde${SLOT}"
193     else
194     HME=".kde4"
195     fi
196     mycmakeargs+=(
197     -DWITH_HSPELL=OFF
198     -DWITH_ASPELL=OFF
199     -DKDE_DEFAULT_HOME=${HME}
200     -DKAUTH_BACKEND=POLKITQT-1
201     $(cmake-utils_use_build handbook doc)
202     $(cmake-utils_use_has 3dnow X86_3DNOW)
203     $(cmake-utils_use_has altivec PPC_ALTIVEC)
204     $(cmake-utils_use_has mmx X86_MMX)
205     $(cmake-utils_use_has sse X86_SSE)
206     $(cmake-utils_use_has sse2 X86_SSE2)
207     $(cmake-utils_use_with acl)
208     $(cmake-utils_use_with alsa)
209     $(cmake-utils_use_with bzip2 BZip2)
210     $(cmake-utils_use_with fam)
211     $(cmake-utils_use_with jpeg2k Jasper)
212     $(cmake-utils_use_with kerberos GSSAPI)
213     $(cmake-utils_use_with lzma LibLZMA)
214     $(cmake-utils_use_with nls Libintl)
215     $(cmake-utils_use_with openexr OpenEXR)
216     $(cmake-utils_use_with opengl OpenGL)
217     $(cmake-utils_use_with policykit PolkitQt-1)
218     $(cmake-utils_use_with semantic-desktop Soprano)
219     $(cmake-utils_use_with semantic-desktop SharedDesktopOntologies)
220     $(cmake-utils_use_with spell ENCHANT)
221     $(cmake-utils_use_with ssl OpenSSL)
222     )
223     kde4-base_src_configure
224     }
225    
226     src_compile() {
227     kde4-base_src_compile
228    
229     # The building of apidox is not managed anymore by the build system
230     if use doc; then
231     einfo "Building API documentation"
232     cd "${S}"/doc/api/
233     ./doxygen.sh "${S}" || die "APIDOX generation failed"
234     fi
235     }
236    
237     src_install() {
238     kde4-base_src_install
239    
240     # use system certificates
241     rm -f "${ED}/${KDEDIR}"/share/apps/kssl/ca-bundle.crt || die
242     dosym /etc/ssl/certs/ca-certificates.crt \
243     "${KDEDIR}"/share/apps/kssl/ca-bundle.crt || die
244    
245     if use doc; then
246     einfo "Installing API documentation. This could take a bit of time."
247     cd "${S}"/doc/api/
248     docinto /HTML/en/kdelibs-apidox
249     dohtml -r ${P}-apidocs/* || die "Install phase of KDE4 API Documentation failed"
250     fi
251    
252     if use aqua; then
253     einfo "fixing ${PN} plugins"
254    
255     local _PV=${PV:0:3}.0
256     local _dir=${EKDEDIR}/$(get_libdir)/kde4/plugins/script
257    
258     install_name_tool -id \
259     "${_dir}/libkrossqtsplugin.${_PV}.dylib" \
260     "${D}/${_dir}/libkrossqtsplugin.${_PV}.dylib" \
261     || die "failed fixing libkrossqtsplugin.${_PV}.dylib"
262    
263     einfo "fixing ${PN} cmake detection files"
264     #sed -i -e \
265     # "s:if (HAVE_XKB):if (HAVE_XKB AND NOT APPLE):g" \
266     echo -e "set(XKB_FOUND FALSE)\nset(HAVE_XKB FALSE)" > \
267     "${ED}"/${KDEDIR}/share/apps/cmake/modules/FindXKB.cmake \
268     || die "failed fixing FindXKB.cmake"
269     fi
270     }
271    
272     pkg_postinst() {
273     fdo-mime_mime_database_update
274    
275     if use zeroconf; then
276     echo
277     elog "To make zeroconf support available in KDE make sure that the 'mdnsd' daemon"
278     elog "is running."
279     echo
280     einfo "If you also want to use zeroconf for hostname resolution, emerge sys-auth/nss-mdns"
281     einfo "and enable multicast dns lookups by editing the 'hosts:' line in /etc/nsswitch.conf"
282     einfo "to include 'mdns', e.g.:"
283     einfo " hosts: files mdns dns"
284     echo
285     fi
286    
287     elog "Your homedir is set to \${HOME}/${HME}"
288     echo
289    
290     if ! has_version sys-apps/hal; then
291     echo
292     ewarn "You need sys-apps/hal for new device notifications, power management and any"
293     ewarn "other hardware related functionalities to work."
294     echo
295     fi
296    
297     kde4-base_pkg_postinst
298     }
299    
300     pkg_prerm() {
301     # Remove ksycoca4 global database
302     rm -f "${EROOT}${PREFIX}"/share/kde4/services/ksycoca4
303     }
304    
305     pkg_postrm() {
306     fdo-mime_mime_database_update
307    
308     kde4-base_pkg_postrm
309     }

  ViewVC Help
Powered by ViewVC 1.1.20