diff options
author | seb <seb> | 2004-02-07 17:44:10 +0000 |
---|---|---|
committer | seb <seb> | 2004-02-07 17:44:10 +0000 |
commit | 085502c3b9b98db1f0f0b49f3e4a862895609ad5 (patch) | |
tree | 0cc9b59ae35a2c0d004fab9d1b2b81078ee56651 /databases/rrdtool | |
parent | 3aecf97e36467739a8e9b4908d564177ab4143df (diff) | |
download | pkgsrc-085502c3b9b98db1f0f0b49f3e4a862895609ad5.tar.gz |
Now that lang/perl5/module.mk fiddles with OTHERLDFLAGS fix the way
RRDs.so shared perl module is built and thus fix runtime failure
described in PR pkg/24292 by Michael van Elst <mlelstv at serpens dot de>.
Also fix sparc64 compilation warnings and runtime failure due to
time_t's size assumption: sizeof(time_t) != sizeof(long) on NetBSD/sparc64.
While here bl3ify, this somewhat simplify the package, and provide
a buildlink3.mk file.
Bump PKGREVISION.
With wulf@'s blessing.
Diffstat (limited to 'databases/rrdtool')
-rw-r--r-- | databases/rrdtool/Makefile | 29 | ||||
-rw-r--r-- | databases/rrdtool/buildlink3.mk | 22 | ||||
-rw-r--r-- | databases/rrdtool/distinfo | 10 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-ap | 35 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-as | 11 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-av | 22 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-aw | 34 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-ax | 30 | ||||
-rw-r--r-- | databases/rrdtool/patches/patch-ay | 13 |
9 files changed, 151 insertions, 55 deletions
diff --git a/databases/rrdtool/Makefile b/databases/rrdtool/Makefile index df2996fc3e5..a9e47f8b799 100644 --- a/databases/rrdtool/Makefile +++ b/databases/rrdtool/Makefile @@ -1,8 +1,8 @@ -# $NetBSD: Makefile,v 1.22 2004/01/22 08:02:16 grant Exp $ +# $NetBSD: Makefile,v 1.23 2004/02/07 17:44:10 seb Exp $ # DISTNAME= rrdtool-1.0.40 -PKGREVISION= 1 +PKGREVISION= 2 CATEGORIES= databases graphics net MASTER_SITES= http://ee-staff.ethz.ch/~oetiker/webtools/rrdtool/pub/ @@ -15,7 +15,7 @@ NOT_FOR_PLATFORM= NetBSD-1.[0-4]*-alpha NetBSD-1.5-alpha \ NetBSD-1.5.*-alpha NetBSD-1.5[A-U]-alpha USE_LIBTOOL= # defined -USE_BUILDLINK2= # defined +USE_BUILDLINK3= yes LTCONFIG_OVERRIDE= ${WRKSRC}/config/ltconfig LTCONFIG_OVERRIDE+= ${WRKSRC}/contrib/php4/ltconfig USE_GNU_TOOLS+= make @@ -30,28 +30,13 @@ PERL5_PACKLIST+= ${PERL5_SITEARCH}/auto/RRDs/.packlist INSTALL_DIRS= ${WRKSRC} ${WRKSRC}/perl-piped ${WRKSRC}/perl-shared -MAKE_ENV+= CGILIB_INC=${BUILDLINK_PREFIX.cgilib}/include -MAKE_ENV+= CGILIB_LIB=${BUILDLINK_PREFIX.cgilib}/lib -MAKE_ENV+= GD_INC=${BUILDLINK_PREFIX.gd}/include -MAKE_ENV+= GD_LIB=${BUILDLINK_PREFIX.gd}/lib -MAKE_ENV+= JPEG_INC=${BUILDLINK_PREFIX.jpeg}/include -MAKE_ENV+= JPEG_LIB=${BUILDLINK_PREFIX.jpeg}/lib -MAKE_ENV+= ZLIB_INC=${BUILDLINK_PREFIX.zlib}/include -MAKE_ENV+= ZLIB_LIB=${BUILDLINK_PREFIX.zlib}/lib -MAKE_ENV+= PNG_INC=${BUILDLINK_PREFIX.png}/include -MAKE_ENV+= PNG_LIB=${BUILDLINK_PREFIX.png}/lib -MAKE_ENV+= TTF_INC=${BUILDLINK_PREFIX.freetype}/include -MAKE_ENV+= TTF_LIB=${BUILDLINK_PREFIX.freetype}/lib - -MAKE_ENV+= _RPATH=${_OPSYS_RPATH_NAME} - # remove this or else it is installed post-extract: ${RM} ${WRKSRC}/perl-shared/ntmake.pl -.include "../../graphics/freetype-lib/buildlink2.mk" -.include "../../graphics/jpeg/buildlink2.mk" -.include "../../graphics/gd/buildlink2.mk" -.include "../../www/cgilib/buildlink2.mk" +.include "../../graphics/freetype-lib/buildlink3.mk" +.include "../../graphics/jpeg/buildlink3.mk" +.include "../../graphics/gd/buildlink3.mk" +.include "../../www/cgilib/buildlink3.mk" .include "../../lang/perl5/module.mk" .include "../../mk/bsd.pkg.mk" diff --git a/databases/rrdtool/buildlink3.mk b/databases/rrdtool/buildlink3.mk new file mode 100644 index 00000000000..7044c4881eb --- /dev/null +++ b/databases/rrdtool/buildlink3.mk @@ -0,0 +1,22 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/02/07 17:44:10 seb Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +RRDTOOL_BUILDLINK3_MK:= ${RRDTOOL_BUILDLINK3_MK}+ + +.if !empty(BUILDLINK_DEPTH:M+) +BUILDLINK_DEPENDS+= rrdtool +.endif + +.if !empty(RRDTOOL_BUILDLINK3_MK:M+) +BUILDLINK_PACKAGES+= rrdtool +BUILDLINK_DEPENDS.rrdtool?= rrdtool>=1.0.40nb2 +BUILDLINK_PKGSRCDIR.rrdtool?= ../../databases/rrdtool + +.include "../../graphics/freetype-lib/buildlink3.mk" +.include "../../graphics/jpeg/buildlink3.mk" +.include "../../graphics/gd/buildlink3.mk" +.include "../../www/cgilib/buildlink3.mk" + +.endif # RRDTOOL_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} diff --git a/databases/rrdtool/distinfo b/databases/rrdtool/distinfo index a0983489b60..15210878c83 100644 --- a/databases/rrdtool/distinfo +++ b/databases/rrdtool/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.9 2003/02/16 23:08:56 seb Exp $ +$NetBSD: distinfo,v 1.10 2004/02/07 17:44:10 seb Exp $ SHA1 (rrdtool-1.0.40.tar.gz) = 6ad5265826049868663d0f3b4e2ef8f2f1aa06ed Size (rrdtool-1.0.40.tar.gz) = 1148458 bytes @@ -17,9 +17,13 @@ SHA1 (patch-al) = 5293431b7966b25c48c624c6b7d0a4e86a5f70d2 SHA1 (patch-am) = a48ad230b9a9a2d18dabd747e6759aa1e211831f SHA1 (patch-an) = 9b0e279929549d22187f1b24512e939b965f76c2 SHA1 (patch-ao) = 88cd4b0b43782338145c1ee40bc1349a120a9676 -SHA1 (patch-ap) = 40af210cd71e7bfa4af6f134d768b4b9d5e8c424 +SHA1 (patch-ap) = 47e1b9619af73a73b3b141f5496fba1068b8eea9 SHA1 (patch-aq) = 68aebe6c28a7bf4c93ff9196709a2b99c8b8a010 SHA1 (patch-ar) = 18bd27b8d9bda4480d98be07a5c63c4f0667494f -SHA1 (patch-as) = 2a6462263704d8da114d3b801a76844d42da3ce8 +SHA1 (patch-as) = c81106bffd2be89d98a121b136516a2c5c5ce012 SHA1 (patch-at) = 4a832681eb46c81ce957846368981e50a3b96769 SHA1 (patch-au) = 7633d5a70004f10629b6076c5897dc9af0cec59e +SHA1 (patch-av) = 00ab5347cf668347e3f816f21c0d9800a5726eb0 +SHA1 (patch-aw) = 19244da8f514245b171216babd5f1404f2e2ff43 +SHA1 (patch-ax) = 893f84787012fc2ef98a408f847d378c70b63967 +SHA1 (patch-ay) = fe21c6adab6591a4770b2875620712d6135a2dda diff --git a/databases/rrdtool/patches/patch-ap b/databases/rrdtool/patches/patch-ap index 9fb95252c10..6c300f202f1 100644 --- a/databases/rrdtool/patches/patch-ap +++ b/databases/rrdtool/patches/patch-ap @@ -1,42 +1,19 @@ -$NetBSD: patch-ap,v 1.4 2003/02/16 23:08:59 seb Exp $ +$NetBSD: patch-ap,v 1.5 2004/02/07 17:44:10 seb Exp $ ---- perl-shared/Makefile.PL.in.orig Thu Mar 21 21:52:35 2002 +--- perl-shared/Makefile.PL.in.orig 2002-03-21 21:52:35.000000000 +0000 +++ perl-shared/Makefile.PL.in -@@ -6,14 +6,34 @@ use Config; - # Specify the location of the archive containing PIC compiled object files. - my $librrd = "-L../src/.libs/ -lrrd_private" ; - -+my $CGILIB_INC = $ENV{CGILIB_INC}; -+my $CGILIB_LIB = $ENV{CGILIB_LIB}; -+my $GD_INC = $ENV{GD_INC}; -+my $GD_LIB = $ENV{GD_LIB}; -+my $JPEG_INC = $ENV{JPEG_INC}; -+my $JPEG_LIB = $ENV{JPEG_LIB}; -+my $ZLIB_INC = $ENV{ZLIB_INC}; -+my $ZLIB_LIB = $ENV{ZLIB_LIB}; -+my $PNG_INC = $ENV{PNG_INC}; -+my $PNG_LIB = $ENV{PNG_LIB}; -+my $TTF_INC = $ENV{TTF_INC}; -+my $TTF_LIB = $ENV{TTF_LIB}; -+ -+my $_RPATH = $ENV{_RPATH}; -+ -+my $MY_INCS = "-I".join (" -I", ($CGILIB_INC, $GD_INC, $JPEG_INC, $ZLIB_INC, $PNG_INC, $TTF_INC)); -+my $MY_LIBS = join "-L".(" -L", ($CGILIB_LIB, $GD_LIB, $JPEG_LIB, $ZLIB_LIB, $PNG_LIB, $TTF_LIB)); -+my $MY_DLIBS = "-Wl,$_RPATH".join (" -Wl,$_RPATH", ($CGILIB_LIB, $GD_LIB, $JPEG_LIB, $ZLIB_LIB, $PNG_LIB, $TTF_LIB)); -+ - WriteMakefile( +@@ -10,10 +10,11 @@ WriteMakefile( 'NAME' => 'RRDs', 'VERSION_FROM' => '@top_srcdir@/perl-shared/RRDs.pm', # finds $VERSION 'DEFINE' => "-DPERLPATCHLEVEL=$Config{PATCHLEVEL}", - 'INC' => '-I@top_srcdir@/src -I@top_srcdir@/gd1.3', -+ 'INC' => "-I@top_srcdir@/src $MY_INCS", -+ 'LIBS' => "$MY_LIBS -lcgi -lm -lgd -lpng -lz -ljpeg -lttf", ++ 'INC' => "-I@top_srcdir@/src", ++ 'LIBS' => "-lcgi -lm -lgd -lpng -lz -ljpeg -lttf", # where to look for the necessary libraries # Perl will figure out which one is valid - 'depend' => {'RRDs.c' => "../src/.libs/librrd_private.a"}, - 'dynamic_lib' => {'OTHERLDFLAGS' => "$librrd -lm"}, + 'depend' => {'RRDs.c' => "../src/librrd_private.la"}, -+ 'dynamic_lib' => {'OTHERLDFLAGS' => "$librrd $MY_DLIBS"}, ++ 'LDFROM' => "\$(OBJECT) $librrd", 'realclean' => {FILES => 't/demo?.rrd t/demo?.gif' } ); diff --git a/databases/rrdtool/patches/patch-as b/databases/rrdtool/patches/patch-as index ed2c2b99a2a..e63a2e2ca4b 100644 --- a/databases/rrdtool/patches/patch-as +++ b/databases/rrdtool/patches/patch-as @@ -1,4 +1,4 @@ -$NetBSD: patch-as,v 1.4 2003/02/16 23:09:00 seb Exp $ +$NetBSD: patch-as,v 1.5 2004/02/07 17:44:10 seb Exp $ --- src/rrd_cgi.c.orig Fri Oct 11 18:39:46 2002 +++ src/rrd_cgi.c @@ -11,3 +11,12 @@ $NetBSD: patch-as,v 1.4 2003/02/16 23:09:00 seb Exp $ /* in arg[0] find tags beginning with arg[1] call arg[2] on them and replace by result of arg[2] call */ +@@ -168,7 +168,7 @@ int main(int argc, char *argv[]) { + + if (filter==0){ + printf ("Content-Type: text/html\n" +- "Content-Length: %d\n", strlen(buffer)); ++ "Content-Length: %zd\n", strlen(buffer)); + if (labs(goodfor) > 0){ + time_t now; + now = time(NULL); diff --git a/databases/rrdtool/patches/patch-av b/databases/rrdtool/patches/patch-av new file mode 100644 index 00000000000..203a5700ecc --- /dev/null +++ b/databases/rrdtool/patches/patch-av @@ -0,0 +1,22 @@ +$NetBSD: patch-av,v 1.1 2004/02/07 17:44:10 seb Exp $ + +--- src/parsetime.c.orig Fri Oct 11 18:39:46 2002 ++++ src/parsetime.c +@@ -660,6 +660,7 @@ day(struct time_value *ptv) + { + long mday=0, wday, mon, year = ptv->tm.tm_year; + int tlen; ++ time_t montime; + + switch (sc_tokid) { + case YESTERDAY: +@@ -713,7 +714,8 @@ day(struct time_value *ptv) + tlen = strlen(sc_token); + mon = atol(sc_token); + if (mon > 10*356*24*60*60) { +- ptv->tm=*localtime(&mon); ++ montime = mon; ++ ptv->tm=*localtime(&montime); + token(); + break; + } diff --git a/databases/rrdtool/patches/patch-aw b/databases/rrdtool/patches/patch-aw new file mode 100644 index 00000000000..9128e894acc --- /dev/null +++ b/databases/rrdtool/patches/patch-aw @@ -0,0 +1,34 @@ +$NetBSD: patch-aw,v 1.1 2004/02/07 17:44:10 seb Exp $ + +--- src/rrd_tool.c.orig Fri Oct 11 18:39:48 2002 ++++ src/rrd_tool.c +@@ -325,7 +325,7 @@ int HandleInputLine(int argc, char **arg + else if (strcmp("resize", argv[1]) == 0) + rrd_resize(argc-1, &argv[1]); + else if (strcmp("last", argv[1]) == 0) +- printf("%ld\n",rrd_last(argc-1, &argv[1])); ++ printf("%ld\n",(long)rrd_last(argc-1, &argv[1])); + else if (strcmp("update", argv[1]) == 0) + rrd_update(argc-1, &argv[1]); + else if (strcmp("fetch", argv[1]) == 0) { +@@ -363,9 +363,9 @@ int HandleInputLine(int argc, char **arg + printf("<?xml version=\"1.0\" encoding=\"%s\"?>\n\n", XML_ENCODING); + printf("<%s>\n", ROOT_TAG); + printf(" <%s>\n", META_TAG); +- printf(" <%s>%lu</%s>\n", META_START_TAG, start, META_START_TAG); ++ printf(" <%s>%lu</%s>\n", META_START_TAG, (unsigned long)start, META_START_TAG); + printf(" <%s>%lu</%s>\n", META_STEP_TAG, step, META_STEP_TAG); +- printf(" <%s>%lu</%s>\n", META_END_TAG, end, META_END_TAG); ++ printf(" <%s>%lu</%s>\n", META_END_TAG, (unsigned long)end, META_END_TAG); + printf(" <%s>%lu</%s>\n", META_ROWS_TAG, row_cnt, META_ROWS_TAG); + printf(" <%s>%lu</%s>\n", META_COLS_TAG, col_cnt, META_COLS_TAG); + printf(" <%s>\n", LEGEND_TAG); +@@ -381,7 +381,7 @@ int HandleInputLine(int argc, char **arg + printf(" <%s>\n", DATA_TAG); + for (i = start; i <= end; i += step) { + printf (" <%s>", DATA_ROW_TAG); +- printf ("<%s>%lu</%s>", COL_TIME_TAG, i, COL_TIME_TAG); ++ printf ("<%s>%lu</%s>", COL_TIME_TAG, (unsigned long)i, COL_TIME_TAG); + for (j = 0; j < col_cnt; j++) { + rrd_value_t newval = DNAN; + newval = *(ptr++); diff --git a/databases/rrdtool/patches/patch-ax b/databases/rrdtool/patches/patch-ax new file mode 100644 index 00000000000..22bb2ca2811 --- /dev/null +++ b/databases/rrdtool/patches/patch-ax @@ -0,0 +1,30 @@ +$NetBSD: patch-ax,v 1.1 2004/02/07 17:44:10 seb Exp $ + +--- contrib/trytime/trytime.c.orig Tue Feb 26 10:21:19 2002 ++++ contrib/trytime/trytime.c +@@ -84,21 +84,21 @@ int main ( int ac, char **av ) + if( *soption ) + printf( "Start time was specified as: '%s',\n" + "for me this means: %s (or %ld sec since epoch)\n\n", +- soption, tim_b, start_tmp ); ++ soption, tim_b, (long) start_tmp ); + else + printf( "Start time was not specified, default value will be used (end-24h)\n" + "for me this means: %s (or %ld sec since epoch)\n\n", +- tim_b, start_tmp ); ++ tim_b, (long)start_tmp ); + + strftime(tim_b,100,"%c %Z",localtime(&end_tmp)); + if( *eoption ) + printf( "End time was specified as: '%s',\n" + "for me this means: %s (or %ld sec since epoch)\n", +- eoption, tim_b, end_tmp ); ++ eoption, tim_b, (long)end_tmp ); + else + printf( "End time was not specified, default value will be used (now)\n" + "for me this means: %s (or %ld sec since epoch)\n\n", +- tim_b, end_tmp ); ++ tim_b, (long)end_tmp ); + exit(0); + } + diff --git a/databases/rrdtool/patches/patch-ay b/databases/rrdtool/patches/patch-ay new file mode 100644 index 00000000000..7076acf4627 --- /dev/null +++ b/databases/rrdtool/patches/patch-ay @@ -0,0 +1,13 @@ +$NetBSD: patch-ay,v 1.1 2004/02/07 17:44:10 seb Exp $ + +--- src/rrd_dump.c.orig Fri Oct 11 18:39:47 2002 ++++ src/rrd_dump.c +@@ -40,7 +40,7 @@ rrd_dump(int argc, char **argv) + # error "Need strftime" + #endif + printf("\t<lastupdate> %ld </lastupdate> <!-- %s -->\n\n", +- rrd.live_head->last_up,somestring); ++ (long)rrd.live_head->last_up,somestring); + for(i=0;i<rrd.stat_head->ds_cnt;i++){ + printf("\t<ds>\n"); + printf("\t\t<name> %s </name>\n",rrd.ds_def[i].ds_nam); |