ports/155707: port: math/PDL upgrades to 2.4.7
Zhihao Yuan
lichray at gmail.com
Sun Mar 20 01:00:12 UTC 2011
>Number: 155707
>Category: ports
>Synopsis: port: math/PDL upgrades to 2.4.7
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Sun Mar 20 01:00:10 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Zhihao Yuan
>Release: FreeBSD 8.2-STABLE amd64
>Organization:
Northern Illinois University
>Environment:
System: FreeBSD compaq.yuetime 8.2-STABLE FreeBSD 8.2-STABLE #0: Mon Mar 14 02:51:28 CDT 2011 root at compaq.yuetime:/usr/obj/usr/src/sys/HOUKAGO amd64
>Description:
PDL has been upgraded to 2.4.7 for a long time. It's stable enough :)
Check http://pdl.perl.org/ for details.
p5-OpenGL needs to be upgrade also. Currently, this PDL port depends on GLU only. But we hope it can work better with p5-OpenGL >= 0.64.
>How-To-Repeat:
>Fix:
In this patch, I made some big changes:
1. Replace the hard coded dependence with options, according to PDL's DEPENDENCIES intoduction and actual tests on FreeBSD;
2. Use the book "PDL -- Scientific Programming in Perl" (http://www.johnlapeyre.com/pdl/pdldoc/newbook/) as a reference to select the default options;
3. Update the FreeBSD-specific patches.
Note that I disabled the `new' pdl2 shell, since it depends on Devel::REPL, which has lots of dependences, and pdl2 is not that fancy.
A big issue is, the build of PDL::Minuit and PDL::Slatec are broken. The reason is that p5-ExtUtils-F77 is broken (it can not find -lg2c or -lf2c out of box). After the F77 port is fixed, these features will work automatically.
--- patch-PDL-2.4.7 begins here ---
===> Generating patch
===> Viewing diff with more
diff -ruN --exclude=CVS /usr/ports/math/PDL.orig/Makefile /usr/ports/math/PDL/Makefile
--- /usr/ports/math/PDL.orig/Makefile 2011-03-04 09:28:53.000000000 -0600
+++ /usr/ports/math/PDL/Makefile 2011-03-19 19:26:59.183846586 -0500
@@ -7,8 +7,7 @@
#
PORTNAME= PDL
-PORTVERSION= 2.4.4
-PORTREVISION= 8
+PORTVERSION= 2.4.7
CATEGORIES= math perl5
MASTER_SITES= CPAN/${PORTNAME}:cpan \
SF/pdl/PDL/${PORTVERSION}:sf
@@ -17,19 +16,11 @@
MAINTAINER= perl at FreeBSD.org
COMMENT= Perl Data Language
-BUILD_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/PGPLOT.pm:${PORTSDIR}/graphics/pgperl \
- ${SITE_PERL}/ExtUtils/F77.pm:${PORTSDIR}/lang/p5-F77 \
- ${SITE_PERL}/Inline.pm:${PORTSDIR}/devel/p5-Inline \
+BUILD_DEPENDS= ${SITE_PERL}/Inline.pm:${PORTSDIR}/devel/p5-Inline \
${SITE_PERL}/${PERL_ARCH}/Filter/Util/Call.pm:${PORTSDIR}/devel/p5-Filter \
- ${SITE_PERL}/Astro/FITS/Header.pm:${PORTSDIR}/astro/p5-Astro-FITS-Header \
- ${SITE_PERL}/${PERL_ARCH}/PGPLOT.pm:${PORTSDIR}/graphics/pgperl \
- ${SITE_PERL}/Term/ReadLine/readline.pm:${PORTSDIR}/devel/p5-ReadLine-Perl
-LIB_DEPENDS= plplotd.10:${PORTSDIR}/math/plplot \
- fftw.2:${PORTSDIR}/math/fftw \
- gsl.15:${PORTSDIR}/math/gsl
+ ${SITE_PERL}/Astro/FITS/Header.pm:${PORTSDIR}/astro/p5-Astro-FITS-Header
RUN_DEPENDS= ${BUILD_DEPENDS}
-USE_GL= yes
PERL_CONFIGURE= yes
USE_GMAKE= yes
MAKE_ENV+= PERL5LIB=${WRKSRC}/blib/lib
@@ -39,23 +30,66 @@
${SITE_PERL_REL}/${PERL_ARCH}/Inline/MakePdlppInstallable.pm
MAKE_JOBS_UNSAFE= yes
-.if defined(KITCHEN_SINK)
-RUN_DEPENDS+= ppmtogif:${PORTSDIR}/graphics/netpbm \
- mpeg_encode:${PORTSDIR}/multimedia/mpeg_encode \
- saoimage:${PORTSDIR}/astro/saoimage
+OPTIONS= PGPLOT "Enable PDL::Graphics::PGPLOT" on \
+ PLPLOT "Enable PDL::Graphics::PLplot" off \
+ GL "Enable PDL::Graphics::TriD and OpenGL" on \
+ GD "Enable PDL::IO::GD" off \
+ FFTW "Enable PDL::FFTW" on \
+ GSL "Enable PDL::GSL interface" off \
+ HDF "Enable PDL::IO::HDF interface" off \
+ PROJ "Enable PDL::GIS::Proj interface" off \
+ F77 "Enable PDL::Minuit and PDL::Slatec" on \
+ READLINE "Use GNU readline" off \
+ SINK "Include PDL kitchen sink" off
+
+.include <bsd.port.options.mk>
+
+.if defined(WITH_PGPLOT)
+BUILD_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/PGPLOT.pm:${PORTSDIR}/graphics/pgperl
.endif
-.SILENT:
+.if defined(WITH_PLPLOT)
+LIB_DEPENDS+= plplotd.10:${PORTSDIR}/math/plplot
+.endif
-.if !defined(KITCHEN_SINK)
-pre-extract:
- ${ECHO} "You can build additional functionality into PDL by defining KITCHEN_SINK"
+.if defined(WITH_GL)
+USE_GL= yes
.endif
-.include <bsd.port.pre.mk>
+.if defined(WITH_GD)
+LIB_DEPENDS+= gd:${PORTSDIR}/graphics/gd
+.endif
+
+.if defined(WITH_F77)
+BUILD_DEPENDS+= ${SITE_PERL}/ExtUtils/F77.pm:${PORTSDIR}/lang/p5-F77
+.endif
+
+.if defined(WITH_FFTW)
+LIB_DEPENDS+= fftw.2:${PORTSDIR}/math/fftw
+.endif
+
+.if defined(WITH_GSL)
+LIB_DEPENDS+= gsl:${PORTSDIR}/math/gsl
+.endif
+
+.if defined(WITH_HDF)
+LIB_DEPENDS+= df:${PORTSDIR}/science/hdf
+.endif
+
+.if defined(WITH_PROJ)
+LIB_DEPENDS+= proj:${PORTSDIR}/graphics/proj
+.endif
-.if ${ARCH} == "alpha"
-BROKEN= test script t/flexraw.t fails all 26 tests
+.if defined(WITH_READLINE)
+RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Term/ReadLine/Gnu.pm:${PORTSDIR}/devel/p5-ReadLine-Gnu
+.else
+RUN_DEPENDS+= ${SITE_PERL}/Term/ReadLine/readline.pm:${PORTSDIR}/devel/p5-ReadLine-Perl
+.endif
+
+.if defined(WITH_SINK)
+RUN_DEPENDS+= ppmtogif:${PORTSDIR}/graphics/netpbm \
+ mpeg_encode:${PORTSDIR}/multimedia/mpeg_encode \
+ saoimage:${PORTSDIR}/astro/saoimage
.endif
post-patch:
@@ -84,4 +118,5 @@
${FIND} ${SITE_PERL}/${PERL_ARCH}/auto/PDL -type d | ${SORT} -r | \
${SED} "s,^${PREFIX}/, at dirrm ," >> ${TMPPLIST})
+.include <bsd.port.pre.mk>
.include <bsd.port.post.mk>
diff -ruN --exclude=CVS /usr/ports/math/PDL.orig/distinfo /usr/ports/math/PDL/distinfo
--- /usr/ports/math/PDL.orig/distinfo 2009-02-01 12:52:44.000000000 -0600
+++ /usr/ports/math/PDL/distinfo 2011-03-19 16:20:01.853390495 -0500
@@ -1,3 +1,2 @@
-MD5 (PDL-2.4.4.tar.gz) = 1c3e8f2fd001a8b48687fb277bc16eed
-SHA256 (PDL-2.4.4.tar.gz) = e7d4dfcae14f02dac1b0b353465bb49f474304d8a6e7e139dc62fefdcb77978d
-SIZE (PDL-2.4.4.tar.gz) = 2341784
+SHA256 (PDL-2.4.7.tar.gz) = 907ecfa69fa2bdfc5d3464eab7eda9df11f647b4fb3cb87e25969bc29f710a58
+SIZE (PDL-2.4.7.tar.gz) = 2598921
diff -ruN --exclude=CVS /usr/ports/math/PDL.orig/files/patch-gg /usr/ports/math/PDL/files/patch-gg
--- /usr/ports/math/PDL.orig/files/patch-gg 2004-03-11 20:58:25.000000000 -0600
+++ /usr/ports/math/PDL/files/patch-gg 1969-12-31 18:00:00.000000000 -0600
@@ -1,12 +0,0 @@
---- Basic/Math/mconf.h.orig Wed Sep 25 00:57:31 2002
-+++ Basic/Math/mconf.h Wed Sep 25 00:58:06 2002
-@@ -89,7 +89,9 @@
- #endif
- #if defined __alpha && ! defined __linux
- #include <float.h>
-+#ifndef __FreeBSD__
- #include <nan.h>
-+#endif
- #endif
- #ifndef NANARG
- #define NANARG
diff -ruN --exclude=CVS /usr/ports/math/PDL.orig/files/patch-mconf.h /usr/ports/math/PDL/files/patch-mconf.h
--- /usr/ports/math/PDL.orig/files/patch-mconf.h 1969-12-31 18:00:00.000000000 -0600
+++ /usr/ports/math/PDL/files/patch-mconf.h 2011-03-19 17:12:52.000000000 -0500
@@ -0,0 +1,13 @@
+--- Basic/Math/mconf.h.orig 2010-05-08 21:43:08.000000000 -0500
++++ Basic/Math/mconf.h 2011-03-19 17:12:01.099417176 -0500
+@@ -89,8 +89,10 @@ Copyright 1984, 1987, 1989, 1995 by Step
+ #endif
+ #if defined __alpha && ! defined __linux
+ #include <float.h>
++#ifndef __FreeBSD__
+ #include <nan.h>
+ #endif
++#endif
+ #ifndef NANARG
+ #define NANARG
+ #endif
diff -ruN --exclude=CVS /usr/ports/math/PDL.orig/files/patch-perldl.conf /usr/ports/math/PDL/files/patch-perldl.conf
--- /usr/ports/math/PDL.orig/files/patch-perldl.conf 2006-10-05 23:04:05.000000000 -0500
+++ /usr/ports/math/PDL/files/patch-perldl.conf 2011-03-19 19:07:23.000000000 -0500
@@ -1,21 +1,20 @@
---- perldl.conf.orig Thu Aug 17 10:59:51 2006
-+++ perldl.conf Mon Oct 2 09:45:30 2006
-@@ -113,6 +113,9 @@
- # OPENGL_LIBS => undef,
- # OPENGL_INC => undef,
- # OPENGL_DEFINE => undef,
-+ OPENGL_LIBS => '-L/usr/X11R6/lib -lGL -lGLU -lXext -lX11',
-+ OPENGL_INC => '-I/usr/X11R6/include',
-+ OPENGL_DEFINE => '-DGL_GLEXT_LEGACY',
-
- # Whether or not to build the Karma interface module
-
-@@ -191,7 +194,7 @@
- # about curses to fix it
- # - 1 builds, 0 or undef does not build
+--- perldl.conf.orig 2010-08-15 12:38:21.000000000 -0500
++++ perldl.conf 2011-03-19 19:07:04.854128623 -0500
+@@ -229,7 +229,7 @@
+ # Do we build PDL::IO::Browser?
+ # default -> do not build (module needs to be updated)
#
- WITH_IO_BROWSER => 0,
+ WITH_IO_BROWSER => 1,
# Quiet Astro::FITS::Header warnings for PDL build process by default
# Eventually would be better to set undef by default, and have the
+@@ -246,7 +246,7 @@
+ # false -> don't install pdl2 support
+ # true -> force pdl2 install (default)
+
+- WITH_DEVEL_REPL => 1,
++ WITH_DEVEL_REPL => 0,
+
+ # Set this for official CPAN releases of PDL since these
+ # tests will always fail until they are fixed. It can also
===> Done
--- patch-PDL-2.4.7 ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list