/[gentoo-x86]/sci-geosciences/grass/grass-6.3.0.ebuild
Gentoo

Diff of /sci-geosciences/grass/grass-6.3.0.ebuild

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.19 Revision 1.23
1# Copyright 1999-2011 Gentoo Foundation 1# Copyright 1999-2011 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/sci-geosciences/grass/Attic/grass-6.3.0.ebuild,v 1.19 2011/02/20 23:44:24 nerdboy Exp $ 3# $Header: /var/cvsroot/gentoo-x86/sci-geosciences/grass/Attic/grass-6.3.0.ebuild,v 1.23 2011/04/10 22:10:42 arfrever Exp $
4 4
5EAPI=1 5EAPI=3
6 6
7inherit eutils distutils fdo-mime versionator wxwidgets 7inherit eutils distutils fdo-mime versionator wxwidgets
8 8
9MY_PV=$(get_version_component_range 1-2 ${PV}) 9MY_PV=$(get_version_component_range 1-2 ${PV})
10MY_PVM=$(delete_all_version_separators ${MY_PV}) 10MY_PVM=$(delete_all_version_separators ${MY_PV})
14HOMEPAGE="http://grass.osgeo.org//" 14HOMEPAGE="http://grass.osgeo.org//"
15SRC_URI="http://download.osgeo.org/grass/${MY_PM}/source/${P}.tar.gz" 15SRC_URI="http://download.osgeo.org/grass/${MY_PM}/source/${P}.tar.gz"
16 16
17LICENSE="GPL-2" 17LICENSE="GPL-2"
18SLOT="6" 18SLOT="6"
19KEYWORDS="amd64 ppc ~ppc64 sparc x86" 19KEYWORDS="amd64 ppc ~ppc64 x86"
20 20
21IUSE="ffmpeg fftw gmath jpeg largefile motif mysql nls odbc opengl png \ 21IUSE="ffmpeg fftw gmath jpeg motif mysql nls odbc opengl png \
22postgres python readline sqlite tiff truetype wxwidgets X" 22postgres python readline sqlite tiff truetype wxwidgets X"
23 23
24RESTRICT="strip" 24RESTRICT="strip"
25 25
26RDEPEND=">=sys-libs/zlib-1.1.4 26RDEPEND=">=sys-libs/zlib-1.1.4
29 || ( 29 || (
30 sys-apps/man 30 sys-apps/man
31 sys-apps/man-db ) 31 sys-apps/man-db )
32 sci-libs/gdal 32 sci-libs/gdal
33 >=sci-libs/proj-4.4.7 33 >=sci-libs/proj-4.4.7
34 ffmpeg? ( media-video/ffmpeg ) 34 ffmpeg? ( virtual/ffmpeg )
35 fftw? ( sci-libs/fftw ) 35 fftw? ( sci-libs/fftw )
36 gmath? ( virtual/blas 36 gmath? ( virtual/blas
37 virtual/lapack ) 37 virtual/lapack )
38 jpeg? ( virtual/jpeg ) 38 jpeg? ( virtual/jpeg )
39 mysql? ( dev-db/mysql ) 39 mysql? ( dev-db/mysql )
106 ewarn "GRASS OpenGL support needs X (will also pull in Tcl/Tk)." 106 ewarn "GRASS OpenGL support needs X (will also pull in Tcl/Tk)."
107 die "Please set the X useflag." 107 die "Please set the X useflag."
108 fi 108 fi
109} 109}
110 110
111src_unpack() { 111src_prepare() {
112 unpack ${A}
113 cd "${S}"
114
115 epatch rpm/fedora/grass-readline.patch 112 epatch rpm/fedora/grass-readline.patch
116 # fix the fortify_source and buffer issues (see bug #261283) 113 # fix the fortify_source and buffer issues (see bug #261283)
117 epatch "${FILESDIR}"/${P}-o_creat.patch 114 epatch "${FILESDIR}"/${P}-o_creat.patch
118 # and update for gcc 4.4 C++ changes (see bug #270916) 115 # and update for gcc 4.4 C++ changes (see bug #270916)
119 epatch "${FILESDIR}"/${P}-gcc44.patch 116 epatch "${FILESDIR}"/${P}-gcc44.patch
128 # patch missing math functions (yes, this is still needed) 125 # patch missing math functions (yes, this is still needed)
129 sed -i -e "s:\$(EXTRA_LIBS):\$(EXTRA_LIBS) \$(MATHLIB):g" include/Make/Shlib.make 126 sed -i -e "s:\$(EXTRA_LIBS):\$(EXTRA_LIBS) \$(MATHLIB):g" include/Make/Shlib.make
130 echo "MATHLIB=-lm" >> include/Make/Rules.make 127 echo "MATHLIB=-lm" >> include/Make/Rules.make
131} 128}
132 129
133src_compile() { 130src_configure() {
134 local myconf 131 local myconf
135 addpredict /var/cache/fontconfig 132 addpredict /var/cache/fontconfig
136 133
137 myconf="--prefix=/usr --with-cxx --enable-shared \ 134 myconf="--prefix=/usr --with-cxx --enable-shared \
138 --with-gdal=$(type -P gdal-config) --with-curses --with-proj \ 135 --with-gdal=$(type -P gdal-config) --with-curses --with-proj \
176 # Should handle either older or latest without intervention; 173 # Should handle either older or latest without intervention;
177 # this won't work forever, but it should be okay for a while... 174 # this won't work forever, but it should be okay for a while...
178 if use ffmpeg; then 175 if use ffmpeg; then
179 myconf="${myconf} --with-ffmpeg \ 176 myconf="${myconf} --with-ffmpeg \
180 --with-ffmpeg-libs=/usr/$(get_libdir)" 177 --with-ffmpeg-libs=/usr/$(get_libdir)"
181 if has_version ">=media-video/ffmpeg-0.4.9_p20080326" ; then
182 # must pass multiple include dirs now; if you have a better
183 # way to do this, please speak up and file a bug :)
184 myconf="${myconf} --with-ffmpeg-includes=/usr/include/libav*" 178 myconf="${myconf} --with-ffmpeg-includes=/usr/include/libav*"
185 else
186 myconf="${myconf} --with-ffmpeg-includes=/usr/include/ffmpeg"
187 fi
188 else 179 else
189 myconf="${myconf} --without-ffmpeg" 180 myconf="${myconf} --without-ffmpeg"
190 fi 181 fi
191 182
192 if use truetype; then 183 if use truetype; then
212 $(use_enable amd64 64bit) \ 203 $(use_enable amd64 64bit) \
213 $(use_with fftw) \ 204 $(use_with fftw) \
214 $(use_with gmath blas) \ 205 $(use_with gmath blas) \
215 $(use_with gmath lapack) \ 206 $(use_with gmath lapack) \
216 $(use_with jpeg) \ 207 $(use_with jpeg) \
217 $(use_enable largefile) \
218 $(use_with motif) \ 208 $(use_with motif) \
219 $(use_with nls) \ 209 $(use_with nls) \
220 $(use_with odbc) \ 210 $(use_with odbc) \
221 $(use_with png) \ 211 $(use_with png) \
222 $(use_with postgres) \ 212 $(use_with postgres) \
223 $(use_with readline) \ 213 $(use_with readline) \
224 $(use_with tiff) || die "configure failed!" 214 $(use_with tiff) \
215 --enable-largefile
216}
225 217
218src_compile() {
226 if use wxwidgets; then 219 if use wxwidgets; then
227 # can't use die here since we need to hack the vdigit build 220 # can't use die here since we need to hack the vdigit build
228 emake -j1 221 emake -j1
229 ln -sf "${LIBGDI}" dist.${CHOST}/lib/libgdi.so \ 222 ln -sf "${LIBGDI}" dist.${CHOST}/lib/libgdi.so \
230 || die "making libgdi link failed" 223 || die "making libgdi link failed"

Legend:
Removed from v.1.19  
changed lines
  Added in v.1.23

  ViewVC Help
Powered by ViewVC 1.1.20