MD5 4f8ac4db89ea14bd777557e225b200e4 files/pgplot-compile-setup.patch 1600
RMD160 73f4786d421b6d353d0e195cc772e13fea1504ca files/pgplot-compile-setup.patch 1600
SHA256 972cbe86b72e79c15deec3c3ecf44b80b23ad56a4e9da4bfdbeb4e872af65e1b files/pgplot-compile-setup.patch 1600
-AUX pgplot-drivers.patch 4024 RMD160 86e1a4a7137d0e1a18667d4fdc142bebe7acb56c SHA1 8eaf1af6167d781f56ff4086e74bdb9446868352 SHA256 99bcbcff9d8218ba9ca8dd240daae636f1c9b2f960c9bd5cc68c71d986bc2f68
-MD5 d097f08f0c028bea283303904d133116 files/pgplot-drivers.patch 4024
-RMD160 86e1a4a7137d0e1a18667d4fdc142bebe7acb56c files/pgplot-drivers.patch 4024
-SHA256 99bcbcff9d8218ba9ca8dd240daae636f1c9b2f960c9bd5cc68c71d986bc2f68 files/pgplot-drivers.patch 4024
+AUX pgplot-drivers.patch 7431 RMD160 d300ecf9d5ed3b3117465330e4c235a3f17d0540 SHA1 d1cd686dd0f93b7550affe1e0d4d36f0a336b440 SHA256 19cabb29fd05c2c44cbb0492167ee3e45ab8890390b1e98de672f2ca2588baed
+MD5 ef96cf658c1b3405bc6bd97a102f2047 files/pgplot-drivers.patch 7431
+RMD160 d300ecf9d5ed3b3117465330e4c235a3f17d0540 files/pgplot-drivers.patch 7431
+SHA256 19cabb29fd05c2c44cbb0492167ee3e45ab8890390b1e98de672f2ca2588baed files/pgplot-drivers.patch 7431
AUX pgplot-makemake.patch 1040 RMD160 2181f8c8a5347a41ac78aae0c6a3ac3392fe4342 SHA1 0d98a3893077f07c2927258832d0525e0307709b SHA256 ef819809db1cfcdd89c8756d157fa6c3283697a5d54607074c7f9c2ee493cc77
MD5 1e3d99da0d638ce62b08ca0958eb66fb files/pgplot-makemake.patch 1040
RMD160 2181f8c8a5347a41ac78aae0c6a3ac3392fe4342 files/pgplot-makemake.patch 1040
SHA256 ef819809db1cfcdd89c8756d157fa6c3283697a5d54607074c7f9c2ee493cc77 files/pgplot-makemake.patch 1040
-AUX pgplot-path.patch 604 RMD160 e256b6af9f110fcf96fd86d1d8035d0cb0c895a1 SHA1 21af489f237f78e949f8c9fbd49cc6de21455aa8 SHA256 11046b2fbb258ff767ee545f542888f99feb7169669712883abfaf37637ca1e3
-MD5 0cb095a0d125a87be8913a52fba1d346 files/pgplot-path.patch 604
-RMD160 e256b6af9f110fcf96fd86d1d8035d0cb0c895a1 files/pgplot-path.patch 604
-SHA256 11046b2fbb258ff767ee545f542888f99feb7169669712883abfaf37637ca1e3 files/pgplot-path.patch 604
+AUX pgplot-pgdisp.patch 332 RMD160 1bd3c2ed7770bb60be19c50c4610c35d67bf92e9 SHA1 891475823d011156aa919fc2b844d1786ae6d85f SHA256 3aac6127d35f4039023a13182553b24e1902d6e1b46530fbd68e034357d0b078
+MD5 2464539695079e49d14eb3e242b26ee8 files/pgplot-pgdisp.patch 332
+RMD160 1bd3c2ed7770bb60be19c50c4610c35d67bf92e9 files/pgplot-pgdisp.patch 332
+SHA256 3aac6127d35f4039023a13182553b24e1902d6e1b46530fbd68e034357d0b078 files/pgplot-pgdisp.patch 332
DIST pgplot522.tar.gz 1197397 RMD160 4c21cad6613772f4104c65ac3d8d9a42e3c4afe1 SHA1 1f1c9aa17eeec9a2fb23fd15a0e4a91dcc49ddc1 SHA256 a5799ff719a510d84d26df4ae7409ae61fe66477e3f1e8820422a9a4727a5be4
EBUILD pgplot-5.2.2-r1.ebuild 2675 RMD160 46872e1529f960a15da3cd5af22cd756c8bb814f SHA1 e39121bbb662822fc8854abb8351a951d1bb1b56 SHA256 adb40f700186435029be74a0b4674421fd3239617bbc479515141daba02cffe5
MD5 d4f417f61f31ae7a963291b2d55fdc2b pgplot-5.2.2-r1.ebuild 2675
RMD160 46872e1529f960a15da3cd5af22cd756c8bb814f pgplot-5.2.2-r1.ebuild 2675
SHA256 adb40f700186435029be74a0b4674421fd3239617bbc479515141daba02cffe5 pgplot-5.2.2-r1.ebuild 2675
+EBUILD pgplot-5.2.2-r2.ebuild 4129 RMD160 225c5daf13b584f23c12f22c81804f401193aec7 SHA1 f7669dc78ac448e34c5218be263a0bec8e1f1c8d SHA256 3bdcb470fcb3f805c0a9de6349670c86dc4880b04eecdb636ff700284969a6f6
+MD5 34e6df1964c859c8e9d94f0cf2dbad86 pgplot-5.2.2-r2.ebuild 4129
+RMD160 225c5daf13b584f23c12f22c81804f401193aec7 pgplot-5.2.2-r2.ebuild 4129
+SHA256 3bdcb470fcb3f805c0a9de6349670c86dc4880b04eecdb636ff700284969a6f6 pgplot-5.2.2-r2.ebuild 4129
EBUILD pgplot-5.2.2.ebuild 1495 RMD160 a4f1a5938ebbe907420bd8713d52f23563c28425 SHA1 ca5fc475e64814139cbdf4459a11c6f95ed42f13 SHA256 6cd622f38a4d14fb2c99e48fe083236d3b3ee032e3fb857f2226ce51d621f8fd
MD5 fafa78d339765591a2a587af00c58fd3 pgplot-5.2.2.ebuild 1495
RMD160 a4f1a5938ebbe907420bd8713d52f23563c28425 pgplot-5.2.2.ebuild 1495
SHA256 6cd622f38a4d14fb2c99e48fe083236d3b3ee032e3fb857f2226ce51d621f8fd pgplot-5.2.2.ebuild 1495
-MISC ChangeLog 1283 RMD160 372215e8069401dee05700be1b4c541b146aac7f SHA1 e2e788c3b67263cfe115044df30c22a837322c96 SHA256 4abe557dfaf8f748c8463de8a8e96d74b1ab0063d24d7ea0b692e555f8862536
-MD5 38e837ce4e3fced94d7aac8b438c50b1 ChangeLog 1283
-RMD160 372215e8069401dee05700be1b4c541b146aac7f ChangeLog 1283
-SHA256 4abe557dfaf8f748c8463de8a8e96d74b1ab0063d24d7ea0b692e555f8862536 ChangeLog 1283
+MISC ChangeLog 1751 RMD160 1aab21186e3510fef39f143f6ba36efd44b99916 SHA1 271beddbdb1f4a0715b736fb65c2424d1b388c5b SHA256 e477fe7af3146404cd5c2d84703edc6d5e878bcf5da7036ceb8126fb15439d23
+MD5 76b72cd00d20d19ed4a0631975a1ae22 ChangeLog 1751
+RMD160 1aab21186e3510fef39f143f6ba36efd44b99916 ChangeLog 1751
+SHA256 e477fe7af3146404cd5c2d84703edc6d5e878bcf5da7036ceb8126fb15439d23 ChangeLog 1751
MISC metadata.xml 507 RMD160 8f89aef225b3c7fa4b817bd88ebfa5e73c9f1f4f SHA1 93061e1e4b6fa0967fec2829db49dbcaa74b6410 SHA256 44c0abf74199b2c4780cd7bf4bbc9b7c235ccc5e74e262985517ec8ade97189c
MD5 0b77527426ef4e61d561d28de9662c34 metadata.xml 507
RMD160 8f89aef225b3c7fa4b817bd88ebfa5e73c9f1f4f metadata.xml 507
MD5 381ff8dd7151ce6c864ea589a0e500f7 files/digest-pgplot-5.2.2-r1 232
RMD160 837a8454b49f25495e1776c9fb3ad4022b611b5a files/digest-pgplot-5.2.2-r1 232
SHA256 ee8e209202357347a9e6685f0f2930998edef0897d7496557c32fa767210e182 files/digest-pgplot-5.2.2-r1 232
+MD5 381ff8dd7151ce6c864ea589a0e500f7 files/digest-pgplot-5.2.2-r2 232
+RMD160 837a8454b49f25495e1776c9fb3ad4022b611b5a files/digest-pgplot-5.2.2-r2 232
+SHA256 ee8e209202357347a9e6685f0f2930998edef0897d7496557c32fa767210e182 files/digest-pgplot-5.2.2-r2 232
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
-iD8DBQFF7GhZWc/Ciu+QQGkRAu8VAJwNCsyTGtmP6ao5htSRsV3/7BXrjgCcDvf8
-33+AZOJ2CevhAb1nNBVsMkk=
-=fUUB
+iD8DBQFF8MyEWc/Ciu+QQGkRAmuaAJ9PkiAxd2VDiRY70SVdUFh2bSK1DQCfakPG
+9ZfUfKPhyaBlHJeo0isUtBY=
+=t/+W
-----END PGP SIGNATURE-----
-diff -ur pgplot.orig/drivers.list pgplot/drivers.list
---- pgplot.orig/drivers.list 1999-05-03 22:02:15.000000000 -0700
-+++ pgplot/drivers.list 2005-12-15 20:17:23.000000000 -0800
-@@ -16,8 +16,8 @@
+--- drivers.list.orig 2007-03-08 15:56:20.000000000 +0000
++++ drivers.list 2007-03-08 15:59:21.000000000 +0000
+@@ -6,71 +6,71 @@
+ !------------------------------------------------------------------------------
+ ! File Code Description Restrictions
+ ! BCDRIV 0 /BCANON Canon Laser printer (bitmap version), landscape
+-! CADRIV 0 /CANON Canon Laser printer, LBP-8/A2, landscape
++ CADRIV 0 /CANON Canon Laser printer, LBP-8/A2, landscape
+ ! CCDRIV 0 /CCP DEC LJ250 Color Companion printer
+-! CGDRIV 1 /CGM CGM metafile, indexed colour selection C
+-! CGDRIV 2 /CGMD CGM metafile, direct colour selection C
+-! CWDRIV 0 /CW6320 Gould/Bryans Colourwriter 6320 pen plotter Std F77
++ CGDRIV 1 /CGM CGM metafile, indexed colour selection C
++ CGDRIV 2 /CGMD CGM metafile, direct colour selection C
++ CWDRIV 0 /CW6320 Gould/Bryans Colourwriter 6320 pen plotter Std F77
+ ! EPDRIV 0 /EPSON Epson FX100 dot matrix printer
+ ! EXDRIV 1 /EXCL Talaris/EXCL printers, landscape
! EXDRIV 2 /EXCL Talaris/EXCL printers, portrait
! GCDRIV 0 /GENICOM Genicom 4410 dot-matrix printer, landscape
! Caution: use of GIDRIV may require a license from Unisys:
-! GIDRIV 1 /GIF GIF-format file, landscape
-! GIDRIV 2 /VGIF GIF-format file, portrait
-+ GIDRIV 1 /GIF GIF-format file, landscape
-+ GIDRIV 2 /VGIF GIF-format file, portrait
- ! GLDRIV 1 /HPGL Hewlett-Packard HP-GL plotters, landscape Std F77
- ! GLDRIV 2 /VHPGL Hewlett-Packard HP-GL plotters, portrait Std F77
+-! GLDRIV 1 /HPGL Hewlett-Packard HP-GL plotters, landscape Std F77
+-! GLDRIV 2 /VHPGL Hewlett-Packard HP-GL plotters, portrait Std F77
++ GIDRIV 1 /GIF GIF-format file, landscape
++ GIDRIV 2 /VGIF GIF-format file, portrait
++ GLDRIV 1 /HPGL Hewlett-Packard HP-GL plotters, landscape Std F77
++ GLDRIV 2 /VHPGL Hewlett-Packard HP-GL plotters, portrait Std F77
! GODRIV 0 /GOC GOC Sigma T5670 terminal VMS
-@@ -32,19 +32,19 @@
- ! LSDRIV 2 /VLIPS2 Canon LaserShot printer (portrait)
+ ! GVDRIV 0 /GVENICOM Genicom 4410 dot-matrix printer, portrait
+-! HGDRIV 0 /HPGL2 Hewlett-Packard graphics language
+-! HIDRIV 0 /HIDMP Houston Instruments HIDMP pen plotter
++ HGDRIV 0 /HPGL2 Hewlett-Packard graphics language
++ HIDRIV 0 /HIDMP Houston Instruments HIDMP pen plotter
+ ! HJDRIV 0 /HJ Hewlett-Packard Desk/Laserjet printer
+-! HPDRIV 0 /HP7221 Hewlett-Packard HP7221 pen plotter Std F77
++ HPDRIV 0 /HP7221 Hewlett-Packard HP7221 pen plotter Std F77
+ ! LADRIV 0 /LA50 Dec LA50 and other sixel printers
+ ! LJDRIV 0 /LJ Hewlett-Packard LaserJet printers VMS
+-! LSDRIV 1 /LIPS2 Canon LaserShot printer (landscape)
+-! LSDRIV 2 /VLIPS2 Canon LaserShot printer (portrait)
++ LSDRIV 1 /LIPS2 Canon LaserShot printer (landscape)
++ LSDRIV 2 /VLIPS2 Canon LaserShot printer (portrait)
! LNDRIV 0 /LN03 Dec LN03-PLUS Laser printer (landscape) VMS
! LVDRIV 0 /LVN03 Dec LN03-PLUS Laser printer (portrait) VMS
-! LXDRIV 0 /LATEX LaTeX picture environment
-+ LXDRIV 0 /LATEX LaTeX picture environment
++ LXDRIV 0 /LATEX LaTeX picture environment
! MFDRIV 0 /FILE PGPLOT graphics metafile
! NEDRIV 0 /NEXT Computers running NeXTstep operating system
NUDRIV 0 /NULL Null device (no output) Std F77
- ! PGDRIV 0 /PGMF PGPLOT metafile (new format, experimental) Std F77
+-! PGDRIV 0 /PGMF PGPLOT metafile (new format, experimental) Std F77
-! PNDRIV 1 /PNG Portable Network Graphics file C
-! PNDRIV 2 /TPNG Portable Network Graphics file - transparent background C
-+ PNDRIV 1 /PNG Portable Network Graphics file C
-+ PNDRIV 2 /TPNG Portable Network Graphics file - transparent background C
- ! PPDRIV 1 /PPM Portable Pixel Map file, landscape
- ! PPDRIV 2 /VPPM Portable PIxel Map file, portrait
+-! PPDRIV 1 /PPM Portable Pixel Map file, landscape
+-! PPDRIV 2 /VPPM Portable PIxel Map file, portrait
-! PSDRIV 1 /PS PostScript printers, monochrome, landscape Std F77
-! PSDRIV 2 /VPS Postscript printers, monochrome, portrait Std F77
-! PSDRIV 3 /CPS PostScript printers, color, landscape Std F77
-! PSDRIV 4 /VCPS PostScript printers, color, portrait Std F77
-+ PSDRIV 1 /PS PostScript printers, monochrome, landscape Std F77
-+ PSDRIV 2 /VPS Postscript printers, monochrome, portrait Std F77
-+ PSDRIV 3 /CPS PostScript printers, color, landscape Std F77
-+ PSDRIV 4 /VCPS PostScript printers, color, portrait Std F77
++ PGDRIV 0 /PGMF PGPLOT metafile (new format, experimental) Std F77
++ PNDRIV 1 /PNG Portable Network Graphics file C
++ PNDRIV 2 /TPNG Portable Network Graphics file - transparent background C
++ PPDRIV 1 /PPM Portable Pixel Map file, landscape
++ PPDRIV 2 /VPPM Portable PIxel Map file, portrait
++ PSDRIV 1 /PS PostScript printers, monochrome, landscape Std F77
++ PSDRIV 2 /VPS Postscript printers, monochrome, portrait Std F77
++ PSDRIV 3 /CPS PostScript printers, color, landscape Std F77
++ PSDRIV 4 /VCPS PostScript printers, color, portrait Std F77
! PXDRIV 0 /PRINTRONI Printronix P300 or P600 dot-matrix printer
- ! QMDRIV 1 /QMS QUIC devices (QMS and Talaris), landscape Std F77
- ! QMDRIV 2 /VQMS QUIC devices (QMS and Talaris), portrait Std F77
-@@ -54,7 +54,7 @@
- ! TTDRIV 2 /GF GraphOn terminal Std F77
- ! TTDRIV 3 /RETRO RetroGraphics terminal Std F77
- ! TTDRIV 4 /GTERM GTERM Tektronix terminal emulator Std F77
+-! QMDRIV 1 /QMS QUIC devices (QMS and Talaris), landscape Std F77
+-! QMDRIV 2 /VQMS QUIC devices (QMS and Talaris), portrait Std F77
++ QMDRIV 1 /QMS QUIC devices (QMS and Talaris), landscape Std F77
++ QMDRIV 2 /VQMS QUIC devices (QMS and Talaris), portrait Std F77
+ ! TFDRIV 0 /TFILE Tektronix-format disk file VMS
+ ! TODRIV 0 /TOSHIBA Toshiba "3-in-one" printer, model P351
+-! TTDRIV 1 /TEK4010 Tektronix 4006/4010 storage-tube terminal Std F77
+-! TTDRIV 2 /GF GraphOn terminal Std F77
+-! TTDRIV 3 /RETRO RetroGraphics terminal Std F77
+-! TTDRIV 4 /GTERM GTERM Tektronix terminal emulator Std F77
-! TTDRIV 5 /XTERM XTERM Tektronix terminal emulator Std F77
-+ TTDRIV 5 /XTERM XTERM Tektronix terminal emulator Std F77
- ! TTDRIV 6 /ZSTEM ZSTEM terminal emulator Std F77
- ! TTDRIV 7 /V603 Visual 603 terminal Std F77
+-! TTDRIV 6 /ZSTEM ZSTEM terminal emulator Std F77
+-! TTDRIV 7 /V603 Visual 603 terminal Std F77
++ TTDRIV 1 /TEK4010 Tektronix 4006/4010 storage-tube terminal Std F77
++ TTDRIV 2 /GF GraphOn terminal Std F77
++ TTDRIV 3 /RETRO RetroGraphics terminal Std F77
++ TTDRIV 4 /GTERM GTERM Tektronix terminal emulator Std F77
++ TTDRIV 5 /XTERM XTERM Tektronix terminal emulator Std F77
++ TTDRIV 6 /ZSTEM ZSTEM terminal emulator Std F77
++ TTDRIV 7 /V603 Visual 603 terminal Std F77
! TTDRIV 8 /KRM3 Kermit 3 on IBM-PC Std F77
-@@ -64,12 +64,12 @@
- ! VADRIV 0 /VCANON Canon Laser printer, LBP-8/A2, portrait
- ! VBDRIV 0 /VBCANON Canon Laser printer (bitmap version), portrait
- ! VTDRIV 0 /VT125 Dec Regis terminals (VT125 etc.) Std F77
+-! TTDRIV 9 /TK4100 Tektronix 4100-series terminals Std F77
+-! TTDRIV 10 /VMAC Macintosh VersaTerm-PRO Tektronix-4105 emulator Std F77
++ TTDRIV 9 /TK4100 Tektronix 4100-series terminals Std F77
++ TTDRIV 10 /VMAC Macintosh VersaTerm-PRO Tektronix-4105 emulator Std F77
+ ! TXDRIV 0 /TX TeX PK Font Output files
+-! VADRIV 0 /VCANON Canon Laser printer, LBP-8/A2, portrait
+-! VBDRIV 0 /VBCANON Canon Laser printer (bitmap version), portrait
+-! VTDRIV 0 /VT125 Dec Regis terminals (VT125 etc.) Std F77
-! WDDRIV 1 /WD X Window dump file, landscape
-! WDDRIV 2 /VWD X Window dump file, portrait
-+ WDDRIV 1 /WD X Window dump file, landscape
-+ WDDRIV 2 /VWD X Window dump file, portrait
++ VADRIV 0 /VCANON Canon Laser printer, LBP-8/A2, portrait
++! VBDRIV 0 /VBCANON Canon Laser printer (bitmap version), portrait
++ VTDRIV 0 /VT125 Dec Regis terminals (VT125 etc.) Std F77
++ WDDRIV 1 /WD X Window dump file, landscape
++ WDDRIV 2 /VWD X Window dump file, portrait
! WSDRIV 0 /WS VAX workstations running VWS software VMS
- ! X2DRIV 0 /XDISP PGDISP or FIGDISP server for X workstations C
+-! X2DRIV 0 /XDISP PGDISP or FIGDISP server for X workstations C
-! XWDRIV 1 /XWINDOW Workstations running X Window System C
-! XWDRIV 2 /XSERVE Persistent window on X Window System C
-+ XWDRIV 1 /XWINDOW Workstations running X Window System C
-+ XWDRIV 2 /XSERVE Persistent window on X Window System C
- ! ZEDRIV 0 /ZETA Zeta 8 Digital Plotter
+-! ZEDRIV 0 /ZETA Zeta 8 Digital Plotter
++ X2DRIV 0 /XDISP PGDISP or FIGDISP server for X workstations C
++ XWDRIV 1 /XWINDOW Workstations running X Window System C
++ XWDRIV 2 /XSERVE Persistent window on X Window System C
++! ZEDRIV 0 /ZETA Zeta 8 Digital Plotter
!
! The following drivers can only be used in PGPLOT installations on MS-DOS
+ ! systems with appropriate hardware and software. Do not select these
--- /dev/null
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/pgplot/pgplot-5.2.2-r2.ebuild,v 1.1 2007/03/09 02:54:50 bicatali Exp $
+
+inherit eutils toolchain-funcs fortran
+
+MY_P="${PN}${PV//.}"
+DESCRIPTION="A C/FORTRAN device-independent graphics library for making simple scientific graphs"
+HOMEPAGE="http://www.astro.caltech.edu/~tjp/pgplot/"
+SRC_URI="ftp://ftp.astro.caltech.edu/pub/pgplot/${MY_P}.tar.gz"
+LICENSE="free-noncomm"
+SLOT="0"
+KEYWORDS="~amd64 ~ia64 ~x86"
+IUSE="doc motif tk"
+RDEPEND="x11-libs/libX11
+ media-libs/libpng
+ motif? ( virtual/motif )
+ tk? ( dev-lang/tk )"
+DEPEND="${RDEPEND}
+ doc? ( virtual/tetex )"
+
+S="${WORKDIR}/${PN}"
+
+FORTRAN="g77 gfortran"
+
+src_unpack() {
+ fortran_src_unpack ${A}
+ cd "${S}"
+
+ epatch "${FILESDIR}"/${PN}-drivers.patch
+ epatch "${FILESDIR}"/${PN}-makemake.patch
+ epatch "${FILESDIR}"/${PN}-compile-setup.patch
+ epatch "${FILESDIR}"/${PN}-pgdisp.patch
+
+ # gfortran does not compile gif, pp and wd drivers
+ # (might change with gfortran 4.2 or 4.3)
+ if [[ "${FORTRANC}" == "gfortran" ]]; then
+ ewarn
+ ewarn "Warning!"
+ elog "gfortran selected: does not yet compile all drivers"
+ elog "disabling gif, wd, and ppd drivers"
+ elog "if you want more drivers, use g77"
+ ewarn
+ sed -i \
+ -e 's/GIDRIV/! GIDRIV/g' \
+ -e 's/PPDRIV/! GIDRIV/g' \
+ -e 's/WDDRIV/! GIDRIV/g' \
+ drivers.list || die "sed drivers failed"
+ fi
+
+ # fix pointers for 64 bits
+ if use amd64 -o use ia64; then
+ sed -i \
+ -e 's/INTEGER PIXMAP/INTEGER*8 PIXMAP/g' \
+ drivers/{gi,pp,wd}driv.f || die "sed 64bits failed"
+ fi
+
+ cp sys_linux/g77_gcc.conf local.conf
+
+ sed -i \
+ -e "s:FCOMPL=.*:FCOMPL=\"${FORTRANC}\":g" \
+ -e "s:FFLAGOPT=.*:FFLAGOPT=\"${FFLAGS:- -O2}\":g" \
+ -e "s:CCOMPL=.*:CCOMPL=\"$(tc-getCC)\":g" \
+ -e "s:CFLAGOPT=.*:CFLAGOPT=\"${CFLAGS}\":g" \
+ local.conf || die "sed flags failed"
+
+ sed -i \
+ -e "s:/usr/local/pgplot:/usr/$(get_libdir)/pgplot:g" \
+ -e "s:/usr/local/bin:/usr/bin:g" \
+ src/grgfil.f makehtml maketex || die "sed path failed"
+
+ use motif && \
+ sed -i -e '/XMDRIV/s/!//' drivers.list
+
+ use tk && \
+ sed -i -e '/TKDRIV/s/!//' drivers.list
+}
+
+src_compile() {
+ ./makemake "${S}" linux
+
+ emake -j1 || die "emake failed"
+
+ # Build C portion
+ make cpg || die "make cpg failed"
+
+ if use doc; then
+ make pgplot.html || die "make pgplot.html failed"
+ make pgplot-routines.tex || die "make pgplot-routines failed"
+ pdflatex pgplot-routines.tex
+ pdflatex pgplot-routines.tex
+ fi
+
+ # this just cleans out unneeded files
+ make clean
+}
+
+src_test() {
+ einfo "Testing various demo programs"
+ # i can go to 16
+ for i in 1 2 3; do
+ make pgdemo${i}
+ # j can also be LATEX CPS...
+ for j in NULL PNG PS CPS LATEX; do
+ local testexe=./test_${j}_${i}
+ echo "./pgdemo${i} <<EOF" > ${testexe}
+ echo "/${j}" >> ${testexe}
+ echo "EOF" >> ${testexe}
+ sh ${testexe} || die "test ${i} failed"
+ done
+ done
+}
+
+src_install() {
+ insinto /usr/$(get_libdir)/pgplot
+ doins grfont.dat grexec.f *.inc rgb.txt
+
+ # FORTRAN libs
+ dolib.a libpgplot.a
+ dolib.so libpgplot.so
+ dosym libpgplot.so.5 /usr/$(get_libdir)/libpgplot.so
+ dobin pgxwin_server pgdisp
+
+ # C binding
+ insinto /usr/include
+ doins cpgplot.h
+ dolib.a libcpgplot.a
+ # shared lib: todo eventually in a patch
+ # dolib.so libcpgplot.so
+ # dosym libcpgplot.so.5 /usr/$(get_libdir)/libcpgplot.so
+
+ if use motif; then
+ doins XmPgplot.h
+ dolib.a libXmPgplot.a
+ fi
+
+ if use tk; then
+ doins tkpgplot.h
+ dolib.a libtkpgplot.a
+ fi
+
+ # minimal doc
+ dodoc aaaread.me pgplot.doc
+ newdoc pgdispd/aaaread.me pgdisp.txt
+
+ if use doc; then
+ dodoc cpg/cpgplot.doc applications/curvefit/curvefit.doc
+ dohtml pgplot.html
+ insinto /usr/share/doc/${PF}
+ doins pgplot-routines.pdf pgplot-routines.tex
+ insinto /usr/share/doc/${PF}/examples
+ doins examples/* cpg/cpgdemo.c
+ insinto /usr/share/doc/${PF}/applications
+ doins -r applications/*
+ if use motif; then
+ insinto /usr/share/doc/${PF}/pgm
+ doins pgmf/* drivers/xmotif/pgmdemo.c
+ fi
+ if use tk; then
+ insinto /usr/share/doc/${PF}/pgtk
+ doins drivers/xtk/pgtkdemo.*
+ fi
+ fi
+}