blob: b87398d42269e32022c7a55b678e93a911faa540 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
|
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-util/codeblocks/codeblocks-8.02.ebuild,v 1.3 2009/02/12 04:42:37 dirtyepic Exp $
inherit autotools wxwidgets flag-o-matic eutils
WX_GTK_VER="2.8"
DESCRIPTION="free cross-platform C/C++ IDE"
HOMEPAGE="http://www.codeblocks.org/"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~amd64"
SRC_URI="mirror://sourceforge/codeblocks/${P}-src.tar.bz2"
IUSE="contrib debug pch static unicode"
RDEPEND="=x11-libs/wxGTK-${WX_GTK_VER}*
x11-libs/gtk+"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-2.5.0
>=sys-devel/automake-1.7
>=sys-devel/libtool-1.4
app-arch/zip"
pkg_setup() {
if use unicode; then
need-wxwidgets "unicode"
else
need-wxwidgets "gtk2"
fi
}
src_unpack() {
unpack ${A}
epatch "${FILESDIR}/${PV}-version.patch"
epatch "${FILESDIR}"/${P}-gcc43.patch
#epatch "${FILESDIR}/${PV}-install-plugins.patch"
cd "${S}"
find src/plugins -name Makefile.am -exec \
sed -i -e 's#^libdir#pluginsdir#' \
-e 's#^lib_LTLIBRARIES#plugins_LTLIBRARIES#' \
'{}' \;
# This one's buggy
sed -i -e 's#^plugins_LTLIBRARIES#lib_LTLIBRARIES#' \
src/plugins/contrib/wxSmith/Makefile.am
eautoreconf || die "autoreconf failed"
# ./bootstrap || die "boostrap failed"
}
src_compile() {
# C::B is picky on CXXFLAG -fomit-frame-pointer
# (project-wizard crash, instability ...)
filter-flags -fomit-frame-pointer
append-flags -fno-strict-aliasing
cd "${S}"
local myconf="$(use_enable pch)"
# $(use_enable autosave) \
# $(use_enable class-wizard) \
# $(use_enable code-completion) \
# $(use_enable compiler) \
# $(use_enable debuger) \
# $(use_enable mime-handler) \
# $(use_enable open-files-list) \
#
# $(use_enable projects-importer) \
# $(use_enable source-formatter) \
# $(use_enable todo) \
# $(use_enable xpmanifest)
if use contrib; then
myconf="${myconf} --with-contrib-plugins=all"
fi
econf --with-wx-config="${WX_CONFIG}" \
--enable-dependency-tracking \
$(use_enable unicode) \
$(use_enable debug) \
$(use_enable static) \
${myconf} || die "Died in action: econf ..."
emake || die "Died in action: make ..."
}
src_install() {
einstall || die "Install failed"
}
|