Buildlinkify, don't use perl, sed is good enough, install examples into

share/examples hierarchy, standardize patch names, remove FreeBSDisms
from PLIST.
This commit is contained in:
wiz 2001-10-18 11:39:23 +00:00
parent 65b8671918
commit 949c83c065
7 changed files with 39 additions and 51 deletions

View file

@ -1,5 +1,5 @@
# $NetBSD: Makefile,v 1.1 2001/10/18 11:13:56 darcy Exp $
# FreeBSD Id: ports/graphics/gdchart/Makefile,v 1.5 2001/10/07 02:03:41 petef Exp
# $NetBSD: Makefile,v 1.2 2001/10/18 11:39:23 wiz Exp $
#
DISTNAME= gdchart0.10.1dev
PKGNAME= gdchart-0.10.1
@ -11,13 +11,16 @@ MAINTAINER= packages@netbsd.org
HOMEPAGE= http://www.fred.net/brv/chart/
COMMENT= Easy to use, fast C API for creating charts and graphs
DEPENDS= gd-1.8*:../../graphics/gd
MAKEFILE= makefile
WRKSRC= ${WRKDIR}/${DISTNAME}
USE_BUILDLINK_ONLY= YES
post-patch:
${PERL5} -i -pe 's/^#ifdef HAVE_JPEG/#ifndef NO_JPEG/' ${WRKSRC}/*.[ch]
for fn in ${WRKSRC}/*.[ch]; do \
${SED} 's/^#ifdef HAVE_JPEG/#ifndef NO_JPEG/' $${fn} \
> $${fn}.new; \
${MV} $${fn}.new $${fn}; \
done
do-install:
${INSTALL_DATA} ${WRKSRC}/libgdchart.a ${PREFIX}/lib
@ -27,16 +30,13 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/gifencode.h ${PREFIX}/include
post-install:
@${INSTALL} -d -m 0755 ${PREFIX}/share/doc/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_samp1.c ${PREFIX}/share/doc/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_samp2.c ${PREFIX}/share/doc/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_pie_samp.c ${PREFIX}/share/doc/gdchart
${INSTALL_DATA_DIR} -d -m 0755 ${PREFIX}/share/doc/gdchart
${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/gdchart
@${ECHO} "================================================================================"
@${ECHO} "Have a look at the sample code and README in ${PREFIX}/share/doc/${PORTNAME}."
@${ECHO} "To compile gdc_samp1, try something like:"
@${ECHO}
@${ECHO} "gcc -I${PREFIX}/include -o gdc_samp1 gdc_samp1.c -L${PREFIX}/lib -lgdchart -lgd"
@${ECHO} "================================================================================"
${INSTALL_DATA_DIR} -d -m 0755 ${PREFIX}/share/examples/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_samp1.c ${PREFIX}/share/examples/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_samp2.c ${PREFIX}/share/examples/gdchart
${INSTALL_DATA} ${WRKSRC}/gdc_pie_samp.c \
${PREFIX}/share/examples/gdchart
.include "../../graphics/gd/buildlink.mk"
.include "../../mk/bsd.pkg.mk"

View file

@ -1,7 +1,9 @@
$NetBSD: distinfo,v 1.1 2001/10/18 11:13:56 darcy Exp $
$NetBSD: distinfo,v 1.2 2001/10/18 11:39:23 wiz Exp $
SHA1 (gdchart0.10.1dev.tar.gz) = 52edc97cb45fc441afc4728c812cd33ddab9ef5c
Size (gdchart0.10.1dev.tar.gz) = 40708 bytes
SHA1 (patch-gdc.h) = 21876306acb359b4487cf35bf871b67e68778f0e
SHA1 (patch-gdchart.c) = b64571899b38ef026af076c6876af20c74b98ab8
SHA1 (patch-makefile) = 5988ea7896ac6cb6aad87c7a42626b9a0c68c400
SHA1 (patch-aa) = 6755bc77ee3e5bfb4dc92459d41f6ad4f8f76e75
SHA1 (patch-ab) = 100c284c8f9400785ef9eff42c81a9f13d73c1e5
SHA1 (patch-ac) = 766c3880e3ac842889b310d38e96b907adb59e92

View file

@ -1,7 +1,7 @@
$NetBSD: patch-gdc.h,v 1.1 2001/10/18 11:13:56 darcy Exp $
$NetBSD: patch-aa,v 1.1 2001/10/18 11:39:24 wiz Exp $
--- gdc.h.orig Mon Jun 18 00:51:01 2001
+++ gdc.h Mon Jun 18 00:51:16 2001
--- gdc.h.orig Sat Nov 4 02:49:46 2000
+++ gdc.h
@@ -9,7 +9,7 @@
#define _GDC_H

View file

@ -1,7 +1,7 @@
$NetBSD: patch-gdchart.c,v 1.1 2001/10/18 11:13:56 darcy Exp $
$NetBSD: patch-ab,v 1.1 2001/10/18 11:39:24 wiz Exp $
--- gdchart.c.orig Sat Nov 4 02:49:46 2000
+++ gdchart.c Mon Jun 18 00:56:42 2001
+++ gdchart.c
@@ -664,7 +664,7 @@
if( GDC_xaxis && xlbl )

View file

@ -1,18 +1,7 @@
$NetBSD: patch-makefile,v 1.1 2001/10/18 11:13:56 darcy Exp $
$NetBSD: patch-ac,v 1.1 2001/10/18 11:39:24 wiz Exp $
--- makefile.orig Sat Nov 4 02:49:46 2000
+++ makefile Tue Jul 17 01:42:30 2001
@@ -2,8 +2,8 @@
GDC_LIB = .
# GDChart requires the gd library - www.boutell.com/gd/
-GD_INCL = ../gd-1.8.3
-GD_LIB = ../gd-1.8.3
+GD_INCL = $(LOCALBASE)/include
+GD_LIB = $(LOCALBASE)/lib
# libgd requires libpng
# PNG_INCL = ../libpng-1.0.8
+++ makefile
@@ -23,6 +23,8 @@
# if not installed in standard paths (/lib, /usr/lib), or LD_LIBRARY_PATH
# LIB_PATHS = -L$(GD_LIB) -L$(PNG_LIB) -L$(ZLIB_LIB) -L$(JPEG_LIB)
@ -92,7 +81,7 @@ $NetBSD: patch-makefile,v 1.1 2001/10/18 11:13:56 darcy Exp $
# --- compile the lib ---
gifencode.o: gifencode.c gifencode.h
- $(CC) -I$(GD_INCL) -c gifencode.c
+ $(CC) $(CFLAGS) -I$(GD_INCL) -c gifencode.c
+ $(CC) $(CFLAGS) -c gifencode.c
price_conv.o: price_conv.c
- $(CC) -c price_conv.c
@ -100,15 +89,15 @@ $NetBSD: patch-makefile,v 1.1 2001/10/18 11:13:56 darcy Exp $
gdc.o: gdc.c $(GDC_INCL)/gdc.h $(GDC_INCL)/gifencode.h
- $(CC) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdc.c
+ $(CC) $(CFLAGS) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdc.c
+ $(CC) $(CFLAGS) $(JPEG_DEF) -c gdc.c
gdc_pie.o: $(GDC_INCL)/gdc.h $(GDC_INCL)/gifencode.h $(GDC_INCL)/gdcpie.h gdc_pie.c
- $(CC) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdc_pie.c
+ $(CC) $(CFLAGS) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdc_pie.c
+ $(CC) $(CFLAGS) $(JPEG_DEF) -c gdc_pie.c
gdchart.o: $(GDC_INCL)/gdc.h $(GDC_INCL)/gifencode.h $(GDC_INCL)/gdchart.h gdchart.c
- $(CC) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdchart.c
+ $(CC) $(CFLAGS) -I$(GD_INCL) -I$(GDC_INCL) $(JPEG_DEF) -c gdchart.c
+ $(CC) $(CFLAGS) $(JPEG_DEF) -c gdchart.c
# --- supporting libraries ---
# should be compile & installed separately

View file

@ -1,6 +1,2 @@
GDChart is an easy to use, high performance library/C API for creating charts
and graphs in GIF, PNG, JPEG and WBMP format.
WWW: http://www.fred.net/brv/chart/
- Anders Nordby <anders@fix.no>

View file

@ -1,11 +1,12 @@
@comment $NetBSD: PLIST,v 1.1 2001/10/18 11:13:57 darcy Exp $
lib/libgdchart.a
@comment $NetBSD: PLIST,v 1.2 2001/10/18 11:39:25 wiz Exp $
include/gdchart.h
include/gdc.h
include/gdcpie.h
include/gifencode.h
${PORTDOCS}share/doc/gdchart/gdc_samp1.c
${PORTDOCS}share/doc/gdchart/gdc_samp2.c
${PORTDOCS}share/doc/gdchart/gdc_pie_samp.c
${PORTDOCS}share/doc/gdchart/README
${PORTDOCS}@dirrm share/doc/gdchart
lib/libgdchart.a
share/doc/gdchart/README
share/examples/gdchart/gdc_samp1.c
share/examples/gdchart/gdc_samp2.c
share/examples/gdchart/gdc_pie_samp.c
@dirrm share/examples/gdchart
@dirrm share/doc/gdchart