link-grammar: SunOS build fixes.diff -r1.1 -r1.2 pkgsrc/textproc/link-grammar/Makefile.common
(jperkin)
@@ -1,28 +1,30 @@ | @@ -1,28 +1,30 @@ | |||
1 | # $NetBSD: Makefile.common,v 1.1 2023/10/15 06:39:25 ryoon Exp $ | 1 | # $NetBSD: Makefile.common,v 1.2 2023/12/11 16:32:19 jperkin Exp $ | |
2 | # | 2 | # | |
3 | # used by textproc/link-grammar/Makefile | 3 | # used by textproc/link-grammar/Makefile | |
4 | # used by textproc/py-link-grammar/Makefile | 4 | # used by textproc/py-link-grammar/Makefile | |
5 | 5 | |||
6 | DISTNAME= link-grammar-5.12.3 | 6 | DISTNAME= link-grammar-5.12.3 | |
7 | MASTER_SITES= https://www.abisource.com/downloads/link-grammar/${PKGVERSION_NOREV}/ | 7 | MASTER_SITES= https://www.abisource.com/downloads/link-grammar/${PKGVERSION_NOREV}/ | |
8 | 8 | |||
9 | HOMEPAGE= https://www.abisource.com/projects/link-grammar/ | 9 | HOMEPAGE= https://www.abisource.com/projects/link-grammar/ | |
10 | LICENSE= modified-bsd AND gnu-lgpl-v2.1 | 10 | LICENSE= modified-bsd AND gnu-lgpl-v2.1 | |
11 | 11 | |||
12 | DISTINFO_FILE= ${.CURDIR}/../link-grammar/distinfo | 12 | DISTINFO_FILE= ${.CURDIR}/../link-grammar/distinfo | |
13 | FILESDIR= ${.CURDIR}/../link-grammar/files | 13 | FILESDIR= ${.CURDIR}/../link-grammar/files | |
14 | PATCHDIR= ${.CURDIR}/../link-grammar/patches | 14 | PATCHDIR= ${.CURDIR}/../link-grammar/patches | |
15 | 15 | |||
16 | USE_LANGUAGES= c99 c++ | 16 | USE_LANGUAGES= c99 c++ | |
17 | USE_LIBTOOL= yes | 17 | USE_LIBTOOL= yes | |
18 | USE_TOOLS+= gmake pkg-config | 18 | USE_TOOLS+= gmake pkg-config | |
19 | GNU_CONFIGURE= yes | 19 | GNU_CONFIGURE= yes | |
20 | 20 | |||
21 | CONFIGURE_ARGS+= --disable-java-bindings | 21 | CONFIGURE_ARGS+= --disable-java-bindings | |
22 | 22 | |||
23 | # Not all currently supported compilers provide this option. | 23 | # Not all currently supported compilers provide this option. | |
24 | # The configure script purports to check whether the compiler | 24 | # The configure script purports to check whether the compiler | |
25 | # supports it, but doesn't do so correctly. | 25 | # supports it, but doesn't do so correctly. | |
26 | BUILDLINK_TRANSFORM+= rm:-Wformat-signedness | 26 | BUILDLINK_TRANSFORM+= rm:-Wformat-signedness | |
27 | 27 | |||
28 | CPPFLAGS.SunOS+= -D__EXTENSIONS__ | |||
29 | ||||
28 | .include "../../devel/pcre2/buildlink3.mk" | 30 | .include "../../devel/pcre2/buildlink3.mk" |
@@ -1,9 +1,9 @@ | @@ -1,9 +1,9 @@ | |||
1 | $NetBSD: distinfo,v 1.18 2023/10/15 06:39:25 ryoon Exp $ | 1 | $NetBSD: distinfo,v 1.19 2023/12/11 16:32:19 jperkin Exp $ | |
2 | 2 | |||
3 | BLAKE2s (link-grammar-5.12.3.tar.gz) = 1c08aa63dbed6663544b35888366b1ceb577954e7a5852b9514e7fc2dfc20a95 | 3 | BLAKE2s (link-grammar-5.12.3.tar.gz) = 1c08aa63dbed6663544b35888366b1ceb577954e7a5852b9514e7fc2dfc20a95 | |
4 | SHA512 (link-grammar-5.12.3.tar.gz) = e0fdb78ec03042119011afea005a62829317fd0bc20afcd94e3f234c9c5252ed9c57d717b75368ac4a63dd8493bd86f551870299925f3b9b95b11915f48d8abe | 4 | SHA512 (link-grammar-5.12.3.tar.gz) = e0fdb78ec03042119011afea005a62829317fd0bc20afcd94e3f234c9c5252ed9c57d717b75368ac4a63dd8493bd86f551870299925f3b9b95b11915f48d8abe | |
5 | Size (link-grammar-5.12.3.tar.gz) = 4704751 bytes | 5 | Size (link-grammar-5.12.3.tar.gz) = 4704751 bytes | |
6 | SHA1 (patch-aa) = 3be918c26b639442b56efab2e9416974f31969c5 | 6 | SHA1 (patch-aa) = 3be918c26b639442b56efab2e9416974f31969c5 | |
7 | SHA1 (patch-configure) = 1d6c28dbc3f2bc09214cf70e77e2c6b8bbcfc6e7 | 7 | SHA1 (patch-configure) = 1d6c28dbc3f2bc09214cf70e77e2c6b8bbcfc6e7 | |
8 | SHA1 (patch-link-grammar_parse_extract-links.c) = a4f62310f7d2dca939e17c9a3be55ba2d562b3c3 | 8 | SHA1 (patch-link-grammar_parse_extract-links.c) = 36d45b0c80db537d8c28a5dc4a4348a9044ef3a0 | |
9 | SHA1 (patch-link-grammar_resources.c) = 8c9b2c8cfe88e0e7d7d790094fd0c38e0221b362 | 9 | SHA1 (patch-link-grammar_resources.c) = 8c9b2c8cfe88e0e7d7d790094fd0c38e0221b362 |
@@ -1,13 +1,15 @@ | @@ -1,13 +1,15 @@ | |||
1 | $NetBSD: patch-link-grammar_parse_extract-links.c,v 1.1 2023/10/15 06:39:25 ryoon Exp $ | 1 | $NetBSD: patch-link-grammar_parse_extract-links.c,v 1.2 2023/12/11 16:32:19 jperkin Exp $ | |
2 | ||||
3 | __GNUC__ does not imply malloc_trim() support. | |||
2 | 4 | |||
3 | --- link-grammar/parse/extract-links.c.orig 2023-03-16 18:49:51.000000000 +0000 | 5 | --- link-grammar/parse/extract-links.c.orig 2023-03-16 18:49:51.000000000 +0000 | |
4 | +++ link-grammar/parse/extract-links.c | 6 | +++ link-grammar/parse/extract-links.c | |
5 | @@ -294,7 +294,7 @@ void free_extractor(extractor_t * pex) | 7 | @@ -294,7 +294,7 @@ void free_extractor(extractor_t * pex) | |
6 | 8 | |||
7 | xfree((void *) pex, sizeof(extractor_t)); | 9 | xfree((void *) pex, sizeof(extractor_t)); | |
8 | 10 | |||
9 | -#if defined __GNUC__ | 11 | -#if defined __GNUC__ | |
10 | +#if defined(__GNUC__) && !defined(__NetBSD__) | 12 | +#if defined(__GNUC__) && !defined(__NetBSD__) && !defined(__sun) | |
11 | // malloc_trim() is a gnu extension. An alternative would be | 13 | // malloc_trim() is a gnu extension. An alternative would be | |
12 | // to call madvise(MADV_DONTNEED) but this is more complicated. | 14 | // to call madvise(MADV_DONTNEED) but this is more complicated. | |
13 | if (trim) malloc_trim(0); | 15 | if (trim) malloc_trim(0); |