pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/geography/garmin-utils On Linux, define NEEDS_STRLCPY ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/a58dc61c2e39
branches:  trunk
changeset: 554968:a58dc61c2e39
user:      gdt <gdt%pkgsrc.org@localhost>
date:      Sun Feb 22 22:07:52 2009 +0000

description:
On Linux, define NEEDS_STRLCPY in MAKE_ENV.

In the patched Makefile, switch on NEEDS_STRLCPY instead of OPSYS,
because OPSYS isn't defined in my world (vanilla netbsd-5 on i386),
and I can't find any reason it should be.

Add a comment to the patch explaining why the install: target was
removed, and about NEEDS_STRLCPY.

diffstat:

 geography/garmin-utils/Makefile         |  15 ++++++++++-----
 geography/garmin-utils/distinfo         |   4 ++--
 geography/garmin-utils/patches/patch-aa |  12 ++++++++++--
 3 files changed, 22 insertions(+), 9 deletions(-)

diffs (87 lines):

diff -r 1e2b579b724a -r a58dc61c2e39 geography/garmin-utils/Makefile
--- a/geography/garmin-utils/Makefile   Sun Feb 22 20:57:42 2009 +0000
+++ b/geography/garmin-utils/Makefile   Sun Feb 22 22:07:52 2009 +0000
@@ -1,35 +1,40 @@
-# $NetBSD: Makefile,v 1.11 2009/02/22 20:57:25 gdt Exp $
+# $NetBSD: Makefile,v 1.12 2009/02/22 22:07:52 gdt Exp $
 #
 
 DISTNAME=              garmin-utils-2.5
+PKGREVISION=           1
 CATEGORIES=            geography
 MASTER_SITES=          ftp://ftp.snafu.org/pub/
 
 MAINTAINER=            gson%NetBSD.org@localhost
+# also gdt%NetBSD.org@localhost is helping
 HOMEPAGE=              http://www.snafu.org/
 COMMENT=               Utilities for Garmin GPS receivers
 
 PKG_DESTDIR_SUPPORT=   user-destdir
 
+# This seems excessive; on other ones it can be made to work.
 ONLY_FOR_PLATFORM=     NetBSD-*-* Linux-*-*
 
 INSTALLATION_DIRS=     bin lib ${PKGMANDIR}/cat1 ${PKGMANDIR}/man1
 
 USE_BSD_MAKEFILE=      yes
 
+MAKE_JOBS_SAFE=                no
+
 # No actual serial port will be right for any significant number of users,
 # so make everyone use a symlink.
 MAKE_FLAGS+=           GPS_SERIAL_PORT=/dev/gps
 
-MAKE_JOBS_SAFE=                no
-
 .include "../../mk/bsd.prefs.mk"
 
 CPPFLAGS.Linux=                -DLINUX
 
 .if ${OPSYS} == "Linux"
-MAKE_FLAGS+=   SIO_TYPE=-DSIO_TYPE=Linux \
-               NEEDS_STRLCPY=1
+MAKE_FLAGS+=   SIO_TYPE=-DSIO_TYPE=Linux
+
+# On Linux, libc apparently does not have strlcpy.
+MAKE_FLAGS+=   NEEDS_STRLCPY=1
 .endif
 
 .include "../../mk/bsd.pkg.mk"
diff -r 1e2b579b724a -r a58dc61c2e39 geography/garmin-utils/distinfo
--- a/geography/garmin-utils/distinfo   Sun Feb 22 20:57:42 2009 +0000
+++ b/geography/garmin-utils/distinfo   Sun Feb 22 22:07:52 2009 +0000
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.10 2009/02/22 20:57:25 gdt Exp $
+$NetBSD: distinfo,v 1.11 2009/02/22 22:07:52 gdt Exp $
 
 SHA1 (garmin-utils-2.5.tar.gz) = 1b7ee9936a691bf5e5466a3efd052f71dd3cb63c
 RMD160 (garmin-utils-2.5.tar.gz) = c32dd4b9efaef80fb203059ac399e52d0cd86fbe
 Size (garmin-utils-2.5.tar.gz) = 174336 bytes
-SHA1 (patch-aa) = 650305540171cea6b77b52acbffe89fd76901d20
+SHA1 (patch-aa) = 3a04f974bd0eae012977dc3a8090b19032463ce7
diff -r 1e2b579b724a -r a58dc61c2e39 geography/garmin-utils/patches/patch-aa
--- a/geography/garmin-utils/patches/patch-aa   Sun Feb 22 20:57:42 2009 +0000
+++ b/geography/garmin-utils/patches/patch-aa   Sun Feb 22 22:07:52 2009 +0000
@@ -1,4 +1,12 @@
-$NetBSD: patch-aa,v 1.5 2009/02/21 14:53:43 gdt Exp $
+$NetBSD: patch-aa,v 1.6 2009/02/22 22:07:52 gdt Exp $
+
+Remove empty install target, to let the standard rules install the
+library.
+
+If NEEDS_STRLCPY is defined in the make environment, as it will be on
+at least Linux, compile and link with the provided version of strlcpy.
+
+As of 2009-02-22 neither patch has been sent upstream.
 
 --- lib/Makefile.orig  2009-01-13 20:50:30.000000000 +0100
 +++ lib/Makefile
@@ -7,7 +15,7 @@
                gpsprint.c gpsversion.c gpsformat.c gpsload.c gpsfloat.c
  
 -install:
-+.if defined(OPSYS) && ${OPSYS} == "Linux"
++.if defined(NEEDS_STRLCPY)
 +SRCS+=                strlcpy.c
 +.endif
  



Home | Main Index | Thread Index | Old Index