/[gentoo-x86]/media-gfx/radiance/radiance-3.5.ebuild
Gentoo

Contents of /media-gfx/radiance/radiance-3.5.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.7 - (show annotations) (download)
Thu Nov 30 01:56:34 2006 UTC (13 years, 1 month ago) by beandog
Branch: MAIN
CVS Tags: HEAD
Changes since 1.6: +1 -1 lines
FILE REMOVED
Treecleaned
media-gfx/radiance for bug(s) 106158, 112675

1 # Copyright 1999-2004 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-gfx/radiance/radiance-3.5.ebuild,v 1.6 2004/06/24 22:48:55 agriffis Exp $
4
5 inherit eutils
6
7 MY_P=${P/./R}
8 MY_P=${MY_P/radiance-/rad}
9
10 IUSE="X"
11
12 DESCRIPTION="Radiance is a suite of programs for the analysis and visualization of lighting in design"
13 HOMEPAGE="http://radsite.lbl.gov/radiance/"
14 SRC_URI="http://radsite.lbl.gov/${PN}/dist/$MY_P.tar.gz"
15
16 LICENSE="Radiance"
17 SLOT="0"
18 KEYWORDS="~x86"
19
20 DEPEND="media-libs/tiff
21 app-shells/tcsh
22 X? ( virtual/x11 dev-lang/tk )"
23
24 src_unpack() {
25 unpack ${A}
26 cd ${WORKDIR}/ray
27 mkdir -p src/lib
28
29 use X || epatch ${FILESDIR}/${P}-noX11.patch
30
31 # patch to not build libtiff that comes with Radiance
32 cp src/px/Rmakefile src/px/Rmakefile.orig
33 sed -e "s/\.\.\/lib\/libtiff\.a$//g" \
34 src/px/Rmakefile.orig > src/px/Rmakefile
35
36 # fix syntax error in standard.h
37 cp src/common/standard.h src/common/standard.h.orig
38 sed -e "s/error(et,em) else$/error(et,em); else/g" \
39 src/common/standard.h.orig > src/common/standard.h
40
41 # fix incorrect use of errno.h
42 cp src/cal/ev.c src/cal/ev.c.orig
43 sed -e "s/extern int errno;/#include <errno.h>/g" \
44 src/cal/ev.c.orig > src/cal/ev.c
45 }
46
47 src_compile() {
48 mkdir -p ${T}/bin
49 mkdir -p ${T}/bin/dev
50 mkdir -p ${T}/lib/ray
51
52 cd ${WORKDIR}/ray/src
53 local srcdirs="common meta cv gen ot rt px hd util cal"
54 for i in $srcdirs ;
55 do
56 pushd $i
57 make "SPECIAL=" \
58 "OPT=$CFLAGS -DSPEED=200" \
59 "MACH=-Dlinux -L/usr/X11R6/lib -I/usr/include/X11 -DNOSTEREO -DBIGMEM" \
60 ARCH=IBMPC "COMPAT=bmalloc.o erf.o getpagesize.o" \
61 INSTDIR=${T}/bin \
62 LIBDIR=${T}/lib/ray \
63 CC=gcc "$@" -f Rmakefile install || die "Unable to build $i"
64 popd
65 done
66
67 # TODO: figure out what to do with the dev files
68 mv ${T}/bin/dev ${T}/dev
69
70 rm -r ${WORKDIR}/ray/lib/CVS
71 rm -r ${T}/lib/ray/CVS
72 rm -r ${WORKDIR}/ray/doc/notes/CVS
73 }
74
75 src_install() {
76 mkdir -p ${D}/usr/bin
77 mkdir -p ${D}/usr/lib/ray
78
79 dobin ${T}/bin/*
80
81 cp -R ${T}/lib/ray ${D}/usr/lib/ray
82 cd ${WORKDIR}/ray
83 (cd lib ; tar -cf - *) | (cd ${D}/usr/lib/ray ; tar -xf -)
84
85 # man = /usr/share/man
86 cd ${WORKDIR}/ray
87 doman doc/man/man1/*.1
88 doman doc/ray.1
89 doman doc/man/man3/*.3
90 doman doc/man/man5/*.5
91 prepallman
92
93 dodoc README
94
95 docinto notes
96 dodoc doc/notes/*
97
98 docinto pdf
99 dodoc doc/pdf/*.pdf
100 dodoc doc/ps/*.ps
101 dohtml doc/ray.html
102 prepalldocs
103 }

  ViewVC Help
Powered by ViewVC 1.1.20