This is based on what Rui Reis submitted here earlier this month. I'm currently running a full package build with this on i386.
Overriding the GNU m4 check and substituting our m4 will cause the regression tests to blow up. I haven't looked further into this. Index: Makefile =================================================================== RCS file: /cvs/ports/devel/bison/Makefile,v retrieving revision 1.38 diff -u -r1.38 Makefile --- Makefile 26 Jan 2005 16:41:04 -0000 1.38 +++ Makefile 27 Oct 2005 20:42:07 -0000 @@ -2,25 +2,24 @@ COMMENT= "GNU parser generator" -DISTNAME= bison-1.35 -PKGNAME= ${DISTNAME}p1 +DISTNAME= bison-2.1 CATEGORIES= devel MASTER_SITES= ${MASTER_SITE_GNU:=bison/} HOMEPAGE= http://www.gnu.org/software/bison/ -MODULES= devel/gettext - # GPL PERMIT_PACKAGE_CDROM= Yes PERMIT_PACKAGE_FTP= Yes PERMIT_DISTFILES_CDROM= Yes PERMIT_DISTFILES_FTP= Yes -WANTLIB= c -CONFIGURE_STYLE= gnu -CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ - LDFLAGS="-L${LOCALBASE}/lib" -MODGNU_CONFIG_GUESS_DIRS=${WRKSRC}/config +MODULES= devel/gettext +BUILD_DEPENDS= ::devel/m4 +WANTLIB= c + +CONFIGURE_STYLE=gnu +CONFIGURE_ARGS= --disable-yacc +MODGNU_CONFIG_GUESS_DIRS=${WRKSRC}/build-aux .include <bsd.port.mk> Index: distinfo =================================================================== RCS file: /cvs/ports/devel/bison/distinfo,v retrieving revision 1.5 diff -u -r1.5 distinfo --- distinfo 5 Jan 2005 16:22:28 -0000 1.5 +++ distinfo 27 Oct 2005 20:42:07 -0000 @@ -1,4 +1,4 @@ -MD5 (bison-1.35.tar.gz) = e2c06b27f463c6ba19cafbe113d53b1e -RMD160 (bison-1.35.tar.gz) = 92fcd3c974dec80076e2bbcfaa9f73e78a95fefa -SHA1 (bison-1.35.tar.gz) = 83cf06fc56ba2264a5ef1e63678a269dc8de3692 -SIZE (bison-1.35.tar.gz) = 770444 +MD5 (bison-2.1.tar.gz) = b1468d49c1357aebcd1de6ef12cbf3e8 +RMD160 (bison-2.1.tar.gz) = 5c77c0777201bb6a570087c665a7190f924a8b57 +SHA1 (bison-2.1.tar.gz) = b236923e7d4909c6fd8873ac87431833fa45069b +SIZE (bison-2.1.tar.gz) = 1316270 Index: patches/patch-configure =================================================================== RCS file: /cvs/ports/devel/bison/patches/patch-configure,v retrieving revision 1.1 diff -u -r1.1 patch-configure --- patches/patch-configure 13 May 2003 00:12:37 -0000 1.1 +++ patches/patch-configure 27 Oct 2005 20:42:07 -0000 @@ -1,37 +1,16 @@ $OpenBSD: patch-configure,v 1.1 2003/05/13 00:12:37 naddy Exp $ ---- configure.orig Mon May 12 16:37:29 2003 -+++ configure Mon May 12 16:42:29 2003 -@@ -9649,7 +9649,6 @@ else - #include "confdefs.h" - #include <libintl.h> - extern int _nl_msg_cat_cntr; --extern int *_nl_domain_bindings; - extern - #ifdef __cplusplus - "C" -@@ -9665,7 +9664,7 @@ int - main () - { - bindtextdomain ("", ""); --return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_domain_bindings + *_nl_expand_alias (0) -+return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) - ; - return 0; - } -@@ -9696,7 +9695,6 @@ rm -f conftest.$ac_objext conftest$ac_ex - #include "confdefs.h" - #include <libintl.h> - extern int _nl_msg_cat_cntr; --extern int *_nl_domain_bindings; - extern - #ifdef __cplusplus - "C" -@@ -9712,7 +9710,7 @@ int - main () - { - bindtextdomain ("", ""); --return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_domain_bindings + *_nl_expand_alias (0) -+return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) - ; - return 0; - } +--- configure.orig Thu Oct 27 20:27:44 2005 ++++ configure Thu Oct 27 20:28:03 2005 +@@ -15190,10 +15190,10 @@ s,@host_cpu@,$host_cpu,;t t + s,@host_vendor@,$host_vendor,;t t + s,@host_os@,$host_os,;t t + s,@INTL_MACOSX_LIBS@,$INTL_MACOSX_LIBS,;t t +-s,@LIBICONV@,$LIBICONV,;t t ++s,@LIBICONV@,$LTLIBICONV,;t t + s,@LTLIBICONV@,$LTLIBICONV,;t t + s,@INTLLIBS@,$INTLLIBS,;t t +-s,@LIBINTL@,$LIBINTL,;t t ++s,@LIBINTL@,$LTLIBINTL,;t t + s,@LTLIBINTL@,$LTLIBINTL,;t t + s,@POSUB@,$POSUB,;t t + s,@BISON_LOCALEDIR@,$BISON_LOCALEDIR,;t t Index: patches/patch-doc_bison_texinfo =================================================================== RCS file: patches/patch-doc_bison_texinfo diff -N patches/patch-doc_bison_texinfo --- patches/patch-doc_bison_texinfo 13 Jul 2001 01:55:59 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,12 +0,0 @@ -$OpenBSD: patch-doc_bison_texinfo,v 1.1 2001/07/13 01:55:59 brad Exp $ ---- doc/bison.texinfo.orig Thu Jul 12 21:05:58 2001 -+++ doc/bison.texinfo Thu Jul 12 21:06:40 2001 -@@ -38,7 +38,7 @@ - @ifinfo - @format - START-INFO-DIR-ENTRY --* bison: (bison). GNU Project parser generator (yacc replacement). -+* bison: (bison). GNU Project parser generator (yacc replacement). - END-INFO-DIR-ENTRY - @end format - @end ifinfo Index: patches/patch-lib_Makefile_in =================================================================== RCS file: patches/patch-lib_Makefile_in diff -N patches/patch-lib_Makefile_in --- patches/patch-lib_Makefile_in 18 Jan 2003 20:34:35 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,46 +0,0 @@ -$OpenBSD: patch-lib_Makefile_in,v 1.1 2003/01/18 20:34:35 pvalchev Exp $ ---- lib/Makefile.in.orig Mon Mar 25 02:38:27 2002 -+++ lib/Makefile.in Sat Jan 18 13:15:29 2003 -@@ -120,7 +120,6 @@ EXTRA_DIST = malloc.c realloc.c strnlen. - - libbison_a_SOURCES = \ - basename.c dirname.h dirname.c \ -- getopt.h getopt.c getopt1.c \ - quote.h quote.c quotearg.h quotearg.c \ - xalloc.h xmalloc.c xstrdup.c xstrndup.c gettext.h - -@@ -135,7 +134,7 @@ LIBRARIES = $(noinst_LIBRARIES) - - libbison_a_AR = $(AR) cru - am_libbison_a_OBJECTS = basename$U.$(OBJEXT) dirname$U.$(OBJEXT) \ -- getopt$U.$(OBJEXT) getopt1$U.$(OBJEXT) quote$U.$(OBJEXT) \ -+ quote$U.$(OBJEXT) \ - quotearg$U.$(OBJEXT) xmalloc$U.$(OBJEXT) xstrdup$U.$(OBJEXT) \ - xstrndup$U.$(OBJEXT) - libbison_a_OBJECTS = $(am_libbison_a_OBJECTS) -@@ -153,7 +152,6 @@ am__depfiles_maybe = depfiles - @AMDEP_TRUE@ $(DEPDIR)/realloc.Po $(DEPDIR)/stpcpy.Po \ - @AMDEP_TRUE@ $(DEPDIR)/strchr.Po $(DEPDIR)/strspn.Po \ - @AMDEP_TRUE@ ./$(DEPDIR)/basename$U.Po ./$(DEPDIR)/dirname$U.Po \ [EMAIL PROTECTED]@ ./$(DEPDIR)/getopt$U.Po ./$(DEPDIR)/getopt1$U.Po \ - @AMDEP_TRUE@ ./$(DEPDIR)/quote$U.Po ./$(DEPDIR)/quotearg$U.Po \ - @AMDEP_TRUE@ ./$(DEPDIR)/xmalloc$U.Po ./$(DEPDIR)/xstrdup$U.Po \ - @AMDEP_TRUE@ ./$(DEPDIR)/xstrndup$U.Po -@@ -215,8 +213,6 @@ mostlyclean-kr: - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED](DEPDIR)/[EMAIL PROTECTED]@ - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ [EMAIL PROTECTED]@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ [EMAIL PROTECTED]@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ - @AMDEP_TRUE@@am__include@ @[EMAIL PROTECTED]/$(DEPDIR)/[EMAIL PROTECTED]@ -@@ -277,7 +273,7 @@ xstrdup_.c: xstrdup.c $(ANSI2KNR) - xstrndup_.c: xstrndup.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/xstrndup.c; then echo $(srcdir)/xstrndup.c; else echo xstrndup.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > xstrndup_.c || rm -f xstrndup_.c - alloca_.$(OBJEXT) basename_.$(OBJEXT) dirname_.$(OBJEXT) \ --error_.$(OBJEXT) getopt_.$(OBJEXT) getopt1_.$(OBJEXT) malloc_.$(OBJEXT) \ -+error_.$(OBJEXT) malloc_.$(OBJEXT) \ - memchr_.$(OBJEXT) memrchr_.$(OBJEXT) obstack_.$(OBJEXT) \ - quote_.$(OBJEXT) quotearg_.$(OBJEXT) realloc_.$(OBJEXT) \ - stpcpy_.$(OBJEXT) strchr_.$(OBJEXT) strspn_.$(OBJEXT) \ Index: patches/patch-src_getargs_c =================================================================== RCS file: patches/patch-src_getargs_c diff -N patches/patch-src_getargs_c --- patches/patch-src_getargs_c 18 Jan 2003 20:34:35 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,12 +0,0 @@ -$OpenBSD: patch-src_getargs_c,v 1.1 2003/01/18 20:34:35 pvalchev Exp $ ---- src/getargs.c.orig Sat Jan 18 13:08:53 2003 -+++ src/getargs.c Sat Jan 18 13:09:00 2003 -@@ -19,7 +19,7 @@ - 02111-1307, USA. */ - - #include <stdio.h> --#include "getopt.h" -+#include <getopt.h> - #include "system.h" - #include "files.h" - #include "complain.h" Index: patches/patch-src_output_c =================================================================== RCS file: patches/patch-src_output_c diff -N patches/patch-src_output_c --- patches/patch-src_output_c 16 Oct 2003 22:22:00 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,12 +0,0 @@ -$OpenBSD: patch-src_output_c,v 1.1 2003/10/16 22:22:00 brad Exp $ ---- src/output.c.orig 2003-10-16 18:14:27.000000000 -0400 -+++ src/output.c 2003-10-16 18:15:10.000000000 -0400 -@@ -493,7 +493,7 @@ output_rule_data (void) - - XFREE (short_tab); - -- XFREE (rule_table + 1); -+ XFREE (rule_table); - } - - Index: patches/patch-src_reader_c =================================================================== RCS file: patches/patch-src_reader_c diff -N patches/patch-src_reader_c --- patches/patch-src_reader_c 16 Oct 2003 22:22:00 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,12 +0,0 @@ -$OpenBSD: patch-src_reader_c,v 1.1 2003/10/16 22:22:00 brad Exp $ ---- src/reader.c.orig 2003-10-16 18:15:34.000000000 -0400 -+++ src/reader.c 2003-10-16 18:16:12.000000000 -0400 -@@ -1897,7 +1897,7 @@ packgram (void) - symbol_list *p; - - ritem = XCALLOC (short, nitems + 1); -- rule_table = XCALLOC (rule_t, nrules) - 1; -+ rule_table = XCALLOC (rule_t, nrules + 1); - - itemno = 0; - ruleno = 1; Index: pkg/PLIST =================================================================== RCS file: /cvs/ports/devel/bison/pkg/PLIST,v retrieving revision 1.7 diff -u -r1.7 PLIST --- pkg/PLIST 9 Aug 2004 00:21:29 -0000 1.7 +++ pkg/PLIST 27 Oct 2005 20:42:07 -0000 @@ -2,16 +2,63 @@ bin/bison @info info/bison.info @man man/man1/bison.1 +share/aclocal/bison-i18n.m4 share/bison/ -share/bison/bison.hairy -share/bison/bison.simple +share/bison/README +share/bison/c++.m4 +share/bison/c.m4 +share/bison/glr.c +share/bison/lalr1.cc +share/bison/m4sugar/ +share/bison/m4sugar/m4sugar.m4 +share/bison/yacc.c +share/locale/da/LC_MESSAGES/bison-runtime.mo +share/locale/da/LC_MESSAGES/bison.mo +share/locale/de/LC_MESSAGES/bison-runtime.mo share/locale/de/LC_MESSAGES/bison.mo +share/locale/es/LC_MESSAGES/bison-runtime.mo share/locale/es/LC_MESSAGES/bison.mo +share/locale/et/LC_MESSAGES/bison-runtime.mo share/locale/et/LC_MESSAGES/bison.mo +share/locale/fr/LC_MESSAGES/bison-runtime.mo share/locale/fr/LC_MESSAGES/bison.mo +share/locale/ga/ +share/locale/ga/LC_MESSAGES/ +share/locale/ga/LC_MESSAGES/bison-runtime.mo +share/locale/ga/LC_MESSAGES/bison.mo +share/locale/hr/LC_MESSAGES/bison-runtime.mo +share/locale/hr/LC_MESSAGES/bison.mo +share/locale/id/LC_MESSAGES/bison-runtime.mo +share/locale/id/LC_MESSAGES/bison.mo +share/locale/it/LC_MESSAGES/bison-runtime.mo share/locale/it/LC_MESSAGES/bison.mo +share/locale/ja/LC_MESSAGES/bison-runtime.mo share/locale/ja/LC_MESSAGES/bison.mo +share/locale/ms/ +share/locale/ms/LC_MESSAGES/ +share/locale/ms/LC_MESSAGES/bison-runtime.mo +share/locale/ms/LC_MESSAGES/bison.mo +share/locale/nb/LC_MESSAGES/bison-runtime.mo +share/locale/nb/LC_MESSAGES/bison.mo +share/locale/nl/LC_MESSAGES/bison-runtime.mo share/locale/nl/LC_MESSAGES/bison.mo +share/locale/pl/LC_MESSAGES/bison-runtime.mo +share/locale/pl/LC_MESSAGES/bison.mo +share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo +share/locale/pt_BR/LC_MESSAGES/bison.mo +share/locale/ro/LC_MESSAGES/bison-runtime.mo +share/locale/ro/LC_MESSAGES/bison.mo +share/locale/ru/LC_MESSAGES/bison-runtime.mo share/locale/ru/LC_MESSAGES/bison.mo +share/locale/rw/ +share/locale/rw/LC_MESSAGES/ +share/locale/rw/LC_MESSAGES/bison-runtime.mo +share/locale/rw/LC_MESSAGES/bison.mo +share/locale/sv/LC_MESSAGES/bison-runtime.mo share/locale/sv/LC_MESSAGES/bison.mo +share/locale/tr/LC_MESSAGES/bison-runtime.mo share/locale/tr/LC_MESSAGES/bison.mo +share/locale/vi/ +share/locale/vi/LC_MESSAGES/ +share/locale/vi/LC_MESSAGES/bison-runtime.mo +share/locale/vi/LC_MESSAGES/bison.mo -- Christian "naddy" Weisgerber [EMAIL PROTECTED]